Consider this ID as invalid and indeed expired, then authenticate him/her again to generate a new session ID.
But consider a threshold, a number of tries before taking punitive action, a user might mistakenly enter his/her password quite repeatedly with no malicious intent at all, and you don't want to tick a user off at this sesnsitive time.
perl -e '$,=$",$_=(split/\W/,$^X)[y[eval]]]+--$_],print+just,another,split,hack'er