id: salesforce-access-token

info:
  name: Salesforce Access Token
  author: DhiyaneshDK
  severity: info
  reference:
    - https://github.com/praetorian-inc/noseyparker/blob/main/crates/noseyparker/data/default/builtin/rules/salesforce.yml
    - https://help.salesforce.com/s/articleView?id=sf.remoteaccess_access_tokens.htm&type=5
    - https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/quickstart_oauth.htm
  metadata:
    verified: true
    max-request: 1
  tags: salesforce,exposure,tokens

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

    extractors:
      - type: regex
        part: body
        regex:
          - \b(00[a-zA-Z0-9]{13}![a-zA-Z0-9._]{96})(?:\b|$|[^a-zA-Z0-9._])
# digest: 4a0a0047304502206980028e14ffed5b2e82fe14d7badb4a319747eb5e139a6765986a3aa8f183f00221008b6e2d5132b7d6e1ea532b650976f4f4fee59f06cd31560ba6d4845c46a489f4:922c64590222798bb761d5b6d8e72950