Re: Denied access question

Duncan Cameron <[email protected]>
Newsgroups gmane.comp.windows.devel.soap.general
Organization At Home
Message-ID <20020822200816.DXVI23840.mta03-svc.ntlworld.com@pavilion-8670>
On 2002-08-21 Robert Field wrote:
>Let me start with I'm new at this stuff, but this doesn't make sense to
>me. I'm using SOAP::Lite with a static dispatch to my module MyAPI which I
>will be passing in a bunch of xml:
>
>use SOAP::Transport::HTTP
>use MyAPI;
>
>SOAP::Transport::HTTP::CGI
>  -> dispatch_to('MyAPI')
>  -> handle;
>
>In MyAPI.pm, I have a createAccount() method, but when my client sends a
>request to the server, I get back:
>
>Denied access to method (createAccount) in class (main) at ...
>
>So why is it complaining about class main?  No matter what SOAPAction my
>client specifies, I get back:
>
>SOAPAction shall match uri#method if present, expected '#createAccount'
>
>unless the SOAPAction is exactly '#createAccount'.  I'm obviously missing
>something.
>
>--Rob Field

In your client (if it's Perl) you need something like

my $s = SOAP::Lite
  ->uri('urn:MyAPI')
  ->proxy('http://localhost')
;
my $r = $s->createAccount(...);

This will create a SOAPAction value of 'urn:MyAPI#createAccount';


Regards,
Duncan Cameron

You can read messages from the SOAP archive, unsubscribe from SOAP, or subscribe to other
DevelopMentor lists at http://discuss.develop.com.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.