There is a need in my scenario to allow existing users to log in to moodle either directly or through this plugin.
I don't have a problem logging in with moodle_auth_userkey.
The problem occurs when the existing user after going through this login in a future situation has to log in to moodle directly without going through here. In that situation, moodle complains about invalid login and does not allow user unless the user continues to go through with auth_userkey