Recently I've been working on a small chat program that utilizes web sockets to send messages to others that are connected to the website.
It is currently working great, the only problem I have with this is flood control. People are able to spam the chat without being blocked.
Essentially what I am looking for is some ideas about on how to control spam (ie if they send x messages in x time, they will be limited for x amount of time).