7

I'm having a bit of trouble completely understanding the inner workings of ETH and the Ethereum wallet UI vs Mist (when having used testnet), and I need to ask some rather stupid questions to understand the history and reasoning. If this is not the place, I apologize.

  • Generally i don't understand the difference between Mist and Etherum Wallet applications? What is the history of each ?

  • What I also not completely understand, is that a Wallet Contract and some tokens I believe I created on testnet seems to be visible in Ehereum Wallet even when having switched back to mainnet? If i transfer funds when in mainnet, to the above mentioned Wallet Contract, wouldn't they be lost?

I understand that an address can exist in both nets, and that if I have the pk for a particular address, I can retrieve the funds in any net, - but when it's a wallet contract that only exist on testnet, and not just an account, what happens?

  • How do I generally know if i "own" a Wallet Contract, and if I am able to access it and send funds from it? It is "attached" to my Etherbase address or how does that work?

  • Now if i open "Mist" application, everything is as I would probably expect, - I can see my main account, and none of the testnet stuff. Is all my troubles actually what Mist fixes ?

Thank you

1
  • When i understand it right, I can remove my Ethereum Wallet app incl. all historical files on the Mac and can continue with the MIST. How it relates to the private key of the Ethereum Wallet ? Is this key automatically taken over? I haven't the MIST in full function - still loading -, but it seems to establish this in order to prevent me from having 2 double blockchains. Aug 27, 2017 at 10:14

2 Answers 2

5

Ethereum Wallet and Mist share the same source repository (https://github.com/ethereum/mist). Mist is a wallet enabled browser, and "Ethereum Wallet" is Mist but with the browser capability disabled, so you can use it as a wallet. I don't know about recent version but at some point you were able to switch between them with a command line option.

Mainnet y testnet are two independent blockchains. They use the same type or private keys, so you can use the same "address" in both, but you cannot exchange funds or tokens between the blockchains, each blockchain has its own independent state.

Ownership of a contract can mean different things. There's the address that has deployed the contract, but it has no other special properties over the contract, unless it is coded in the source code.

Ownable is common pattern used where there contract declares an special owner. Initially assigned to the deploying address, but it can be changed later. It provides a modifier to restrict access to critical methods only to the owner of the contract.

I'm no sure but I think Ethereum Wallet/Mist has a separate storage for mainnet/testnet, so you can switch between them without problem. But in any case proper care should be taken, make sure to backup your keys when switching because some operations cannot be reversed in case of a mistake.

Thanks to Thomas Jay Rush for confirming the separate storage for mainnet and testnet in Mist/Ethereum Wallet.

2
  • 1
    Definitely separate storage between mainnet and testnet. You should correct that. Otherwise, nice answer. Jul 19, 2017 at 3:15
  • Thank you for your reply. I am currently investigating more inner details and I will try to summarize for final verification.
    – Jesper
    Jul 20, 2017 at 10:32
4

First of all, thank you for taking your time to answer. I have done some further investigations, and I will try to summarize my findings in a new answer.

I hope someone will do a final verification of the statements below and correct me in case something is not correct, maybe it can help others with similar knowlegde gaps.

I got alot of the information from https://klmoney.wordpress.com/beta7-contract-wallets/, and it's for version 0.4 (we're at 0.8) but should be ok; and from here https://forum.daohub.org/t/do-you-need-to-backup-eth-wallet-contracts/887

[Wallet Contracts]

  • In Ethereum, there are two types of Accounts: [Externally Owned Accounts] (EOAs) (or simply "Accounts") and [Contract Accounts].

  • "Accounts" can be thought of simply as private key/address pairs, and serve two roles; as bare stores of ether in their own right, and as OWNERS (or controllers) of Contract Wallets.

  • While an "Account" has a password-protected private key and an address, a Contract Account has no private key but has an address, code, and storage.

  • Contract Wallets (or contract-based wallets) are built with Contract Accounts, utilizing the ability of Contract Accounts to hold and run code with associated persistent storage.

  • Certain receivers, especially exchanges may not be setup to receive from Contract Wallets, and also, sending ether from a Contract Wallet incurs a gas cost, and you only need the wallet in case you need multisig, transaction tracking or other similar functionality.

  • As the Contract Wallet/Contract Account is owned by the Basic ETHERBASE Account (Externally Owned Account), it can always be retrieved, by importing it into MIST. Network and MIST will know it belongs to the EOA, and allow spending.

  • If you only have the keystore, but forgot the contract wallet address, look up your base account on etherchain.io and see which wallet contracts it created, and then import them into MIST.

[MIST (vs. Etherum Wallet) - vs. Testnet vs. Mainnet]

  • MIST and Etherum Wallet is two sides of the same thing. MIST is a DApp browser, and Etherum Wallet is also a DApp browser, but can only show one DApp, - the ethereum wallet DApp.

  • Mainnet and Testnet has separated storage in MIST/Ethereum, but for some reason, Ethereum Wallet still displays testnet Wallet Contracts and Transactions while in mainnet mode, whereas MIST does not. This is absolute biggest point of confusion for me why that design descision was made in Ethereum Wallet.

  • Testnet and mainnet have exactly the same address space.

    • If you, while on mainnet, accidently send funds to a testnet ACCOUNT address that you own, you can retrieve the funds from the mainnet with the same PK as the testnet one.

    • If you, while on mainnet, accidently send funds to a testnet WALLET CONTRACT address you own, the funds will be lost. The Wallet Contract will not exist on mainnet, and assumably the funds would land on a basic account address for which you do not have the private key. Is this correct ??

Thank you

2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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