Package org.bouncycastle.tls
Class ServerHello
- java.lang.Object
-
- org.bouncycastle.tls.ServerHello
-
public class ServerHello extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ServerHello(byte[] sessionID, int cipherSuite, java.util.Hashtable extensions)ServerHello(ProtocolVersion version, byte[] random, byte[] sessionID, int cipherSuite, java.util.Hashtable extensions)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidencode(TlsContext context, java.io.OutputStream output)Encode thisServerHelloto anOutputStream.intgetCipherSuite()java.util.HashtablegetExtensions()byte[]getRandom()byte[]getSessionID()ProtocolVersiongetVersion()booleanisHelloRetryRequest()static ServerHelloparse(java.io.ByteArrayInputStream input)Parse aServerHellofrom aByteArrayInputStream.
-
-
-
Constructor Detail
-
ServerHello
public ServerHello(byte[] sessionID, int cipherSuite, java.util.Hashtable extensions)
-
ServerHello
public ServerHello(ProtocolVersion version, byte[] random, byte[] sessionID, int cipherSuite, java.util.Hashtable extensions)
-
-
Method Detail
-
getCipherSuite
public int getCipherSuite()
-
getExtensions
public java.util.Hashtable getExtensions()
-
getRandom
public byte[] getRandom()
-
getSessionID
public byte[] getSessionID()
-
getVersion
public ProtocolVersion getVersion()
-
isHelloRetryRequest
public boolean isHelloRetryRequest()
-
encode
public void encode(TlsContext context, java.io.OutputStream output) throws java.io.IOException
Encode thisServerHelloto anOutputStream.- Parameters:
context- theTlsContextof the current connection.output- theOutputStreamto encode to.- Throws:
java.io.IOException
-
parse
public static ServerHello parse(java.io.ByteArrayInputStream input) throws java.io.IOException
Parse aServerHellofrom aByteArrayInputStream.- Parameters:
input- theByteArrayInputStreamto parse from.- Returns:
- a
ServerHelloobject. - Throws:
java.io.IOException
-
-