0

This question already has an answer here:

So I've finally given up after searching/trial and error for an hour now on how to find a file given specific criteria (none of which is the name of the file or the extension).

The file info provided is the following: human-readable 1033 bytes in size not executable

I've gotten find commands to take but nothing was returned. I am using Kali linux. The objective is to find the file in the directory that matches these criteria without simply opening them all. Files are visible but there is one hidden one that I'd like to include in the search. Basically I want to search an entire directory that I'm in using the above criteria.

marked as duplicate by don_crissti, Gilles files Jul 6 '15 at 22:50

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • I even searched using those criteria and it didn't pop up...I appologize for the duplicate post – dcvl Jul 6 '15 at 21:49
3
find <path>/. -type f -size 1033c ! -perm -0001 -ls
0

Find honestly is the best way to go about this, but what I tend to do out of habit is grep -r something I know is in the file. It is definitely not the professional way to do things, but hey another option doesn't hurt.

Quick tip, if you want to find commands by what they do, you can type man -k "describe what it does"

Not the answer you're looking for? Browse other questions tagged or ask your own question.