Working three way handshake