拒绝固定思维.(自定义base64)

题目:

exp:

import string
import base64

s = "gmbhvpuufnwoneusnowscrrvuwutotfnwobe"
char = string.ascii_uppercase + string.ascii_lowercase + string.digits
print(char)
# ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789
# JKLMNOxyUVzABCDEFGH789PQIabcdefghijklmWXYZ0123456RSTnopqrstuvw+/=


str = "gmbhvpuufnwoneusnowscrrvuwutotfnwobe"
zdy = "JKLMNOxyUVzABCDEFGH789PQIabcdefghijklmWXYZ0123456RSTnopqrstuvw+/="
stand = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789=+/"
ec = str.maketrans(stand, zdy)
dc = str.maketrans(zdy, stand)


def encode(x):
    return x.translate(ec)


def decode(x):
    return x.translate(dc)


flag = decode(str)
print(flag)
# flag = base64.b64decode(flag)
# print(flag)

flag8277e0910d750195b448797616e091ad

posted @ 2025-05-18 14:00  lethe311  阅读(10)  评论(0)    收藏  举报