Browse Source

Add SRI hash script

Nicolas Lenz 7 months ago
parent
commit
3a5119d5ec
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      get-sri-hash

+ 6
- 0
get-sri-hash View File

@@ -0,0 +1,6 @@
1
+#!/usr/bin/env zsh
2
+
3
+# Calculates subresource integrity hash with OpenSSL.
4
+# Arg 1: Input file
5
+
6
+openssl dgst -sha384 -binary ${1} | openssl base64 -A

Loading…
Cancel
Save