Author

Topic: What does wallet.dat contains exactly ? (Read 1399 times)

legendary
Activity: 3472
Merit: 4801
July 08, 2015, 06:44:25 AM
#15
Wallet.dat is basically Encrypted , right ?

By default, when you install Citcoin Core, the wallet is NOT encrypted.  It is only encrypted if you choose to encrypt it.  If you choose to encrypt the wallet, then you supply a password for the encryption.

but how Bitcoin Core is able to Decrypt it even with password I mean where the password is stored on the first place to check if it's correct or it's not,

The password is NOT stored.  The password is used as an encryption/decryption key to encrypt.  It is supplied as input to the decryption algorithm.  Without the password, the algorithm fails to decrypt, so there is no need to store the password in the wallet.

if it's on the file then isn't some Hexing enough to found the pass ? and also if it's a Decrypting algorithm or whatever to decrypt that file , and the Bitcoin Core source code is public , can't people just decrypt the file by building a Encrypter/Decrypter for that file from the bitcoin core source code ?

Knowing the algorithm isn't useful unless you also know the encryption/decryption key (password).

legendary
Activity: 3472
Merit: 4801
wallet.dat is a file which contains your guid, private key, address, public key.
guid - it is an identifier for your wallet.
private key - Its a key which can actually have your coins BOOM once shared.
public key - Its a key by which you can verify your wallet address.
Address - the wallet address's.

If this file is shared, you will lost your wallet (a type of).

Wallets can generally contain more than one address. Therefore, "Address" is one of multiple addresses stored in the wallet. An address is computed from a public key. If you have a public key, and you don't have the address, it is possible to generate the address from the public key.  The process is not reversible.  If you have an address, it is not possible to compute the public key.

Since each address has it's own public key, and a wallet can contain multiple addresses, a wallet can contain multiple public keys.  At the network level, bitcoin does not use addresses at all.  Addresses are just for us humans so that we have a shorter string of characters to share and so that there is some error checking to prevent us from making a typo and sending to the wrong place. At the network level, bitcoin uses signatures, public keys, and public key hashes. The public keys are generally supplied in transaction inputs to verify the transaction. A public key is computed from a private key.  If you have a private key, and you don't have the public key, it is possible to generate the public key from the private key.  The process is not reversible.  If you have a public key, it is not possible to compute the private key.

Since each public key has it's own private key, and a wallet can contain multiple public keys, a wallet can contain multiple private keys.  How much of you bitcoins someone can access with a single private key depends on how those private keys are generated, and how many different addresses you've received bitcoins at.  Currently Bitcoin Core generates addresses completely randomly, so if you have 1 private key from the wallet it is not possible to compute any of the other private keys.  As such, if someone gains access to just one of your private keys, then they will only have access to the bitcoins that were sent to the one address that is associated with that private key.  They won't be able to access any of the other bitcoins controlled by your wallet.  Of course, unless you accidentally shared the private key, if they were able to extract one private key from your wallet then there is a pretty good chance that were able to extract all of them.

hero member
Activity: 686
Merit: 500
After thinking about it , I can't seem to understand how the file is Encrypted and Decrypted to be honest .
I mean ... Wallet.dat is basically Encrypted , right ? but how Bitcoin Core is able to Decrypt it even with password I mean where the password is stored on the first place to check if it's correct or it's not , if it's on the file then isn't some Hexing enough to found the pass ? and also if it's a Decrypting algorithm or whatever to decrypt that file , and the Bitcoin Core source code is public , can't people just decrypt the file by building a Encrypter/Decrypter for that file from the bitcoin core source code ? I hope it dosen't sound dumb :/
full member
Activity: 216
Merit: 100
wallet.dat is a file which contains your guid, private key, address, public key.
guid - it is an identifier for your wallet.
private key - Its a key which can actually have your coins BOOM once shared.
public key - Its a key by which you can verify your wallet address.
Address - the wallet address's.

If this file is shared, you will lost your wallet (a type of).

legendary
Activity: 1148
Merit: 1014
In Satoshi I Trust
the wallet.dat is a file that store your private key

