Y
yoshi_76
hi there
we have defined a secure area in our webapplication. the
authentication is done via tomcat servlet container. this meas, we
have defined all roles with access right in the web.xml file
...
<security-role>
<role-name>admin</role-name>
</security-role>
<security-role>
<role-name>specialUser</role-name>
</security-role>
....
so far so good! it's all working just as expected.
on an administrator page I would like to show all the <security-roles>
which are defined in the web.xml file. is it possible to get them out
of the file from within a servlet?
i know, it would probably possible to read it using the java.io.
package, but since i can also get the value for the session timeout
with HttpSession.getMaxInactiveInterval I wonder, if there is a way to
read further elements from web.xml? But no servlet init params!
best regards
we have defined a secure area in our webapplication. the
authentication is done via tomcat servlet container. this meas, we
have defined all roles with access right in the web.xml file
...
<security-role>
<role-name>admin</role-name>
</security-role>
<security-role>
<role-name>specialUser</role-name>
</security-role>
....
so far so good! it's all working just as expected.
on an administrator page I would like to show all the <security-roles>
which are defined in the web.xml file. is it possible to get them out
of the file from within a servlet?
i know, it would probably possible to read it using the java.io.
package, but since i can also get the value for the session timeout
with HttpSession.getMaxInactiveInterval I wonder, if there is a way to
read further elements from web.xml? But no servlet init params!
best regards