minor fixes, monkey for sockets/ssl