Find the answer to your Linux question:
Results 1 to 2 of 2
I am trying to create a bash script that will search all users home directories on a system for words like quit, steal, kill etc. Pretty sure I'm going to ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jan 2011
    Posts
    87

    A script to search users home dirs for certain words.


    I am trying to create a bash script that will search all users home directories on a system for words like quit, steal, kill etc. Pretty sure I'm going to be using grep /home. The only thing is that obviously a word like 'kill' could have normal uses too like "I need to kill the process." How would I go about flagging a user with the word/phrase found, and the path while also omitting legitimate uses?

  2. #2
    Just Joined!
    Join Date
    Jan 2011
    Posts
    87
    grep -w will have me search for a specific word, but how to I omit legitimate uses of the word?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •