如何在ZSI,Python中向SOAP请求添加wsse:Security,UsernameToken标头?

Sri*_*nth 5 python ws-security zsi usernametoken

有没有办法在ZSI,Python中的SOAP请求中添加wsse:Security,UsernameToken标头?我在网上搜索,但找不到答案.

Sri*_*nth 4

经过进一步搜索,我确信并计划使用 suds,https://fedorahosted.org/suds/,它似乎用户友好,功能丰富,并提供了将 UsernameToken 添加到 SOAP 标头的类和方法。

Suds 有关 WS-Security 的文档:https://fedorahosted.org/suds/wiki/Documentation#WS-SECURITY