add a set session value behavior to the login page. Go to the server behaviors panel and click the plus button, select WebAssist -> Cookies -> Set Session Value
for the trigger, select any form post.
Set the name to something like "attemptedUserName"
for the value, click the plus button and select the Username form element.
In the insert behavior, you can use the session variable to capture the username