List of usage examples for org.apache.http.impl.nio.reactor SSLIOSession bind
public synchronized void bind(final SSLMode mode, final HttpParams params) throws SSLException
From source file:org.apache.axis2.transport.nhttp.SSLServerIOEventDispatch.java
public void connected(final IOSession session) { SSLIOSession sslSession = new SSLIOSession(session, this.sslcontext, this.sslHandler); LoggingNHttpServerConnection conn = new LoggingNHttpServerConnection(new LoggingIOSession(sslSession), new DefaultHttpRequestFactory(), new HeapByteBufferAllocator(), this.params); session.setAttribute(NHTTP_CONN, conn); session.setAttribute(SSL_SESSION, sslSession); this.handler.connected(conn); try {/*from ww w. java2 s . c o m*/ sslSession.bind(SSLMode.SERVER, this.params); } catch (SSLException ex) { this.handler.exception(conn, ex); sslSession.shutdown(); } }
From source file:org.apache.axis2.transport.nhttp.SSLClientIOEventDispatch.java
public void connected(final IOSession session) { SSLIOSession sslSession = new SSLIOSession(session, this.sslcontext, this.sslHandler); LoggingNHttpClientConnection conn = new LoggingNHttpClientConnection(new LoggingIOSession(sslSession), new DefaultHttpResponseFactory(), new HeapByteBufferAllocator(), this.params); session.setAttribute(NHTTP_CONN, conn); session.setAttribute(SSL_SESSION, sslSession); Object attachment = session.getAttribute(IOSession.ATTACHMENT_KEY); this.handler.connected(conn, attachment); try {//from ww w .j a va2s. c o m sslSession.bind(SSLMode.CLIENT, this.params); } catch (SSLException ex) { this.handler.exception(conn, ex); sslSession.shutdown(); } }