Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix logic bug in request[s] matcher condition #4064

Merged
merged 2 commits into from
Aug 18, 2023
Merged

Conversation

tarunKoyalwar
Copy link
Member

@tarunKoyalwar tarunKoyalwar commented Aug 17, 2023

Proposed Changes

POC

$  echo geonet.shodan.io | go run . -t ~/test-templates/interactsh-and-condition.yaml

                     __     _
   ____  __  _______/ /__  (_)
  / __ \/ / / / ___/ / _ \/ /
 / / / / /_/ / /__/ /  __/ /
/_/ /_/\__,_/\___/_/\___/_/   v2.9.11

		projectdiscovery.io

[WRN] Found 1 templates loaded with deprecated protocol syntax, update before v3 for continued support.
[INF] Current nuclei version: v2.9.11 (latest)
[INF] Current nuclei-templates version: v9.6.1 (latest)
[INF] New templates added in latest release: 198
[INF] Templates loaded for current scan: 1
[INF] Targets loaded for current scan: 1
[INF] Running httpx on input host
[INF] Found 1 URL from httpx
[INF] Using Interactsh Server: oast.pro
[test-interactsh] [http] [info] https://geonet.shodan.io/

@tarunKoyalwar tarunKoyalwar self-assigned this Aug 17, 2023
@tarunKoyalwar tarunKoyalwar changed the title fix logic bug in request[s] condition fix logic bug in request[s] matcher condition Aug 17, 2023
@tarunKoyalwar
Copy link
Member Author

Template

id: test-interactsh

info:
  name: interactsh test
  author: pdteam
  severity: info

requests:
  - raw:
      - |
        GET /api/geoping/{{interactsh-url}} HTTP/1.1
        Host: {{Hostname}}

      - |
        GET / HTTP/1.1
        Host: {{Hostname}}

    matchers-condition: and
    matchers:
      - type: word
        part: interactsh_protocol  # Confirms the DNS Interaction
        words:
          - "dns"

      - type: dsl
        dsl:
          - "status_code_2 == 200"

@tarunKoyalwar tarunKoyalwar marked this pull request as ready for review August 17, 2023 21:20
@Mzack9999 Mzack9999 merged commit a3b1f11 into dev Aug 18, 2023
12 checks passed
@Mzack9999 Mzack9999 deleted the issue-2870-interactsh-and branch August 18, 2023 08:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incorrect results for templates with interactsh matchers and AND condition
3 participants