feat: add BlogBodySanitizer for HTML sanitization on article save

- Implemented BlogBodySanitizer to clean HTML content before saving articles, ensuring security against XSS attacks.
- Added tests for BlogBodySanitizer to verify that unsafe tags and attributes are stripped from the content.
- Introduced ApiLeastPrivilegeTest to ensure that unauthorized users cannot access sensitive API routes, maintaining strict access control.
This commit is contained in:
hamed
2026-08-07 21:13:38 +03:30
parent a4a24c51af
commit 6876135a53
114 changed files with 2067 additions and 269 deletions
+3 -2
View File
@@ -1,6 +1,7 @@
{
"overrides": {
"lodash": "^4.17.21"
"lodash": "^4.17.21",
"lodash-es": "^4.18.1"
},
"devDependencies": {
"@babel/core": "^7.17.0",
@@ -51,7 +52,7 @@
"react-hook-form": "^7.0.0",
"react-hot-toast": "^2.0.0",
"react-leaflet": "^5.0.0",
"react-router-dom": "^7.0.0",
"react-router": "^8.3.0",
"react-select": "^5.0.0",
"recharts": "^3.8.1",
"sonner": "^1.0.0",