3 ms·
"dr--r--r-- 1 bork awesome 6872 Sep 24 11:09 file.txt" This doesn't make sense.
by yubiox 9y ago
"dr--r--r-- 1 bork awesome 6872 Sep 24 11:09 file.txt"
This doesn't make sense.
- biggerfisch 9y ago$ mkdir file.txt $ ls -l drwxr-xr-x 2 USER GROUP 4096 Nov 21 11:49 file.txt $ chmod -xw file.txt $ for i in {1..180}; do touch file.txt/long_name_$i; done $ ls -l dr--r--r-- 2 USER GROUP 12288 Nov 21 11:50 file.txt File size is a bit off, but that's based on sector size and may be separately configurable - that's a bit beyond my knowledge.
- yubiox 9y agobut she says right above it: "So, for example, if a process is owned by the julia user and julia is in the awesome group, then the process would be allowed to read this file."
- biggerfisch 9y agoI'm not sure what you aren't understanding. Directories are just a type of file, so that's not wrong, the dir/file is owned by the `awesome` group, and the group permissions are `r--` so the group can indeed read it.
- jwilk 9y agoOr one could apply Occam's razor and admit that "d" was a typo.
- biggerfisch 9y agoOf course, that's a much more likely scenario. I was attempting to show that the line was not completely nonsensical is all.
- jandrese 9y agoIt's kind of useless, but not illegal. You won't be able to stat/open any of the files in the directory, although anybody can read their names. Putting a .txt on a directory name is also perfectly legal and still in bad form. I agree the most likely explanation is accidentally putting the d in there in the editing process.