Hi,

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

<VHost my.com>

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

      <Plugin My::Auth>
          #Users   buddy
      </Plugin>

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

</VHost>

In My/Auth.pm

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 DJabberd::Connection::ClientIn

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?


Thanks,
Rohan



Reply via email to