mirror of
https://github.com/ergochat/ergo.git
synced 2025-10-27 20:07:33 +01:00
fix validation of web push URLs
They are validated by test message, but it would have been possible to add an http url. If an http url was added, it's still possible to remove it via NS PUSH DELETE.
This commit is contained in:
parent
92f069846c
commit
6b8265fb17
@ -3934,6 +3934,7 @@ func webpushHandler(server *Server, client *Client, msg ircmsg.Message, rb *Resp
|
||||
|
||||
if err := webpush.SanityCheckWebPushEndpoint(endpoint); err != nil {
|
||||
rb.Add(nil, server.name, "FAIL", "WEBPUSH", "INVALID_PARAMS", subcommand, client.t("Invalid web push URL"))
|
||||
return false
|
||||
}
|
||||
|
||||
switch subcommand {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user