Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

As a comment above stated, part of the "input" is the initialized values:

> Initialize hash value h0 to h7: first 32 bits of the fractional parts of the square roots of the first 8 primes 2..19).

My guess is h0 to h7 change throughout the algorithm. If you perform each step in "reverse" as you suggest, "picking" any input at each step that produces the required output for that step, then you may not arrive to the correct initial state with the square roots of the first 8 primes.

You'll arrive at "random-ish garbage".



Ah, yep. You're right. I overlooked that part. It looks like it's truly non-reversible—even if you don't care what the resulting input is.


If you do ever figure out how to reverse SHA-256, best keep it a secret until you've sold all your free Bitcoin.


It's funny, people used to explain that the encryption used in bitcoin is secure because otherwise all your online banking would be at risk.

People don't say that any more because if someone were to break SHA-256 they would actually steal bitcoin first.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: