peerjs-server
peerjs-server copied to clipboard
Implement payload validation
Thank you for this library.
While reviewing this project with ShiftLeft, I came across an insight pointing to this code
https://github.com/peers/peerjs-server/blob/master/src/api/v1/calls/index.ts#L20
It appears like the payload object has no type, sanitization or validation anywhere in the server and is left purely to the end client application to perform their own. It will be nice if there is a possibility to add some default validators and ability to add custom validators since it is not clear if all end user applications have both sanitization and validation.