Advertisement
Guest User

Untitled

a guest
Aug 17th, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.23 KB | None | 0 0
  1. Count numbers:
  2. 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
  3.  
  4. Replace every 0 by A, every 1 by B, etc (monoalphabetic substitution):
  5. In Javascript we can write it by this as:
  6. str.replace(/\d/g, x => "ABCDEFGHIJK"[x])
  7. So we say the code for this alphabet is:
  8. "ABCDEFGHIJK"
  9. In this the symbol at position 0 is what replaces a 0, i.e. 0 -> A, and so on.
  10.  
  11. So if we translate the top counting using "ABCDEFGHIJK" we get:
  12. A B C D E F G H I J BA BB BC BD BE BF BG BH BI BJ CA CB CC CD
  13.  
  14. We can sill see that we are counting because B follows A, C follows B, etc. But we
  15. can only detect it because we know the order of the alphabet.
  16.  
  17. We could use a different alphabet: "6534290871". Then we get:
  18. 6 5 3 4 2 9 0 8 7 1 56 55 53 54 52 59 50 58 57 51 36 35 33 34
  19.  
  20. We know we are still counting, because we translated the counted sequence in a way
  21. that can be reversed. But we cannot see that it is counting anymore. We can see it
  22. by translating it back. But to do this we need to know the alphabet.
  23.  
  24. Is there a clever way to determine the alphabet by just looking at a counted sequence?
  25.  
  26. How does this influence the security of an encryption, if we know enough counted cipher datagrams?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement