Single Byte Multiplication in Python?
byte, multiplication, python
Solution
What about
(0x6c * 0x69) & 0xFF
?
And if you want the hex representation in a string, you can do:
hex(result)
Problem
I have a requirement to decode a file using simple byte multiplication For every byte in the file, the byte value is muliplied by 0x69. The result cannot be a word, it must be a single byte. example: ``` 0x24 * 0x69 = 0xc4 0x6c * 0x69 = 0x4c etc. ``` Sorry for not posting code, but have no idea on an existing approach. Thanks