Problem with jabber-gg-transport that doesn't show in "Service Discovery"

Hellp,

From ubuntu repositiories I have instaled ejabberd server, then configured it and finally added the required dns entries. It works.
Next I tried to install the gadu-gadu transport by following the tutorial http://www.ejabberd.im/jabber-gg-transport/. It seams like both transport and server works because they run without any problems, the log entry seems to be proving that everything is ok.

But I cannot see the transport from any jabber client. For example if I try PSI and click "Service Discovery" I don't see the gadu gadu transport on the list of avaible services.

the ejabberd server is behind the nat, I think I have allowed the required ports, etc.

Please, have a look at my configuration files.

Any tips?

ejabberd.cfg

Quote:

%override_acls.

% Users that have admin access. Add line like one of the following after you
% will be successfully registered on server to get admin access:
{acl, admin, {user, "admin"}}.

% Blocked users:
%{acl, blocked, {user, "test"}}.

% Local users:
{acl, local, {user_regexp, ""}}.

% Only admins can use configuration interface:
{access, configure, [{allow, admin}]}.

% Every username can be registered via in-band registration:
{access, register, [{allow, all}]}.

% None username can be registered via in-band registration:
%{access, register, [{deny, all}]}.

% After successful registration user will get message with following subject
% and body:
{welcome_message,
{"Welcome!",
"Welcome to Debian Jabber Service. "
"For information about Jabber visit http://jabber.org"}}.

% Only admins can send announcement messages:
{access, announce, [{allow, admin}]}.

% Only non-blocked users can use c2s connections:
{access, c2s, [{deny, blocked},
{allow, all}]}.

% Set shaper with name "normal" to limit traffic speed to 1000B/s
{shaper, normal, {maxrate, 1000}}.

% Set shaper with name "fast" to limit traffic speed to 50000B/s
{shaper, fast, {maxrate, 50000}}.

% For all users except admins used "normal" shaper
{access, c2s_shaper, [{none, admin},
{normal, all}]}.

% For all S2S connections used "fast" shaper
{access, s2s_shaper, [{fast, all}]}.

% Admins of this server are also admins of MUC service:
{access, muc_admin, [{allow, admin}]}.

% All users are allowed to use MUC service:
{access, muc, [{allow, all}]}.

% This rule allows access only for local users:
{access, local, [{allow, local}]}.

% Authentication method. If you want to use internal user base, then use
% this line:
{auth_method, internal}.

% Host(s) name: (replace for your hostname(s))
% Old {host, "localhost"}. option is equivalent to {hosts, ["localhost"]}.
{hosts, ["jabber.domain.com"]}.

% Default language for server messages
{language, "en"}.

% Listened ports:
{listen,
% Ordinary client-2-server service
[{5222, ejabberd_c2s, [{access, c2s},
starttls, {certfile, "/etc/ssl/certs/ejabberd.pem"},
{shaper, c2s_shaper}]},

% SSL-enabled client-2-server service
{5223, ejabberd_c2s, [{access, c2s},
tls, {certfile, "/etc/ssl/certs/ejabberd.pem"},
{shaper, c2s_shaper}]},
% Server-2-server service
{5269, ejabberd_s2s_in, [{shaper, s2s_shaper}]},

% gadu gadu
{5237, ejabberd_service, [{host, "gg.domain.com",
[{password, "secret"}]}]},

% HTTP service (You may choose options HTTP-polling and Web-administering)
% When commenting out, be careful with commas
{5280, ejabberd_http, [http_poll, web_admin]}
]}.

% If SRV lookup fails, then port 5269 is used to communicate with remote server
{outgoing_s2s_port, 5269}.

% Used modules:
{modules,
[
{mod_announce, [{access, announce}]},
{mod_register, [{access, register}]},
{mod_roster, []},
{mod_shared_roster, []},
{mod_privacy, []},
{mod_configure, []},
{mod_configure2, []},
{mod_disco, [{extra_domains, ["users.jabber.org"]}]},
{mod_stats, []},
{mod_vcard, []},
{mod_offline, []},
{mod_echo, []},
{mod_private, []},
{mod_irc, []},
% Default options for mod_muc:
% host: "conference." ++ ?MYNAME
% access: all
% access_create: all
% access_admin: none (only room creator has owner privileges)
{mod_muc, [{access, muc},
{access_create, muc},
{access_admin, muc_admin}]},
{mod_pubsub, []},
{mod_time, []},
{mod_last, []},
{mod_version, []}
]}.

jabber-gg-transport.xml

Quote:

<jggtrans>

<service jid="gg.domain.com"/>

<!-- This connects the jabber-gg-transport process to ejabberd. -->
<connect id="gglinker">
<ip>192.168.0.1</ip>
<port>5237</port>
<secret>secret</secret>
</connect>

<register>
<instructions>
Fill in your GG number (after "username")
and password to register on the transport.
<p/>To change your information in the GaduGadu directory you need to fill in the other fields.
<p/>To remove registration you need to leave the form blank.
</instructions>
</register>

<search>
<!-- This tag contains the message displayed to users at search time. -->
<instructions>
To search people:<br/>
First fill in surname or family name, nickname, city, birthyear or range of birthyears (eg. 1950-1960)
and gender (you may fill in more fields at once).<br/>
or<br/>
Fill in phone number<br/>
or<br/>
Fill in the GG number of the person you are searching.
</instructions>
</search>

