Flutter - Fetch signature of a user from Web3Auth

47 views Asked by At

I need to fetch the signed message of a user that has been authenticated using Web3Auth.

There is a function in React that helps fetching the same, as below: const web3 = new Web3(this.provider);

  const fromAddress = (await web3.eth.getAccounts())[0];

  const originalMessage = "YOUR MESSAGE";

  const signedMessage = await web3.eth.personal.sign(
    originalMessage,
    fromAddress,
    "YOUR PASSWORD"
  );

  return signedMessage;

How do I get the same result in Flutter? I am using web3auth_flutter package for the authentication

0

There are 0 answers