Bitcoin Forum
May 10, 2024, 07:15:17 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 [2]  All
  Print  
Author Topic: [HIRING] 1.5 BTC for wallet.dat inspection tool [Raised from 0.5 to 1 to 1.5BTC]  (Read 1984 times)
cointra
Member
**
Offline Offline

Activity: 83
Merit: 10


View Profile WWW
May 23, 2014, 08:49:46 AM
 #21

Fixed the passphrase segfault. Make sure you install pycryto python module or else decryption will be dead slow. Everything should work as expected now.

Great.  I might not have time to test for a while, so please send me your BTC address and I'll send 0.75 BTC now and the rest after I test.

In the one test I did I got an error message:

Code:
$ python wi.py --is-encrypted --wallet=/home/user/wallet1.dat
Traceback (most recent call last):
  File "wi.py", line 1823, in <module>
    db_env = create_env(db_dir)
  File "wi.py", line 1158, in create_env
    (DB_CREATE | DB_INIT_LOCK | DB_INIT_LOG | DB_INIT_MPOOL | DB_INIT_TXN | DB_THREAD | DB_RECOVER))
bsddb.db.DBInvalidArgError: (22, 'Invalid argument -- mmap: Invalid argument')

Tried it with a couple wallet files and got the same error.  The user has read/write permission to the directory.  I have the python-crypto package installed.

Could it be the bsddb module version you have? I tried the exact same command and got no error. I will just post a set up guide to make sure we're installing the correct python/module versions.

Actually just did a quick search, it could be python version issue as mentioned http://stackoverflow.com/questions/15958917/bsddb-4-2-52-dbinvalidargerror-22-invalid-argument

Can you try with python 2.7? If not I will downgrade to python 2.5

Actually, I figured out what is causing the problem.  I'm using VirtualBox and the wallet files are on a shared drive, and for some reason BSDDB can't work with that directory.  All other tools I've used can read/write fine to it, they treat it just like any other directory.  My suggested fix will actually fix two issues:

- Suggested fix: Create a temporary working directory in /tmp, do the operation, remove the directory.

This addresses the issue with the shared drive and also fixes the issue that currently lots of __db.00X files are left behind in the directory after the script finishes.  If you can do the operation using the temporary directory and leaving the wallet file in its current place, that is best.  If you need to have the wallet file in the temporary directory, then copying it over would be ok.

And please send me your Bitcoin address so I can send you half now.  I've been slow to test but I want to make sure you know I'm good for the BTC and to keep you motivated to make these fixes.

/tmp is a good idea and I will implement that. I am completely fine with receiving the whole amount once you're happy with the script, however if you really want to send half now then you can use the address on my profile i.e. 16xe1bCgnDLe27FAWHb4pmKzjiEWzMxLG8

Thanks

1715368517
Hero Member
*
Offline Offline

Posts: 1715368517

View Profile Personal Message (Offline)

Ignore
1715368517
Reply with quote  #2

1715368517
Report to moderator
1715368517
Hero Member
*
Offline Offline

Posts: 1715368517

View Profile Personal Message (Offline)

Ignore
1715368517
Reply with quote  #2

1715368517
Report to moderator
1715368517
Hero Member
*
Offline Offline

Posts: 1715368517

View Profile Personal Message (Offline)

Ignore
1715368517
Reply with quote  #2

1715368517
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
cointra
Member
**
Offline Offline

Activity: 83
Merit: 10


View Profile WWW
May 26, 2014, 12:16:40 AM
 #22

Removed db_env creation, no more __db files and the app is now fully readonly and should work any filesystem, tried on read-only filesystem and worked without errors.

coiner8 (OP)
Member
**
Offline Offline

Activity: 65
Merit: 10


View Profile
May 26, 2014, 07:26:46 PM
 #23

Removed db_env creation, no more __db files and the app is now fully readonly and should work any filesystem, tried on read-only filesystem and worked without errors.

Brilliant!  Much easier to use now.  I can already tell this is going to replace pywallet as the go-to tool for working with wallets.

