This commit is contained in:
Roman Hergenreder
2018-12-05 12:58:22 +01:00
parent 433ed832e0
commit ab0b694600
27 changed files with 1128 additions and 7 deletions

View File

@@ -3,16 +3,24 @@
# URL: https://hackvent.hacking-lab.com/Pirates_123/
s = '::)"<.vd]!&a{":r>Qyh 7';
length = len(s)
f='HV18-';
# indizes: 4, 9, 14, 19
# xxxx-xxxx-xxxx-xxxx
# correctKey = "1xxx1xxx"
correctKey = "00000000"
for i in range(4):
pos = 4 + i*5
key = ord(s[pos]) ^ ord('-')
correctKey += "%02d%s" % (key, "00000000")
correctKey += "%02d" % key
correctKey += "00000000"
# if len(correctKey) % 4 == 0:
# correctKey += "1xxx1xxx"
# else:
# correctKey += "xx1xxx1x"
for i in range(length):
a = ord(s[i])
@@ -23,9 +31,9 @@ upperBytes = ["15", "17"]
lowerBytes = ["12", "84"]
data = [correctKey[i:i+4] for i in range(0, len(correctKey), 4)]
print(correctKey)
print(data)
print(f)
print(correctKey)
print(f.encode("utf-8"))
js = ""
for i in range(len(data)):
@@ -45,4 +53,4 @@ print(js)
# 000000001700008400121500000015001700008400000000
# 000000001700000000120000000015000000008400000000
#