Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

TclSOAP Authorization

17 views
Skip to first unread message

Adrian Wiechec

unread,
Aug 24, 2006, 8:01:54 AM8/24/06
to
I'm writing a small client for the Fedora Digital Repository
System (http://fedora.info), which exports its methods
via SOAP interface.
For some reason I can't get SOAP authorization
in TCL to work: the server keeps responding
with 'Authentication failed'.

The following code in PHP works perfectly
(proving that there's no problem with server setup):

$client = new SoapClient(NULL,
array('location' => 'http://hostname:8080/fedora/services/management',
'uri' => 'http://tempuri.org/dummy',
'login' => 'mylogin',
'password' => 'mypassword'));
$result = $client->__soapCall("getNextPID", array('numPids' => '1',
'pidNamespace' => 'demo'));

but the following code in TCL does not:

SOAP::configure -transport http \
-headers [list "Authorization" "Basic [base64::encode mylogin:mypassword]" ]
SOAP::create getNextPID \
-uri http://tempuri.org/dummy \
-proxy http://hostname:8080/fedora/services/management/ \
-params {"numPids" "string" "pidNamespace" "string"} \
-name getNextPID
getNextPID 1 demo

Can anybody tell me what I'm doing wrong?

rag

tomk

unread,
Aug 30, 2006, 7:53:55 PM8/30/06
to

I don't know anything about fadora, but when I do a SOAP::create I
don't use the -name option. Perhaps it is causing you a problem.
Tom K.

Gerald W. Lester

unread,
Aug 30, 2006, 8:46:28 PM8/30/06
to

Sorry for the delay, been out of pocket.

I looked at the WSDLs defined at http://www.fedora.info/definitions/1/0/api/
and don't see anything about the auth header that is needed.

Could you post the link to the particular WSDL?

Also you might try using the WS::Client package, see
http://members.cox.net/gerald.lester/WebServicesForTcl.html.


--
+--------------------------------+---------------------------------------+
| Gerald W. Lester |
|"The man who fights for his ideals is the man who is alive." - Cervantes|
+------------------------------------------------------------------------+

0 new messages