So basically I have three files, two with permission 744 and one with 601 and I want to list the names of the files that have permission 744 and in addition, it also have to have string def anywhere in the lines of the file.All I got is how to print out if they have permission 744:find * -perm 744How do I get it so it can check for string def?Any help is appreciated. 
Find a file that has a certain word inside that file.
bash
Follow your current options with-exec grep -l def {} +e.g.,find * -perm 744 -exec grep -l def {} +The -l option of grep tells it to just list the names of files where a match occurs, and since that is the only action for find, the output of grep will be all that you see.