Get the vhost info in auth module

Rohan Almeida rohan at
Mon Jul 27 11:52:19 UTC 2009


I'm rolling my own Authentication module, but I fail to see how 
to get the connecting vhost info.


       <Plugin DJabberd::RosterStorage::SQLite>
           Database roster.sqlite

       <Plugin My::Auth>
           #Users   buddy

       <Plugin DJabberd::Delivery::Local />
       <Plugin DJabberd::Delivery::S2S />


In My/

sub check_cleartext {
       my ($self, $cb, %args) = @_;
       my $username = $args{username};
       my $password = $args{password};
       my $conn = $args{conn};


So I get the username, password and the $conn ISA 

I can see that I get all the vhosts using:

my $vhosts = $conn->server->vhosts;

but how I do know which vhost is currently connecting?


More information about the Djabberd mailing list