check message format from client