summary refs log tree commit diff
diff options
context:
space:
mode:
authorPeter Dettman <peter.dettman@bouncycastle.org>2015-12-28 12:25:40 +0700
committerPeter Dettman <peter.dettman@bouncycastle.org>2015-12-28 12:25:40 +0700
commitca836115b48bd3b78312b2a5c88370ff7ef9d338 (patch)
tree86ebd15f9186ca317b294765b4d21f57c4160463
parentFix VmpcMac to actually use offset in BlockUpdate() (diff)
downloadBouncyCastle.NET-ed25519-ca836115b48bd3b78312b2a5c88370ff7ef9d338.tar.xz
XML doc for TlsClient.ClientHelloRecordLayerVersion
-rw-r--r--crypto/src/crypto/tls/AbstractTlsClient.cs11
-rw-r--r--crypto/src/crypto/tls/TlsClient.cs12
2 files changed, 14 insertions, 9 deletions
diff --git a/crypto/src/crypto/tls/AbstractTlsClient.cs b/crypto/src/crypto/tls/AbstractTlsClient.cs
index 046feb78c..fedca0934 100644
--- a/crypto/src/crypto/tls/AbstractTlsClient.cs
+++ b/crypto/src/crypto/tls/AbstractTlsClient.cs
@@ -66,22 +66,15 @@ namespace Org.BouncyCastle.Crypto.Tls
             return null;
         }
 
-        /**
-         * RFC 5246 E.1. "TLS clients that wish to negotiate with older servers MAY send any value
-         * {03,XX} as the record layer version number. Typical values would be {03,00}, the lowest
-         * version number supported by the client, and the value of ClientHello.client_version. No
-         * single value will guarantee interoperability with all old servers, but this is a complex
-         * topic beyond the scope of this document."
-         */
         public virtual ProtocolVersion ClientHelloRecordLayerVersion
         {
             get
             {
                 // "{03,00}"
-                // return ProtocolVersion.SSLv3;
+                //return ProtocolVersion.SSLv3;
 
                 // "the lowest version number supported by the client"
-                // return getMinimumVersion();
+                //return MinimumVersion;
 
                 // "the value of ClientHello.client_version"
                 return ClientVersion;
diff --git a/crypto/src/crypto/tls/TlsClient.cs b/crypto/src/crypto/tls/TlsClient.cs
index 116f6a779..73f169054 100644
--- a/crypto/src/crypto/tls/TlsClient.cs
+++ b/crypto/src/crypto/tls/TlsClient.cs
@@ -23,6 +23,18 @@ namespace Org.BouncyCastle.Crypto.Tls
         /// </returns>
         TlsSession GetSessionToResume();
 
+        /// <summary>
+        /// Return the <see cref="ProtocolVersion"/> to use for the <c>TLSPlaintext.version</c> field prior to
+        /// receiving the server version. NOTE: This method is <b>not</b> called for DTLS.
+        /// </summary>
+        /// <remarks>
+        /// See RFC 5246 E.1.: "TLS clients that wish to negotiate with older servers MAY send any value
+        /// {03,XX} as the record layer version number. Typical values would be {03,00}, the lowest
+        /// version number supported by the client, and the value of ClientHello.client_version. No
+        /// single value will guarantee interoperability with all old servers, but this is a complex
+        /// topic beyond the scope of this document."
+        /// </remarks>
+        /// <returns>The <see cref="ProtocolVersion"/> to use.</returns>
         ProtocolVersion ClientHelloRecordLayerVersion { get; }
 
         ProtocolVersion ClientVersion { get; }