Questions tagged [accounts]

Ethereum has two types of accounts: externally owned user accounts, controlled by private keys, and contract accounts, controlled by their contract code.

0
votes
1answer
51 views

Who owns the ETH in the zero account? [duplicate]

Per https://etherscan.io/address/0x0000000000000000000000000000000000000000 the zero account currently contains ETH worth about $3.3 million USD. I understand how the zero account is used in the EVM. ...
0
votes
1answer
263 views

Account nonce limit/maximum

I've been reading about an account's nonce, that it's supposed to be an incremental number that increments with every transaction. I found about transactions pool and queue, about what happen if you ...
3
votes
1answer
51 views

How to use key derivation and 'coin selection' to increase privacy, like in Bitcoin?

In Bitcoin, you can have increased privacy by never re-using addresses. A single private key can generate many addresses if you are using a key derivation scheme. In Ethereum, instead of UTXOs you ...
0
votes
0answers
29 views

What happens if the “balance” of the address which sends “address.transfer(amount) is ” zero "?

Consider the balance of the address that sends address.transfer(amount); to receive the amount is zero. For example we have following address with balance of zero: web3.eth.getBalance('0x123').then(...
0
votes
1answer
361 views

How can I transfer ownership to another contract?

I have a contract which inherits from contract Claimable by OpenZeppelin (see here): pragma solidity ^0.4.24; import "./Claimable.sol"; contract MyTestContract is Claimable { uint256 public id; ...
1
vote
1answer
96 views

How to give a non-zero balance to a contract at time of deployment using Remix?

In case we want to deploy a contract by web3.js we can easily determine the balance of the contract at time of deployment as follows: const thisContract = new web3.eth.Contract(abi); thisContract....
2
votes
0answers
36 views

Authenticating accounts in Ethereum using web3js

Is a there a way to authenticate accounts in Ethereum using Web3js? Or if there are any other ways to authenticate accounts? We are building an application where users can register in our system. ...
1
vote
1answer
919 views

How to get the balance of a contract using web3.js?

I have deployed a contract as follows and determined its balance to be 5000 wei (value: 5000): const thisContract = new web3.eth.Contract(abi); thisContract.deploy({ data: bytecode, ...
1
vote
2answers
160 views

UPDATED : How to determine “payer address” in “address.transfer(amount)”?

Consider we a function as follows : address public recipient; function settlement(uint256 amount) public { recipient = msg.sender; recipient.transfer(amount); } Then the ...
0
votes
0answers
95 views

UPDATE: (I need to run testrpc before running the code) Problem with signing a message with “web3.eth.personal.sign” or “web3.eth.sign”

I use exactly the example of web3js (here) to sign a text. So, I generated a .js file asfollows : Web3 = require("web3") web3 = new Web3(new Web3.providers.HttpProvider("http://localhost:8545")); ...
1
vote
1answer
258 views

How do the other nodes know which particular node has the account used in the transaction?

A brief about my setup. I am using a private Ethereum network with 3 nodes. I have made all the nodes as peers of each other by using: admin.addPeer("enode:1234abcd..") When mining takes place, all ...
0
votes
1answer
204 views

How can I create a wallet and display the address, public and private key using web3js?

I am using this as my source for web3js: <script src="http://raw.githubusercontent.com/ethereum/web3.js/0.16.0/dist/web3.min.js"> </script> In my HTML I want to display the account's ...
0
votes
1answer
230 views

Retrieve contract byte code

How may I find the byte code of an arbitrary contract? Preferably using a website and not writing my own client.
1
vote
1answer
858 views

Truffle test: How to test Ether transfer? Balance of specific account?

How is it possible to test if my contract actually transfers money to a specific account? function _transfer(address receiver_, uint256 payout) internal{ receiver_.transfer(payout); } Testing in ...
2
votes
1answer
332 views

how to make getAccounts() return a list of all 10 accounts?

I am using Truffle Development (or Ganache at times) and the problem is web3.eth.accounts is only one account and not the list of all 10 accounts I want to get hold of at least first two so that I ...
1
vote
0answers
48 views

Why does address.transfer(amount) cost the same when sent to a new or used address?

In the Ethereum yellow-paper, it's specified that creating a new account costs 25000 gas (Appendix G, entry for Gnewaccount). We can see this if, for example, we call a function that makes a transfer:...
1
vote
0answers
216 views

Paying for gas on behalf of users?

I'm exploring ways to enable contracts/dApp owners to pay for gas on behalf of users. I know contact abstraction should enable this eventually, and the first step has been done with EIP208 which ...
0
votes
1answer
210 views

How does Ethereum account state change? [duplicate]

Ethereum uses Accounts instead of UTXO (Bitcoin). I would like to know how does the ledger keep the account state (technical details if possible)? Does it modify the ledger (accounts) by incrementing ...
2
votes
2answers
205 views

Account created using web3 is not showing in geth console

I have created a new address using web3.eth.accounts.create() and it responds with { address: '0x9AA2767207d0aC9cCdD2e3B244210f630588F3E3', privateKey: '...
2
votes
2answers
125 views

Why public keys are not used directly as account addresses? [duplicate]

I understand that addresses are hashes of the public keys. But why? What is the rationale behind this design decision? And why 160 bits? Why not just use the hash directly? Is 160-bit guaranteed ...
1
vote
0answers
100 views

How can I import the Accounts from ganache-cli into Nethereum?

Is there a way to automatically load the Accounts created by ganache-li into a project which uses Nethereum?
0
votes
1answer
24 views

Can I add my own fields to JSON files in the keystore directory?

I need to add a few fields to JSON v3 wallet file, can I do it ? What is Ethereum's policy on this? For example, to add account name I would do something like this: { "address": "...
1
vote
0answers
27 views

Should I wait for sync to be 'finished' in 'syncmode=light' before I could check account balance OR transact using the account? [duplicate]

NOTE: I'm aware of another question, but, it's related to 'fast' syncmode, and mine is of 'light' syncmode. I'm running light node client for rinkeby using command: geth --rinkeby --rpc --rpcapi ...
1
vote
1answer
43 views

“public key” and “account” : are the same?

When I create a new account as follows : web3.eth.personal.newAccount('pass').then(console.log); -> pass is account password. Then, I receive an account as follows : ...
0
votes
1answer
372 views

Import account from one geth node to another geth node

I had a geth node where i created an account. Then i backed up the keystore folder just in case. I had to format the pc and install geth again. So i would like to know how can i import my old account ...
1
vote
1answer
216 views

How to unlock account from another node in same blockchain network?

I have deployed DAPP on two node private ethereum blockchain network. According to this question it is not possible to access all accounts across multiple nodes. My question is consider a scenario ...
0
votes
1answer
65 views

(Re)create account from a keystore (?) file

Noob. Sorry :-( I have a keystore file that I'm confident represents an account I'd like to retain/use. It's unclear how I can recreate (or reinstantiate) this account within a fresh Ethereum (node) ...
2
votes
0answers
62 views

Programmatically unlock certain accounts with Parity?

Using geth it is easy to send transactions from multiple accounts but I do not know how to do this with Parity. I do not want all accounts unlocked. I do not want any account unlocked when it is not ...
1
vote
1answer
36 views

Account management risks of booting into Tails OS from USB using a “partially air-gapped” Linux PC

My threat tolerance is around a 3 out of 5 on the paranoia scale. What are the practical account management risks of using a flash drive loaded with Tails OS to boot into a Linux PC, which will only ...
0
votes
1answer
119 views

Ethereum account code hash

I've created a contract https://ropsten.etherscan.io/address/0xfaba4475358c1c23e37549f9bd54300261873d41#code And using its createChild() method I've created 3 children https://ropsten.etherscan....
0
votes
1answer
62 views

How to add multiple accounts

I was trying to create an account via geth. My question is about using the non-interactive password input. With the following variables : GETH_ROOT_PATH="${HOME}/Chain_Test" GETH_DATA_DIR="${...
0
votes
1answer
17 views

Address creation in blockchain

Is moment of account creation stored in blockchain? Or only first income or outcome transaction time can estimate it?
2
votes
1answer
2k views

web3js sender account not recognized

Under Ganache, I created some APIs with nodejs to managing a Smart Contract. One API is for the creation of new accounts with newAccount = web3.eth.accounts.create(web3.utils.randomHex(32)); Then, ...
1
vote
1answer
315 views

Sweep tokens from a one-time address without available ether

I'm generating a one-time address for each order in my store, and the order is payed with an ERC-20 token. Is there any way I could sweep the tokens from this address, without an additional ...
0
votes
0answers
1k views

Getting “no key for given address or file” error when trying to unlock account in geth

I'm trying to unlock an ethereum user account using geth, but am getting an error message that doesn't make sense to me. Here's what I do: 1) I start the geth console connected to the ropsten ...
0
votes
1answer
99 views

Viewing account balance of an address

Is there a way to get the account balance of any given address (address which is not belongs to me) using geth or by using a script which reading leveldb? Similar to how etherscan (https://rinkeby....
0
votes
1answer
671 views

How to synchronise Ganache-CLI accounts with Ganache-UI?

When I launch ganache-cli for Port 7545, it will create 10 accounts by default. ganache-cli -p 7545 However, when I then open the Ganache-Desktop-App, it will show different accounts and the ...
0
votes
2answers
254 views

Account created with web3 does not get listed

I am learning ethereum and I have setup a private node with geth. And have a simple client written to create account (web3 1.0 beta34) and list. While the account creation is successful, but it does ...
1
vote
1answer
57 views

Detecting an existing account: coinbase or getAccounts?

When detecting web3 or even an existing node, one typically needs to detect an account - which also gives an indication if the account needs to be unlocked. Should the check for an account be a ...
1
vote
1answer
170 views

How an Ethereum account hold nounce, eth balance, contract code and storage?

I am looking go-ethereum code and it is a bit hard to understand, how actually an account holds its information. Based on Ethereum White Paper, An Ethereum account contains four fields: ...
1
vote
1answer
111 views

How is account managed in Ethereum blockchain?

What is the process for creating account? (I know I can geth account new, but what is the internal process actually being done?) Where does the entropy for randomness come from when creating an ...
1
vote
1answer
30 views

How to differentiate payment transaction from contract transaction?

There are three types of transactions: Ether transfer from one EOA to another Contract creation Contract call 2 can be easily identified since it's "to" field is empty. How to differentiate 1 & ...
1
vote
1answer
29 views

Are the transactions between two accounts have to go through a contract?

Are all the transactions in ethereum have a relation to a contract (its to or from field is a contract). When two accounts want to transfer something between them, do they have to speak through a ...
4
votes
1answer
1k views

List all ethereum accounts using geth [duplicate]

Etherscan displays all accounts in ethereum being used in the following section https://etherscan.io/accounts Question: How can I get a list of all active ethereum accounts using geth? Possible ...
0
votes
1answer
190 views

Account vs ManagedAccount in Nethereum

Account to this text, they are different: https://nethereum.readthedocs.io/en/latest/accounts/ But it never mentioned what are the differences. Anyone know which one to choose from when implementing ...
0
votes
1answer
149 views

Can Contract Accounts send Messages to EOAs?

I often hear the following statement: Contract Accounts cannot send Messages to EOAs. They can only: 1. send Messages to other Contract Accounts 2. send Ether to EOAs ... see, e.g., here: Are ...
1
vote
0answers
68 views

how to check if account is unlocked via JSON RPC

How would one validate if ethereum account is locked/unlocked via JSON RPC ?
1
vote
1answer
65 views

How many non-empty accounts are there?

I am researching into the statistics of Ethereum and I an looking for a datum of how many non-zero balance account currently exist in Ethereum? I know that in total 30M of accounts were created but ...
0
votes
1answer
714 views

How to use not personal account web3

In my previous post I got answer but still I need some clarifications let say when deploying contract with node js we have this line try { web3.personal.unlockAccount(web3.eth.coinbase, ...
0
votes
1answer
368 views

Web3.js unable to unlock account to call smart contract

I am using web3.js 0.20.6 and I want to unlock an account to execute a smart contract method on a private blockchain. The account is used to pay for the gas. I have used the following code to unlock ...