[jboss-cvs] JBossRemoting/src/main/org/jboss/remoting/transport/coyote/ssl ...

Ron Sigal ron_sigal at yahoo.com
Tue Oct 23 20:47:52 EDT 2007


  User: rsigal  
  Date: 07/10/23 20:47:52

  Modified:    src/main/org/jboss/remoting/transport/coyote/ssl  Tag:
                        remoting_2_x RemotingSSLSupport.java
  Log:
  JBREM-713:  Added RemotingSSLSupport(SSLSession session) constructor.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.8.1   +12 -9     JBossRemoting/src/main/org/jboss/remoting/transport/coyote/ssl/RemotingSSLSupport.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemotingSSLSupport.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/coyote/ssl/RemotingSSLSupport.java,v
  retrieving revision 1.3
  retrieving revision 1.3.8.1
  diff -u -b -r1.3 -r1.3.8.1
  --- RemotingSSLSupport.java	10 Feb 2006 04:59:00 -0000	1.3
  +++ RemotingSSLSupport.java	24 Oct 2007 00:47:52 -0000	1.3.8.1
  @@ -42,10 +42,17 @@
   public class RemotingSSLSupport implements SSLSupport
   {
      private SSLSocket sslSocket;
  +   private SSLSession session;
   
      public RemotingSSLSupport(SSLSocket socket)
      {
         this.sslSocket = socket;
  +      this.session = socket.getSession();
  +   }
  +   
  +   public RemotingSSLSupport(SSLSession session)
  +   {
  +      this.session = session;
      }
   
      /**
  @@ -53,7 +60,6 @@
       */
      public String getCipherSuite() throws IOException
      {
  -      SSLSession session = sslSocket.getSession();
         if(session == null)
         {
            return null;
  @@ -72,8 +78,6 @@
      public Object[] getPeerCertificateChain(boolean force)
            throws IOException
      {
  -
  -      SSLSession session = sslSocket.getSession();
         if(session == null)
         {
            return null;
  @@ -105,9 +109,12 @@
   
      protected void handShake() throws IOException
      {
  +      if (sslSocket != null)
  +      {
         sslSocket.setNeedClientAuth(true);
         sslSocket.startHandshake();
      }
  +   }
   
      protected java.security.cert.X509Certificate[] getX509Certificates(SSLSession session) throws IOException
      {
  @@ -165,8 +172,6 @@
       */
      public Integer getKeySize() throws IOException
      {
  -      // Look up the current SSLSession
  -      SSLSession session = sslSocket.getSession();
         SSLSupport.CipherData c_aux[] = ciphers;
         if(session == null)
         {
  @@ -196,8 +201,6 @@
       */
      public String getSessionId() throws IOException
      {
  -      // Look up the current SSLSession
  -      SSLSession session = sslSocket.getSession();
         if(session == null)
         {
            return null;
  
  
  



More information about the jboss-cvs-commits mailing list