Score:0

Display files that have additional rights for group and others that the user does not have

cn flag

I have a problem to solve for a university class I am taking. I need a command that lists files in a directory that have a group or others permission that is set, but it is not set for the owner (such files could have security problems if someone other than the owner has more rights on a file).

How can I do that and display the result as the file name followed by the additional right that appeared for others or for group (for example in g-r or o-x form)?

vanadium avatar
cn flag
We usually do not do homework here. `find` can retrieve files based on many different criteria.
hr flag
This might give you some ideas: [How to find files that user and group have the same permission](https://askubuntu.com/questions/1296163/how-to-find-files-that-user-and-group-have-the-same-permission)
waltinator avatar
it flag
Read `man find stat`.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.