Problem : File Manager Creates New Files with 755 Permission!

REXNET

Member
Jan 31, 2012
10
0
51
San Francisco
cPanel Access Level
Root Administrator
Hello,

As the title says, I got problem with new files permission which created by cPanel File Manager. I don't remember such a problem before, But I suddenly find it on my new server and after configuration.

I'm using a cPanel/WHM on my dedicated server which is run on CloudLinux with the following addons installed: Installatron, WHMSonic & WHMXtra.

Also I've installed some other software and scripts for managing, monitoring, security and better performance and i'll pm them on your request.

Please help me to find the problem.

Thanks
 

arunsv84

Well-Known Member
Oct 20, 2008
372
1
68
127.0.0.1
cPanel Access Level
Root Administrator
I think you need to use the umask option. Also have a look at WHM - Service Configuration - Apache Configuration - PHP and SuExec Configuration for the current settings.
 

REXNET

Member
Jan 31, 2012
10
0
51
San Francisco
cPanel Access Level
Root Administrator
The PHP handler is suphp and Apache suEXEC is enabled. I've Perl/CGI and Ruby enabled on my server, But all files with any extension give 0755 permission when we create new from file manager.

I've checked for umask and added "umask 022" at the end of "/usr/local/apache/bin/envvars" file, After restarting Apache the problem still remain... (A file named "umask" has been created at "/var/cpanel/easy/apache/rawenv/" with value of "022" to save the settings after apache rebuild)
 
Last edited:

Infopro

Well-Known Member
May 20, 2003
17,076
521
613
Pennsylvania
cPanel Access Level
Root Administrator
Twitter
I've added this:

# Infopro Was Here
umask 022

To the very bottom under everything else of this file:
/etc/bashrc

Created a new file on the account via File Manager, result: 644
Created a new folder on the account via File Manager, result: 755


I'm not sure if its possible but if there was some sort of check to add this, or not, I think it might be useful.

Feature Request maybe?
 

REXNET

Member
Jan 31, 2012
10
0
51
San Francisco
cPanel Access Level
Root Administrator
Thank you all, but unfortunately it couldn't fix the problem. Should i restart any service or reboot the system?!

Do you think some software or services on the service cause this?!
 

Infopro

Well-Known Member
May 20, 2003
17,076
521
613
Pennsylvania
cPanel Access Level
Root Administrator
Twitter
I should know better than to get into a topic and suggest changes that I'm not completely familiar with.

Looking for other threads on this very forum via google we find lots of results.

Looking at a few of those posts there are mentions of checking this file if running SuPHP:
/opt/suphp/etc/suphp.conf

...for this:

;Umask to set, specify in octal notation
umask=0022