UNPKG

@0xcert/ethereum-gateway-contracts

Version:

Smart contracts used by the gateway on the Ethereum blockchain.

10 lines (9 loc) 295 B
export async function getSignature(web3: any, claim: string, address: string) { const signature = await web3.eth.sign(claim, address); return { r: signature.substr(0, 66), s: `0x${signature.substr(66, 64)}`, v: parseInt(`0x${signature.substr(130, 2)}`) + 27, kind: 0, }; }