that thing has to do with the 100 address pool, after that you need to do a backup, because he cannot keep the mem about other additional income

https://bitcointalksearch.org/topic/m.3306298

I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?

and make sure you have at least one backup of that file.

I know , but just me paranoid of computer failure then I'am screwed and people don't usually recommend using services like Mega or DropBox or GOogle Drive to have backups of your wallet.dat

I want to use Paper wallet badly to be honest but im too afraid that the adress given by the paper wallet from bitadress github dosen't match the private key .. and after years when I want to import the private keys I will find it empty then I will suicide most likely xD

yeah, dont store it online. that is a stupid idea.

a good advise it to split your funds if you own a stack of BTC

- put some in a paper wallet
- put some in a hardware wallet
- put some on an USB key (encrypt wallet.dat of course)

- use different clean PCs when you do that and install a proper antivirus


very unlikely that you lose all of them now  Cheesy
legendary
Activity: 3472
Merit: 4801
I want to use Paper wallet badly to be honest but im too afraid that the adress given by the paper wallet from bitadress github dosen't match the private key .. and after years when I want to import the private keys I will find it empty then I will suicide most likely xD

You don't need to use the bitaddress from github.

If you trust Bitcoin Core to have you the correct private key for an address, then you can create a paper wallet with Bitcoin Core.

If you don't trust Bitcoin Core to have the correct private key for an address, then why are you using bitcoin at all?
hero member
Activity: 686
Merit: 500
July 07, 2015, 10:56:09 AM
#9
the wallet.dat is a file that store your private key

that thing has to do with the 100 address pool, after that you need to do a backup, because he cannot keep the mem about other additional income

https://bitcointalksearch.org/topic/m.3306298

I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?

and make sure you have at least one backup of that file.

I know , but just me paranoid of computer failure then I'am screwed and people don't usually recommend using services like Mega or DropBox or GOogle Drive to have backups of your wallet.dat

I want to use Paper wallet badly to be honest but im too afraid that the adress given by the paper wallet from bitadress github dosen't match the private key .. and after years when I want to import the private keys I will find it empty then I will suicide most likely xD
legendary
Activity: 1148
Merit: 1014
In Satoshi I Trust
July 07, 2015, 10:06:19 AM
#8
the wallet.dat is a file that store your private key

that thing has to do with the 100 address pool, after that you need to do a backup, because he cannot keep the mem about other additional income

https://bitcointalksearch.org/topic/m.3306298

I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?

and make sure you have at least one backup of that file.
hero member
Activity: 686
Merit: 500
July 06, 2015, 02:55:13 PM
#7
uhh, it contains many things:) is better to check https://en.bitcoin.it/wiki/Wallet section: Bitcoin Qt

generally, for long-term storing is better to use paper wallets, for daily operations some light wallet light like electrum - for higher security with bitcoin trezor..

I downloaded an offline Github file to create Paper wallet last time , I had to move mouse It's by default gets me on "Normal wallet" tab and when I change to "Paper wallet" I get other Adress and other private key on then the one on "normal walelt" so didnt knew if that's normal or not and didn't find a way to confirm  if that private key is related to Adress or not (paranoya) .

the wallet.dat is a file that store your private key

that thing has to do with the 100 address pool, after that you need to do a backup, because he cannot keep the mem about other additional income

https://bitcointalksearch.org/topic/m.3306298

I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?

yeah but what i'm doing to avoid losing precious bitcoin, is saving my wallet, everytime it get bigger, have you noticed that when you create a new address or after some time your wallet.dat "gain" some kb? well at that point i usually do a fresh back up

however i don't like to do many back, because sometime for no reason the wallet get corrupted, especially when you send fund that are not confirmed, i don't know why, but it dead happen two time already, i was lucky that besides that i was still able to move my coin from the corrupted one..

Not really , I have never noticed I rarely look to the file to be honest and I create the six adresses since long time ago and didn't create any since then . whenI like to follow what Satoshi said I use adresses from Lightweight wallets like Electrum then I send them back to one of my Receiving adresses on Bitcoin Core .

I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?

