Created
April 11, 2022 20:48
-
-
Save MarkTiedemann/8c41938c1224c8d2a3f7271afe184acc to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Usage: node sha384.mjs <file> | |
| import fs from "node:fs"; | |
| import crypto from "node:crypto"; | |
| import process from "node:process"; | |
| console.log( | |
| "sha384-" + crypto | |
| .createHash("sha384") | |
| .update( | |
| fs.readFileSync(process.argv[2]) | |
| ) | |
| .digest("base64")); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment