You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit e19deb2
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: nanoFramework.System.Net/Security/SslStream.cs
+72-5Lines changed: 72 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -65,18 +65,29 @@ public SslStream(Socket socket)
65
65
}
66
66
67
67
/// <summary>
68
-
/// Called by clients to authenticate the server and optionally the client in a client-server connection.
68
+
/// Called by clients to authenticate the server and optionally the client in a client-server connection.
69
69
/// The authentication process uses the specified SSL protocols.
70
70
/// </summary>
71
71
/// <param name="targetHost">The name of the server that will share this SslStream.</param>
72
72
/// <param name="enabledSslProtocols">The <see cref="SslProtocols"/> value that represents the protocol used for authentication.</param>
73
+
/// <exception cref="InvalidOperationException">Authentication has already been performed on this stream, or all native SSL context slots are in.</exception>
74
+
/// <exception cref="OutOfMemoryException">A memory allocation failed while setting up the SSL context. The device may be low on heap.</exception>
/// Called by clients to authenticate the server and optionally the client in a client-server connection.
90
+
/// Called by clients to authenticate the server and optionally the client in a client-server connection.
80
91
/// The authentication process uses the specified certificate collections and SSL protocols.
81
92
/// </summary>
82
93
/// <param name="targetHost">The name of the server that will share this SslStream.</param>
@@ -85,13 +96,27 @@ public void AuthenticateAsClient(string targetHost, SslProtocols enabledSslProto
85
96
/// <remarks>
86
97
/// Instead of providing the client certificate in the <paramref name="clientCertificate"/> parameter the <see cref="UseStoredDeviceCertificate"/> property can be used to use the certificate stored in the device.
87
98
/// </remarks>
99
+
/// <exception cref="InvalidOperationException">Authentication has already been performed on this stream, or all native SSL context slots are in.</exception>
100
+
/// <exception cref="OutOfMemoryException">A memory allocation failed while setting up the SSL context. The device may be low on heap.</exception>
/// Called by clients to authenticate the server and optionally the client in a client-server connection.
119
+
/// Called by clients to authenticate the server and optionally the client in a client-server connection.
95
120
/// The authentication process uses the specified certificate collections and SSL protocols.
96
121
/// </summary>
97
122
/// <param name="targetHost">The name of the server that will share this SslStream.</param>
@@ -101,20 +126,48 @@ public void AuthenticateAsClient(string targetHost, X509Certificate clientCertif
101
126
/// <remarks>
102
127
/// Instead of providing the client certificate in the <paramref name="clientCertificate"/> parameter the <see cref="UseStoredDeviceCertificate"/> property can be used to use the certificate stored in the device.
103
128
/// </remarks>
129
+
/// <exception cref="InvalidOperationException">Authentication has already been performed on this stream, or all native SSL context slots are in.</exception>
130
+
/// <exception cref="OutOfMemoryException">A memory allocation failed while setting up the SSL context. The device may be low on heap.</exception>
/// Called by servers to authenticate the server and optionally the client in a client-server connection using the specified certificate,
149
+
/// Called by servers to authenticate the server and optionally the client in a client-server connection using the specified certificate,
111
150
/// verification requirements and security protocol.
112
151
/// </summary>
113
152
/// <param name="serverCertificate">The certificate used to authenticate the server.</param>
114
153
/// <param name="enabledSslProtocols">The protocols that may be used for authentication.</param>
115
154
/// <remarks>
116
155
/// Instead of providing the server certificate in the <paramref name="serverCertificate"/> parameter the <see cref="UseStoredDeviceCertificate"/> property can be used to use the certificate stored in the device.
117
156
/// </remarks>
157
+
/// <exception cref="InvalidOperationException">Authentication has already been performed on this stream, or all native SSL context slots are in.</exception>
158
+
/// <exception cref="OutOfMemoryException">A memory allocation failed while setting up the SSL context. The device may be low on heap.</exception>
@@ -124,11 +177,25 @@ public void AuthenticateAsServer(X509Certificate serverCertificate, SslProtocols
124
177
/// Called by servers to authenticate the server and optionally the client in a client-server connection using the specified certificates, requirements and security protocol.
125
178
/// </summary>
126
179
/// <param name="serverCertificate">The X509Certificate used to authenticate the server.</param>
127
-
/// <param name="clientCertificateRequired">A <see cref="Boolean"/> value that specifies whether the client is asked for a certificate for authentication. Note that this is only a request, if no certificate is provided, the server still accepts the connection request.</param>
180
+
/// <param name="clientCertificateRequired">A <see cref="Boolean"/> value that specifies whether the client is asked for a certificate for authentication. Note that this is only a request — if no certificate is provided, the server still accepts the connection request.</param>
128
181
/// <param name="enabledSslProtocols">The protocols that may be used for authentication.</param>
129
182
/// <remarks>
130
183
/// Instead of providing the server certificate in the <paramref name="serverCertificate"/> parameter the <see cref="UseStoredDeviceCertificate"/> property can be used to use the certificate stored in the device.
131
184
/// </remarks>
185
+
/// <exception cref="InvalidOperationException">Authentication has already been performed on this stream, or all native SSL context slots are in.</exception>
186
+
/// <exception cref="OutOfMemoryException">A memory allocation failed while setting up the SSL context. The device may be low on heap.</exception>
0 commit comments