diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2013-06-22 17:22:41 +0400 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2013-06-22 17:22:41 +0400 |
commit | 93033823c8dfdcf0ded8a3fff6ec5a75de84a921 (patch) | |
tree | 103dd234c50f82ef4caa7ce45edef24ba80ef7ac /core/src/main/java/org/bouncycastle/crypto/tls/TlsServerProtocol.java | |
parent | f658c6ca808b7a14986cd122beae2188b85686e4 (diff) |
Initial implementation of session resumption (client-side TLS)
Diffstat (limited to 'core/src/main/java/org/bouncycastle/crypto/tls/TlsServerProtocol.java')
-rw-r--r-- | core/src/main/java/org/bouncycastle/crypto/tls/TlsServerProtocol.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/src/main/java/org/bouncycastle/crypto/tls/TlsServerProtocol.java b/core/src/main/java/org/bouncycastle/crypto/tls/TlsServerProtocol.java index 342c343a..442ef447 100644 --- a/core/src/main/java/org/bouncycastle/crypto/tls/TlsServerProtocol.java +++ b/core/src/main/java/org/bouncycastle/crypto/tls/TlsServerProtocol.java @@ -55,7 +55,7 @@ public class TlsServerProtocol } if (this.tlsServer != null) { - throw new IllegalStateException("accept can only be called once"); + throw new IllegalStateException("'accept' can only be called once"); } this.tlsServer = tlsServer; @@ -119,8 +119,9 @@ public class TlsServerProtocol // TODO This block could really be done before actually sending the hello { - securityParameters.prfAlgorithm = getPRFAlgorithm(getContext(), selectedCipherSuite); + securityParameters.cipherSuite = this.selectedCipherSuite; securityParameters.compressionAlgorithm = this.selectedCompressionMethod; + securityParameters.prfAlgorithm = getPRFAlgorithm(getContext(), selectedCipherSuite); /* * RFC 5264 7.4.9. Any cipher suite which does not explicitly specify @@ -355,6 +356,7 @@ public class TlsServerProtocol sendFinishedMessage(); this.connection_state = CS_SERVER_FINISHED; + this.connection_state = CS_END; break; } default: |