qrisp.shor.rsa_decrypt#
- rsa_decrypt(e, N, cipher_int, backend=None)[source]#
Decrypts an integer using factorization powered by Shor’s algorithm.
- Parameters:
- eint
Public key 1.
- Nint
Public key 2.
- cipher_intint
The integer to decrypt.
- backendBackendClient, optional
The backend to execute the quantum algorithm. By default the Qrisp simulator will be used.
- Returns:
- plaintextint
The decrypted integer.
Examples
We decrypt the integer 2 using \(N = 33\) and \(e = 7\)
>>> from qrisp.shor import rsa_decrypt >>> rsa_decrypt(7, 33, 2) 8