Untitled
import crypto from "crypto"; const salt = "JN7WKB7F8N45FUE4"; const raw = "{\"data\":{\"nickname\":\"Player240\",\"avatar\":\"\",\"level\":24},\"lb\":{\"score\":{\"$set\":24},\"locale\":{\"$set\":\"US\"}}}"; const result = crypto.createHmac("sha1", "ba49a241a5").update(raw).update(salt).digest("hex"); console.log(result)
Leave a Comment