I'm using hashlib sha256 (python) to prove two input.
My hypotesis was null char and empty string will give same hash.
Here my code
from hashlib import sha256
print(sha256(b'\x00').hexdigest(),end='\n\n')
print(sha256(b'').hexdigest())
And it gave output
6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d
e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
Why they dont gave same result?
Is there relation with C language string format which the string always end with null? So when i hash null, it will hash double null?