Grep plugin - no match

Hi guys,

Im using the plugin grep ver.1.0.3

Im simply trying to match any line that contains “spf”, but still no luck!

Check the output

rapid7/Grep:1.0.3. Step name: match_string
echo ‘i=1;;
dkim=pass header.s=google header.b=TgyIcQPZ;
spf=pass ( domain of designates as permitted sender);
dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE)’ | egrep spf > /tmp/tmprxml9y90/results.txt
No Matches found
[Errno 2] No such file or directory: ‘/tmp/tmprxml9y90/results.txt’
[Errno 2] No such file or directory: ‘/tmp/tmprxml9y90/’
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/komand-1.0.1-py3.7.egg/komand/”, line 311, in handle_step
output = self.start_step(input_message[‘body’], ‘action’, logger, log_stream, is_test, is_debug)
File “/usr/local/lib/python3.7/site-packages/komand-1.0.1-py3.7.egg/komand/”, line 419, in start_step
output = func(params)
File “/usr/local/lib/python3.7/site-packages/grep_rapid7_plugin-1.0.3-py3.7.egg/icon_grep/actions/match_string/”, line 21, in run
File “/usr/local/lib/python3.7/site-packages/grep_rapid7_plugin-1.0.3-py3.7.egg/icon_grep/util/”, line 56, in process_grep
File “/usr/local/lib/python3.7/”, line 482, in rmtree
onerror(os.lstat, path, sys.exc_info())
File “/usr/local/lib/python3.7/”, line 480, in rmtree
orig_st = os.lstat(path)
FileNotFoundError: [Errno 2] No such file or directory: ‘/tmp/tmprxml9y90/’

What’s your input in the “Pattern” field look like? If you have spf in quotes, could you try removing the quotes?


I only have spf without quotes or anything else.

I’ve replaced it with a pattern match (regex) but still don’t get grep to work.

I just did some additional testing here, and initially I saw grep working as expected, but then I started inconsistently seeing an error similar to yours. I’m going to file a ticket so we can look into this further.

Thanks Holly,

Let us know if a new ver is launched! :slight_smile:

1 Like