[Fedora-suds-list] https authentication failing

Bruce Edge bruce.edge at gmail.com
Sat Jun 20 00:02:18 UTC 2009


I'm having a problem with https basic authentication

Is there something I'm doing wrong here?

security = Security()
token = UsernameToken('username', 'password')
security.tokens.append(token)
url = 'https://targetboc:8443/service-war/dpmcore?wsdl'
c = Client(url, wsse=security)
print c.service

# OK so far

c.service.getOemKey(wsse=security)

# fails with

Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "wsenv.py", line 22, in <module>
    c.service.getOemKey(wsse=security)
  File "suds/client.py", line 240, in __call__
    return target.call(*args, **kwargs)
  File "suds/client.py", line 379, in call
    return method(*args, **kwargs)
  File "suds/client.py", line 240, in __call__
    return target.call(*args, **kwargs)
  File "suds/client.py", line 422, in call
    return client.invoke(args, kwargs)
  File "suds/client.py", line 480, in invoke
    result = self.send(msg)
  File "suds/client.py", line 504, in send
    reply = transport.send(request)
  File "suds/transport/https.py", line 64, in send
    return HttpTransport.send(self, request)
  File "suds/transport/http.py", line 78, in send
    fp = self.__open(u2request)
  File "suds/transport/http.py", line 99, in __open
    return self.urlopener.open(u2request)
  File "/usr/lib/python2.6/urllib2.py", line 383, in open
    response = self._open(req, data)
  File "/usr/lib/python2.6/urllib2.py", line 401, in _open
    '_open', req)
  File "/usr/lib/python2.6/urllib2.py", line 361, in _call_chain
    result = func(*args)
  File "/usr/lib/python2.6/urllib2.py", line 1138, in https_open
    return self.do_open(httplib.HTTPSConnection, req)
  File "/usr/lib/python2.6/urllib2.py", line 1105, in do_open
    raise URLError(err)
URLError: <urlopen error [Errno 111] Connection refused>
>>>

I tried the beta with the same result.

I know the service is OK because I can do this:

 curl -ku username:password
https://localhost:8443/service-war/dpmcore/getOemKey
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><getOemKeyResponse
xmlns="http://lsi.com/dpm/core/types"
xmlns:ns2="http://lsi.com/dpm/types"><oemKey>LSI</oemKey></getOemKeyResponse></soap:Body></soap:Envelope>



Thanks, Bruce
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/fedora-suds-list/attachments/20090619/4b9ee7d4/attachment.htm>


More information about the fedora-suds-list mailing list