Issue #85 - Expose TLS protocol used for connection in SecureRequestCustomizer
This commit is contained in:
parent
2cc50ed925
commit
195a02fdaa
|
@ -48,6 +48,8 @@ public class SecureRequestCustomizer implements HttpConfiguration.Customizer
|
|||
*/
|
||||
public static final String CACHED_INFO_ATTR = CachedInfo.class.getName();
|
||||
|
||||
private String sslSessionAttribute = "org.eclipse.jetty.servlet.request.ssl_session";
|
||||
|
||||
@Override
|
||||
public void customize(Connector connector, HttpConfiguration channelConfig, Request request)
|
||||
{
|
||||
|
@ -118,12 +120,23 @@ public class SecureRequestCustomizer implements HttpConfiguration.Customizer
|
|||
request.setAttribute("javax.servlet.request.cipher_suite",cipherSuite);
|
||||
request.setAttribute("javax.servlet.request.key_size",keySize);
|
||||
request.setAttribute("javax.servlet.request.ssl_session_id", idStr);
|
||||
request.setAttribute(getSslSessionAttribute(), sslSession);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
LOG.warn(Log.EXCEPTION,e);
|
||||
}
|
||||
}
|
||||
|
||||
public void setSslSessionAttribute(String attribute)
|
||||
{
|
||||
this.sslSessionAttribute = attribute;
|
||||
}
|
||||
|
||||
public String getSslSessionAttribute()
|
||||
{
|
||||
return sslSessionAttribute;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
|
|
Loading…
Reference in New Issue