Skip to content

Commit a260fa3

Browse files
committed
Minor changes
1 parent bd07ac5 commit a260fa3

7 files changed

Lines changed: 7 additions & 7 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ o
193193
`radio` | text <-> radio words | aka NATO or radio phonetic alphabet
194194
`resistor` | text <-> resistor colors | aka resistor color codes
195195
`rot` | text <-> rot(N) ciphertext | aka Caesar cipher (N belongs to [1,25])
196-
`rotate` | text <-> N-bits-rotated text | rotates characters by the specified number of bits
196+
`rotate` | text <-> N-bits-rotated text | rotates characters by the specified number of bits ; Python 3 only
197197
`scytale` | text <-> scytale ciphertext | encrypts with L, the number of letters on the rod (belongs to [1,[)
198198
`shift` | text <-> shift(N) ciphertext | shift ordinals with N (belongs to [1,255])
199199
`sms` | text <-> phone keystrokes | also called T9 code ; uses "`-`" as a separator for encoding, "`-`" or "`_`" or whitespace for decoding

codext/crypto/barbie.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
'enc(barbie3|barbie_3|barbie-3)': {'this is a test': "fpsu su h ftuf"},
2323
'enc(barbie4|barbie_4|barbie-4)': {'this is a test': "pufq fq s phqp"},
2424
}
25-
__guess__ = ["barbie%d" % i for i in range(1, 5)]
25+
__guess__ = ["barbie-%d" % i for i in range(1, 5)]
2626

2727

2828
STD = [

codext/crypto/rot.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
'enc(rot3|caesar-3)': {'this is a test': "wklv lv d whvw"},
1919
'enc(rot47)': {'this is a test': "E9:D :D 2 E6DE"},
2020
}
21-
__guess__ = ["rot%d" % i for i in range(1, 26)] + ["rot47"]
21+
__guess__ = ["rot-%d" % i for i in range(1, 26)] + ["rot-47"]
2222

2323

2424
ROT47 = "!\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~"

codext/crypto/scytale.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
'enc(scytale2|scytale-2|scytale_2)': {'this is a test': "ti satshsi et"},
1818
'enc(scytale5|scytale-5|scytale_5)': {'this is a test': "tithsei ssat "},
1919
}
20-
__guess__ = ["scytale%d" % i for i in range(10)]
20+
__guess__ = ["scytale-%d" % i for i in range(10)]
2121

2222

2323
PADDING_CHAR = ""

codext/crypto/shift.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
'enc(shift1|shift_1|shift-1)': {'this is a test': "uijt!jt!b!uftu"},
1616
'enc(shift9|shift_9|shift-9)': {'this is a test': "}qr|)r|)j)}n|}"},
1717
}
18-
__guess__ = ["shift%d" % i for i in range(1, 256)]
18+
__guess__ = ["shift-%d" % i for i in range(1, 256)]
1919

2020

2121
def ord_shift_decode(i):

codext/crypto/xor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
'enc(xor3|xor-3|xor_3)': {'wkjp#jp#b#wfpw': "this is a test"},
1717
'enc(xor6|xor-6|xor_6)': {'this is a test': "rnou&ou&g&rcur"},
1818
}
19-
__guess__ = ["xor%d" % i for i in range(1, 256)]
19+
__guess__ = ["xor-%d" % i for i in range(1, 256)]
2020

2121

2222
def _xorn(text, n=1):

codext/stegano/whitespace.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,6 @@ def decode(text, errors="strict"):
6363

6464

6565
op = r"[+-](?:\d+(?:\.\d+)?[*/])?"
66-
add("whitespace_after_before", wsba_encode, wsba_decode, guess=__guess2__, entropy=1., printables_rate=1.,
66+
add("whitespace_after_before", wsba_encode, wsba_decode, guess=__guess2__, entropy=1., printables_rate=1., penalty=.1,
6767
pattern=r"whitespace("+op+r"before"+op+r"after|"+op+r"after"+op+r"before)$")
6868

0 commit comments

Comments
 (0)