john pfeiffer
  • Home
  • Categories
  • Tags
  • Archives

Tomcat6 sslv3 only disable sslv2 list files

tomcat6-sslv3-only

sudo vi /etc/tomcat6/server.xml

TEST IT VIA: openssl s_client -ssl2 -connect localhost:443

The "built in servlet" has a lot of functionality (usually disabled for security reasons) $CATALINA_BASE/conf/web.xml (/var/lib/tomcat6/conf/web.xml)

<servlet>
    <servlet-name>default</servlet-name>
    <servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
    <init-param>
        <param-name>debug</param-name>
        <param-value>0</param-value>
    </init-param>
    <init-param>
        <param-name>listings</param-name>
        <param-value>false</param-value>
    </init-param>
    <load-on-startup>1</load-on-startup>
</servlet>

To allow symbolic linking (symbolic link = ln -s /universal/path/example targetname )

Note sure why I had to modify the universal context.xml instead of just the local one =(

sudo vi /var/lib/tomcat6/conf/context.xml

WEB-INF/web.xml


NOTE: if you do the listings = true change above and drop Helloworld.war in /var/lib/tomcat6/webapps any files in /var/lib/tomcat6/webapps/Helloworld are listed

sudo vi /etc/tomcat6/web.xml

default org.apache.catalina.servlets.DefaultServlet debug 0 listings true 1

/var/lib/tomcat/webapps/ROOT (has a simple java servlet "Helloworld" and then any static files)

e.g. http://domain.com/static.html


For Logging

/etc/tomcat6/server.xml

  <Valve className="org.apache.catalina.valves.AccessLogValve"
           directory="logs"
           prefix="localhost_access_log."
           suffix=".txt"
           pattern="combined"
           resolveHosts="false"
           fileDateFormat="yyyy-MM"/>

http://tomcat.apache.org/tomcat-6.0-doc/config/valve.html


  • « file read tokenizer isdigit
  • Perl strings »

Published

Apr 2, 2012

Category

linux

~127 words

Tags

  • disable 8
  • files 16
  • linux 249
  • list 23
  • only 4
  • sslv2 1
  • sslv3 1
  • tomcat6 7