fix compile error
update socket's interface
improve socket class
add interface to socket
fix issue: the handshake result judgement is wrong