Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function verifyPaymentChannelClaim(
channel: string,
amount: string,
signature: string,
publicKey: string
): string {
validate.verifyPaymentChannelClaim({channel, amount, signature, publicKey})
const signingData = binary.encodeForSigningClaim({
channel: channel,
amount: xrpToDrops(amount)
})
return keypairs.verify(signingData, signature, publicKey)
}