Subject: | Authentication failure due to system error doesn't really fail in 0.07_02 |
Using rt 3.8.2 and ExternalAuth 0.07_02 on FreeBSD 7.0 in a dedicated
jail, dependencies installed from ports but RT installed by hand and
ExternalAuth from CPAN. No code or template customizations so far other
than ExternalAuth. The web server is:
Apache/2.2.11 (FreeBSD) mod_ssl/2.2.11 OpenSSL/0.9.8e DAV/2
mod_perl/2.0.4 Perl/v5.8.8
Using LDAP for authentication, a correct username with a record in LDAP
or internally and correct password works as expected on the first test
after an Apache restart: unknown users have an unprivileged account
created, unprivileged accounts are sent to SelfService, privileged
accounts go to the home page.
However, subsequent logins display a disturbing behavior. Rather than
succeeding or failing or falling back to RT internal auth, a "System
error" page is sent back (see attachment "goodpasserr.txt") with an
error apparently inside the Net::LDAP complex and the following in the
RT log (logging at 'debug' depth via syslog)
Jan 17 22:39:28 rttest RT: $pass defined (MUNGE), Running IsPassword
Jan 17 22:39:28 rttest RT: Trying External Authentication ( root )
Jan 17 22:39:28 rttest RT: Attempting to use external auth service:
My_LDAP
Jan 17 22:39:28 rttest RT: Trying external auth service: My_LDAP
Jan 17 22:39:28 rttest RT: LDAP Search === Base: dc=com == Filter:
(&(mail=root)(objectClass=inetOrgPerson)) == Attrs: dn
As you see, the failure is before there's even success or failure from
the search for the user DN, so there should be no chance of success in
authentication (and in that case the user is internal and could not
succeed in LDAP.) Yet after that error, reloading the base URL results
in a redirect to the "At A Glance" home page, because there's a new
RT_SID cookie that arrived *on the error page* that somehow RT is
trusting as identifying an authenticated session.
Obviously this is a complex bug. It has taken me some time to nail down
the behavior, as it appears to be a combination of problems in RT
proper, ExternalAuth, and perl-ldap, with mod_perl a likely contributor
to the perl-ldap failure that exposed the problem. I may end up
reporting bugs in many places on this, but I figured the top layer was
the best place to start.
Subject: | goodpasserr.txt |
Message body is not shown because it is too large.