websocket frame encoder/decoder