# Subresource Integrity (SRI)

> What is Subresource Integrity (SRI), how does the browser enforce it, and when should you use it for scripts loaded from a CDN?

Canonical: https://www.internhack.in/learn/interview/web-security/security-subresource-integrity
Last updated: 2026-11-28

Difficulty: Intermediate

## Question

What is Subresource Integrity (SRI), how does the browser enforce it, and when should you use it for scripts loaded from a CDN?

*The full answer is for InternHack members. Open the page link above to read it.*

## Concepts covered

Subresource Integrity, integrity attribute, SHA-384, CDN Compromise, Supply Chain Security, CORS

Previous: [CSP: Content Security Policy](https://www.internhack.in/learn/interview/web-security/security-content-security-policy) · Next: [Same-Origin Policy (SOP)](https://www.internhack.in/learn/interview/web-security/security-same-origin-policy) · [All of Web Security (OWASP, JWT, XSS, CSRF)](https://www.internhack.in/learn/interview/web-security)

## More Web Security (OWASP, JWT, XSS, CSRF) questions

- [Brute Force Protection](https://www.internhack.in/learn/interview/web-security/security-brute-force-vulnerability)
- [CSPRNG](https://www.internhack.in/learn/interview/web-security/security-cryptographically-secure-random)
- [Data at Rest](https://www.internhack.in/learn/interview/web-security/security-sensitive-data-rest)
- [Security Misconfiguration](https://www.internhack.in/learn/interview/web-security/security-security-misconfiguration)
- [Phishing Protection](https://www.internhack.in/learn/interview/web-security/security-phishing-prevention)
- [Social Engineering](https://www.internhack.in/learn/interview/web-security/security-social-engineering-basics)

## Related

- [Learn](https://www.internhack.in/learn)
- [Interview Prep](https://www.internhack.in/learn/interview)
- [Web Security (OWASP, JWT, XSS, CSRF)](https://www.internhack.in/learn/interview/web-security)
