fix: use 0xFA as flag haed

This commit is contained in:
2023-10-16 14:32:36 +08:00
parent c2de294d1c
commit 1c680b646a
3 changed files with 5 additions and 5 deletions

View File

@@ -1,8 +1,8 @@
import gmpy2 import gmpy2
from sympy import nextprime from sympy import nextprime
from Crypto.Util.number import * from Crypto.Util.number import *
n = 119089874014927074688341672884508166875005676500322264758691717600758737133958853429775347698400246542956663932584349274109281162512900740554148968627493442686180696496512753102593837838697028745592258709705875168834908314583594102947493349091661801379830005354833653565157987808629144151353148601181998243399 n = 131218645413263355153882609539056016131417346313857164694985244482795553321017628052409848109502464613127315618163239570703997367565089679231386965428337884937201599530967017131631155141474278378404319209291510075037073905863337674016959942427881314862079017726040171724955667479955452318495669802898606424779
cipher = 117095409962662175082351896808794751507022710425611245694723238077959955609489552866653772250169627679450018400780468195080203740614508425379908667955368095074633690882446901510961333353751345467769557765781287285368700648236247094896521401160296460446518097963846290488354458277094831166588801569124630935182 cipher = 26956916426221432592724280571104585450884434311786111534684952145936843234803020133270687335772238641092604523138936635434436452351638173961249648611694741353332785924630668149684381852459140144587038595053081706954959823271114216030131967673910349569926570370812503337360887328344577462535615172014761814718
e = 65537 e = 65537
root = gmpy2.iroot(n,2)[0] root = gmpy2.iroot(n,2)[0]
q = nextprime(root) q = nextprime(root)

View File

@@ -1 +1 @@
flag = b'flag{You_can_do_this}' flag = b'0xFA{You_can_do_this}'

View File

@@ -11,6 +11,6 @@ cipher = pow(message, e, n)
print('n = ', n) print('n = ', n)
print('cipher = ', cipher) print('cipher = ', cipher)
''' '''
n = 119089874014927074688341672884508166875005676500322264758691717600758737133958853429775347698400246542956663932584349274109281162512900740554148968627493442686180696496512753102593837838697028745592258709705875168834908314583594102947493349091661801379830005354833653565157987808629144151353148601181998243399 n = 131218645413263355153882609539056016131417346313857164694985244482795553321017628052409848109502464613127315618163239570703997367565089679231386965428337884937201599530967017131631155141474278378404319209291510075037073905863337674016959942427881314862079017726040171724955667479955452318495669802898606424779
cipher = 117095409962662175082351896808794751507022710425611245694723238077959955609489552866653772250169627679450018400780468195080203740614508425379908667955368095074633690882446901510961333353751345467769557765781287285368700648236247094896521401160296460446518097963846290488354458277094831166588801569124630935182 cipher = 26956916426221432592724280571104585450884434311786111534684952145936843234803020133270687335772238641092604523138936635434436452351638173961249648611694741353332785924630668149684381852459140144587038595053081706954959823271114216030131967673910349569926570370812503337360887328344577462535615172014761814718
''' '''