Improve the Socket Handshakes
Created by: agraubert
Socket, QueuedSocket, SecureSocket, and SecureConnection all use a handshake scheme to determine if they're connected to an appropriate socket on the remote end by sending expected identifiers. SecureSocket additionally uses this scheme to confirm passwords used for its lowest encryption level.
The old scheme was rather fragile and involved initializing the same object multiple times. The new scheme only initiates each socket once and still ensures that each socket level is using the appropriate scheme.
This also changes the constructors for the various sockets to be more intuitive