Results 1 to 4 of 4

Thread: authz tag not working

  1. #1

    Default authz tag not working

    I'm using some simple code just to see if the tags would work, unfortunately the "you're logged in" shows up regardless of any situation (not logged in, logged in, hold the right credentials, etc.)

    Code:
    <authz&#58;authorize ifAllGranted="ROLE_USER">
          you're logged in...<br />
    </authz&#58;authorize>
    This is the code I've added to web.xml copied from the reference manual.
    Code:
    <taglib>
         <taglib-uri>http&#58;//acegisecurity.sf.net/authz</taglib-uri>
         <taglib-location>/WEB-INF/authz.tld</taglib-location>
    </taglib>
    Interestingly enough, when I do add this line, eclipse throws up a red X next to the file name to indicate something's wrong. I assume it's because the authz.tld doesn't physically exist there. The acegi-security jar is in the WEB-INF/lib folder, and the rest of the authentication seems to work fine. I'm using Tomcat 5.5. Did I miss something?
    PJ

  2. #2

    Default

    The problem was that I didn't have this included on the page. I'm using that it's 3:30AM as my defense.
    <%@ taglib prefix="authz" uri="http://acegisecurity.sf.net/authz" %>
    PJ

  3. #3
    Join Date
    Aug 2004
    Location
    St. Louis, MO
    Posts
    39

    Default Another Problem and Solution

    Thought I'd tack this on, although it doesn't techincally pertain to your problem

    If you are using Sitemesh and Acegi, it is imperative that you order the filters correctly or your authz tags will not work properly in the decorator.

  4. #4

    Default

    I am using sitemesh, I guess I just got lucky, the authz tag is working fine in my decorator.
    PJ

Similar Threads

  1. Jboss, JAAS, Spring -- working example?
    By jkwon in forum Security
    Replies: 4
    Last Post: May 14th, 2009, 03:41 PM
  2. authz tags not working
    By asarco in forum Security
    Replies: 4
    Last Post: Apr 28th, 2007, 03:12 PM
  3. Replies: 7
    Last Post: Nov 22nd, 2005, 02:21 PM
  4. Replies: 1
    Last Post: Oct 6th, 2005, 10:32 AM
  5. Replies: 2
    Last Post: Apr 22nd, 2005, 09:16 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •