cmeng-git / atalk-android

xmpp/jabber client for android
Apache License 2.0
159 stars 60 forks source link

Compatibility with Conversations #219

Open Eirikr70 opened 2 months ago

Eirikr70 commented 2 months ago

Hello, I have installed Conversations and it runs fine for messages and audio/video calls with another Conversations instance. However if I try and call an aTalk instance, the communication drops immediately and aTalk indicates a DTLS problem. The situation is identical if the call is initiated on the aTalk side. On the server part (docker-ejabberd), the log shows

jabber  | 19:44:03.376 [info] (#PID<0.1926.0>) Accepted connection [::ffff:x.x.x.x]:58558 -> [::ffff:x.x.x.x]:5222
jabber  | 
jabber  | 19:44:04.008 [info] (tls|<0.1926.0>) Accepted c2s SCRAM-SHA-1 authentication for gilles@jabber.xxx.fr by mnesia backend from ::ffff:x.x.x.x
jabber  | 
jabber  | 19:44:04.161 [info] (tls|<0.1926.0>) Resumed session for gilles@jabber.xxx.fr/atalk-10di38b
jabber  | 
jabber  | 19:46:42.765 [info] Offering STUN/TURN services to eric@jabber.xxx.fr/Conversations.fQuLeDzpef (3f8d0008491cf7bd)
jabber  | 
jabber  | 19:46:42.931 [notice] Creating TURN allocation (lifetime: 600 seconds) [UDP, session o51qufz6bnlz, user 1724831202:3f8d0008491cf7bd, client x.x.x.x:51128, relay x.x.x.x:49351]
jabber  | 
jabber  | 19:46:42.932 [notice] Creating TURN allocation (lifetime: 599 seconds) [UDP, session uiwhu7h45g2q, user 1724831202:3f8d0008491cf7bd, client x.x.x.x:35632, relay x.x.x.x:49371]
jabber  | 
jabber  | 19:46:43.757 [notice] Relayed 2 KiB (in 708 B / 7 packets, out 1137 B / 12 packets), duration: 0 seconds [UDP, session uiwhu7h45g2q, user 1724831202:3f8d0008491cf7bd, client x.x.x.x:35632, relay x.x.x.x:49371]
jabber  | 
jabber  | 19:46:43.758 [notice] Relayed 3 KiB (in 2117 B / 12 packets, out 1393 B / 16 packets), duration: 0 seconds [UDP, session o51qufz6bnlz, user 1724831202:3f8d0008491cf7bd, client x.x.x.x:51128, relay x.x.x.x:49351]
jabber  | 
jabber  | 19:50:29.083 [info] (tls|<0.1926.0>) Closing c2s connection for gilles@jabber.xxx.fr/atalk-10di38b: Connection failed: connection closed; waiting 300 seconds for stream resumption

The text messages are correctly delivered. Got any clue about how to solve that problem ?

cmeng-git commented 2 months ago

You may refer to aTalk releaseNotes.txt on media call compatibility problem/details with conversations. It has been a while since I last tested media call with conversations.

Note: conversations does not have the full DTLS implementation as aTalk. I am not sure if the following still valid.

For Conversations 2.12.2 dtls media call compatibility with aTalk; use RSA 'TLS Certificate Signature Algorithm' only e.g. "SHA256withRSA"

Eirikr70 commented 2 months ago

Thanks for the advice. aTalk being installed on the remote client I can't test it now unfortunately.

cmeng-git commented 2 months ago

How can I achieve that with docker-ejabberd ? I am using ejabberd as my home server for all my aTalk system testing. I did not have media call problem via the server, but not using the STUN/TURN service. Not sure if docker-ejabberd is the same as ejabberd.

From the docker-ejabberd log, it appears that you are using the STUN/TURN service via docker-ejabberd. The problem seems like the devices failed to setup a valid UDP connection pair based on the candidates offered; likely to be the STUN/TURN setup. This is my best guess.