#!/usr/bin/node function sha512(s) { const sha512 = require('crypto').createHash('sha512') const data = sha512.update(s, 'utf-8') return data.digest('hex') } const secretkey = 'Tim was here' const github = 'This is a test' const mac = sha512(secretkey + sha512(secretkey + github)).substr(0, 12) console.log(mac)
You can't compute the SupportKey in the browser because it would give up the secret key. Thus, the SupportKey needs to be computed on the server using node.js.
This JavaScript code is included for testing.
GitHub Name: