Hi, I found some questions on the internet wondering whether chmod tool does support binary numbers as input. Even though it doesn't support I downloaded core-utils source and got started reading chmode code.
Let's to the point: I added binary input support by making changes into the /lib/modechanges.c file. PS: (b) prefix is not case sensitive.
Tests: ./chmod b10111 t
stat t (0027/-----w-rwx) ./chmod b t (Error) ./chmod: invalid mode: `b' ./chmod b111111 t stat t (0077/----rwxrwx)
Octal mode fulfills its goal very well, though Binary mode may be an interesting feature.