Secure Programming Cookbook for C and C++ is an important new resource for developers serious about writing secure code for Unix(including Linux) and Windows environments. This essential code companion covers a wide range of topics, including safe initialization, access control, input validation, symmetric and public key cryptography, cryptographic hashes and MACs, authentication and key exchange, PKI, random numbers, and anti-tampering.
接收pop3
Public Function Retrieve(ByVal rhs As Pop3Message) As Pop3Message
Dim message, response As String
Dim msg As New Pop3Message
msg.bytes = rhs.bytes
msg.number = rhs.number
message = "RETR " + rhs.number.ToString + vbCrLf
write(message)
response = Respond()
If response.Substring(0, 3) <> "+OK" Then
Throw New Pop3Exception(response)
End If
MsgBox(msg)
msg.retrieved = True
While (1 = 1)
response = Respond()
If response = "." + vbCrLf Then
Exit While
Else
msg.message += response
End If
End While
Return msg
End Function
Base64 demonstrates how easy it is to decipher
plaintext usernames and passwords. Never login to a public network resource
unless some type of encryption is being used, secure socket layer is one example.
Most FTP sites also use plaintext passwords.