Modify

#14225 closed defect (worksforme)

/login request unhandled when running in trac 1.5.4

Reported by: anonymous Owned by: Ryan J Ollos
Priority: normal Component: AccountManagerPlugin
Severity: normal Keywords:
Cc: Trac Release:

Description (last modified by Jun Omae)

acct_mgr.web_ui.LoginModule.__init__ checks for and attempts to disable trac.web.auth.loginmodule. This somehow seems to fail resulting in the 'enabled' property returning false and the the '/login' request not being processed at all. Some debug output below

01:24:23 Trac[web_ui] INFO: Concurrent enabled login modules found, fixing configuration ...
01:24:23 Trac[web_ui] INFO: trac.web.auth.LoginModule disabled, giving preference to <class 'acct_mgr.web_ui.LoginModule'>.
AAAA True True                       <--------------------------- printed from web_ui.LoginModule.enabled with: 
                                       | print("AAAA", 
                                       |       self.env.is_enabled(self.__class__),
                                       |       self.env.is_enabled(auth.LoginModule))
AAAA True True
01:24:23 Trac[main] DEBUG: Chosen handler is None
AAAA True True
AAAA True True
01:24:23 Trac[api] DEBUG: action controllers for ticket workflow: ['ConfigurableTicketWorkflow']
01:24:23 Trac[session] DEBUG: Retrieving session for ID 'fd9907968f5072a2870c7fc9'
01:24:23 Trac[main] WARNING: [192.168.50.3] HTTPNotFound: 404 Not Found (No handler matched request to /login), <RequestWithSession "GET '/login'">, referrer 'http://localhost:8000/test1/wiki'

This was tested with Trac 1.5.4 and accountmanagerplugin-18544.zip.

Attachments (0)

Change History (3)

comment:1 Changed 12 months ago by anonymous

Forgot to add, explicitly disabling the default login handler in [components] looks like a valid workaround. Specifically, adding the line below allows the accountmgr login page to be displayed and I was able to login.

[components]
trac.web.auth.loginmodule = disabled

FYI the LDAPAcctMngrPlugin appears to also work in this set-up so it can probably be marked as '1.6' - safe.

comment:2 Changed 12 months ago by Jun Omae

Description: modified (diff)

Please provide $ENV/conf/trac.ini and log/trac.log.

comment:3 Changed 12 months ago by Jun Omae

Resolution: worksforme
Status: newclosed

That is by design. The following should be configured if you want to use the login page of AccountManagerPlugin.

[components]
acct_mgr.web_ui.LoginModule = enabled
trac.web.auth.LoginModule = disabled

See wiki:AccountManagerPlugin/Modules#LoginModule

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.