Sockets secure implementations

Rebased on `master`.
Add a comment here saying why it's not necessary to remove the read interest.