@@ -30,7 +30,7 @@ Namespace Examples.System.Net
3030 ProcessClient(client)
3131 End While
3232 End Sub
33- '<snippet1
33+ '<snippet1>
3434 Private Shared Sub ProcessClient(client As TcpClient)
3535 ' A client has connected. Create the
3636 ' SslStream using the client's network stream.
@@ -108,8 +108,8 @@ Namespace Examples.System.Net
108108
109109 Return messageData.ToString()
110110 End Function
111-
112111 ' </snippet2>
112+
113113 ' <snippet3>
114114 Private Shared Sub DisplaySecurityLevel(stream As SslStream)
115115 Console.WriteLine( "Cipher: {0} strength {1}" , stream.CipherAlgorithm, stream.CipherStrength)
@@ -118,21 +118,22 @@ Namespace Examples.System.Net
118118 Console.WriteLine( "Protocol: {0}" , stream.SslProtocol)
119119 End Sub
120120 '</snippet3>
121- '<snippet4>
122121
122+ '<snippet4>
123123 Private Shared Sub DisplaySecurityServices(stream As SslStream)
124124 Console.WriteLine( "Is authenticated: {0} as server? {1}" , stream.IsAuthenticated, stream.IsServer)
125125 Console.WriteLine( "IsSigned: {0}" , stream.IsSigned)
126126 Console.WriteLine( "Is Encrypted: {0}" , stream.IsEncrypted)
127127 End Sub
128128 ' </snippet4>
129+
129130 ' <snippet5>
130131 Private Shared Sub DisplayStreamProperties(stream As SslStream)
131132 Console.WriteLine( "Can read: {0}, write {1}" , stream.CanRead, stream.CanWrite)
132133 Console.WriteLine( "Can timeout: {0}" , stream.CanTimeout)
133134 End Sub
134-
135135 ' </snippet5>
136+
136137 ' <snippet6>
137138 Private Shared Sub DisplayCertificateInformation(stream As SslStream)
138139 Console.WriteLine( "Certificate revocation list checked: {0}" , stream.CheckCertRevocationStatus)
@@ -153,8 +154,8 @@ Namespace Examples.System.Net
153154 Console.WriteLine( "Remote certificate is null." )
154155 End If
155156 End Sub
156-
157157 ' </snippet6>
158+
158159 Private Shared Sub DisplayUsage()
159160 Console.WriteLine( "To start the server specify:" )
160161 Console.WriteLine( "serverSync certificateFile.cer" )
0 commit comments