feat: SVG image captcha with noise and color distortion

This commit is contained in:
2026-07-13 18:33:31 +08:00
parent befd51dbd5
commit bc16833a57
4 changed files with 70 additions and 22 deletions

31
package-lock.json generated
View File

@@ -18,6 +18,7 @@
"multer": "^1.4.5-lts.1",
"mysql2": "^3.11.0",
"nodemailer": "^6.9.8",
"svg-captcha": "^1.4.0",
"uuid": "^9.0.0",
"xss": "^1.0.15"
}
@@ -996,6 +997,18 @@
"node": ">= 0.8"
}
},
"node_modules/opentype.js": {
"version": "0.7.3",
"resolved": "https://registry.npmjs.org/opentype.js/-/opentype.js-0.7.3.tgz",
"integrity": "sha512-Veui5vl2bLonFJ/SjX/WRWJT3SncgiZNnKUyahmXCc2sa1xXW15u3R/3TN5+JFiP7RsjK5ER4HA5eWaEmV9deA==",
"license": "MIT",
"dependencies": {
"tiny-inflate": "^1.0.2"
},
"bin": {
"ot": "bin/ot"
}
},
"node_modules/parseurl": {
"version": "1.3.3",
"resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz",
@@ -1263,6 +1276,24 @@
"node": ">=10.0.0"
}
},
"node_modules/svg-captcha": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/svg-captcha/-/svg-captcha-1.4.0.tgz",
"integrity": "sha512-/fkkhavXPE57zRRCjNqAP3txRCSncpMx3NnNZL7iEoyAtYwUjPhJxW6FQTQPG5UPEmCrbFoXS10C3YdJlW7PDg==",
"license": "MIT",
"dependencies": {
"opentype.js": "^0.7.3"
},
"engines": {
"node": ">=4.x"
}
},
"node_modules/tiny-inflate": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/tiny-inflate/-/tiny-inflate-1.0.3.tgz",
"integrity": "sha512-pkY1fj1cKHb2seWDy0B16HeWyczlJA9/WW3u3c4z/NiWDsO3DOU5D7nhTLE9CF0yXv/QZFY7sEJmj24dK+Rrqw==",
"license": "MIT"
},
"node_modules/toidentifier": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz",