mirror of
https://github.com/twisterarmy/DarkenedAges.git
synced 2025-03-12 05:21:20 +00:00
Note re python3
Better lorem ipsum ;)
This commit is contained in:
parent
5e0e2597c6
commit
2c38248daa
@ -56,6 +56,8 @@ Perhaps you could trade this information with their adversaries? The possibiliti
|
||||
|
||||
### How to play
|
||||
|
||||
**Note:** All code here should be run with python3. No telling what this code might do on python2 ;)
|
||||
|
||||
#### First you need to join
|
||||
|
||||
* Every player should have a [twister](http://twister.net.co) account
|
||||
|
@ -206,14 +206,14 @@ def testit():
|
||||
for p in getplayers().values():
|
||||
print('\n# {name} ({player}, @{twister}):'.format(**p))
|
||||
print('\n'.join(' '+l for l in textwrap.wrap(p['bio'])))
|
||||
print('\n\n### Redacting prefab plaintext (2 trustees)')
|
||||
plaintext = "Here's the first line, \nfollowed by a second one"
|
||||
print('\n\n### Redacting "fake redaction" to 2 trustees')
|
||||
plaintext = "You're not as █████████\nas you think you are"
|
||||
redaction = redact(plaintext, 'alice', recipients=['bob','carol'], subject='Is this thing on?', k=2)
|
||||
for line in textwrap.wrap(json.dumps(redaction)): print(line)
|
||||
for t in redaction['__public__']['trustees']:
|
||||
print('\n# >>> Unredaction for trustee: {}'.format(t))
|
||||
print(unredact(redaction['__public__'], redaction[t]))
|
||||
print('\n### >>> integration >>>')
|
||||
print('\n(one of them has utf-8 bloat)\n\n### >>> integration >>>')
|
||||
print(unredact(redaction['__public__'], redaction['__to__']))
|
||||
print('\n\n### Unredaction of prefab message (with conflicting pads)')
|
||||
for t in prefab['__public__']['trustees']:
|
||||
|
80
output.txt
80
output.txt
@ -1,5 +1,16 @@
|
||||
### Players
|
||||
|
||||
# Zabadee O'Mally (zayo, @zayo):
|
||||
A defrocked ███████████ priest turned confession analysis contractor
|
||||
(CAC).
|
||||
|
||||
# Daan II (daanii, @black_puppydog):
|
||||
██ ███ ███████ of ██████.
|
||||
|
||||
# Trantor Alexis (talex, @talex):
|
||||
A confirmed human resident of █████████ ███████████ and ChurchApproved
|
||||
DepescheProzessor since 2048.
|
||||
|
||||
# Rabbi Yoav (broyo, @thedod):
|
||||
Confession sensor technician (CST) and ChurchApproved Rabbi (CAR)
|
||||
[technically, a priest] in the Geneva parish. Born 2061 in Kibbutz
|
||||
@ -8,54 +19,47 @@
|
||||
(mainly due to family and origin). 77% heterosexual. No other known
|
||||
dominant deviations.
|
||||
|
||||
# Daan II (daanii, @black_puppydog):
|
||||
██ ███ ███████ of ██████.
|
||||
|
||||
# Trantor Alexis (talex, @talex):
|
||||
A confirmed human resident of █████████ ███████████ and ChurchApproved
|
||||
DepescheProzessor since 2048.
|
||||
|
||||
# Zabadee O'Mally (zayo, @zayo):
|
||||
A defrocked ███████████ priest turned confession analysis contractor
|
||||
(CAC).
|
||||
# Forth Inc. (forth, @forth):
|
||||
Registered ████████.
|
||||
|
||||
# Sandy Claws (sandyclaws, @sandyclaws):
|
||||
From the Magic Tuna Show (ask your kids).
|
||||
|
||||
# Forth Inc. (forth, @forth):
|
||||
Registered ████████.
|
||||
|
||||
### Redacting "fake redaction" to 2 trustees
|
||||
{"__public__": {"recipients": ["bob", "carol"], "cipher":
|
||||
[["W7MZY1y1", "mnb7", "TQY=", "sT6ZUgYlTlkIaog69AbAFgYCydQ/Na335paz"],
|
||||
["mCs=", "KalY", "7uvPaTg=", "D4Nc", "jaiB"]], "sender": "alice",
|
||||
"subject": "Is this thing on?", "trustees": ["forth", "zayo"],
|
||||
"msgid": "DA14348757490111"}, "forth": {"recipients": ["bob",
|
||||
"carol"], "pads": {"forth": [[null, "9BmP", null,
|
||||
"U6gRsJCtrM+AiB6yFpBI9JCKK0K31zt/BAA7"], ["+Vg=", "UMYt", "moOmB1M=",
|
||||
"duwp", null]]}, "sender": "alice", "subject": "Is this thing on?",
|
||||
"trustees": ["forth", "zayo"], "msgid": "DA14348757490111"}, "zayo":
|
||||
{"recipients": ["bob", "carol"], "pads": {"zayo": [["AtxsRC7Q", null,
|
||||
"LHU=", null], [null, null, null, null, "7Nrk"]]}, "sender": "alice",
|
||||
"subject": "Is this thing on?", "trustees": ["forth", "zayo"],
|
||||
"msgid": "DA14348757490111"}, "__to__": {"recipients": ["bob",
|
||||
"carol"], "pads": {"forth": [[null, "9BmP", null,
|
||||
"U6gRsJCtrM+AiB6yFpBI9JCKK0K31zt/BAA7"], ["+Vg=", "UMYt", "moOmB1M=",
|
||||
"duwp", null]], "zayo": [["AtxsRC7Q", null, "LHU=", null], [null,
|
||||
null, null, null, "7Nrk"]]}, "sender": "alice", "subject": "Is this
|
||||
thing on?", "trustees": ["forth", "zayo"], "msgid":
|
||||
"DA14348757490111"}}
|
||||
|
||||
### Redacting prefab plaintext (2 trustees)
|
||||
{"__to__": {"sender": "alice", "recipients": ["bob", "carol"],
|
||||
"subject": "Is this thing on?", "msgid": "DA14345355125001", "pads":
|
||||
{"daanii": [["EX9FwomA", null, "O1oE0lk=", "8bBvQdY="], [null, "Ddw=",
|
||||
null, "PjVkQR2S", "rPqr"]], "talex": [[null, "4t54", null, null],
|
||||
["5E2TnuiWtQQ=", null, "Hw==", null, null]]}, "trustees": ["daanii",
|
||||
"talex"]}, "daanii": {"sender": "alice", "recipients": ["bob",
|
||||
"carol"], "subject": "Is this thing on?", "msgid": "DA14345355125001",
|
||||
"pads": {"daanii": [["EX9FwomA", null, "O1oE0lk=", "8bBvQdY="], [null,
|
||||
"Ddw=", null, "PjVkQR2S", "rPqr"]]}, "trustees": ["daanii", "talex"]},
|
||||
"__public__": {"cipher": [["WRo3p67z", "lrYd", "XTN2oS0=",
|
||||
"ndkBJPo="], ["giL/8ofh0GA=", "b6U=", "fg==", "TVAHLnP2", "w5TO"]],
|
||||
"sender": "alice", "recipients": ["bob", "carol"], "subject": "Is this
|
||||
thing on?", "msgid": "DA14345355125001", "trustees": ["daanii",
|
||||
"talex"]}, "talex": {"sender": "alice", "recipients": ["bob",
|
||||
"carol"], "subject": "Is this thing on?", "msgid": "DA14345355125001",
|
||||
"pads": {"talex": [[null, "4t54", null, null], ["5E2TnuiWtQQ=", null,
|
||||
"Hw==", null, null]]}, "trustees": ["daanii", "talex"]}}
|
||||
# >>> Unredaction for trustee: forth
|
||||
██████ not ██ █████████
|
||||
as you think you ███
|
||||
|
||||
# >>> Unredaction for trustee: daanii
|
||||
Here's ███ first line,
|
||||
████████ by █ second one
|
||||
# >>> Unredaction for trustee: zayo
|
||||
You're ███ as ███████████████████████████
|
||||
██ ███ █████ ███ are
|
||||
|
||||
# >>> Unredaction for trustee: talex
|
||||
██████ the █████ █████
|
||||
followed ██ a ██████ ███
|
||||
(one of them has utf-8 bloat)
|
||||
|
||||
### >>> integration >>>
|
||||
Here's the first line,
|
||||
followed by a second one
|
||||
You're not as █████████
|
||||
as you think you are
|
||||
|
||||
|
||||
### Unredaction of prefab message (with conflicting pads)
|
||||
|
Loading…
x
Reference in New Issue
Block a user