Open andreasstieger opened 2 months ago
hi again andreas!
This is super odd. I'm getting "all checks passed" on my linux mint system when using statically linked libUseful-5.14. I did do a lot of work on 'make check' in this release, but it seems from your post like the issue is actually in hashrat/libUseful. I am suspicious that sha256 is a hash that is supported in-processor on some architectures, though I didn't think I'd added the feature to use that, so I'd think that can't be it.
I guess 'make check' has earned it's keep here, although I think this is going to be a tough one to debug. A I right in thinking that this only effects sha256?
Colum
hang on... are sha384 and sha512 showing as failed too?
The two failures are the only ones failing, the "files" test is using sha256 too.
that's creepy, it's the same code path for all of them! I'm going to put more tests into 'make check' in the next release (which is coming soon) so we can see more.
Has this been compiled with '--disable-ssl'? If not, could you try that?
Same results with and without TLS/SSL.
okay, I have a new version on the launchpad here, because I had an idea that it might be openssl. If compiled with openssl, hashrat can use openssl digest functions, and those can override the built in ones. But it sounds like this isn't the problem. The whole openssl thing is still a bit experimental, and I'm going to put it on a firmer footing. I'm also adding 'make check' for sha384 and sha512. Those should fail as well if the problem is the sha2 common code.
Seems to return incorrect SHA-256 hashes:
More specifically:
Apparently okay for the empty string:
But fails for any non-empty string:
openSUSE Tumbleweed, x86_64, gcc 14.1.0. Does not happen in gcc 13.2.1. Also does not happen when using a system libUseful 5.14.