Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | wizzofozz <oxxxxxxxxxxxs@gmail.com> |
|---|---|
| Newsgroups | sci.crypt |
| Subject | Re: Toy cipher I made for a reddit challenge |
| Date | 2021-10-02 13:28 +0200 |
| Organization | A noiseless patient Spider |
| Message-ID | <sj9fo1$9dd$1@dont-email.me> (permalink) |
| References | (5 earlier) <sj03aq$puk$1@dont-email.me> <sj58uc$nlj$1@dont-email.me> <sj7r3v$avt$1@dont-email.me> <sj8fl6$b86$1@gioia.aioe.org> <sj9bli$1ui7$1@gioia.aioe.org> |
Op 2-10-2021 om 12:18 schreef Max:
>
> Ok. This isn't the only possible order in which to sort the letters.
> Some steps are forced, but not all. E.g., for the 3rd b one could either
> move the L to the right or the P to the left. This creates a tree. Have
> to dig into this later.
>
I just tested with an implementation which uses a "left list" and "right
list". I think this slightly different from :
> "b" means: take the right of the two "inner letters" and put it to
the > right end, this means:
You can also think:
"b" means: take the first (/last) letter of the right (/left) list and
put it to the end (/beginning) of the right (/left) list.
This way, the lists are growing and shrinking and I get slightly
different results (in my editor the below text hurts your eyes, but if
aligned you may see what I mean):
python brute.py babbylevelsoeasy 1 1
['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M']
['N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z']
b ['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L'] ['N',
'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M']
a ['N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L']
['O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M']
b ['N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K'] ['O',
'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L']
b ['N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J'] ['O', 'P',
'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K']
y ['O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J'] ['P',
'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K']
l ['O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I'] ['P', 'Q',
'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J']
e ['P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I'] ['Q',
'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J']
v ['P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H'] ['Q', 'R',
'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I']
e ['Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H'] ['R',
'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I']
l ['Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G'] ['R', 'S',
'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I', 'H']
s ['R', 'Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G'] ['S',
'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I', 'H']
o ['S', 'R', 'Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G']
['T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I', 'H']
e ['T', 'S', 'R', 'Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F', 'G']
['U', 'V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I', 'H']
a ['U', 'T', 'S', 'R', 'Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D', 'E', 'F',
'G'] ['V', 'W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I', 'H']
s ['V', 'U', 'T', 'S', 'R', 'Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D', 'E',
'F', 'G'] ['W', 'X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I', 'H']
y ['W', 'V', 'U', 'T', 'S', 'R', 'Q', 'P', 'O', 'N', 'A', 'B', 'C', 'D',
'E', 'F', 'G'] ['X', 'Y', 'Z', 'M', 'L', 'K', 'J', 'I', 'H']
Some code:
#!/usr/bin/python
import sys
k=sys.argv[1]
i=int(sys.argv[2]) # set to 0 or 1 to toggle the ifs
j=int(sys.argv[3]) # dito
al=[c for c in "ABCDEFGHIJKLM"]
ar=[c for c in "NOPQRSTUVWXYZ"]
def round(c,al,ar):
n=ord(c)-ord('a')
if n%2 == i:
ta=al.pop() # take from left list
else:
ta=ar[0] # take from right list
ar=ar[1:]
#if (n/2)%2 == j:
if n%2 == j:
ar.append(ta) # append to right list
else:
al.insert(0,ta) # insert in left list
return (al,ar)
print ' ',al,ar
for c in k:
(al,ar) = round(c,al,ar)
print c,al,ar
Back to sci.crypt | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Toy cipher I made for a reddit challenge Leo <usenet@gkbrk.com> - 2021-09-27 21:15 +0000
Re: Toy cipher I made for a reddit challenge Richard Heathfield <rjh@cpax.org.uk> - 2021-09-27 23:12 +0100
Re: Toy cipher I made for a reddit challenge Leo <usenet@gkbrk.com> - 2021-09-27 22:32 +0000
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-09-28 00:51 +0200
Re: Toy cipher I made for a reddit challenge Leo <usenet@gkbrk.com> - 2021-09-28 04:04 -0500
Re: Toy cipher I made for a reddit challenge Richard Heathfield <rjh@cpax.org.uk> - 2021-09-28 11:29 +0100
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-09-28 21:11 +0200
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-09-29 00:00 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-09-30 23:07 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-01 22:29 +0200
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-02 04:20 +0200
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-02 12:18 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-02 13:28 +0200
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-02 16:25 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-02 17:25 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-02 12:28 +0200
Re: Toy cipher I made for a reddit challenge Leo <usenet@gkbrk.com> - 2021-10-02 10:42 -0500
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-02 18:13 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-03 12:27 +0200
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-03 18:02 +0200
Re: Toy cipher I made for a reddit challenge Stefan Claas <spam.trap.usenet@gmail.com> - 2021-10-03 09:23 -0700
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-03 21:32 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-18 08:52 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-18 19:24 +0200
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-19 00:47 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-17 17:17 +0200
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-17 20:05 +0200
Re: Toy cipher I made for a reddit challenge Leo <usenet@gkbrk.com> - 2021-10-25 17:18 -0500
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-26 20:03 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-27 19:49 +0200
Re: Toy cipher I made for a reddit challenge Leo <usenet@gkbrk.com> - 2021-10-27 17:15 -0500
Re: Toy cipher I made for a reddit challenge Max <maxturv26@gmx.net> - 2021-10-28 12:51 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-28 13:33 +0200
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-10-31 22:17 +0100
Re: Toy cipher I made for a reddit challenge Richard Heathfield <rjh@cpax.org.uk> - 2021-10-31 22:38 +0000
Re: Toy cipher I made for a reddit challenge Leo <usenet@gkbrk.com> - 2021-10-31 18:42 -0500
Re: Toy cipher I made for a reddit challenge "Chris M. Thomasson" <chris.m.thomasson.1@gmail.com> - 2021-10-31 19:30 -0700
Re: Toy cipher I made for a reddit challenge wizzofozz <oxxxxxxxxxxxs@gmail.com> - 2021-11-01 21:40 +0100
csiph-web