summary refs log tree commit diff
path: root/crypto/src/tls/TlsUtilities.cs
diff options
context:
space:
mode:
authorPeter Dettman <peter.dettman@bouncycastle.org>2023-05-11 21:04:11 +0700
committerPeter Dettman <peter.dettman@bouncycastle.org>2023-05-11 21:04:11 +0700
commit5b27019abd9ae16f883b1fdff8398288d50abbfc (patch)
treedef16ac4ed34c587020f70ae474be90d61588e76 /crypto/src/tls/TlsUtilities.cs
parentfix exception during DTLS server handshake when the client has no extensions (diff)
downloadBouncyCastle.NET-ed25519-5b27019abd9ae16f883b1fdff8398288d50abbfc.tar.xz
TLS: Add NotifyConnectionClosed callback
Diffstat (limited to '')
-rw-r--r--crypto/src/tls/TlsUtilities.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/crypto/src/tls/TlsUtilities.cs b/crypto/src/tls/TlsUtilities.cs
index 69a458a5a..92102e826 100644
--- a/crypto/src/tls/TlsUtilities.cs
+++ b/crypto/src/tls/TlsUtilities.cs
@@ -5730,5 +5730,14 @@ namespace Org.BouncyCastle.Tls
 
             return 1000;
         }
+
+        // TODO[api] Not needed once NotifyConnectionClosed() has been added to TlsPeer
+        internal static void NotifyConnectionClosed(TlsPeer tlsPeer)
+        {
+            if (tlsPeer is AbstractTlsPeer abstractTlsPeer)
+            {
+                abstractTlsPeer.NotifyConnectionClosed();
+            }
+        }
     }
 }