Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 7 of 7
  1. #1
    Member
    Join Date
    Apr 2003
    Posts
    479

    Default security issue with error_log files

    The error_log files that are created (I believe that's only with phpsuexec enabled) in each directory are accessable by apache (http://domain.com/error_log)

    Although this problem is not urgent, it can create a security issue by possibly exposing inner workings of php scripts and exposing names of scripts that are being developed in that directory.

    Recommendation to cpanel/phpsuexec/apache (I'm not sure who would be relavent here): chmod 600 these error_logs so they cannot be retreived by apache

    Recommendation to users:

    In httpd.conf (usually /usr/local/apache/conf/httpd.conf), find this section:

    <Files ~ "^\.ht">
    Order allow,deny
    Deny from all
    Satisfy All
    </Files>

    under it, ADD (DO NOT CHANGE):

    <Files ~ "^error_log$">
    Order allow,deny
    Deny from all
    Satisfy All
    </Files>

    This will create a 403 error on any file named error_log for any site

  2. #2
    Member sawbuck's Avatar
    Join Date
    Jan 2004
    Posts
    1,313
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Not sure what version of WHM/cPanel you are talking about but I receive a 403 error currently when accessing the example you provide (with phpsuexec enabled).

  3. #3
    Member
    Join Date
    Apr 2003
    Posts
    479

    Default

    On a new RHE server with phpsuexec enabled, this the behavior that I've seen several times for a while now, but just realised the security hole here.

  4. #4
    Member
    Join Date
    Apr 2002
    Posts
    223

    Default

    I can confirm this problem

  5. #5
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    So, have you logged a bugzilla report?
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  6. #6
    Member
    Join Date
    Apr 2003
    Posts
    479

    Default

    No. The reason I haven't is because I don't think this is a bug in cPanel. I think it is actually apache's or phpsuexec's, and I'm not sure how to find out. Would you recommend that I submit a bug report to cPanel anyway?

  7. #7
    Member
    Join Date
    Apr 2002
    Posts
    223

    Default

    Yes include the code to fix it to otherwise you will be waiting a while for a response.

Similar Threads & Tags
Similar threads

  1. Replies: 2
    Last Post: 05-31-2011, 03:19 PM
  2. Help!! Security Issue?
    By SetLar8 in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 05-01-2006, 02:24 PM
  3. Why isn't rotatelog used for rotating the access_log and error_log files?
    By anup123 in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 11-30-2004, 02:11 PM
  4. Possible security issue
    By GordonH in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 01-27-2004, 04:38 AM
  5. security issue
    By NNNils in forum cPanel and WHM Discussions
    Replies: 16
    Last Post: 04-28-2003, 02:55 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube