id: gcloud-access-token

info:
  name: Google Cloud Access Token
  author: DhiyaneshDK
  severity: medium
  description: Internal Google Cloud access tokens are exposed.
  metadata:
    verified: true
    max-request: 2
    shodan-query: html:"access_tokens.db"
  tags: google,cloud,devops,exposure,files,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/access_tokens.db"
      - "{{BaseURL}}/.config/gcloud/access_tokens.db"

    stop-at-first-match: true

    matchers-condition: and
    matchers:
      - type: word
        words:
          - 'SQLite'
          - 'access_token'
        condition: and

      - type: word
        part: header
        words:
          - 'application/octet-stream'

      - type: status
        status:
          - 200
# digest: 4a0a00473045022100890028d65bc2f588d739eee24abe49b0e3fea0a30bf8d9451fb92f754e8b7d8f02206ff0735feb19ae8f555bd3980e629f2e49a5144557498f74eba21c8229526a20:922c64590222798bb761d5b6d8e72950