本帖最后由 jimcold 于 2012-02-03 14:10:11 编辑

解决方案 »

  1.   

    下面是目标的xml结构:
    POST /Services/UserService.asmx HTTP/1.1
    Host: interface.edu24ol.com
    Content-Type: text/xml; charset=utf-8
    Content-Length: length
    SOAPAction: "http://www.edu24ol.com/UserLogin"<?xml version="1.0" encoding="utf-8"?>
    <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
      <soap:Body>
        <UserLogin xmlns="http://www.edu24ol.com/">
          <accountId>string</accountId>
          <password>string</password>
          <accountType>string</accountType>
          <encRet>string</encRet>
        </UserLogin>
      </soap:Body>
    </soap:Envelope>
    问题是我的程序连接是成功了,也收到目标的返回信息,不过返回的消息提示是目标方定义的信息有误代码,目标方也给出参数有误的可能原因
    1,传递的参数有空值
    2,加密字符串有错误,解密后跟accountid不对应
    我对web的东西不是太熟悉,请哪位大侠帮忙看看,感激不尽
      

  2.   

    肯定是数据填充的问题了,应该是加密那块,服务器需要的是unicode形式的,不过我加密的是单字节字符串,该怎么改呢