Read only archive ; use for new issues
Bug 847 - Bidirectional Connection does not work when SSL is enabled
Summary: Bidirectional Connection does not work when SSL is enabled
Alias: None
Product: JacORB
Classification: Unclassified
Component: SSL/IIOP (show other bugs)
Version: 2.3.0
Hardware: PC All
: P2 normal
Assignee: Nicolas Noffke
Depends on:
Blocks: 886
  Show dependency tree
Reported: 2008-12-16 12:52 CET by Alex.C.Punnen
Modified: 2010-01-21 15:27 CET (History)
3 users (show)

See Also:

diff of (diff -b -B -E -U 3) (5.11 KB, text/plain)
2008-12-16 12:54 CET, Alex.C.Punnen
diff of (diff -b -B -E -U 3) (2.54 KB, text/plain)
2008-12-16 12:55 CET, Alex.C.Punnen
diff of (diff -b -B -E -U 3) (1.55 KB, text/plain)
2008-12-16 12:56 CET, Alex.C.Punnen
The changed files for this corection (8.59 KB, application/x-zip-compressed)
2008-12-16 12:57 CET, Alex.C.Punnen

Note You need to log in before you can comment on or make changes to this bug.
Description Alex.C.Punnen 2008-12-16 12:52:41 CET
I set the client to run behind a firewall, and then made the server callback to the client. This is after setting SSL and enabling bidirectional GIIOP.
The server could not connect to the client as it was trying to open another port

Checking the code I found that though the profile was added in BiDirConnectionServerInterceptor::addConnection, the requestId was not found in the ClientConnectionManager::getConnection

I changed the code in the BiDirConnectionServerInterceptor::addConnection and also made the hashmap key in the ClientConnectionManager to a string explicitly,
while setting the keys and getting it.
private final Map connections = new HashMap(); 

ClientConnection clientConnection =
            (ClientConnection)connections.get(profile.toString() );
After these changes the server is able to callback on the client, which is behind the firewall. Also from the jacorb traces I was able to see that the profile is found for the requst id and the same profile is reused. I will attach the diff of the changed files. (Note I am behind company firewall and cannot aceess cvs source direclty and cannot do a cvs diff)

Client Code
 ClientCallback ccb = ClientCallbackHelper.narrow(bidir_poa.servant_to_reference( new ClientCallbackPOAImpl() ));
System.out.println("Going to register callback with the Server for Topology Change");

Server Code


public void register_callback(ClientCallback clntobj) {
		System.out.println("Received the callback from the client");
		callbackobj =clntobj;
		System.out.println("Going to call the client");
		callbackobj.TopologyChanged("", true);

Comment 1 Alex.C.Punnen 2008-12-16 12:54:45 CET
Created attachment 353 [details]
diff of (diff -b -B -E -U 3)
Comment 2 Alex.C.Punnen 2008-12-16 12:55:55 CET
Created attachment 354 [details]
diff of (diff -b -B -E -U 3)
Comment 3 Alex.C.Punnen 2008-12-16 12:56:22 CET
Created attachment 355 [details]
diff of (diff -b -B -E -U 3)
Comment 4 Alex.C.Punnen 2008-12-16 12:57:48 CET
Created attachment 356 [details]
The changed files for this corection

The changed files for this corection
Comment 5 Nick Cross 2009-11-23 12:04:00 CET
This should be fixed by separate PrismTech fixes in CVS.
Comment 6 Alex.C.Punnen 2010-01-21 12:42:46 CET
The corrections for this are not there in the latest 2.3.1 source. So reopening this
Comment 7 Nick Cross 2010-01-21 15:27:27 CET
Patches are made into CVS head not against released versions of the code. If you need updates to a stable version you may wish to look at where various companies offer commercial support for JacORB.