# \[Archive\] Pregenerated Wallets

**URL:** <https://builder.metamask.io/t/archive-pregenerated-wallets/1192>\
**Category:** Embedded Wallets (Web3Auth)\
**Created:** [October 22, 2024, 9:55pm UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192 "2024-10-22T21:55:06Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![sdelvalle57](https://avatars.discourse-cdn.com/v4/letter/s/9de053/32.png) [@sdelvalle57](https://builder.metamask.io/u/sdelvalle57)\
**Post date:** [October 22, 2024, 9:55pm UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192/1 "2024-10-22T21:55:06Z")

</div>

> **🏛 Archived Content from Web3Auth Community**
> 
> This topic was originally posted by **sdelvalle57** on 10/23/2024.  
> This content has been migrated from our previous community forum to preserve valuable discussions.

* * *

I have a PnP Web Application EVM Based Chain sapphire\_devnet Project under base plan

I want to test if from response of the lookup url I can get the same evm wallet address after logging in in my app, Ive tried many approaches since there’s no much documentation nor examples of this topic, I had to reach at this forum for some help, this is the lookup link using email\_passwordless:

[https://lookup.web3auth.io/lookup?verifier=Darwin&verifierId=sdelvalle57@gmail.com&web3AuthNetwork=sapphire\_devnet&clientId=BGOuHe9fhDfK1KJSUHsTOvHENWCCoepmOAI531fLTf53-eq8qxvR4PO4akTaoysbUGBAXaDeNaxTsq0uaZTrT7M&](https://lookup.web3auth.io/lookup?verifier=Darwin&verifierId=sdelvalle57@gmail.com&web3AuthNetwork=sapphire_devnet&clientId=BGOuHe9fhDfK1KJSUHsTOvHENWCCoepmOAI531fLTf53-eq8qxvR4PO4akTaoysbUGBAXaDeNaxTsq0uaZTrT7M&)

Response:

```auto
{
  "data": {
    "evmAddress": "0x95ab4ade8bE591D47FB95710B5bE7DF1820Da6ed",
    "X": "3b471d50be0dc15e82600366753a53ce28c2249dabacfbad2809d14a9e91014a",
    "Y": "6c712d9ad16fc34b123eee2baf30cc2679f2b3d69ec26ba6cea96d705c654ef8",
    "isMfaEnabled": false
  },
  "success": true
}

```

And this is my app configuration:  
Im trying to wrap the connector into wagmi

```auto
export const config = createConfig({
  chains: process.env.REACT_APP_USE_CHAIN === 'polygon' ? [polygon] : [arbitrumSepolia],
  transports: { [arbitrumSepolia.id]: http(), [polygon.id]: http() },
  connectors: [SocialWeb3AuthConnector()],
});

```

Where SocialWeb3AuthConnector:

```auto
// Web3Auth Libraries
import { Web3AuthConnector } from '@web3auth/web3auth-wagmi-connector';
import { Web3Auth } from '@web3auth/modal';
import { EthereumPrivateKeyProvider } from '@web3auth/ethereum-provider';
import { CHAIN_NAMESPACES, WEB3AUTH_NETWORK } from '@web3auth/base';
import { AuthAdapter } from '@web3auth/auth-adapter';
export default function SocialWeb3AuthConnector() {
// Create Web3Auth Instance
const name = “Darwin Evolution”;
const clientId = “BGOuHe9fhDfK1KJSUHsTOvHENWCCoepmOAI531fLTf53-eq8qxvR4PO4akTaoysbUGBAXaDeNaxTsq0uaZTrT7M”
const chainConfig = {
logo: “https://web3auth.io/images/web3authlog.png”,
chainNamespace: CHAIN_NAMESPACES.EIP155,
chainId: process.env.REACT_APP_USE_CHAIN === “polygon” ? “0x89” : “0x66eee”,
rpcTarget: process.env.REACT_APP_USE_CHAIN === “polygon” ? process.env.REACT_APP_ALCHEMY_POLYGON_API_KEY as string : process.env.REACT_APP_QUICKNODE_ARBITRUM_SEPOLIA_API_KEY as string,
displayName: process.env.REACT_APP_USE_CHAIN === “polygon” ? “Polygon Mainnet” : “Arbitrum Sepolia”,
blockExplorerUrl: process.env.REACT_APP_USE_CHAIN === “polygon” ? process.env.REACT_APP_MATIC_SCAN as string : process.env.REACT_APP_SEPOLIA_SCAN as string,
ticker: process.env.REACT_APP_USE_CHAIN === “polygon” ? “MATIC” : “ETH”,
tickerName: process.env.REACT_APP_USE_CHAIN === “polygon” ? “Polygon” : “Arbitrum Sepolia”,
};
const privateKeyProvider = new EthereumPrivateKeyProvider({ config: { chainConfig } });
const web3AuthInstance = new Web3Auth({
clientId,
chainConfig,
privateKeyProvider,
uiConfig: {
appName: name,
loginMethodsOrder: [“google”, “github”],
defaultLanguage: “en”,
modalZIndex: “2147483647”,
logoLight: “https://web3auth.io/images/web3authlog.png”,
logoDark: “https://web3auth.io/images/web3authlogodark.png”,
uxMode: “redirect”,
mode: “light”,
},
web3AuthNetwork:
  process.env.REACT_APP_USE_CHAIN === 'polygon'
    ? WEB3AUTH_NETWORK.SAPPHIRE_MAINNET
    : WEB3AUTH_NETWORK.SAPPHIRE_DEVNET,
enableLogging: true

});
const authAdapter = new AuthAdapter({
adapterSettings: {
loginConfig: {
email_passwordless: {
verifier: “Darwin”, // Pass the Verifier name here. eg. aggregate-sapphire
typeOfLogin: “email_passwordless”
},
google: {
verifier: “DarwinGoole”,
typeOfLogin: “google”
}
},
},
});
web3AuthInstance.configureAdapter(authAdapter);

```

Trying to use both passwordless or google Im still getting a different wallet address

Any help would be much appreciated

---

<div class="post-metadata">

**Author:** ![w3abot](https://avatars.discourse-cdn.com/v4/letter/w/4da419/32.png) [@w3abot](https://builder.metamask.io/u/w3abot)\
**Post date:** [October 22, 2024, 9:57pm UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192/2 "2024-10-22T21:57:28Z")

</div>

Hi Santiago! Thanks for reaching out and providing such detailed information about your issue. It sounds like you’re encountering a challenge with pre-generated wallets in your PnP Web Application on the EVM-based chain, specifically with maintaining the same wallet address after login.

Here’s a summary of the details you’ve provided:

### Issue Details:

- **SDK Details** : PnP Web SDK
- **Platform** : Web Application (EVM-Based)
- **Environment** : sapphire\_devnet
- **Lookup URL** : Provided
- **Expected Outcome** : Consistent EVM wallet address after login
- **Code Snippets** : Shared login configuration code and setup for the `SocialWeb3AuthConnector`

### Response from Lookup:

You’re receiving a wallet address from the lookup URL, but after logging in with either passwordless or Google, the wallet address differs.

### Proposed Solutions:

1. **Double-check the Verifier** : Ensure that the Verifier name you’re using in the authentication configuration matches the one used when generating the wallets. This will help maintain consistency in the wallet retrieval process.
2. **Session Management** : Check if there’s any session-related handling that could be influencing wallet generation across different login methods (passwordless vs. Google).
3. **Logger** : Since you have logging enabled in `Web3Auth`, check the logs for any discrepancies or errors during the login process that relate to wallet generation.

Would it be possible for you to share any error messages from the browser console associated with this issue? Additionally, if you have any screenshots or links to further clarify the problem, that would be helpful for our support team to dive deeper into the issue.

Looking forward to helping you sort this out!

> Note: This response was generated by an AI bot and may require further verification. The Web3Auth support team has tracked this issue and will be responding as soon as possible.

---

<div class="post-metadata">

**Author:** ![sdelvalle57](https://avatars.discourse-cdn.com/v4/letter/s/9de053/32.png) [@sdelvalle57](https://builder.metamask.io/u/sdelvalle57)\
**Post date:** [October 22, 2024, 10:42pm UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192/3 "2024-10-22T22:42:01Z")

</div>

Sure, this is my Web3Auth project configuration:

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/394de5a634d75f134a75d8038b1480c5fc08d457.png)
image1666×796 65.8 KB
](https://web3auth.io/community/uploads/default/original/2X/d/dda2d2910076218235b3c1f678f5fbd420fc7230.png "image")

And the custom authentication methods I have set:

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/4f3a3bcfaac15f688e2a8627b6982706f0f0ee0c.png)
image1685×581 46.4 KB
](https://web3auth.io/community/uploads/default/original/2X/a/aee96e24b46b9388023949d2de5dfc93deaf815d.png "image")

So the lookup query would be something like this:

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/1312b9168ba3fa4eb34b0de4f6f6a0b6c14ab1ee.png)
image1100×938 112 KB
](https://web3auth.io/community/uploads/default/original/2X/3/3985afbc8b7f28edd7b7842b7fdb9391c4eb2eb2.png "image")

This is what happens when running the app:

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/0a8770f097598e997c2d41c0bb8d8cc9cb21e810.png)
image874×586 141 KB
](https://web3auth.io/community/uploads/default/original/2X/9/92b20c2eae6739751a189497d4be183267c85d69.png "image")

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/e27c9fb94e6ee3c2839828853710b85ab1ae2267.png)
image874×586 27.3 KB
](https://web3auth.io/community/uploads/default/original/2X/4/489897ded9a1778d055f7f6725085cffab824715.png "image")

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/e84d63b20453f6c733133be13f1751ab557e2d2f.png)
image857×945 103 KB
](https://web3auth.io/community/uploads/default/original/2X/d/d620e3f27caeb052b392c5bb9e5bb6a504bd1453.png "image")

If you see there’s a mismatch between wallet addresses

Is there an example of an app where it shows it matches the addresses from the lookup query?

---

<div class="post-metadata">

**Author:** ![maharshi](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/maharshi/32/1525_2.png) [@maharshi](https://builder.metamask.io/u/maharshi)\
**Post date:** [October 23, 2024, 4:16am UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192/4 "2024-10-23T04:16:35Z")

</div>

Hey @sdelvalle57,

The mismatch you’re experiencing is likely due to the missing `useCoreKitKey: true` flag in your Web3Auth constructor. I know the documentation might feel a bit light on details, but it’s important to take a close look at what’s already there.

If you scroll up from the screenshot you posted, there’s a section that explains the situation clearly:

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/2d2de3252e16f3a2865309ca5315e2dd9141ff58.jpeg)
image1920×1993 224 KB
](https://web3auth.io/community/uploads/default/original/2X/1/1107cca7aba3356a350171dc082d9b0dca2caf66.jpeg "image")

It states:

> “This API only returns the Core Kit Key wallet addresses. To use the wallet addresses with the Web3Auth SDKs, you will need to either use the _`useCoreKitKey` flag_ in our PnP SDKs or use any of our Core Kit SFA SDKs.”

If you search for `useCoreKitKey` in the docs, you’d find the relevant details for the Modal SDK right here: [Initializing PnP Web Modal SDK | Documentation | Web3Auth](https://web3auth.io/docs/sdk/pnp/web/modal/initialize#web3authoptions)

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/086c6259bf4a7fadcd10b685c9fef72076439585.jpeg)
image1920×1993 164 KB
](https://web3auth.io/community/uploads/default/original/2X/2/2b3fad3c85973db8cd4eb7e58551f4f1595d388b.jpeg "image")

Hope this helps to get everything aligned for you! Let me know if anything else comes up.

---

<div class="post-metadata">

**Author:** ![sdelvalle57](https://avatars.discourse-cdn.com/v4/letter/s/9de053/32.png) [@sdelvalle57](https://builder.metamask.io/u/sdelvalle57)\
**Post date:** [October 23, 2024, 12:45pm UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192/5 "2024-10-23T12:45:54Z")

</div>

Thank you for you response

But Ive also tried to add the coreKit flag, but when I do this I get:

`Failed to connect with cached openlogin provider WalletLoginError: useCoreKitKey flag is enabled but coreKitKey is not available. `

---

<div class="post-metadata">

**Author:** ![sdelvalle57](https://avatars.discourse-cdn.com/v4/letter/s/9de053/32.png) [@sdelvalle57](https://builder.metamask.io/u/sdelvalle57)\
**Post date:** [October 23, 2024, 10:12pm UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192/6 "2024-10-23T22:12:00Z")

</div>

Ok, now I managed to make it work by updating packages to latest.  
Now I have an issue trying to implement `email_passwordless` functionality:

This is the web3 connector instance:

```auto
// Web3Auth Libraries
import { Web3AuthConnector } from "@web3auth/web3auth-wagmi-connector";
import { Web3AuthNoModal } from "@web3auth/no-modal";
import { EthereumPrivateKeyProvider } from "@web3auth/ethereum-provider";
import { CHAIN_NAMESPACES, WEB3AUTH_NETWORK, UX_MODE } from "@web3auth/base";
import { WalletServicesPlugin } from "@web3auth/wallet-services-plugin";
import { AuthAdapter } from "@web3auth/auth-adapter";
export default function Web3AuthConnectorInstance(email: string) {
// Create Web3Auth Instance
const name = “My App Name”;
const chainConfig = {
logo: “https://web3auth.io/images/web3authlog.png”,
chainNamespace: CHAIN_NAMESPACES.EIP155,
chainId: “0x66eee”,
rpcTarget: “https://nameless-blissful-glitter.arbitrum-sepolia.quiknode.pro/68645066d69fab1fa0eb7cbdee71acdf9a91fb3c/”,
displayName: “Arbitrum Sepolia”,
blockExplorerUrl: “https://sepolia.arbiscan.io/”,
ticker: “ETH”,
tickerName: “Arbitrum Sepolia”,
};
const privateKeyProvider = new EthereumPrivateKeyProvider({ config: { chainConfig } });
const web3AuthInstance = new Web3AuthNoModal({
clientId: “BGOuHe9fhDfK1KJSUHsTOvHENWCCoepmOAI531fLTf53-eq8qxvR4PO4akTaoysbUGBAXaDeNaxTsq0uaZTrT7M”,
chainConfig,
privateKeyProvider,
uiConfig: {
appName: name,
defaultLanguage: “en”,
logoLight: “https://web3auth.io/images/web3authlog.png”,
logoDark: “https://web3auth.io/images/web3authlogodark.png”,
mode: “light”,
},
web3AuthNetwork: WEB3AUTH_NETWORK.SAPPHIRE_DEVNET,
enableLogging: true,
useCoreKitKey: true
});
const authAdapter = new AuthAdapter({
adapterSettings: {
loginConfig: {
email_passwordless: {
verifier: “DarwinPasswordless”,
typeOfLogin: “email_passwordless”,
clientId: “BGOuHe9fhDfK1KJSUHsTOvHENWCCoepmOAI531fLTf53-eq8qxvR4PO4akTaoysbUGBAXaDeNaxTsq0uaZTrT7M”
}
},
},
});
web3AuthInstance.configureAdapter(authAdapter);
const walletServicesPlugin = new WalletServicesPlugin({
walletInitOptions: {
whiteLabel: {
showWidgetButton: true,
}
}
});
web3AuthInstance.addPlugin(walletServicesPlugin);

```

And my App.tsx file, please note the login function how the connector gets injected into wagmi

```auto
// WAGMI Libraries
import { WagmiProvider, createConfig, http, useAccount, useConnect, useDisconnect } from "wagmi";
import { arbitrumSepolia } from "wagmi/chains";
import { QueryClient, QueryClientProvider } from '@tanstack/react-query' 
import { SendTransaction } from “./sendTransaction”;
import { SwitchChain } from “./switchNetwork”;
import { Balance } from “./balance”;
import { WriteContract } from “./writeContract”;
import Web3AuthConnectorInstance from “./Web3AuthConnectorInstance”;
import “./App.css”;
const queryClient = new QueryClient()
// Set up client
const config = createConfig({
chains: [arbitrumSepolia],
transports: { [arbitrumSepolia.id]: http() },
connectors: [
// Web3AuthConnectorInstance([arbitrumSepolia]),
],
});
function Profile() {
const { address, connector, isConnected } = useAccount();
const { connect, connectors, error } = useConnect();
const { disconnect } = useDisconnect();
const login = () =>{
const web3AuthConnector = Web3AuthConnectorInstance(“sdelvalle57@gmail.com”);
if (!web3AuthConnector) {
console.log(“no web3auth connector”)
return;
}
connect({ connector: web3AuthConnector });

}
if (isConnected) {
return (
<div className=“main”>
<div className=“title”>Connected to {connector?.name}</div>
<div>{address}</div>
<button className=“card” onClick={disconnect as any}>
Disconnect
</button>
<SendTransaction />
<Balance />
<WriteContract />
<SwitchChain />
</div>
);
} else {
return (
<div className=“main”>
<button onClick={login}>Email</button>
</div>
);
}
}
// Pass client to React Context Provider
function App() {
return (
<WagmiProvider config={config}>
<QueryClientProvider client={queryClient}>
<div className=“container”>
<Profile />
</div>
</QueryClientProvider>
</WagmiProvider>
);
}

```

###### There seems to be some bug in the code. Please contact support to fix this.

###### Error occurred while verifying params unable to verify jwt token, [failed to verify jws signature: failed to verify message: failed to verify signature using ecdsa failed to verify jws signature: failed to verify message: crypto/rsa: verification error failed to verify jws signature: failed to verify message: crypto/rsa: verification error]

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/aefe43a00be8d0fb87150dafa3e37fa7ba14fbfe.png)
image1072×687 53.2 KB
](https://web3auth.io/community/uploads/default/original/2X/8/817f492bc9848d17d234f4c042726eeed747829f.png "image")

---

<div class="post-metadata">

**Author:** ![maharshi](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/maharshi/32/1525_2.png) [@maharshi](https://builder.metamask.io/u/maharshi)\
**Post date:** [October 23, 2024, 11:53pm UTC](https://builder.metamask.io/t/archive-pregenerated-wallets/1192/7 "2024-10-23T23:53:52Z")

</div>

Hey @sdelvalle57,  
Could you please submit a recording of the issue using a tool like jam.dev? We need more logs to properly understand what’s happening. We’ll take cognizance of the issue and report it to the team for a closer look.
