(bytes)
| 22 | |
| 23 | // Return the hexadecimal representation of the given byte array. |
| 24 | function hexlify(bytes) { |
| 25 | var res = []; |
| 26 | for (var i = 0; i < bytes.length; i++) |
| 27 | res.push(hex(bytes[i])); |
| 28 | |
| 29 | return res.join(''); |
| 30 | } |
| 31 | |
| 32 | // Return the binary data represented by the given hexdecimal string. |
| 33 | function unhexlify(hexstr) { |