secator icon indicating copy to clipboard operation
secator copied to clipboard

feat(task): add nslookup DNS lookup task

Open Copilot opened this issue 1 month ago • 3 comments

Adds nslookup as a new ReconDns task for DNS record enumeration.

Implementation

  • New task: secator/tasks/nslookup.py

    • Line-by-line parser for nslookup output
    • Supports A, AAAA, MX, NS, TXT, CNAME record types
    • Outputs Record and Ip types for IPv4/IPv6 addresses
    • Options: --type (record type filter), --server (custom DNS server)
  • Test fixture: tests/fixtures/nslookup_output.txt

    • Sample output with A and AAAA records
  • Integration tests:

    • Added input configuration in tests/integration/inputs.py
    • Added expected output configuration in tests/integration/outputs.py

Usage

# Basic lookup
secator task nslookup example.com

# Query MX records via custom server
secator task nslookup -type MX -server 8.8.8.8 example.com

Parser Details

Distinguishes DNS server metadata (Address: 8.8.8.8#53) from result IPs (Address: 93.184.216.34) by checking for port notation. Maintains state across Name: and Address: line pairs to correlate hostnames with IPs.

[!WARNING]

Original prompt

This section details on the original issue you should resolve

<filter_complete></filter_complete>

<issue_title>feat(task): add support for nslookup</issue_title> <issue_description></issue_description>

Comments on the Issue (you are @copilot in this section)

  • Fixes freelabz/secator#765
Original prompt

This section details on the original issue you should resolve

<issue_title>feat(task): add support for nslookup</issue_title> <issue_description></issue_description>

Comments on the Issue (you are @copilot in this section)

  • Fixes freelabz/secator#765

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot avatar Nov 22 '25 14:11 Copilot

[!IMPORTANT]

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Comment @coderabbitai help to get the list of available commands and usage tips.

coderabbitai[bot] avatar Nov 22 '25 14:11 coderabbitai[bot]

@copilot You were rate-limited. Finish your work from where you left off

ocervell avatar Nov 22 '25 18:11 ocervell

@copilot You were rate-limited. Finish your work from where you left off

Done. Added integration test configuration in commit f58965f:

  • tests/integration/inputs.py: Added 'nslookup': 'wikipedia.org'
  • tests/integration/outputs.py: Added expected Ip and Record outputs for nslookup task

Copilot avatar Nov 22 '25 18:11 Copilot