From http://java.sun.com/dtd/web-app_2_3.dtd

<!ELEMENT security-constraint (display-name?, web-resource-collection+,
auth-constraint?, user-data-constraint?)>
... then later ...
<!ELEMENT web-resource-collection (web-resource-name, description?,
url-pattern*, http-method*)>

So you can do this:
<security-constraint>
    <web-resource-collection>
        <web-resource-name>resources</web-resource-name>
        <url-pattern>/input/*</url-pattern>
    </web-resource-collection>
    <web-resource-collection>
        <web-resource-name>more resources</web-resource-name>
        <url-pattern>/input2/*</url-pattern>
    </web-resource-collection>
    <web-resource-collection>
        <web-resource-name>even more resources</web-resource-name>
        <url-pattern>/input3/*</url-pattern>
    </web-resource-collection>
    <auth-constraint>
        <role-name>user</role-name>
        <role-name>NAFO</role-name>
        <role-name>ICON</role-name>
        <role-name>EMEA</role-name>
        <role-name>admin</role-name>
    </auth-constraint>
</security-constraint>

-Tim

Jim Lynch wrote:

"Shapira, Yoav" wrote:


Howdy,
What does your web.xml look like, specifically the security-constraint
parts?

Yoav Shapira
Millennium ChemInformatics


I think I understand where you are going and I changed it slightly and
partially accomplished what I wanted to do.  Here is the modified
version but I have a question, how do I specify a second or third
url-pattern?  I tried to put a second <web-resource-name> section in but
it gave me errors.  Can I have muliple security-constraint sections?  Is
that the right way to add more url-patterns?

Thanks,
Jim.

<security-constraint>
    <web-resource-collection>
        <web-resource-name>resources</web-resource-name>
        <url-pattern>/input/*</url-pattern>
    </web-resource-collection>
    <auth-constraint>
        <role-name>user</role-name>
        <role-name>NAFO</role-name>
        <role-name>ICON</role-name>
        <role-name>EMEA</role-name>
        <role-name>admin</role-name>
    </auth-constraint>
</security-constraint>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to