一、base??

开启本题得到一个txt文件,里面给出了字典和密码。很明显需要通过对应关系求出flag截屏2022-03-07 13.57.34.png

写一个python程序

解出flag:
截屏2022-03-07 13.59.25.png
代码在这里

  1. import base64
  2. txt = {0: 'J', 1: 'K', 2: 'L', 3: 'M', 4: 'N', 5: 'O', 6: 'x', 7: 'y', 8: 'U', 9: 'V', 10: 'z', 11: 'A', 12: 'B', 13: 'C', 14: 'D', 15: 'E', 16: 'F', 17: 'G', 18: 'H', 19: '7', 20: '8', 21: '9', 22: 'P', 23: 'Q', 24: 'I', 25: 'a', 26: 'b', 27: 'c', 28: 'd', 29: 'e', 30: 'f', 31: 'g', 32: 'h', 33: 'i', 34: 'j', 35: 'k', 36: 'l', 37: 'm', 38: 'W', 39: 'X', 40: 'Y', 41: 'Z', 42: '0', 43: '1', 44: '2', 45: '3', 46: '4', 47: '5', 48: '6', 49: 'R', 50: 'S', 51: 'T', 52: 'n', 53: 'o', 54: 'p', 55: 'q', 56: 'r', 57: 's', 58: 't', 59: 'u', 60: 'v', 61: 'w', 62: '+', 63: '/', 64: '='}
  3. chipertext = 'FlZNfnF6Qol6e9w17WwQQoGYBQCgIkGTa9w3IQKw'
  4. base64_list = ['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', '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', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '+', '/']
  5. flag = ''
  6. for i in chipertext:
  7. for j in txt:
  8. if i == txt[j]:
  9. flag+=base64_list[j]
  10. else:
  11. continue
  12. print(flag)
  13. FLAG = base64.b64decode(flag)
  14. print(FLAG)

flag:BJD{D0_Y0u_kNoW_Th1s_b4se_map}

二、Not_only_base

开启本题得到一串糊掉的base?
MCJIJSGKP=ZZYXZXRMU=W3YZG3ZZ==G3HQHCUS==
既然题目说这是跟base有关,那就当它是base好了。然而它的格式并不能称得上是一个base编码。

尝试进行栅栏转换

截屏2022-03-07 14.06.48.png
果然,得到了真正的base编码
截屏2022-03-07 14.07.38.png
由base32解码得到flag
flag{N0t_0NLy_b4sE32}