<gateway>
<!-- This is message, that may be displayed to user when adding gg contact. -->
<desc>Please fill in the GaduGadu number of the person you want to add.</desc>
<!-- And this is the prompt for GG number. -->
<prompt>GG Nummer</prompt>
</gateway>

<vCard>
<FN>Gadu-Gadu Transport</FN>
<DESC>This is the Gadu-Gadu Transport.</DESC>
<EMAIL>EMAIL@ADDRESS.COM</EMAIL>
<URL>http://www.jabberstudio.org/projects/jabber-gg-transport/</URL>
</vCard>

<!-- Default user locale (language).
Empty means system locale setting,
no (or commented-out) <default_locale> tag means no translations. -->
<!-- <default_locale>pl_PL</default_locale> -->
<!-- Logger configuration.
You may configure one logger of type "syslog" and/or one of type "file".
You may also not configure logging at all. -->
<log type="syslog" facility="local0"/>
<log type="file">/var/log/jabber/jabber-gg-transport.log</log>

<!-- You can change these values according to your needs. -->
<conn_timeout>60</conn_timeout>
<ping_interval>10</ping_interval>

<!-- Gadu-Gadu server doesn't seem to answer pings anymore :-(
So let's give it 10 year :-) -->
<pong_timeout>315360000</pong_timeout>

<!-- This time after disconnection from Gadu-Gadu server the transport
will try to connect again. -->
<reconnect>300</reconnect>

<!-- How long to wait before restart, after jabber server connection is broken
negative value means, that jggtrans should terminate. -->
<restart_timeout>60</restart_timeout>

<!-- Delay between the unavailable presence is received from user and loggin out
from Gadu-Gadu - for nice <presence type="invisible"/> support. -->
<disconnect_delay>5</disconnect_delay>

<!--

<servers>
<hub/>
<server port="443">217.17.41.90</server>
<server tls="no">217.17.41.85</server>
<server tls="no">217.17.41.88</server>
</servers>
-->

<!-- Spool directory. This is the place, where user info will be stored. -->
<!-- Be careful about permissions - users' Gadu-Gadu passwords are stored there. -->

<spool>/var/spool/jabber/gg.domain.com/</spool>

<!-- Where to store pid file. This tag is optional. -->
<pidfile>/var/run/jabber/jabber-gg-transport.pid</pidfile>

<!-- jid allowed to do some administrative task (eg. discovering online users).
May be used multiple times. -->
<admin>admin@jabber.domain.com</admin>

<!-- ACL gives detailed access control to the transport. -->
<acl>
<!-- Example entries: -->

<allow who="admin@jabber.domain.com" what="iq/query?xmlns=http://jabber.org/protocol/stats"/>
<!-- will allow statistics gathering to admin@SERVER.COM -->

<deny who="*" what="iq/query?xmlns=http://jabber.org/protocol/stats"/>
<!-- will deny statistics gathering for anybody else -->

<allow who="*"/>
<!-- will allow anything else to users from "SERVER.COM" -->

</acl>

</jggtrans>

the dns config file

Quote:

$TTL 604800
@ IN SOA domain.com. root.localhost. (

1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS localhost.
@ IN A 62.121.94.170
jabber IN A 62.121.94.170
gg IN A 62.121.94.170
* IN A 62.121.94.170

_jabber._tcp.domain.com. 86400 IN SRV 5 0 5269 jabber.domain.com.
_xmpp-server._tcp.domain.com. 86400 IN SRV 5 0 5269 jabber.domain.com.
_xmpp-client._tcp.domain.com. 86400 IN SRV 5 0 5222 jabber.domain.com.

the firewall script

Quote:

#!/bin/sh
iptables -F
iptables -F -t nat
iptables -P INPUT DROP
iptables -P FORWARD DROP
iptables -P OUTPUT ACCEPT
iptables -A INPUT -p icmp -j ACCEPT
iptables -A INPUT -i lo -j ACCEPT
iptables -A INPUT -i eth0 -m state --state ESTABLISHED,RELATED -j ACCEPT

iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

iptables -A FORWARD -o eth0 -i eth1 -j ACCEPT
iptables -A FORWARD -i eth0 -o eth1 -j ACCEPT

iptables -A INPUT -i eth1 -s 192.168.0.0/24 -j ACCEPT
iptables -A INPUT -i eth1 -d 192.168.0.0/24 -j ACCEPT

[....]

iptables -A INPUT -i eth0 -p tcp --dport 5222 -j ACCEPT
iptables -A INPUT -i eth0 -p tcp --dport 5223 -j ACCEPT
iptables -A INPUT -i eth0 -p tcp --dport 5269 -j ACCEPT
iptables -A INPUT -i eth0 -p tcp --dport 5237 -j ACCEPT

the log that prooves, I think, that everything is ok.

Quote:

=INFO REPORT==== 2007-04-24 12:34:15 ===
I(<0.1289.0>:ejabberd_listener:90): (#Port<0.1071>) Accepted connection {{192,168,0,1},56881} -> {{192,168,0,1},5237}

the nestat -a interesting output

Quote:

tcp 0 0 *:5237 *:* LISTEN

Check the FAQ

Since that question is quite common, I've added it to the FAQ. You will find the answer on: Transport not shown on Service Discovery

Syndicate content