Mh, it’s the same code twice.
When the user logs in for the first time, the password is encrypted and stored in the database.
When the user logs in the next time, you fetch the user-document matching the user’s login name from the database. Then you encrypt the password the user has given with the same algorithm as above and compare the result with the string stored in the document.
If the both match, the user has given the correct password and can proceed, if not, the password given was incorrect.
Best regards, Andreas
#webMethods#API-Management#Tamino