shell: fix files and directories permissions