File creation modes
page needs to be linked from somewhere
DokuWiki will check if your configuration differs from what the system would use automatically and will call chmod after creating the files or directories to set up the wanted permissions. It will not alter your system's umask settings.
Why do we have the “umask” in the first place?
Well, the system calls for creating a new file(ie. open, fopen, etc.) do not have a parameter for setting the UNIX permissions ((probably for legacy reasons), but a file needs permission settings when it is created. By default this is a mode of 0666. Unfortunately this means eryone would be able to write to our file when it is first opened
This is where umask comes into the picture, to make sure the file has sane permissions the umask is applied to the default permissions. Specifically, permissions in the umask are turned off from default mode. Eg.
(0666 & ~0022) = 0644.
Creating a directory (mkdir) is a little bit diffrent, here you can set the permissions but the umask is also applied, so we still need to take that into account.