public function markAsAuthenticated($username, array $attrs = null)
    {
        if (!$attrs) {
            $attrs = $this->fetchAttrs($username);
        }
        $authResult = new AuthResult($username, $attrs);
        return $this->_stateMgr->set('authResult', $authResult);
    }