苍天有泪 发表于 2017-1-28 15:33:37

tomcat 禁止 IP访问

  <Engine name="Catalina" defaultHost="www.jrd.com">
  <!--For clustering, please take a look at documentation at:
  /docs/cluster-howto.html  (simple how to)
  /docs/config/cluster.html (reference documentation) -->
  <!--
  <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"/>
  -->
  <!-- Use the LockOutRealm to prevent attempts to guess user passwords
  via a brute-force attack -->
  <Realm className="org.apache.catalina.realm.LockOutRealm">
  <!-- This Realm uses the UserDatabase configured in the global JNDI
  resources under the key "UserDatabase".  Any edits
  that are performed against this UserDatabase are immediately
  available for use by the Realm.  -->
  <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
  resourceName="UserDatabase"/>
  </Realm>
  <Host name="www.jrd.com"  appBase="webapps"
  unpackWARs="true" autoDeploy="true"
  xmlValidation="false" xmlNamespaceAware="false">
  <!-- SingleSignOn valve, share authentication between web applications
  Documentation at: /docs/config/valve.html -->
  <!--
  <Valve className="org.apache.catalina.authenticator.SingleSignOn" />
  -->
  <!-- Access log processes all example.
  Documentation at: /docs/config/valve.html
  Note: The pattern used is equivalent to using pattern="common" -->
  <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
  prefix="localhost_access_log." suffix=".txt"
  pattern="%h %l %u %t &quot;%r&quot; %s %b %{Referer}i %{User-Agent}i " />
  <!-- <Context path="" docBase="D:/****" sessionCookiePath="/" sessionCookieDomain="****"/> -->
  </Host>
  <Host name="192.168.1.126"  appBase="ipapps"
  unpackWARs="true" autoDeploy="true"
  xmlValidation="false" xmlNamespaceAware="false"/>
  </Engine>
页: [1]
查看完整版本: tomcat 禁止 IP访问