0

I've generated thousands of addresses with my seed phrase and deposited some USDT tokens to one of them (m/44'/60'/0'/267) and ensured that I'm able to spend that tokens. But after I've imported this seed phrase to Metamask and Trust wallet, I see no tokens on the balance. enter image description here

4
  • 1
    If the tokens really are in the address you may need to add the token manually in Metamask - click the "Add token" button – Lauri Peltonen Jan 6 at 12:23
  • Yes, I tried to add token from templates and as a custom token but in both cases metamask provides info about only frst generated address instead of all addresses – Vassily Jan 6 at 12:29
  • Can you disclose what tool/library/app you used to generate the addresses? – The Renaissance Jan 10 at 15:20
  • @TheRenaissance py_crypto_hd_wallet. It generate proper address that I successfully imported to MyEtherWallet but it was not an action of 3 clicks – Vassily Jan 11 at 1:42
0
+50

Let's talk about what's going on, and then talk about a potential solution for the OP's specific case. When generating many accounts from one seed, there is a master keypair (public and private keys, just like a regular keypair), and then the other accounts have their private and public keys generated from that keypair. The generated accounts do not have the same private key as the master keypair. As a result, when the master private key is used to import an account in MetaMask or similar, only the master account is imported. In order to import the specific address holding the USDT, you'll need the private key from that specific keypair.

Now for a potential solution: First, a caveat. I'm out of my league a bit here, but will try to mention a path that might totally work, and might have a chance of working, and might be very unlikely to work.

The OP mentioned in comments that the accounts were generated using py_crypto_hd_wallet. Looking at their README (here), we can offer a few solutions in Python. I strongly recommend verifying my solutions - I've just familiarized myself with this library now.

Assuming that you can recreate the wallet either using the mnemonic, seed, or private key as detailed here, we should be able to set up a script that tries to find the private key of your USDT-holding account so that you cna import it into MetaMask. We'll be calling the wallet hd_wallet in the code (following the README).

# this skips the imports and generating the wallet, as detailed above

hd_wallet.Generate(addr_num=10000)
addresses = hd_wallet.GetData(HdWalletDataTypes.ADDRESSES)
USDT_address = "PUT_THE_ADDRESS_WITH_THE_USDT_HERE_STARTING_WITH_0x"

for address in addresses:
    if address == USDT_address:
        print(address.GetKey(HdWalletKeyTypes.EX_PRIV))
        break

One thing I don't know is if given the same master key, if the same key pairs are always generated in the same order. As such, you'll see that I've set the generate event to generate 10K addresses. If the keypair generation has entropy in it (meaning that different accounts are generated when the same master is run through the generator), than I do not know what the probability of this working is. If someone here knows key generation stuff better than me, please comment if this is a waste of time.

Assuming it's not a waste of time, even if you don't find the key the first time, you can always generate more accounts at once. This may be resource intensive, and will likely run for a long time.

2
  • Finally, I don't found a better solution than to access funds by private key every time I need to send it to my wallet. I'm so sad that the industry still doesn't offer software that cat do it for me. Anyway, I will accept this answer and give the author a bounty since this answer was the last point before I decided to stop the research – Vassily Jan 15 at 20:09
  • Thanks! Please leave feedback if this works, or if it doesn't. – The Renaissance Jan 17 at 18:06
0

You can try to import the wallet into myetherwallet.com or mycrypto.com app. What you need is add the contract address for the token if its not included as standard in your wallet of choice.

3
  • 1
    Myetherwallet allowed me to access 267th address, thanks! But it's so annoying process to scroll to it with 5 addresses per click. Is there any better solution? – Vassily Jan 9 at 12:27
  • In my etherwallet after entering the words there is an option to add custom derivation path right next to HD Derivation path (scroll down to bottom of list - Add custom path). Name it in alias and in path enter that of yours for example m/44'/1'/0'/267 and by choosing that you will always go to that one directly – KeychainX Jan 11 at 8:57
  • I tried this way but it's not offering me to choose desired 267th address. Instead of that it generates another set of addresses where first is different than first in m/44'/60'/0'/0's one – Vassily Jan 11 at 9:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.