Skip to content

Instantly share code, notes, and snippets.

@redknight99
Last active January 9, 2020 23:28
Show Gist options
  • Save redknight99/8a8f4109ae19210d18435914265f220e to your computer and use it in GitHub Desktop.
Save redknight99/8a8f4109ae19210d18435914265f220e to your computer and use it in GitHub Desktop.
A proof of concept script for attempting to crack the remaining unsolved ciphers of Black Ops3 Zombies Revelations Map. Background: https://www.reddit.com/r/CODZombies/wiki/revelations#wiki_ciphers
"""
This module is a test to see if any of the remaining unsolved Black Ops 3
ciphers were Rot13'd + Base64 using the Base64 alphabet / chart.
Base64 alphabet / chart example: https://en.wikipedia.org/wiki/Base64#Base64table .
The results of the test suggest that none of the remaining ciphers we're dealing
with are encrypted using this technique.
"""
import base64
import string
map_letters = string.ascii_uppercase + string.ascii_lowercase + string.digits + "+/"
# Cipher Alias: MotD_Corkboard / Cipher #4
# x = """iW9cXmzOU7ZuZBtW40b3ngK2icE75R0Vb7HvniQd7aCAh5aQRum8gp91EzIDtgySXvGUQxAn3gOM2grBpiLf3QjdfBwjLForeHhqEX59HyOVq9vos22eBNP3ouDrTTNZpwHZPeJDGVt1oauYa+pgDuG7FzHdHFqTfsu5YIdFNlhO7TH3ytjgZKBtCRTtSHfoKU63MvLd1J+UYTzGic90jSJY7k6gWRDDnRfQuthzgo49ELKNRei5W58fAf27hnhUVMEi5KVIXqrI4J7ttys971vENRROhGz8JkhnqJbtKuftKUXgpt2/Iy/fGI6iHT/aaQg7Yddd2YocXsDE7D8NqXr3JqS0m5tSMdFYsipJONks1Iu21OlfwJhbXVQfbpkFnwXYlkLJJL8Yq+3wjeCYYmySmWU6rGMH0Jz/g0B2T3CG+uKU2i3UZ0YxOtl4ugiDkrZnGuZKmdSkJJPvdDqJeEjpFKY+8le7bVzTx7qHKvpITj3E/HH/Ac8Jd9zOOqIb+stbpJDRYI6hMP8uqKyPydHe40v0sXjCkwTj/letJVtNseMqQ6NGEAIdazM54rJUeMPq3wglsndvYMoKILOXocFaydVYzAH4iwnoxxk2kZ3zoV4YJCxI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mD0T9V97wuspvR7TLHCXM1O6mm+Zw+cUD/TBbYHdKU6SbEQQe6oNtBe8U9QGxn7wJFE0Dm+9iyK4BsbbZYzvIlJCHkjwDez+hhTjxuviYCWs+R4H2uIr1d3YtGC83E8ANZV8YBWdaiwEZaDPrgB5wQPl5bIwhX4Z553ioWgVhaw4n31OQgNo8mzJtEgyvRwtpkG6KxfbwX4JyUolC6iRlAgMkAYrx3ncQu00+MAI8LB/gAd/kZTxM="""
# Cipher Alias: DE_bucket / Cipher #10
# x = """OkEeZHnifuMdYB1IbHyAfb0g2FJzrVmfkKcSbKrpQGvhQ0/bvu76RdnGy/WtT7T3"""
# Cipher Alias: Origins_Trench / Cipher #6
# NOTE: We converted the original hex bytes to Base64 to standardize the cipher to the others.
x = """ODMgQjU3QjIgQzM0MzQgNjk3RjYgRkNBM0YgOEVBRDYgNjNDNDIgQjdGMjAgMDQxQjUgQjZBMEQgQTRBRTAgQUQyNEIgOTNCMjcgRkY1NEMgNkU3OUEgMTEzNkUgMzY4NjAgQzY5QzcgMkQ0OTcgQ0RDOTggMkQ0OUMgRDI1QjMgRkNCMzYgRDkzNEMgRjBEMzEgNTEyQUYgQTc4RTYgMjZGRkQgODFDQUMgQUFFRDYgMjI2REEgQ0Q0NDkgODY3NjggM0EyRTAgQjlFNjQgNDA2QzYgMTBDMTQgMDQ5MDcgNTFBOUQgNEE1RjIgNDQ3NUMgOTFDOTEgOUFFNUUgODlENzkgNDc3REIgMkIyOUMgNTQ0NEQgRUEzNjIgNTRFOTQgQTE0QTcgNThDNDIgMDk2RkUgQkQxNzcgNzM5QjMgQTQxODUgNjI3MkEgRDlBMkYgOTU1NEYgODBFNjggNTA0RjkgMjQ1MUMgMjdEMDAgNjgwMTMgODM3M0EgRkI2QzIgOTE0MzkgRjdFODMgQTdGMTIgMUU1NkMgOTk2NDYgNzQwNDYgMjYyM0MgQ0Y4NUMgMkQ4N0EgQUJFNjMgMUY0RDMgRkFCQTcgNUUwMDMgRDY0RjQgRDR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NTkgRUY2NDIgNTA0ODggOTYyRjIgRDNEMjMgMzg2MkUgRjdDMUUgNzc1NTQgNDdERTQgMjk0RTEgMUE0N0Y="""
# Cipher Alias: SamsRoom_Floor / Cipher #7
# x = """nee1bHowKtghExi46wfcRfcWMAFtUVkDuKBtj75XtJy0uaD4cYWtsXKmIpw7YBWFqjpHmb8kAC2UXj71"""
# Test a single possible rotation.
# shift = int(input("How far would you like to shift each letter on the Base64 chart?"))
# Test all 0 to 63 possible rotations
for shift in range(0, 64):
final_string = ""
for char in x:
if char != "=":
indexy = str(map_letters.index(char))
shift_indexy = int(indexy) + shift
if shift_indexy > 63:
shift_indexy = int(shift_indexy) - 63
final_string += map_letters[shift_indexy]
final_string += "="
try:
base64_x = base64.b64decode(final_string)
print("The base64_x is: " + str(base64_x))
except Exception as e:
print("An error occurred when we tried to b64decode that string.")
print("The error was: " + str(e))
# input() used for manually checking the base64 decoded output.
# input("How it look?")
# TODO: Add English language detection logic.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment