Sockets secure implementations

Rebased on `master`.
This looks like a busy loop since it's one line and the method name seems like a getter. Suggestion:
    boolean hasWork = true;
    while(hasWork) {
      hasWork = msg.socket.performNextHandshakeStep();
    }