Official Angular Security Guide speaks about 4 security contexts: HTML, Url, Style and Resource Url
.
Each one is responsible for sanitizing corresponding type of resource.
In addition, there are 5 methods (per resource type) in DomSanitizer service
- bypassSecurityTrustHtml
- bypassSecurityTrustScript
- bypassSecurityTrustStyle
- bypassSecurityTrustUrl
- bypassSecurityTrustResourceUrl
However, I didn't find any mention of SecurityContext.NONE
in official documentation. And it's does exist in the code.
I would assume that it aggregates all the resource types, meaning the resource being sanitized can be HTML, which contains styling and scripts.
Is that the case? Any official source?