1

I have ran a command to find a string in files on the server like this:

cd /
grep -r "string to be found" *

And the server returned some results like this

Binary file dev/disk/by-path/pci-0000:00:10.0-scsi-0:0:0:0-part1 matches
Binary file dev/disk/by-path/pci-0000:00:10.0-scsi-0:0:0:0 matches

As far as I know these are files that keep the actual storage on the raid matrix (please correct me if I am wrong). How can I find exactly where my match is located?

Is there any faster solution to this than running "grep" all accross the files of the server?

Thank you for your time!

1 Answer 1

1

Generally on a binary file you have to do something like:

$ string /binary/file | grep -i whatuwant

but if u want search on text file, my advice is:

$ find / -type f -exec grep -i whatuwant '{}' ';'
3
  • Actually what I want is to find a script that performs a bruteforce attack on some domain. The string that I am searching for is the domainname itself. So if there are any matches it means that there is a particular script doing so
    – Mike
    Jul 23, 2013 at 18:46
  • Is the script active? Jul 23, 2013 at 18:53
  • yes because i receive from time to time notifications like this one pastebin.com/raw.php?i=84vJ6eWv from time to time
    – Mike
    Jul 23, 2013 at 20:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .