Common modulus attack
An organization gave two departments the same modulus n, but made the public exponents different: e1 and e2. The management sent the same order to both departments, resulting in a single message being encrypted twice — with different e.
This is the classic common modulus vulnerability. If gcd(e1, e2) = 1, the extended Euclidean algorithm gives such integers a, b that a·e1 + b·e2 = 1. Then:
c1^a * c2^b = (m^e1)^a * (m^e2)^b = m^(a*e1 + b*e2) = m^1 = m (mod n)
The tricky part: one of a or b will necessarily be negative. For a negative exponent, first take the modular inverse of the ciphertext: pow(c, -1, n), then raise it to the positive power.
The data is in the xabar.txt file: n, e1, e2, c1, c2. Read the message without finding the private key — the decrypted bytes directly give the flag.