You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Addressing #50, optimization and fix of tohex() (#53)
* This optimizes tohex() a fair bit
* Also fixes the link I missed in November to the old osslsignicode
project page in the README
* Made the unit tests for hashes case-insensitive; this should capture
the spirit of the string representation of strings better. Where it
_truly_ matters, a case-sensitive check can explicitly be used.
* Added checks against the expected (string) length for the known hashes
* Replaced a number of the literal hashes given in the unit tests. It
turns out the old tohex() was not just slower but also had a defect
which caused leading '0' in the hexadecimal representation of bytes to
disappear. The resulting strings also had irregular sizes.
Below a list of the wrong and correct string representation (duplicates
included):
6663dd7c24fa84fce7f16eb2689952c06cfa22
6663dd7c24fa84fce7f16e0b02689952c06cfa22
2559e91a60953a5e16f965f5f88953a2cca5425
2559e91a60953a5e16f9650f5f88953a2cca5425
f1c260304ec64414a97e10cb19dd4c755f9e7079f85feb38ee7ff9f938db99
f10c2600304ec64414a97e10cb19dd4c755f9e7079f85feb38ee7ff9f938db99
ddc5b39c429212745eb86a67eaa331032cc5a0dafaf6e28ec9aaf189c408d
ddc5b39c4292120745eb86a67eaa331032cc05a0dafaf6e28ec9aa0f189c408d
6f7ac8c1754fad04fba2a552a122e7
6f7ac8c17504fad04fba2a552a122e07
4ba4c91418e28cb63b97cfde1cff95a91139
4ba40c91418e28cb630b97cfde1cff0905a91139
e260f8a57faa823453bd9552506878fcbfb33203d9b606cb9a27e605a8d7b
e260f8a57faa823453bd95525068780fcbfb0332003d9b606cb9a27e605a8d7b
6663dd7c24fa84fce7f16eb2689952c06cfa22
6663dd7c24fa84fce7f16e0b02689952c06cfa22
ea13992f99840f76dcac225dd1262edcec3254511b250a6d1e98d99fc48f815
ea013992f99840f76dcac225dd1262edcec3254511b250a6d1e98d99fc48f815
ea235b77d552633c5a38974cef0e2b5
ea0235b77d552633c5a38974cef0e2b5
2559e91a60953a5e16f965f5f88953a2cca5425
2559e91a60953a5e16f9650f5f88953a2cca5425
5c823491c5991914aec971d9456d93d6cf2b8ee7e0ed7abcb7731d8ec073c0
5c823491c5991914aec971d9456d93d6cf2b8ee7e0ed7abc0b77031d8ec073c0
0 commit comments