Java Tomcat8安全

Java Tomcat8安全,java,security,tomcat8,Java,Security,Tomcat8,嗨,我有Tomcat8安全问题,请帮助我 我的应用程序在Tomcat 6中带有Apache Struts1。 当我尝试登录获取HTTP 403时-对请求的资源的访问被拒绝,但我认为我的配置安全性是正确的,这是我的web.xml: <welcome-file-list> <welcome-file>index.jsp</welcome-file> </welcome-file-list> <security-constraint>

嗨,我有Tomcat8安全问题,请帮助我

我的应用程序在Tomcat 6中带有Apache Struts1。 当我尝试登录获取HTTP 403时-对请求的资源的访问被拒绝,但我认为我的配置安全性是正确的,这是我的web.xml:

<welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
</welcome-file-list>

<security-constraint>
    <display-name>EEEExample Security Constraint</display-name>
    <web-resource-collection>
        <web-resource-name>Protected Area</web-resource-name>
        <url-pattern>*.do</url-pattern>
        <url-pattern>*.jsp</url-pattern>
        <url-pattern>/gp</url-pattern>
        <url-pattern>/hp</url-pattern>
        <url-pattern>/sp</url-pattern>
        <url-pattern>/gi</url-pattern>
        <http-method>DELETE</http-method>
        <http-method>GET</http-method>
        <http-method>POST</http-method>
        <http-method>PUT</http-method>
        <http-method>LOCK</http-method>
        <http-method>OPTIONS</http-method>
        <http-method>TRACE</http-method>
        <http-method>HEAD</http-method>
    </web-resource-collection>
    <auth-constraint>
        <role-name>ADMINISTRADORES</role-name>
    </auth-constraint>
</security-constraint>
<security-constraint>
    <web-resource-collection>
            <web-resource-name>Protected Area</web-resource-name>
            <url-pattern>/gp</url-pattern>
            <url-pattern>/hp</url-pattern>
            <url-pattern>/sp</url-pattern>
            <url-pattern>/gi</url-pattern>
    </web-resource-collection>
</security-constraint>
<login-config>
    <auth-method>FORM</auth-method>
    <realm-name>Example FFFForm-Based Authentication Area</realm-name>
    <form-login-config>
        <form-login-page>/WEB-INF/jsp/login.jsp</form-login-page>
        <form-error-page>/WEB-INF/jsp/login_error.jsp</form-error-page>
    </form-login-config>
</login-config>
<security-role>
    <role-name>ADMINISTRADORES</role-name>      
</security-role>

index.jsp
例如安全约束
保护区
*.做
*.jsp
/全科医生
/惠普
/sp
/胃肠道
删除
得到
邮递
放
锁
选择权
痕迹
头
行政人员
保护区
/全科医生
/惠普
/sp
/胃肠道
形式
基于FFFForm的身份验证区域示例
/WEB-INF/jsp/login.jsp
/WEB-INF/jsp/login\u error.jsp
行政人员
我的login.jsp表单有以下内容:

<form method="POST" action='j_security_check' >
  <table border="0" cellspacing="5">
<tr>
  <td align="right">Usuario:</td>
  <td align="left"><input type="text" name="j_username"></td>
</tr>
<tr>
  <td align="right">CContraseña:</td>
  <td align="left"><input type="password" name="j_password"></td>
</tr>
<tr>
  <td align="right">&nbsp;</td>
  <td align="left"><input type="submit" value="Entrar"></td>
</tr>
  </table>
</form> 

乌萨里奥:
CContraseña:
我的领域类有authenticate方法和startInternal、stopInternal方法。 authenticate方法正确地返回了主体类,那么我不知道为什么要获取HTTP403。我希望看到index.jsp 谢谢你的帮助