public abstract class AbstractOpenSSLSession extends Object implements SSLSession
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractOpenSSLSession(org.conscrypt.AbstractSessionContext sessionContext)
Class constructor creates an SSL session context given the appropriate
session context.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getApplicationBufferSize()
Returns the largest buffer size for the application's data bound to this
concrete SSL session.
|
Certificate[] |
getLocalCertificates()
Returns the certificate(s) of the principal (subject) of this concrete SSL
session used in the handshaking phase of the connection.
|
Principal |
getLocalPrincipal()
Returns the principal (subject) of this concrete SSL session used in the
handshaking phase of the connection.
|
int |
getPacketBufferSize()
Returns the largest SSL/TLS packet size one can expect for this concrete
SSL session.
|
X509Certificate[] |
getPeerCertificateChain()
Returns the certificate(s) of the peer in this SSL session
used in the handshaking phase of the connection.
|
Certificate[] |
getPeerCertificates()
Return the identity of the peer in this SSL session
determined via certificate(s).
|
Principal |
getPeerPrincipal()
The identity of the principal that was used by the peer during the SSL
handshake phase is returned by this method.
|
abstract String |
getRequestedServerName()
Returns the name requested by the SNI extension.
|
SSLSessionContext |
getSessionContext()
Returns the context to which the actual SSL session is bound.
|
abstract List<byte[]> |
getStatusResponses()
Returns the OCSP stapled response.
|
abstract byte[] |
getTlsSctData()
Returns the TLS Stapled Certificate Transparency data.
|
Object |
getValue(String name)
Returns the object which is bound to the the input parameter name.
|
String[] |
getValueNames()
Returns an array with the names (sort of links) of all the data
objects of the application layer bound into the SSL session.
|
protected abstract X509Certificate[] |
getX509LocalCertificates() |
protected abstract X509Certificate[] |
getX509PeerCertificates() |
void |
invalidate()
It invalidates a SSL session forbidding any resumption.
|
boolean |
isValid()
Returns a boolean flag signaling whether a SSL session is valid
and available for resuming or joining or not.
|
void |
putValue(String name,
Object value)
A link (name) with the specified value object of the SSL session's
application layer data is created or replaced.
|
void |
removeValue(String name)
Removes a link (name) with the specified value object of the SSL
session's application layer data.
|
abstract void |
setLastAccessedTime(long accessTimeMillis)
Sets the last accessed time for this session in milliseconds since Jan 1,
1970 00:00:00 UTC.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetCipherSuite, getCreationTime, getId, getLastAccessedTime, getPeerHost, getPeerPort, getProtocolprotected AbstractOpenSSLSession(org.conscrypt.AbstractSessionContext sessionContext)
protected abstract X509Certificate[] getX509PeerCertificates() throws SSLPeerUnverifiedException
SSLPeerUnverifiedExceptionprotected abstract X509Certificate[] getX509LocalCertificates()
public Certificate[] getPeerCertificates() throws SSLPeerUnverifiedException
getPeerCertificates in interface SSLSessionSSLPeerUnverifiedException - if either a non-X.509 certificate
was used (i.e. Kerberos certificates) or the peer could not
be verified.public X509Certificate[] getPeerCertificateChain() throws SSLPeerUnverifiedException
getPeerCertificates().getPeerCertificateChain in interface SSLSessionSSLPeerUnverifiedException - if either a non-X.509 certificate
was used (i.e. Kerberos certificates) or the peer could not
be verified.public Principal getPeerPrincipal() throws SSLPeerUnverifiedException
getPeerPrincipal in interface SSLSessionSSLPeerUnverifiedException - if either a non-X.509 certificate
was used (i.e. Kerberos certificates) or the peer does not exist.public Principal getLocalPrincipal()
getLocalPrincipal in interface SSLSessionpublic Certificate[] getLocalCertificates()
getLocalCertificates in interface SSLSessionpublic int getApplicationBufferSize()
getApplicationBufferSize in interface SSLSessionpublic int getPacketBufferSize()
getPacketBufferSize in interface SSLSessionpublic Object getValue(String name)
getValue in interface SSLSessionname - the name of the binding to find.IllegalArgumentException - if the argument is null.public String[] getValueNames()
getValueNames in interface SSLSessionpublic void putValue(String name, Object value)
SSLSessionBindingListener
interface, that object will be notified in due course.putValue in interface SSLSessionname - the name of the link (no null are
accepted!)value - data object that shall be bound to
name.IllegalArgumentException - if one or both argument(s) is null.public void removeValue(String name)
If the value object implements the SSLSessionBindingListener
interface, the object will receive a valueUnbound notification.
removeValue in interface SSLSessionname - the name of the link (no null are
accepted!)IllegalArgumentException - if the argument is null.public SSLSessionContext getSessionContext()
getSessionContext in interface SSLSessionpublic boolean isValid()
isValid in interface SSLSessionpublic void invalidate()
invalidate in interface SSLSessionpublic abstract String getRequestedServerName()
public abstract List<byte[]> getStatusResponses()
public abstract byte[] getTlsSctData()
public abstract void setLastAccessedTime(long accessTimeMillis)