Generate an integrity attribute for your styles and scripts with the click of a button

  • Henk Verlindeby Henk Verlinde
  • Download more icon variants from https://tabler-icons.io/i/clock01 min read
  • Download more icon variants from https://tabler-icons.io/i/calendar-eventMar 25, 2021
Generate an integrity attribute for your styles and scripts with the click of a button

Subresource Integrity (SRI) is a security feature that enables browsers to verify that resources they fetch (for example, from a CDN) are delivered without unexpected manipulation. It works by allowing you to provide a cryptographic hash that a fetched resource must match.

Source: mdn web docs

Progressive Web App (PWA) generating a <script> or <link> element with an integrity attribute.

App

Usage

  1. Enter URL of JS or CSS file — or drop a local file
  2. Select SHA strength
  3. Click Generate
  4. Click Copy
  5. Paste <script> or <link> element

Documentation

Acknowledgements

Based on:

Major changes:

  • Use one SHA option only — following current practice
  • Default to SHA-512 — following current browser support
  • Add Reset button
  • Replace Copied alert with in page message
  • Replace CSS with Water.css