Prevent apache exposing modules

Discussion in 'Apache' started by robbyc, Mar 1, 2007.

  1. #1
    Hi how do I prevent Apache exposing perl and python?

    i.e. if someone requests a none existent page they see

    Not Found
    The requested URL /test was not found on this server.

    Apache/2.0.54 (Debian GNU/Linux) mod_python/3.1.3 Python/2.3.5 mod_perl/1.999.21 Perl/v5.8.4 Server at my.server.com Port 80

    It originally was showing PHP but that was easy to turn off in the php config file. How do I do the same for python and perl?

    Thanks in advance
     
    robbyc, Mar 1, 2007 IP
  2. rootbinbash

    rootbinbash Peon

    Messages:
    2,198
    Likes Received:
    88
    Best Answers:
    0
    Trophy Points:
    0
    #2
    # Optionally add a line containing the server version and virtual host
    # name to server-generated pages (error documents, FTP directory listings,
    # mod_status and mod_info output etc., but not CGI generated documents).
    # Set to "EMail" to also include a mailto: link to the ServerAdmin.
    # Set to one of: On | Off | EMail
    #
    ServerSignature Off

    from default httpd.conf
     
    rootbinbash, Mar 1, 2007 IP
  3. robbyc

    robbyc Peon

    Messages:
    8
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Thanks for that althought it didn't quite work for me.
    I added that line but also had to add

    ServerTokens Prod

    There are a number of options for ServerTokens see http://www.debianhelp.co.uk/tuning.htm
     
    robbyc, Mar 2, 2007 IP