[FIX] Reset failed login, redirect to trusted location

Fixes #1701