Bitcoin Core will use a new private key every time you send a transaction AND every time you request a new bitcoin address.

With default settings, it pre-generates the next 100 addresses that it will use.  So, if you create a backup, that backup should be able to recover all bitcoins in the wallet until the sum of the number of addresses you request plus the number of transactions you send reaches 100.

Of course, it would be really bad to lose track and not realize that you've exceeded 100.  It would also be bad to have only 1 backup and then discover that the backup is damaged, lost, corrupted, etc.

Therefore, I generally recommend creating a new backup every time the sum of addresses and transactions exceeds 25 since the last backup.  Then keep the 3 most recent backups in safe locations.  That way any 1 of the three backups can recover your bitcoins.

I see I got it now perfectly , thank you so much mate .
Its weird how I'am using Bitcoin since about one year now (9 monthsor something) and still learning new stuff each day . Grin

legendary
Activity: 3472
Merit: 4801
July 06, 2015, 02:18:31 PM
#6
I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?

Bitcoin Core will use a new private key every time you send a transaction AND every time you request a new bitcoin address.

With default settings, it pre-generates the next 100 addresses that it will use.  So, if you create a backup, that backup should be able to recover all bitcoins in the wallet until the sum of the number of addresses you request plus the number of transactions you send reaches 100.

Of course, it would be really bad to lose track and not realize that you've exceeded 100.  It would also be bad to have only 1 backup and then discover that the backup is damaged, lost, corrupted, etc.

Therefore, I generally recommend creating a new backup every time the sum of addresses and transactions exceeds 25 since the last backup.  Then keep the 3 most recent backups in safe locations.  That way any 1 of the three backups can recover your bitcoins.
legendary
Activity: 3248
Merit: 1070
July 06, 2015, 02:06:31 PM
#5
the wallet.dat is a file that store your private key

that thing has to do with the 100 address pool, after that you need to do a backup, because he cannot keep the mem about other additional income

https://bitcointalksearch.org/topic/m.3306298

I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?

yeah but what i'm doing to avoid losing precious bitcoin, is saving my wallet, everytime it get bigger, have you noticed that when you create a new address or after some time your wallet.dat "gain" some kb? well at that point i usually do a fresh back up

however i don't like to do many back, because sometime for no reason the wallet get corrupted, especially when you send fund that are not confirmed, i don't know why, but it dead happen two time already, i was lucky that besides that i was still able to move my coin from the corrupted one..
legendary
Activity: 1036
Merit: 1001
/dev/null
July 06, 2015, 02:02:16 PM
#4
uhh, it contains many things:) is better to check https://en.bitcoin.it/wiki/Wallet section: Bitcoin Qt

generally, for long-term storing is better to use paper wallets, for daily operations some light wallet light like electrum - for higher security with bitcoin trezor..
hero member
Activity: 686
Merit: 500
July 06, 2015, 02:00:06 PM
#3
the wallet.dat is a file that store your private key

that thing has to do with the 100 address pool, after that you need to do a backup, because he cannot keep the mem about other additional income

https://bitcointalksearch.org/topic/m.3306298

I personally have only six receiving adresses and only few transactions , most likely 15 or something . (sent two times and all others are receiving transactions)
Basically I don't have to make any backup since I installed Bitcoin Core unless I reach 100 , correct ?
legendary
Activity: 3248
Merit: 1070
July 06, 2015, 01:55:12 PM
#2
the wallet.dat is a file that store your private key

that thing has to do with the 100 address pool, after that you need to do a backup, because he cannot keep the mem about other additional income

https://bitcointalksearch.org/topic/m.3306298
hero member
Activity: 686
Merit: 500
July 06, 2015, 01:15:02 PM
#1
I use Bitcoin Core as a wallet so there isn't really a way to save Private keys on a file as far as I know however you can get the private keys using a command .
Anyway I was wondering what wallet.dat contains exactly because last time some people adviced me to take backup from "time" to "time" or after x "transactions" for wallet.dat
so really want to know whats the important thing that changes from time to time or when there is a lot of transactions and it's needed to recover our bitcoin wallets ?
Jump to: