After years of dealing with having to change permissions on newly uploaded files from 664 to lower (I use 600 on php) I finally found how to change the umask for sftp on my server. Apparently, this is how Cpanel is set up because it's discussed in their forums. Someone posted the solution for SFTP in the SSHD config. I still have to change the php file permissions, but at least folders are automatically set at 755 and files at 644. I believe CPanel will be changing the default when using suPHP.
Using Beyond Compare to connet to the server I can easily set the file mask to only show php files then sort by permissions, so it's easy to find files and folders with too loose of permissions.
- bruyndoncx likes this