Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const signDemo = async () => {
console.log('signDemo')
const keys = await RSA.generate()
const signature = await RSA.sign(secret, keys.private)
console.log('signature', signature);
const valid = await RSA.verify(signature, secret, keys.public)
console.log('verified', valid);
}