Tag: 洗出来

rails通过肥皂基本认证与savon

我正在尝试使用savon gem发送带有基本身份validation的soap请求 我的soap服务器设置了wash_out gem class OrdersController < ApplicationController soap_service namespace: 'sir:WashOut', wsse_username: SIRA[:auth][:username], wsse_password: SIRA[:auth][:password] …. 当我通过savon向soap服务器发出请求时出现错误: @client = Savon.client( wsdl: “http://localhost:3000/orders/wsdl”, soap_header: { ‘Username’ =>SIRA[:auth][:username], ‘Password’ => SIRA[:auth][:password] } ) @response = @client.call(:notify ).to_hash 在最后一个命令我得到一个错误 Savon::SOAPFault: (Server) Missing required UsernameToken