Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

SOAP::Transport::HTTP::Daemon w/ Auth

by hpavc (Acolyte)
on Jun 27, 2004 at 17:20 UTC ( [id://370007]=perlquestion: print w/replies, xml ) Need Help??

hpavc has asked for the wisdom of the Perl Monks concerning the following question:

Is there a way to have authen/author-ization and access control with the Daemon interface? I would rather not use a webserver. I am so surprised there are not any examples of doing this, or any subclasses specifically for it. Thanks
use SOAP::Transport::HTTP; my $daemon = SOAP::Transport::HTTP::Daemon -> new (LocalPort => 2112, Reuse => 1) -> dispatch_to('Demo'); $daemon->handle;

Replies are listed 'Best First'.
Re: SOAP::Transport::HTTP::Daemon w/ Auth
by fglock (Vicar) on Jun 27, 2004 at 18:09 UTC
      Those are LWP request methods are they not? (eg the client side) ... how do you see this working on the Auth side for the ::Daemon?
Re: SOAP::Transport::HTTP::Daemon w/ Auth
by PodMaster (Abbot) on Jun 28, 2004 at 03:11 UTC
    Looks like you need to write your own sub SOAP::Transport::HTTP::Daemon::handle
    sub handle { my $self = shift->new; while (my $c = $self->accept) { while (my $r = $c->get_request) { ## handle cookie based authentication somewhere in here $self->request($r); $self->SUPER::handle; $c->send_response($self->response) } # replaced ->close, thanks to Sean Meisner <Sean.Meisner@VerizonWi +reless.com> # shutdown() doesn't work on AIX. close() is used in this case. Th +anks to Jos Clijmans <jos.clijmans@recyfin.be> UNIVERSAL::isa($c, 'shutdown') ? $c->shutdown(2) : $c->close(); undef $c; } }

    MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
    I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
    ** The third rule of perl club is a statement of fact: pod is sexy.

      thanks, that seems to be what i expected ... thanks

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://370007]
Approved by neniro
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2024-03-19 05:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found