Modularized websocket authentication and filled out frontend chat functionality/validation