Hello guys!

inside of my "/opt/tomcat7/webapps/" folder, I have many apps over there


I would like to protect for instance, "Student" (/opt/tomcat7/webapps/Student) 
app to only allow specific IP address, so I did:


"# vi /opt/tomcat7/conf/Catalina/localhost/Student.xml" and addedd:


<Context antiResourceLocking="false" privileged="true" 
docBase="${catalina.home}/webapps/Student">
   <Valve className="org.apache.catalina.valves.RemoteAddrValve"
    allow="127\.0\.0\.1" denyStatus="404"/>
</Context>

It is working, I am not able to access the https://server.domain.com/Student 
while I am not source = 127.0.0.1 [😊]

But, My HTTP Status on Browser, does not show 404, always saying 403...

My questions:

 - For the first statement, that configuration I did (Student.xml) is the 
correct way?
 - Why the 404 denyStatus is not working?

I am running tomcat 7.0.11

Thanks!


Diego

Reply via email to