Hi,<br>
<br>
I'm integrating trac with a couple of other things (incl. Zope), using the Apache module mod_auth_tkt for single sign-on.<br>
My login/logout pages also take care of the trac cookies, and all of this actually works great!<br>
<br>
However, the &quot;metanav navigation&quot; in trac is not hardcoded anymore (I'm
using 0.9.4 now), and I couldn't find an easy way to override the
existing login/logout URLs.<br>
My current workaround is to change the &quot;chrome.nav.metanav&quot; items
inside the header template, just before the menu bar is generated by
nav():<br>
<br>
&lt;?cs # Mangle navigation items for customized authentication ?&gt;<br>
&lt;?cs if:trac.authname == &quot;anonymous&quot; || !trac.authname ?&gt;<br>
&lt;?cs set:chrome.nav.metanav.login = 'logged in as ' + trac.authname ?&gt;<br>
&lt;?cs set:chrome.nav.metanav.logout = '&lt;a href=&quot;/logout&quot;&gt;Logout&lt;/a&gt;'&nbsp; ?&gt;<br>
&lt;?cs else ?&gt;<br>
&lt;?cs set:chrome.nav.metanav.login = 'not logged in' ?&gt;<br>
&lt;?cs set:chrome.nav.metanav.logout = '&lt;a href=&quot;/login&quot;&gt;Login&lt;/a&gt;' ?&gt;<br>
&lt;?cs /if ?&gt;<br>
<br>
That's not only ugly, it poses two other problems:<br>
1. The actual trac variables trac.href.login/logout - from which
metanav seems to be built - remain the same: if they are used somewhere
else they will have the wrong value<br>
2. I had to swap login and logout to make it prettier - adding to the
confusion - because Clearsilver only knows &quot;set&quot;, not &quot;unset&quot;/&quot;del&quot;.
Rebuilding the whole list seemed insane.<br>
<br>
Is there a way - let's say in trac.ini - to redefine trac.href.login/logout?<br>
Do I really have to write a plugin that replaces (though inherits 99% of) the existing login module?<br>
<br>
All I want to do is change the URLs - the actual auth is sorted!<br>
<br>
Cheers,<br clear="all">Danny<br>