I'm just looking at very simple encryption. I've noticed that the key is typically either at the front or at the back of the encrypted text. This is quite easy to break if you know the key. It can be made more difficult if the key is split up and scattered in random known positions within the encrypted message. The locations used by the key will only be known to the encrypter and decrypter.
Say the key is 0xBAADF00D and the message, after encryption is 20 bytes long. Say
If the key is added, it will be 24 bytes. The encrypted code is shifted to make holes in positions 2, 9, 15 and 19.
0102 030405060708 090A0B0C0D 0E0F10 11121314
Then add key byte 1 at 15, key byte 2 at 9, 3 at 19 and 4 at 2 instead of the standard 1, 2, 3, 4 positions.
On decryption, just extract the bytes from those positions, pack the remainder to obtain the key and the original encrypted message and begin the process of decryption.
Is there a name already given to this technique.