dumpmon
dumpmon copied to clipboard
FIX: lib/regexes.py update 'telegram_bot' regular expression.
I came along this repository by searching for a Telegram Bot API token regular expression. After checking the token format from a SO answer, i found a possible incorrectness in the 'telegram_bot' regex format.
In lib/regexes.py line 15:
change the regex from:
r'\d{9}:[0-9A-Za-z_-]{35}'
to:
r'^[0-9]{8,10}:[0-9A-Za-z_-]{35}$'
The line was last edited on this issue -> #15
The related SO answer ( which i also later adjusted ) is this https://stackoverflow.com/questions/61868770/tegram-bot-api-token-format