crypto1_bs icon indicating copy to clipboard operation
crypto1_bs copied to clipboard

Windows gcc verson

Open dxls168 opened this issue 7 years ago • 21 comments

Hi: I have tried to compile your project with MINGW and have solved all the compilation warnings and errors, but the final project still does not work and the program stuck in the crack process. In Ubuntu, the program is very easy to use. Sincerely hope that you can out of a windows version of the project, very grateful to you.

dxls168 avatar Oct 08 '16 18:10 dxls168

Hey, I'm sorry but I don't think this will really work again. There is no up-to-date libnfc.dll as far as I can tell.

aczid avatar Nov 21 '16 16:11 aczid

I just built the libnfc.dll from source?

iWhacko avatar Nov 28 '16 08:11 iWhacko

solve_bs is enough.Not need libnfc.

dxls168 avatar Nov 28 '16 09:11 dxls168

I had trouble building the latest libnfc.dll. Anyway I'm not sure why it doesn't work when compiled on windows.

aczid avatar Nov 29 '16 00:11 aczid

Hi,You can use cmake to build it.Then use gcc .Can you give me an e-mail address?I can send you lib and dll.

dxls168 avatar Nov 29 '16 01:11 dxls168

crypto1_bs_crack.c uses sysinfo.h etc and some linux specific calls for memory. I'm not familiar enough with it that I can port it to windows. However I added the dll etc to this post maybe it's of use to you for testing libnfc.zip

iWhacko avatar Nov 29 '16 12:11 iWhacko

I did a bit more investigation. The problem I'm having is combining a 32 bit-library (libnfc) with some 64-bit code (crypto1_bs/crapto1/craptev1).

aczid avatar Jan 10 '17 08:01 aczid

After some more small patches, I've tested a linux/mingw cross-compiled versions of solve_piwi and solve_piwi_bs for 32-bit windows in a win7 VM and they both work fine for me. No detection of the number of CPU cores yet, though. And also I did not get these versions working on native win8 for some reason... Added make targets 'win32' and 'win64' for these. If anything it's evidence the code works on windows in principle.

aczid avatar May 04 '17 19:05 aczid

I'll try! Thank you again for your great help!

dxls168 avatar May 05 '17 13:05 dxls168

text

Perfect! Thanks again!

dxls168 avatar May 05 '17 16:05 dxls168

Wow, I didn't get libnfc code to work when cross-compiling. Thank you for testing, that's even better than I had hoped!

aczid avatar May 05 '17 17:05 aczid

What build system are you using? You're very welcome to add native (non-mingw) targets to the Makefile and file a pull request. Feel free to rename the mingw cross-compilation make targets while you are at it.

aczid avatar May 05 '17 18:05 aczid

I assume you also had to replace some of the signal()/alarm() calls to use windows-style Timers? I have an untested patch for libnfc_crypto1_bs.c for that, too.

aczid avatar May 05 '17 18:05 aczid

dxls168, write please how compile crypto1_bs on windows platform.

maxben14 avatar May 30 '17 17:05 maxben14

1.You need download the Mingw . 2.Put the files into the ’user‘ folder. 3 Run the Mingw-shell and into the ’user‘ folder,then input the command 'make' . 4 If anything get wrong,change the Makefile chose one to make.

dxls168 avatar May 31 '17 02:05 dxls168

dxls168, can send me win exe file compiled please ?

maxben14 avatar May 31 '17 12:05 maxben14

Bla's license clearly states no redistribution. Don't be lazy.

aczid avatar May 31 '17 12:05 aczid

hi dxls168, may I have some tips to get crypto1_bs compiled for Windows? My emal is marco.rossinol at gmail . com

marcoxx888 avatar Jun 03 '17 14:06 marcoxx888

Hi @dxls168, I also compiled crypto1_bs for Win, but still couldn't get keys despite the long time passed. What did you do with (Mingw warning and errors):

  1. thread_count = get_nprocs_conf();? //hardcoded threads?
  2. alarm(1); signal(SIGALRM, notify_status_offline);? //some kind of: timeSetEvent(0, 0, notify_status_offline, 0, TIME_PERIODIC);?
  3. fcntl(0, F_SETFL, O_NONBLOCK);? //unsigned long on = 1; ioctlsocket(0, FIONBIO, &on);?

briggeml avatar Jun 12 '17 15:06 briggeml

Hi @briggeml: These are Linux functions.You can ignore progress display and set the thread_count =1.

dxls168 avatar Jun 13 '17 12:06 dxls168

Hi @briggeml: These are Linux functions.You can ignore progress display and set the thread_count =1.

Hello! Can you please help with compiling on Windows?

Semen8991 avatar Jul 31 '19 19:07 Semen8991