Malicious input vulnerability in Source interface mitigated
THREAT20
· Mitigated: Controls in place bring the risk down to an acceptable level.
· Defined in catalog.py:360
- Risk
- Medium impact × Low likelihood = 4 medium
- After mitigations
- Medium impact × Low likelihood = 4 medium (unchanged)
Failure to adequately validate content coming from Sources may result in injection vulnerabilities in the Source interface (SQL injection, XSS, CSRF) and result in an attacker being able to execute arbitrary commands on the server or in a Source's browser.
Threat actors: Any
Mitigations
| Mitigation | Status |
|---|---|
| Tor security slider set to high MITIG67 | optional |
| X-XSS-protection, CSP set to self MITIG71 | implemented |
| SQLAlchemy as an ORM MITIG68 | implemented |
| Use of Flask/Jinja for templating escaping MITIG64 | implemented |
Possible further mitigations
- Verify all attributes are quoted as per http://flask.pocoo.org/docs/0.12/security/ MITIG80 proposed
- Use WAF MITIG78 proposed
Where it applies
Applies to 1 component in 2 scenarios.
Source submission · Source Interface
Supply chain and dependencies · Source Interface
Notes
Existing mitigations: Sources are instructed to set the Tor Browser security to "high" to prevent scripts from running on the page (MITIG67). X-XSS-PROTECTION is enabled and Content-Security-Policy set to self (MITIG71). SQLAlchemy is used as ORM for all database queries (MITIG68). Flask/Jinja2 escapes all HTML content (though not attributes) (MITIG64). Further mitigations: Validate that all attributes are quoted per http://flask.pocoo.org/docs/0.12/security/ (MITIG80), use a WAF to further increase defense-in-depth (e.g. Apache Modsecurity) (MITIG78). Automated test for mitigation: Yes.
How this threat is matched
Listed for these components. A boundary covers every component inside it.