mirror of
https://codeberg.org/keyoxide/doipjs.git
synced 2025-04-23 23:01:31 -06:00
Make IRC fetcher more abuse-proof by checking the sender's nick
This commit is contained in:
parent
a4d7aa7750
commit
9838d8d33e
1 changed files with 4 additions and 0 deletions
|
@ -76,6 +76,10 @@ export async function fn (data, opts) {
|
|||
})
|
||||
// @ts-ignore
|
||||
client.addListener('notice', (nick, to, text, message) => {
|
||||
// ignore notices from users that are not NickServ
|
||||
if (nick !== 'NickServ') {
|
||||
return
|
||||
}
|
||||
if (reKey.test(text)) {
|
||||
const match = text.match(reKey)
|
||||
keys.push(match[1])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue