fork download
  1. # Given values as hexadecimal strings
  2. n_hex = "1DF03E7E77300932A9021A21ED2726C4196ABF85572C4613A6A7897A857E3147E14956FAF448F2335FF82C2F168DCA3A85A8CBF85AF3C2A119C0739294FDEFC760C1ED2491883AB06490075634B9E6BCCA2729875E67C59606B68855EA85B715ECE1CA773126661E0761D235153A349FCFA6B5CAA595F3E6405B1E23CEA27611"
  3. c_hex = "9B0FBD688E294AFAB3869A2003DD24CCA6A070D273FAE3B13F94CAA44F982430A390C7E279C576C31F38863092646D7194C49A6D37AEA59FCBD5EF0915929688EBBB7F6E27AFB8F1E101CCDE0A8B8DE3B098BE51573E3B749075A0E0AC60D883233B1628BC5E5A2559F3CB4E141DC3B6DD3C16E01F9D75D45E8E02711C4C6177"
  4. e = 5
  5.  
  6. # Convert hex to integers
  7. c = int(c_hex, 16)
  8. n = int(n_hex, 16)
  9.  
  10. # Attempt to find the e-th root of c
  11. m_guess = int(c ** (1/e))
  12.  
  13. # Convert m_guess back to bytes
  14. message_bytes = m_guess.to_bytes((m_guess.bit_length() + 7) // 8, byteorder='big')
  15.  
  16. # Print the result
  17. print(message_bytes)
  18.  
Success #stdin #stdout 0.04s 9792KB
stdin
Standard input is empty
stdout
b'\x193$\xdf\x8a\xab\xf2\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'