1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
| from Crypto.Util.number import * import gmpy2 from hashlib import md5
n = 113021375625152132650190712599981988437204747209058903684387817901743950240396649608148052382567758817980625681440722581705541952712770770893410244646286485083142929097056891857721084849003860977390188797648441292666187101736281034814846427200984062294497391471725496839508139522313741138689378936638290593969 c1 = 43054766235531111372528859352567995977948625157340673795619075138183683929001986100833866227688081563803862977936680822407924897357491201356413493645515962458854570731176193055259779564051991277092941379392700065150286936607784073707448630150405898083000157174927733260198355690620639487049523345380364948649 p = 10631151190024160908870967192522097752991652918777416177941351782447314225123009693276679810786266997133099934443701772661928189884235742113123409596993409 q = n // p e = 65537 assert p * q == n phi = (p - 1) * (q - 1) d = gmpy2.invert(e, phi) m = pow(c1, d, n) print(long_to_bytes(m))
def md5_hash(m): return md5(m.encode()).hexdigest()
c2 = ['4a8a08f09d37b73795649038408b5f33', '03c7c0ace395d80182db07ae2c30f034', 'e1671797c52e15f763380b45e841ec32', 'b14a7b8059d9c055954c92674ce60032', 'e358efa489f58062f10dd7316b65649e', 'cfcd208495d565ef66e7dff9f98764da', 'b14a7b8059d9c055954c92674ce60032', '8fa14cdd754f91cc6554c9e71929cce7', '0cc175b9c0f1b6a831c399e269772661', '4a8a08f09d37b73795649038408b5f33', 'e358efa489f58062f10dd7316b65649e', 'cfcd208495d565ef66e7dff9f98764da', '4b43b0aee35624cd95b910189b3dc231', 'cbb184dd8e05c9709e5dcaedaa0495cf'] flag2 = '' title = '01234567890qwertyuiopasdfghjklzxcvbnm_}' for i in c2: for j in title: if md5_hash(j) == i: flag2 = flag2 + j break print(flag2)
|