id: aws-session-token

info:
  name: AWS Session Token
  author: DhiyaneshDK
  severity: info
  reference:
    - https://github.com/praetorian-inc/noseyparker/blob/main/data/default/rules/aws.yml
  metadata:
    verified: true
    max-request: 1
  tags: aws,amazon,token,exposure,session

http:
  - method: GET
    path:
      - "{{BaseURL}}"

    extractors:
      - type: regex
        part: body
        regex:
          - '(?i)(?:aws.?session|aws.?session.?token|aws.?token)["''`]?\s{0,30}(?::|=>|=)\s{0,30}["''`]?([a-z0-9/+=]{16,200})[^a-z0-9/+=]'
# digest: 4b0a004830460221009f21aa955d571e6cc909e05c9bafb58cb201f84c2c51da0e2791bd49cb55473f02210096e3de2b2b4527b1f7877287027f8160e52ae522b6a8ff0506b2d331dca5a952:922c64590222798bb761d5b6d8e72950