Speed Posted September 2, 2016 Share Posted September 2, 2016 I understand writable need to be locked and make it readable inside config.php. But... I am not sure I understand what I need to do to make writeable locked after reading from this link https://processwire.com/docs/security/file-permissions/#securing-your-site-config.php-file. I opened config.php and could not find what I need to change. Can anyone give me idea what I need to do? This came from after completion of PW installation. Link to comment Share on other sites More sharing options...
deltavik Posted September 2, 2016 Share Posted September 2, 2016 To lock and protect the file, you will have to modify its permissions on the file system. To do that, you will have to execute "chmod 400 config.php" on command line. There is no "setting" inside config.php. To run that command, you will have to gain ssh access to the server. If ssh is not your thing, you can change file permissions in your FTP client as well -- at least most FTP clients support it. In your FTP client, right-click on config.php and and click on file permissions. Then set the permissions to 400. 1 Link to comment Share on other sites More sharing options...
Doug G Posted September 3, 2016 Share Posted September 3, 2016 Or if you have a local setup like I do on windows w/xampp, you'd navigate to the config file in windows explorer, right-click and choose the security tab to access the permission settings. Windows ntfs doesn't understand chmod and linux permissions. I used to run php on a shared commercial windows-based host and their control panel had a permissions tool, since using ftp clients wouldn't properly change permissions on ntfs. Link to comment Share on other sites More sharing options...
Speed Posted September 3, 2016 Author Share Posted September 3, 2016 Thank you deltavik and Doug G. for clarification. I had permission changed by visiting host's cPanel > File manager. Oh, FTP Filezilla didn't work. It keep on changing after I enter 400. As much I prefer using FTP over cPanel filemanager It'd be nice to know which FTP will work, Anyone? Should I change Writable Permission for htaccess too? Link to comment Share on other sites More sharing options...
deltavik Posted September 3, 2016 Share Posted September 3, 2016 dont think you need to secure htaccess. If it were important, PW would've mentioned it. Moreover, at least in wordpress world, there are third-party plugins that need to edit htaccess file. Link to comment Share on other sites More sharing options...
Speed Posted September 3, 2016 Author Share Posted September 3, 2016 Thank you deltavik. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now