Currently, I am utilizing Angular 4 to develop the front end of my application. For authentication, I have integrated OAuth2 on the backend (which is created using Spring in Java), ensuring that only authorized individuals can access my app.
However, there is a major concern as passwords are stored in plain text format in the backend server logs, making them vulnerable to interception by a Man-in-the-Middle (MITM) attack until SSL is implemented.
To address this issue, I have made the decision to encrypt the transmitted passwords using RSA. While my backend implementation is complete, I am facing difficulties finding modern libraries that offer a reliable API for encryption/decryption with RSA key-pairs.
I have explored options like the 'crypto' module, but it is no longer supported in ECMAScript 6. The 'crypto-js' library only supports AES and certain hash functions like MD5/SHA.