I had previously implemented SFA with Custom Auth and it was working fine.
When I created a new Custom Verifier on the new Dashboard, the new Verifier did not pass authentication and gave me an error. Error: Verifier not supported
When I had a similar error before, it was due to a different web3AuthNetwork in the new Web3Auth parameter, so I am wondering if this is the cause of the error again.
At first, I was able to create it with mainnet, but from the middle of the process, I was only able to select Aqua, and this time it is Sapphire.
Does anyone have any idea what the cause might be?
Please provide the following details too when asking for help in this category:
I created a project with Legacy Testnet and Verifier and checked it.
The result is the same as sapphire_devnet.
In case of web3AuthNetwork: ‘sapphire_devnet’, Verifier not supported error is displayed, and in case of web3AuthNetwork: ‘testnet’, wallet generation itself works fine.
The error seems to be in the part of my application where the private key is retrieved after the wallet is generated, but I wonder if the method of retrieving the private key has changed.
If the user has not enabled MFA, we use the @web3auth/single-factor-auth sdk to retrieve the private key shares from the Web3Auth auth network nodes and reconstruct the private key.
My account is not MFA enabled, but it doesn’t seem to work. I stated earlier that the wallet was created, but it seems to be an error in the connect portion of the process.
Looking at the contents of the log in the above capture (presumably the log produced by Lib), it seems that privkey corresponds to the private key, and I was able to actually load the wallet by importing this one.
Therefore, it seems that torus is able to generate the pkey, but an error is occurring when it gets the pkey to the web3auth side.
Hi @taaaaho, could you please create a new custom verifier using this guide. This has been our go-to guide which has solved a lot of issues with custom verifiers.
Please don’t forget to change the client id if you create the verifier with another project. And also the network you’re creating the verifiers on.
Hi @maharshi , thank you for your advice.
In the case of custom authentication, does single-factor-auth not work?
It would be helpful for existing customers to be able to use the same code that worked with single-factor-auth before the change to the new structure.
I have also tried the code you mentioned, but I get the following error
WalletInitializationError: Wallet is not found, Please add wallet adapter for openlogin wallet, before connecting
at WalletInitializationError.fromCode (base.esm.js:242:1)
at WalletInitializationError.notFound (base.esm.js:248:1)
at Web3AuthNoModal.connectTo (noModal.esm.js:117:77)
at initWeb3Auth (useWeb3Auth.ts:111:47)
at startWeb3AuthForCreateWallet (_app.tsx:64:31)
The sample code does not use an openLoginAdapter instance after it is created, is this correct?
const openloginAdapter = new OpenloginAdapter({
adapterSettings: {
uxMode: "redirect", // redirect or popup
loginConfig: {
jwt: {
verifier: "verifier-name", // name of the verifier created on Web3Auth Dashboard
typeOfLogin: "jwt",
clientId: "", // Web3Auth Client ID
},
},
},
privateKeyProvider,
});
await web3auth.connectTo(WALLET_ADAPTERS.OPENLOGIN, {
loginProvider: "jwt",
extraLoginOptions: {
id_token: "YOUR_GENERATED_ID_TOKEN",
verifierIdField: "sub", // sub, email, or custom
},
});
....