Hardened hex2bytes version.