in this link https://www.geeksforgeeks.org/rsa-algorithm-cryptography it says that The server encrypts the data using client’s public key. but here you are decrypting data using client's public key why ?
and also your are encrypting data using private keys.
if some another attacker has this public key then anybody can access the data.
in this link https://www.geeksforgeeks.org/rsa-algorithm-cryptography it says that The server encrypts the data using client’s public key. but here you are decrypting data using client's public key why ?
and also your are encrypting data using private keys.
if some another attacker has this public key then anybody can access the data.