【发布时间】:2011-10-01 03:12:01
【问题描述】:
我正在使用 Python 的 SUDs 库来访问 Sharepoint Web 服务。 我遵循了 Suds 网站上的标准文档。 这2天,无论我访问哪个服务,远程服务总是返回403 Forbidden。
我使用的是 Suds 0.4,因此它内置了对访问 Python NTLM 的支持。
如果有人对此有任何线索,请告诉我。
from suds import transport
from suds import client
from suds.transport.https import WindowsHttpAuthenticated
import logging
logging.basicConfig(level=logging.INFO)
logging.getLogger('suds.client').setLevel(logging.DEBUG)
ntlm = WindowsHttpAuthenticated(username='USER_ID', password='PASS')
c_lists = client.Client(url='https://SHAREPOINT_URL/_vti_bin/Lists.asmx?WSDL', transport=ntlm)
#c_lists = client.Client(url='https://SHAREPOINT_URL/_vti_bin/spsearch.asmx?WSDL')
#print c_lists
listsCollection = c_lists.service.GetListCollection()
【问题讨论】:
标签: python sharepoint suds