We would like to implement the feature of remembering user's passwords in our application similar to how Microsoft SQL Server login credentials are stored.
(nothing to do with SQL server connection)
We researched and found some information on this.
However, it is not clear how the process/flow of encryption/decryption takes place, i.e, how the process of securely saving and matching of password takes place during validation process.Some of the websites also mention that the SQL login passwords can be cracked.
As per this document from Microsoft, Windows DPAPI is also being used in the form of Service Master Key (SMK) to secure data stored in database, but the actual SQL credentials validation flow is not mentioned. (We found this question as well which mentions DPAPI.)
So is there any method where we can store user's application passwords similar to SQLServer's methodology or any other secure method to ensure they are not cracked or decrypted? We have also read that DPAPI-encrypted passwords can be cracked.
EDIT 11/05/2022: Added screenshot of SQL Server login page, and made minor edits to content.