The previous post about Heinz numbers got me thinking about how secret numbers that we might use as pass numbers for access to various services could be encoded. Let say we have a secret number 659347 that we want to encode using the one to one correspondence between Heinz numbers and integer sequences. Let's treat 659347 as a Heinz number, generate the corresponding integer sequence and then concatenate the numbers in the sequence:If we concatenate the numbers in this sequence, there is ambiguity because the sequences (1341, 96) or (13419, 6) give the same result when the members are concatenated. It would thus be necessary to introduce a dot between the sequence members so as to resemble an IP address. An additional dummy 0 could be added so that it does indeed look like an IP address (0 cannot appear in any Heinz integer sequence). Thus we would have (permalink):The point is that 134.19.6 or 134.19.6.0 can be written in plain sight and there's no way to decode the encrypted secret number (unless you know the magic word: Heinz).

An alternative method would be use the Gray Code. I've written about this in a post titled Gray Code in June of 2023. Here the secret number undergoes the following transformation:Again this number (985178) can be written in plain sight and there's no way to decode it without the magic phrase: Gray Code. Another encoding mechanism is Binary Complement. See my post Binary Complement from October of 2024. Here the encoding goes as follows:There is a problem once we try to decode from 389228. If we convert this number to binary then we don't have a leading zero anymore, we have 1011111000001101100. We need to add this leading zero because binary complements always have a leading zero. Once we do this, we can flip each 0 to 1 and each 1 to 0 to recover our secret number once we convert from binary. If one wanted to be really devious then two or even three encoding techniques could be used sequentially.
No comments:
Post a Comment