I sent you 1 BTC at 16xe1bCgnDLe27FAWHb4pmKzjiEWzMxLG8.  My list below contains some things not in the OP so I'll bump up the total to 2.0 BTC (1.0 BTC left) if these are added.

  • --wallet: Can we get rid of the need to type --wallet?  Instead just use the first non-option parameter as the wallet file, i.e. wi.py --is-encrypted somewallet.dat
  •   Note/warning/error formats: For any note/warning/error, let's follow these rules:
      
    • Notes start with NOTE:, warnings start with WARN:, errors start with ERR:
    • Always go to stderr instead of stdout
    • Always one line
    • For any command that requires decrypting the wallet (e.g. --list-keys, --list-private-keys) and an incorrect or missing passphrase is provided, continue running the operation but output <Encrypted> wherever an unencrypted private key would normally appear
  •   Note/warning/error conditions:  These are the places I can think of where a message is needed now:
      
    • WARN: whenever a command requires decrypting the wallet and an incorrect/missing passphrase is provided (except for --test-passphrase since that is the whole point of the command)
    • NOTE: whenever a command requires decrypting the wallet, the wallet is encrypted, and the correct passphrase is provided
    • NOTE: when the wallet is unencrypted and a passphrase is provided
    • ERR: whenever the script encounters an error condition during processing it should output an ERR line and keep going if possible.  Ideally only one line will be output and not a traceback/debug dump unless a --debug type option is provided.  If a traceback/dump is output though it should go to stderr.
    • ERR: when --determine-coin is used but the coin is unknown (even if the script knows the "otherversion" still output an ERR since we don't know the coin name.  So the output would be ERR to stderr and Unknown,123 to stdout where 123 is the otherversion)
  • --balances: This is the major change and why I'm adding the 0.5 BTC since this may take some work.  For BTC, LTC, and any other currency that blockr.io supports, use their multi-request API in order to get multiple balances at once.  You can pass up to 20 addresses at a time (I think it's 20) and that will greatly speed up --balances.
  • --balances: For other non-blockr.io currencies, can the script re-use the existing connection to the web server instead of closing and starting a new request?  That should help the speed too.
  • --balances: Currently if a lookup fails for one address the script stops.  Instead it should output an ERR line and output the public key with "Error" as the balance and keep going.
  • --list-public-keys, --balances: Add an --include-contacts option.  When this is provided the public keys/balances for addresses in the contact list will be included in the output too.  No label is needed, the addresses from the contact list should appear in the output the same way as local addresses.
  • --balances: VTC addresses that have not been seen on the network are reported as having a balance of 7.0 by the script.  It should report 0.
  •     Blackcoin/Ultracoin/Mintcoin: Any command I run on Blackcoin/Ultracoin/Mintcoin wallets gives this error message:
        
Code:
Traceback (most recent call last):
  File "wi.py", line 1562, in parse_wallet
    d['txIn'].append(parse_TxIn(vds))
  File "wi.py", line 1502, in parse_TxIn
    d['sequence'] = vds.read_uint32()
  File "wi.py", line 782, in read_uint32
    return self._read_num('<I')
  File "wi.py", line 838, in _read_num
    (i,) = struct.unpack_from(format, self.input, self.read_cursor)
error: unpack_from requires a buffer of at least 4 bytes
ERROR parsing wallet.dat, type tx
[...]
    
    [/li]
cointra
Member
**
Offline Offline

Activity: 83
Merit: 10


View Profile WWW
May 26, 2014, 08:57:53 PM
Last edit: May 26, 2014, 09:45:06 PM by cointra
 #24

BTC 1.0015 well received. Thank you! Will check and update on the new additions and errors.

Edit: Found the bug with Ultracoin/Blackcoin etc. they use a slightly different format, nothing big and should be working in the next push tomorrow. Ultracoin was missing from the coins list, added it, blackcoin seems to be working fine.

Edit 2: The VTC error is related to the vertcoin explorer. Try pasting the address at the end of: https://explorer.vertcoin.org/chain/Vertcoin/q/addressbalance/ and you would see the same behavior. I will try to find another explorer if I can, or we have to live with this bug.

Pages: « 1 [2]  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!