<br><br><div class="gmail_quote">2011/8/7 paul <span dir="ltr">&lt;<a href="mailto:paul@aptrackers.com">paul@aptrackers.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
I was wondering whether there&#39;s an easier way to do this.<br>
<br>
Currently, whenever I use the grok UI manager interface, my grok instance remains logged in as manager- so my app PAU instance detects a valid login and doesn&#39;t allow me to log out.   I can log out my own users at application level, but since the &#39;manager&#39; identity is not managed by my own PAU instance, I cannot seem to log out manager.<br>

<br>
Currently, I clear the zope session cookie, close the browser tab, and reload the URL to clear the login.   I&#39;m sure there&#39;s an easier way, but after much searching through the web online docs and the zope implementation code, I&#39;m blowed if I know what it is.<br>

<br>
Can someone point me in the right direction?<br>
<br>
<br></blockquote><div><br>I do this to logout using Basic Auth.<br><br>It detect if I&#39;m logged, if it&#39;s true then raise an unauthorized status and ask again for user and password. Just press OK and you are logout.<br>
<br>PageTemplate:<br>    &lt;div id=&quot;cuadro-usuario&quot;<br>         tal:define=&quot;usr user/getUserName&quot;&gt;<br><br>      &lt;div tal:condition=&quot;python: usr &lt;&gt; &#39;Anonymous User&#39;&quot;&gt;<br>
        &lt;span tal:condition=&quot;exists: request/salgo&quot;&gt;<br>           &lt;span tal:define=&quot;x context/scripts/usuario_salir&quot;&gt;&lt;/span&gt;<br>        &lt;/span&gt;<br><br>        &lt;span tal:content=&quot;usr&quot;&gt;&lt;/span&gt;<br>
           &lt;a tal:attributes=&quot;href python:request.BASE2 + &#39;?salgo=true&#39;&quot; <br>              target=&quot;_parent&quot;&gt; - Logout&lt;/a&gt;<br>      &lt;/div&gt;<br><br><br>      &lt;div tal:condition=&quot;python: usr == &#39;Anonymous User&#39;&quot;&gt;<br>
        &lt;span tal:condition=&quot;exists: request/entro&quot;&gt;<br>           &lt;span tal:define=&quot;x context/scripts/usuario_entrar&quot;&gt;&lt;/span&gt;<br>        &lt;/span&gt;<br><br>          &lt;a tal:attributes=&quot;href python:request.BASE2 + &#39;?entro=true&#39;&quot; <br>
              target=&quot;_parent&quot;&gt;Login&lt;/a&gt;<br>       &lt;/div&gt;<br>         <br>    &lt;/div&gt;<br><br><br>&lt;usuario_entrar&gt;:<br>request = container.REQUEST<br>response =  request.RESPONSE<br><br>
response.setStatus(&#39;Unauthorized&#39;)<br>response.setHeader(&#39;WWW-Authenticate&#39;, &#39;basic realm=&quot;OPTIMUSMX&#39;, 1)<br><br><br>&lt;usuario_salir&gt;:<br>request = container.REQUEST<br>response =  request.RESPONSE<br>
<br>response.setHeader(&#39;WWW-Authenticate&#39;, &#39;basic realm=&quot;OPTIMUSMX&#39;, 1)<br>response.setStatus(&#39;Unauthorized&#39;)<br><br><br><br></div></div>-- <br>________________________________________<br>Lo bueno de vivir un dia mas<br>
es saber que nos queda un dia menos de vida<br>