gSoap身份认证

按照onvif协议要求,要想将用户名密码发送给球机,把gSoap源码中的如下源文件加入到工程中:
duration.c
duration.h
mecevp.c
mecevp.h
smdevp.c
smdevp.h
threads.c
threads.h
wsaapi.c
wsaapi.h
wsseapi.c
wsseapi.h
在客户端代码中,加入:

1
2
3
4
5
6
#include "wsaapi.h"
#include "wsseapi.h"
...
struct soap soapCtx;
...
soap_wsse_add_UsernameTokenDigest(&soapCtx, NULL, userName, passwd);