How to change file permissions of the .well-known and challenge folder

Using File Manager in cPanel

One of the easy and basic ways to change the permissions is through File manager in cPanel. To change the permissions for a file or folder in cpanel, please do the following:

  • Login to your cPanel (if not already there)
  • Click File Manager
  • Choose the .well-known folder.
  • Select the Change Permissions link at the top right of the page
  • Select the permissions you would like to set for the file. In this case, please set it to 0755, if after changing this to 0755 the acme challenge validation function still doesn’t work, try change it to 0777 then you can change it back to 0755 when you finish requesting the SSL certificate)
  • Click Change Permissions

Next change permissions for the challenge folder

  • Click the .well-known folder
  • Select the acme-challenge folder
  • Select the Change Permissions link at the top right of the page
  • Select the permissions you would like to set for the file. In this case, please set it to 0755, if after changing this to 0755 the acme challenge validation function still doesn’t work, try change it to 0777 then you can change it back to 0755 when you finish requesting the SSL certificate)
  • Click Change Permissions

Using FTP

Connect to FTP. Go to the file and right click. Choose Permissions or Attributes or Properties (depends on your program).

Further reading

All files on UNIX (including Linux and other UNIX variants) machines have access permissions. In this way the operating system knows how to deal with requests to access the files. There are three types of access:

  • Read – Denoted as r, files with read access can be displayed to the user.
  • Write – Denoted as w, files with write access can be modified by the user.
  • Execute – Denoted as x, files with execute access can be executed as programs by the user.

Access types are set for three types of user group:

  • User – The owner of the file.
  • Group – Other files which are in the same folder or group.
  • World – Everyone else.

What do the digits of the permissions mean?

The permission digits range from 0 to 7, with each digit representing the actions you allow each user to have.

  • 0 – The user cannot read, write, or execute the file
  • 1 – The user can only execute the file
  • 2 – The user can only write the file
  • 3 – The user can only write AND execute the file
  • 4 – The user can only read the file
  • 5 – The user can only read AND execute the file
  • 6 – The user can only read AND write the file
  • 7 – The user can read, write, AND execute the file

Meanwhile, the arrangement of the three-digits corresponds to owner-group-world users.

Reminder

  • If you see four digits like 0755, it’s actually the same as 755.
  • All folders mustalways have 755 permissions.
  • Files inside the cgi-bin folder must always have 755 permissions.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

+1
Share
Tweet
Share