Skip to content

Conversation

@amroes
Copy link

@amroes amroes commented Sep 3, 2025

Description

This PR adds a KEYWORDS option to the spider_plus module, enabling users to filter files by keywords in their contents (e.g., -o KEYWORDS=password). The feature enhances targeted file discovery while maintaining backward compatibility with the original module behavior when no keywords are provided. It also:

  • Resolves Ruff linting issues (Q000: single quotes to double quotes, W293: trailing whitespace).
  • Adds e2e tests to tests/e2e_commands.txt and screenshots for both KEYWORDS and non-KEYWORDS runs.

No issues fixed; this is a new feature.
No new dependencies required.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Deprecation of feature or functionality
  • This change requires a documentation update
  • This requires a third party update (such as Impacket, Dploot, lsassy, etc)

Setup guide for the review

  • Environment: Kali Linux, Python 3.13 (Poetry virtualenv: /home/atra/.cache/pypoetry/virtualenvs/netexec-DA4IO4FG-py3.13).
  • Setup:
    • Clone: git clone https://github.com/amroes/NetExec.git
    • Install: poetry install
    • Ensure Rust: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
  • Target: Windows SMB share (e.g., 192.168.252.129) with credentials (e.g., amroes:amroes).
  • Test Commands:
    source /home/atra/.cache/pypoetry/virtualenvs/netexec-DA4IO4FG-py3.13/bin/activate
    nxc smb 192.168.252.129 -u amroes -p amroes -M spider_plus -o KEYWORDS=password

Screenshots

With KEYWORDS:
1
2
Without KEYWORDS (shows normal spider_plus usage) :
3

Checklist

[x] I have ran Ruff against my changes (via poetry: poetry run python -m ruff check . --preview, use --fix to automatically fix what it can)
[x] I have added or updated the tests/e2e_commands.txt file if necessary
[x] New and existing e2e tests pass locally with my changes
[] If reliant on changes of third party dependencies, such as Impacket, dploot, lsassy, etc, I have linked the relevant PRs in those projects
[x] I have performed a self-review of my own code
[x] I have commented my code, particularly in hard-to-understand areas
[] I have made corresponding changes to the documentation (PR: pending)

Copy link
Member

@NeffIsBack NeffIsBack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Besides one change the diff looks good so far

Comment on lines 516 to 476
category = "enum" # Added to fix the loading error
supported_protocols = ["smb"]
category = CATEGORY.CREDENTIAL_DUMPING
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please revert this change

Copy link
Author

@amroes amroes Sep 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please revert this change

any updates in this PR?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately not yet, there are roughly 50 PRs that need to be reviewed first

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh i see, got it !

@NeffIsBack NeffIsBack added the enhancement New feature or request label Sep 4, 2025
@amroes amroes requested a review from NeffIsBack September 4, 2025 09:57
@amroes
Copy link
Author

amroes commented Sep 4, 2025

Besides one change the diff looks good so far

Done, you may check it out now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants