Regular Expressions 101

Community Patterns

1...56789...864

Discord links scam detector

1

Regular Expression
PCRE2 (PHP >=7.3)

/
\[(?:http(?:s)?(:\/\/)?)?(www\.)?discord\S*\]\(((?!discord)\S)*\)
/
gm

Description

This regex tries to mitigate some of the most common scam practices found in discord since the support of masking links.

Submitted by KifoPL - 4 months ago