This Question is Answered (go to answer)

1 "helpful" answer available (5 pts)
2,609 Views 12 Replies Last post: Dec 4, 2008 11:32 PM by Brian Menges RSS
Brian Menges Bronze 48 posts since
Jul 4, 2008
Currently Being Moderated

Sep 29, 2008 12:56 PM

Connection Manager 3.6.0 and Openfire 3.6.0 Security

I'm extending my architecture for my openfire setup, and I'm using the connection manager in conjunction with my server.  I'm trying to make sure the whole network is secure, but I'm finding that connections through the connection manager are not listed as secure according to the server.

 

When I look at the list of users, I see the little golden pad lock for all those connecting diretly to the server, but for those going through the connection manager server, they're not there.  This leads me to believe these connections aren't secured across TLS/SSL.

 

Upon further investigation, I thought I should poke into the keytool syntax on the connection manager server (maybe it needed the crt I thought).  So I imported them according to the syntax, and now my keystore/trust store looks like this:

 

jabber:/opt/connection_manager/conf# keytool -list -keystore keystore
Enter keystore password:

 

Keystore type: JKS
Keystore provider: SUN

 

Your keystore contains 1 entry

 

servepath.com, 30 Sep, 2008, trustedCertEntry,
Certificate fingerprint (MD5): E3:C3:50:DA:5F:8B:CD:3A:2A:7E:E6:59:10:C0:2A:A4

 

jabber:/opt/connection_manager/conf# keytool -list -keystore truststore
Enter keystore password:

 

Keystore type: JKS
Keystore provider: SUN

 

Your keystore contains 1 entry

 

gd_intermediate, 30 Sep, 2008, trustedCertEntry,
Certificate fingerprint (MD5): D5:DF:85:B7:9A:52:87:D1:8C:D5:0F:90:23:2D:B5:34

 

Now... my keystore and truststore are both in /opt/connection_manager/conf so I don't know if that's right or not.  I'm also noticing that all the other stuff isn't in there... it just has entries for my two certs, my domain certificate and the intermediate authenticating certificate.  Am I missing something or are the files wrong?  Is there something extra that I have to do to to the manager.xml?  do these files belong in ../resources/security/ instead?

 

Help appreciated.

Gaston Dombiak Jiver 3,834 posts since
Sep 26, 2001
Currently Being Moderated
Sep 29, 2008 11:38 PM in response to: Brian Menges
Re: Connection Manager 3.6.0 and Openfire 3.6.0 Security

Hey Brian,

 

Are you trying to secure the connection between the CMs and Openfire? First off, I would ask why is it that you need to use CMs on top of Openfire? Since a single Openfire instance scaled from 5K to 250K we stopped recommending using CMs for "regular" scalability needs. We are now recommending CMs if your servers are under really heavy load so using CMs is a way to reduce the CPU and I/O burden. Having said that the second question is why use TLS between CMs and Openfire? If both machines are under a protected network then you might want to reconsider using TLS since using TLS is an expensive feature. IOW, if you still need to use CMs and you need secured connections between them then make sure to provide RSA and DSA certs (that should take care of the cipher issues).

 

Regards,

 

  -- Gato

Gaston Dombiak Jiver 3,834 posts since
Sep 26, 2001
Currently Being Moderated
Sep 30, 2008 12:44 PM in response to: Brian Menges
Re: Connection Manager 3.6.0 and Openfire 3.6.0 Security

Hey Brian,

 

I think that there could be a misunderstanding about how CMs work. Lets assume that you have an Openfire server running in the US, a CM running in Rome and another CM in Japan. Each CM will open a socket connection to Openfire. Lets now imagine that we have 2 users connected  from Japan (J1 and J2) and 2 users from Rome (R1 and R2). If J1 sends a message to J2 then J1's client will send the message to the CM at Japan. The CM will then forward the message to the Openfire server in the US and the Openfire server will then send a message to the CM in Japan so that it can forward the message to J2. As you can imagine a conversation between J1 and R1 would imply this flow: J1 --> CM (Japan) --> Openfire --> CM (Rome) --> R1.

 

Having said that, I think that what you need in order to have local network traffic between local users is to run different Openfire installations in each place. And then rely on server-2-server (using TLS) to secure communication between servers/countries/places. BTW, CMs are not a way to workaround clustering. If the Openfire server goes down then the entire XMPP service will be down.

 

Regards,

 

  -- Gato

Gaston Dombiak Jiver 3,834 posts since
Sep 26, 2001
Currently Being Moderated
Oct 1, 2008 1:22 PM in response to: Brian Menges
Re: Connection Manager 3.6.0 and Openfire 3.6.0 Security

Hey Brian,

 

CMs were created for dealing with all the burden of IO network activity and at the same time be 100% dumb. They are just proxies that will forward traffic between clients and XMPP servers. They do not have any of the logic that lives on the server. For instance, if you have a PacketInterceptor that is preventing some people from communicating (aka ethical walls) then your CM will skip that and let people just talk. Auditing, logging, permission, etc. are many other things that would get lost with that architecture. Having said that, you are welcome to add a short-circuit to the CM and make it optional.

 

You are not the first one interested in clustering and willing to implement it. In fact, some community members went ahead and implemented a proof of concept using an open source clustering solution and it worked fine with Openfire. I would recommend joining all the effort from many community members and move on. I'm open to answer questions or make recommendations in this initiative.

 

Regards,

 

  -- Gato

LG KeyContributor 5,452 posts since
Dec 13, 2005
Currently Being Moderated
Oct 15, 2008 12:15 PM in response to: Brian Menges
Re: Connection Manager 3.6.0 and Openfire 3.6.0 Security

Hi Brian,

 

I wonder why you want to use the old SSL methods for clients.

 

You may want to use TLS / port 5222 and the same certificates and settings as Openfire uses. JM-791 is a known issue, so a "lock" will not be displayed in the Openfire console.

 

There's also JM-835 - it may cause that the sequence of messages is not kept, especially if messages are sent very fast (offline messages or entering a MUC).

 

I did not look at the source code, but I think that the CM connection to Openfire port 5262 is TLS encrypted - otherwise the jive.xmpp.server.certificate section wouldl make little sense in the conf file of the CM.

 

LG

mculbert Bronze 3 posts since
Nov 20, 2008
Currently Being Moderated
Nov 24, 2008 10:34 AM in response to: Brian Menges
Re: Connection Manager 3.6.0 and Openfire 3.6.0 Security

I went after CM for the exact same reason, not for clustering, but to provide acces points in multiple locations that fit in with our security model, and without directly exposing our primary Openfire server.

 

I also was able to get SSL working with relative ease from client -> CM, and in my case SSL also did not work from CM -> OF.  Perhaps there are settings on the Openfire side to enable this, but a few "openssl s_client" calls revealed that the listener on OF accepted neither SSL nor TLS.  CM is really handy, it would be nice if the SSL was fixed.

 

I should add that while my CM is rejecting non-TLS connections on 5222, there is no obvious way to explicitly disable non-SSL connections

 

Brian: just in case you revisit this issue... I stuck with CM, but I just ran it through stunnel to the OF server.  It's another moving part, but it works well and now we're crypto end-to-end..

 

-Mike

More Like This

  • Retrieving data ...

Bookmarked By (0)