Bitcoin Forum

Bitcoin => Mining software (miners) => Topic started by: p3yot33at3r on June 04, 2015, 11:18:57 AM



Title: Looking for a good decompiler - any suggestions?
Post by: p3yot33at3r on June 04, 2015, 11:18:57 AM
Hello all,

I'm looking for a good (free ;)) decompiler that is capable of decompiling Bitmain firmware - can anyone give me a suggestion?

Thanks.


Title: Re: Looking for a good decompiler - any suggestions?
Post by: kano on June 05, 2015, 11:30:00 AM
Hello all,

I'm looking for a good (free ;)) decompiler that is capable of decompiling Bitmain firmware - can anyone give me a suggestion?

Thanks.
Bitmain firmware is basically just an OS partition.
Nothing to do with decompiling.


Title: Re: Looking for a good decompiler - any suggestions?
Post by: p3yot33at3r on June 05, 2015, 11:41:39 AM
Thanks kano, I realised my mistake while at work earlier..... ::)

Can you recommend a suitable (cross platform?) decompiler for regular applications/binaries?


Title: Re: Looking for a good decompiler - any suggestions?
Post by: bitsolutions on June 05, 2015, 02:42:25 PM
Thanks kano, I realised my mistake while at work earlier..... ::)

Can you recommend a suitable (cross platform?) decompiler for regular applications/binaries?
Why would you want a decompiler when you can just use the source code?


Title: Re: Looking for a good decompiler - any suggestions?
Post by: kano on June 05, 2015, 02:48:33 PM
Most of it:
https://github.com/bitmaintech


Title: Re: Looking for a good decompiler - any suggestions?
Post by: p3yot33at3r on June 05, 2015, 04:43:11 PM
Why would you want a decompiler when you can just use the source code?

I'm looking for a good decompiler for software that doesn't provide source code.


Title: Re: Looking for a good decompiler - any suggestions?
Post by: MarkAz on June 05, 2015, 08:45:25 PM
There's only one that's even marginally good for compiled (non-interpreted languages), and that's Hex-Rays:

https://www.hex-rays.com/products/decompiler/

That being said, you can't recompile what you decompile, so it only will give you is slightly more insight into what they're doing...  You're better off just getting a disassembler and working in assembly - it will completely work, and you can do whatever you want, but it's also much more difficult.


Title: Re: Looking for a good decompiler - any suggestions?
Post by: bitsolutions on June 05, 2015, 08:55:36 PM
I'm looking for a good decompiler for software that doesn't provide source code.
Which software in particular? Its hard to help without knowing specifically what you are trying to decompile and why.

There's only one that's even marginally good for compiled (non-interpreted languages), and that's Hex-Rays:

https://www.hex-rays.com/products/decompiler/

That being said, you can't recompile what you decompile, so it only will give you is slightly more insight into what they're doing...  You're better off just getting a disassembler and working in assembly - it will completely work, and you can do whatever you want, but it's also much more difficult.


This is very true, reversing most compiled languages such as c and c++ is very difficult. The software on bitcoin miners is mostly written in c with scripts controlling execution and configuration.


Title: Re: Looking for a good decompiler - any suggestions?
Post by: smolen on July 11, 2015, 03:41:20 PM
There's only one that's even marginally good for compiled (non-interpreted languages), and that's Hex-Rays:

https://www.hex-rays.com/products/decompiler/

That being said, you can't recompile what you decompile, so it only will give you is slightly more insight into what they're doing...  You're better off just getting a disassembler and working in assembly - it will completely work, and you can do whatever you want, but it's also much more difficult.


This is very true, reversing most compiled languages such as c and c++ is very difficult. The software on bitcoin miners is mostly written in c with scripts controlling execution and configuration.
Last time I looked at it HexRays was not ready for production use. With trained eyes, disassembler and debugger it's possible to locate algorithm inside a program and make usable C sketch of it, but it takes A LOT of time, think ~3 full days for 100 lines of C code.