summaryrefslogtreecommitdiffstats
path: root/bcprov/src/main/java/org/bouncycastle/crypto/tls/AbstractTlsPeer.java
diff options
context:
space:
mode:
Diffstat (limited to 'bcprov/src/main/java/org/bouncycastle/crypto/tls/AbstractTlsPeer.java')
-rw-r--r--bcprov/src/main/java/org/bouncycastle/crypto/tls/AbstractTlsPeer.java17
1 files changed, 17 insertions, 0 deletions
diff --git a/bcprov/src/main/java/org/bouncycastle/crypto/tls/AbstractTlsPeer.java b/bcprov/src/main/java/org/bouncycastle/crypto/tls/AbstractTlsPeer.java
index bdfd0d5..80d6af7 100644
--- a/bcprov/src/main/java/org/bouncycastle/crypto/tls/AbstractTlsPeer.java
+++ b/bcprov/src/main/java/org/bouncycastle/crypto/tls/AbstractTlsPeer.java
@@ -1,8 +1,21 @@
package org.bouncycastle.crypto.tls;
+import java.io.IOException;
+
public abstract class AbstractTlsPeer
implements TlsPeer
{
+ public void notifySecureRenegotiation(boolean secureRenegotiation) throws IOException
+ {
+ if (!secureRenegotiation)
+ {
+ /*
+ * RFC 5746 3.4/3.6. In this case, some clients/servers may want to terminate the handshake instead
+ * of continuing; see Section 4.1/4.3 for discussion.
+ */
+ throw new TlsFatalAlert(AlertDescription.handshake_failure);
+ }
+ }
public void notifyAlertRaised(short alertLevel, short alertDescription, String message, Exception cause)
{
@@ -11,4 +24,8 @@ public abstract class AbstractTlsPeer
public void notifyAlertReceived(short alertLevel, short alertDescription)
{
}
+
+ public void notifyHandshakeComplete() throws IOException
+ {
+ }
}