A file has been encrypted with the same public key twice, in an effort to improve security. However, both n's
are the same, only differing by the value of e
they used.
#Public key 1
n1 = 24016279469503302311768363568486449460171750320351449411053109064904102702186605107662009320942295421144872090146373296123251966130145432041792751439876360474093585612002400165121650447690296909966552951831431726123370359155905316115223804791521947206341327545023938257688891564488348042571100942123588832599
e1 = 11
#Pub Key 2
n2 = 24016279469503302311768363568486449460171750320351449411053109064904102702186605107662009320942295421144872090146373296123251966130145432041792751439876360474093585612002400165121650447690296909966552951831431726123370359155905316115223804791521947206341327545023938257688891564488348042571100942123588832599
e2 = 1979012594580741578965814515737507102724629115259135437002620173501789696652411313993744725896645142948111090785385183099262030766961088009028637044476121912549313185770249316009240104504564277494277703059316855002885408408101154109370574780029908357870187035294088105105999982886731850954738596033927830763
assert(n1 == n2) # True
c = 19077240875014404240513831497347701592496448798525581251271555405125029031254112763878818905801024929555186756783763228867690958988427269235733424681439935493781830895580741081706308780868332000845463226253464982424465795348256005266884842524968814407751760246714244563807678549191109606785376890867915099095
How would I go about finding m
?
Looking at RSA cracking: The same message is sent to two different people problem it seems there's a way to solve this but I cant seem to figure out how.
I've tried finding the d
when e = 11
since it's easy to brute force and got d = 2
. Assuming this is true, i can decrypt the first layer, but the second layer seems impossible.
Am I approaching this the wrong way?