xmppo / Jabber-Net

A modern fork of Jabber-Net
https://github.com/xmppo/Jabber-Net
37 stars 13 forks source link

Jabber-net connect to Cisco Jabber #104

Open cguanes opened 5 years ago

cguanes commented 5 years ago

I'm trying to connect to Cisco Jabber using the send message example but it looks like Cisco Jabber requires some "legacy ssl" connection which I'm not sure what exactly it mean. I tried using System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls; but I keep getting "Not-authorized" with the j.SSL = false; if I change to True, I get " Authentication failed because the remote party has closed the transport stream." We have Jetbrains youtrack installed and it is working with Jabber integration with the option "legacySSL=On"

How can I make this work with Cisco XMPP ?

Thanks

ForNeVeR commented 5 years ago

We already had a conversation about some Cisco product, but for now I still have no idea what the "CISCO CUCM" or "Cisco Jabber" is :(

Could you please show a stacktrace and some application logs?

ForNeVeR commented 5 years ago

If you would explain to me what is the "legacy SSL" and how's it different from the "actual SSL", then I could try to fix the issue in the library.

cguanes commented 5 years ago

I believe the error that I'm getting is similar to the other conversation on "CISCO CUCM". Unfortunately I don't know what Jetbrains Youtrack implemented as "LegacySSL" either. And I couldn't find more information googling for it. It shows the same thing in Jenkins, maybe this can help: https://issues.jenkins-ci.org/browse/JENKINS-2699. Maybe the connection need to fall to SSL2 or SSL1

ForNeVeR commented 5 years ago

Alright, this sheds some light onto what the "legacy SSL" is: https://github.com/RestComm/jain-slee.xmpp/blob/77cfa474c0e04a38f6f854837fbd7fcfd4e216f2/resources/xmpp/library/src/main/java/org/jivesoftware/smack/SSLXMPPConnection.java

So, the modern approach seem to be to use a dedicated SSL port, and this one just dynamically negotiates SSL over the existing port.

cguanes commented 5 years ago

That is great!, trying to use older security protocols didn't make any sense (and I could not find the way to do that in w10) Then I read somebody talking about using port 5223, but doing just that didn't work either (too simples to be true).

Sent from mobile

On Oct 26, 2019, at 1:57 AM, Friedrich von Never notifications@github.com wrote:

 Alright, this sheds some light onto what the "legacy SSL" is: https://github.com/RestComm/jain-slee.xmpp/blob/77cfa474c0e04a38f6f854837fbd7fcfd4e216f2/resources/xmpp/library/src/main/java/org/jivesoftware/smack/SSLXMPPConnection.java

So, the modern approach seem to be to use a dedicated SSL port, and this one just dynamically negotiates SSL over the existing port.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

cguanes commented 5 years ago

Alright, this sheds some light onto what the "legacy SSL" is: https://github.com/RestComm/jain-slee.xmpp/blob/77cfa474c0e04a38f6f854837fbd7fcfd4e216f2/resources/xmpp/library/src/main/java/org/jivesoftware/smack/SSLXMPPConnection.java

So, the modern approach seem to be to use a dedicated SSL port, and this one just dynamically negotiates SSL over the existing port.

Will you be able to implement something like that? Right now this is what I'm getting (replaced domain.com) (using SSL = false) SEND: RECV: RECV: </stream:features> SEND: RECV: SEND: RECV: RECV: PLAINCISCO-VTG-TOKENOAUTHBEARER</stream:features> SEND: AG93YW5qYWJiZXJAcnRhLmNvbQBJd2FuZW1hNzh5ZXM= RECV:

When I use SSL=True, I just get the error "Authentication failed because the remote party has closed the transport stream."

ForNeVeR commented 5 years ago

I believe so.