agurod42 / brute_force_bip38

Brute-force decoder of BIP38 encrypted private keys
MIT License
11 stars 8 forks source link

Error with new version of libwally, non SSE / SSE4 capable hardware #3

Open sigkill opened 3 years ago

sigkill commented 3 years ago

I was able to get it libwally compiled, but now get the following error:

-- Configuring done -- Generating done -- Build files have been written to: /micNfs/tools/tmp/brute_force_bip38 Consolidate compiler generated dependencies of target secp256k1 [ 5%] Building C object third_party/libwally-core/CMakeFiles/secp256k1.dir/src/secp256k1/src/secp256k1.c.o [ 11%] Linking C static library libsecp256k1.a [ 11%] Built target secp256k1 Consolidate compiler generated dependencies of target libwally-core [ 16%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/aes.c.o [ 22%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/base58.c.o [ 27%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/bip38.c.o [ 33%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/hex.c.o [ 38%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/hmac.c.o [ 44%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/internal.c.o [ 50%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/pbkdf2.c.o [ 55%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/scrypt.c.o In file included from /micNfs/tools/tmp/brute_force_bip38/third_party/libwally-core/src/scrypt.c:65:0: /micNfs/tools/tmp/brute_force_bip38/third_party/libwally-core/src/scrypt/crypto_scrypt.c: In function '_crypto_scrypt': /micNfs/tools/tmp/brute_force_bip38/third_party/libwally-core/src/scrypt/crypto_scrypt.c:99:15: warning: implicit declaration of function 'posix_memalign' [-Wimplicit-function-declaration] if ((errno = posix_memalign(&B0, 64, 128 r p)) != 0) { ^ [ 61%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/sign.c.o [ 66%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/ccan/ccan/crypto/ripemd160/ripemd160.c.o [ 72%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/ccan/ccan/crypto/sha256/sha256.c.o [ 77%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/ccan/ccan/crypto/sha512/sha512.c.o [ 83%] Building C object third_party/libwally-core/CMakeFiles/libwally-core.dir/src/ccan/ccan/str/hex/hex.c.o [ 88%] Linking C static library liblibwally-core.a [ 88%] Built target libwally-core Consolidate compiler generated dependencies of target brute_force_bip38 [ 94%] Building CXX object CMakeFiles/brute_force_bip38.dir/src/main.cpp.o [100%] Linking CXX executable brute_force_bip38 CMakeFiles/brute_force_bip38.dir/src/main.cpp.o: In function brute38::bip38_public_key_from_private_key(std::string const&, std::string const&)': main.cpp:(.text+0x19e): undefined reference tobip38_to_private_key(char const, unsigned char const, unsigned long, unsigned int, unsigned char, unsigned long)' main.cpp:(.text+0x1bb): undefined reference to `wally_ec_public_key_from_private_key(unsigned char const, unsigned long, unsigned char, unsigned long)' main.cpp:(.text+0x1d3): undefined reference to `wally_hex_from_bytes(unsigned char const, unsigned long, char)' collect2: error: ld returned 1 exit status make[2]: ** [brute_force_bip38] Error 1 make[1]: [CMakeFiles/brute_force_bip38.dir/all] Error 2 make: *** [all] Error 2

I'm using a pretty old compiler because I don't have access to the fancy Intel compiler. If you have a moment, could you tell me if there is something I am missing here? I have been able to compile your tool on four other pieces of hardware without issue, but this system is very odd and I'm kind of stumped.

Was thinking possibly ABI related, however I've not been able to figure out how to set the ABI values to try setting them the same for libwally.

In this instance - libwally is at: 0.60 on my system, but had to disable all asm options due to weird architecture.

KrazyKerbalnaut commented 3 years ago

Where you able to resolve this issue? Also, I'm having trouble to get it to compile at all. What are you using to compile and how did you implement the missing libwally-core? Thanks!

sigkill commented 3 years ago

I was able to grab a much older version of libwally and a newer version too, but had to disable assembly instruction optimization on the newer version.

I could not get the binary to link, failing at 100% make status.

I was able to compile it on my Intel based 2010 Mac Pro just fine, but not on my Xeon Phi.

On Wed, Aug 25, 2021 at 11:48 AM KrazyKerbalnaut @.***> wrote:

Where you able to resolve this issue? Also, I'm having trouble to get it to compile at all. What are you using to compile and how did you implement the missing libwally-core? Thanks!

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/agurodriguez/brute_force_bip38/issues/3#issuecomment-905786017, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAE265DH6YTK6NH7SGNWNLLT6U3GVANCNFSM5CCX7UKQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .

--

The information contained in this message, and any attachments, may contain confidential and legally privileged material. It is solely for the use of the person or entity to which it is addressed. Any review, retransmission, dissemination, or action taken in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you receive this in error, please contact the sender and delete the material from any computer.

KrazyKerbalnaut commented 3 years ago

I was able to grab a much older version of libwally and a newer version too, but had to disable assembly instruction optimization on the newer version. I could not get the binary to link, failing at 100% make status. I was able to compile it on my Intel based 2010 Mac Pro just fine, but not on my Xeon Phi. On Wed, Aug 25, 2021 at 11:48 AM KrazyKerbalnaut @.***> wrote: Where you able to resolve this issue? Also, I'm having trouble to get it to compile at all. What are you using to compile and how did you implement the missing libwally-core? Thanks! — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <#3 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAE265DH6YTK6NH7SGNWNLLT6U3GVANCNFSM5CCX7UKQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email . -- ------------------------------ The information contained in this message, and any attachments, may contain confidential and legally privileged material. It is solely for the use of the person or entity to which it is addressed. Any review, retransmission, dissemination, or action taken in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you receive this in error, please contact the sender and delete the material from any computer.

Well poo. I did look at the build script and saw the minimum version of C Make and when trying it with that, I still could get it to build. What compiler were you using by chance? Vs code and visual studio 2019 doesn't like it...

zhanshen360 commented 2 years ago

I can't compile it, do you have a compiled product?