Detect ?format=jpg/png images

Fixes #112
This commit is contained in:
Zed 2020-01-19 09:01:11 +01:00
parent edb3751181
commit 973ba585c7

View file

@ -4,8 +4,8 @@ import nimcrypto, regex
var hmacKey = "secretkey" var hmacKey = "secretkey"
const const
badJpgExts = @["1500x500", "jpgn", "jpg:", "jpg_"] badJpgExts = @["1500x500", "jpgn", "jpg:", "jpg_", "_jpg"]
badPngExts = @["pngn", "png:", "png_"] badPngExts = @["pngn", "png:", "png_", "_png"]
twitterDomains = @[ twitterDomains = @[
"twitter.com", "twitter.com",
"twimg.com", "twimg.com",