From 324d7b6fa87d150d9d3b17e0bc4994c62fd68ed6 Mon Sep 17 00:00:00 2001 From: Joel Date: Sat, 16 Oct 2021 21:51:27 +1000 Subject: [PATCH 1/3] ci: disable testing python 3.6 on macos as it is no longer supported by github actions --- .github/workflows/main.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index cdf60ff..0064b7a 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -8,6 +8,9 @@ jobs: matrix: python-version: ['3.6', '3.7', '3.8', '3.9'] os: [ubuntu-latest, windows-latest, macos-latest] + exclude: + - os: macos-latest + python-version: "3.6" runs-on: ${{ matrix.os }} name: Python ${{ matrix.python-version }} on ${{ matrix.os }} steps: @@ -22,4 +25,3 @@ jobs: env: OS: ${{ matrix.os }} PYTHON: ${{ matrix.python-version }} - From cc2a8a2d27ca5e5163ee818f87125f477a0ad895 Mon Sep 17 00:00:00 2001 From: Jirawat I Date: Tue, 30 Nov 2021 14:30:22 +0700 Subject: [PATCH 2/3] Fixed #231 Datadog API - reduced rarity to 0 - add Datalog Application API and Datadog Client key - add valid and invalid examples - remove a junk space in `pyproject.toml` --- pyproject.toml | 2 +- pywhat/Data/regex.json | 101 +++++++++++++++++++++++++++++------------ 2 files changed, 73 insertions(+), 30 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index ccbcffc..386fd5e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -15,7 +15,7 @@ orjson = {version = "^3.6.1", optional = true} [tool.poetry.dev-dependencies] pytest = "^6.2.5" -black = {version = "^21.9b0", python = "^3.6.2"} +black = {version = "^21.9b0", python = "^3.6.2"} isort = {version = "^5.9.3", python = "^3.6.1"} flake8 = "<4.0" requests = "^2.26.0" diff --git a/pywhat/Data/regex.json b/pywhat/Data/regex.json index b8ff4f1..f1585f8 100644 --- a/pywhat/Data/regex.json +++ b/pywhat/Data/regex.json @@ -819,35 +819,6 @@ "Invalid": [] } }, - { - "Name": "Datadog API Key", - "Regex": "^([a-f0-9]{32})$", - "plural_name": false, - "Description": null, - "Exploit": "Use the command below to verify that the API key is valid:\n $ curl -X GET https://api.datadoghq.com/api/v1/validate -H \"Content-Type: application/json\" -H \"DD-API-KEY: API_KEY_HERE\"\n", - "Rarity": 1, - "URL": null, - "Tags": [ - "API Keys", - "Bug Bounty", - "Credentials", - "Datadog" - ] - }, - { - "Name": "Datadog Client Token", - "Regex": "^(pub[a-f0-9]{32})$", - "plural_name": false, - "Description": null, - "Exploit": null, - "Rarity": 1, - "URL": null, - "Tags": [ - "API Keys", - "Bug Bounty", - "Datadog" - ] - }, { "Name": "New Relic Admin API Key", "Regex": "(?i)^(NRAA-[a-f0-9]{27})$", @@ -2500,6 +2471,26 @@ "Invalid": [] } }, + { + "Name": "Datadog Client Token", + "Regex": "^(pub[a-f0-9]{32})$", + "plural_name": false, + "Description": "An [#CAE4F1][link=https://docs.datadoghq.com/logs/log_collection/javascript/]Datadog client token[/link][/#CAE4F1]", + "Exploit": null, + "Rarity": 0.2, + "URL": null, + "Tags": [ + "API Keys", + "Bug Bounty", + "Datadog" + ], + "Examples": { + "Valid": [ + "pub8261e4a07b29d0a148e00a93106ae711" + ], + "Invalid": [] + } + }, { "Name": "ObjectID", "Regex": "^([0-9a-fA-F]{24})$", @@ -2621,6 +2612,58 @@ "Invalid": [] } }, + { + "Name": "Datadog API Key", + "Regex": "^([a-f0-9]{32})$", + "plural_name": false, + "Description": "An [#CAE4F1][link=https://docs.datadoghq.com/api/latest/]Datadog API Key[/link][/#CAE4F1]", + "Exploit": "Use the command below to verify that the API key is valid:\n $ curl -X GET https://api.datadoghq.com/api/v1/validate -H \"Content-Type: application/json\" -H \"DD-API-KEY: API_KEY_HERE\"\n", + "Rarity": 0, + "URL": null, + "Tags": [ + "API Keys", + "Bug Bounty", + "Credentials", + "Datadog" + ], + "Examples": { + "Valid": [ + "68ec0cbd7d0da6770545614dfa573eec", + "683bba7d7f759e0907d35f39a7c36eb5", + "c8561e9b786a07855cbc2983d47eaf93" + ], + "Invalid": [ + "ba36266055c7495ce26bb12e86c7536b4a5e00cd", + "pub8261e4a07b29d0a148e00a93106ae711" + ] + } + }, + { + "Name": "Datadog Application Key", + "Regex": "^([a-f0-9]{40})$", + "plural_name": false, + "Description": "An [#CAE4F1][link=https://docs.datadoghq.com/api/latest/]Datadog Application Key[/link][/#CAE4F1]", + "Exploit": null, + "Rarity": 0, + "URL": null, + "Tags": [ + "API Keys", + "Bug Bounty", + "Credentials", + "Datadog" + ], + "Examples": { + "Valid": [ + "ba36266055c7495ce26bb12e86c7536b4a5e00cd" + ], + "Invalid": [ + "68ec0cbd7d0da6770545614dfa573eec", + "683bba7d7f759e0907d35f39a7c36eb5", + "c8561e9b786a07855cbc2983d47eaf93", + "pub8261e4a07b29d0a148e00a93106ae711" + ] + } + }, { "Name": "YouTube Video ID", "Regex": "^((?=.*[A-Z])(?=.*[a-z])[0-9A-Za-z_-]{10}[048AEIMQUYcgkosw]{1})$", From c40c24af431dee136e387534a23508802f36f565 Mon Sep 17 00:00:00 2001 From: Jirawat I Date: Wed, 1 Dec 2021 14:49:55 +0700 Subject: [PATCH 3/3] Minor fixed #231 - change the rarity of Datadog Client Key to 0.3 - remove `"Description"` of all Datadog RegExp --- pywhat/Data/regex.json | 44 +++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/pywhat/Data/regex.json b/pywhat/Data/regex.json index f1585f8..a6d8cfe 100644 --- a/pywhat/Data/regex.json +++ b/pywhat/Data/regex.json @@ -2345,6 +2345,26 @@ "Invalid": [] } }, + { + "Name": "Datadog Client Token", + "Regex": "^(pub[a-f0-9]{32})$", + "plural_name": false, + "Description": null, + "Exploit": null, + "Rarity": 0.3, + "URL": null, + "Tags": [ + "API Keys", + "Bug Bounty", + "Datadog" + ], + "Examples": { + "Valid": [ + "pub8261e4a07b29d0a148e00a93106ae711" + ], + "Invalid": [] + } + }, { "Name": "JSON Web Token (JWT)", "Regex": "(?i)^((?=.*[a-z])(?=.*[0-9])(?:[a-z0-9_=]+\\.){2}(?:[a-z0-9_\\-\\+\\/=]*))$", @@ -2471,26 +2491,6 @@ "Invalid": [] } }, - { - "Name": "Datadog Client Token", - "Regex": "^(pub[a-f0-9]{32})$", - "plural_name": false, - "Description": "An [#CAE4F1][link=https://docs.datadoghq.com/logs/log_collection/javascript/]Datadog client token[/link][/#CAE4F1]", - "Exploit": null, - "Rarity": 0.2, - "URL": null, - "Tags": [ - "API Keys", - "Bug Bounty", - "Datadog" - ], - "Examples": { - "Valid": [ - "pub8261e4a07b29d0a148e00a93106ae711" - ], - "Invalid": [] - } - }, { "Name": "ObjectID", "Regex": "^([0-9a-fA-F]{24})$", @@ -2616,7 +2616,7 @@ "Name": "Datadog API Key", "Regex": "^([a-f0-9]{32})$", "plural_name": false, - "Description": "An [#CAE4F1][link=https://docs.datadoghq.com/api/latest/]Datadog API Key[/link][/#CAE4F1]", + "Description": null, "Exploit": "Use the command below to verify that the API key is valid:\n $ curl -X GET https://api.datadoghq.com/api/v1/validate -H \"Content-Type: application/json\" -H \"DD-API-KEY: API_KEY_HERE\"\n", "Rarity": 0, "URL": null, @@ -2642,7 +2642,7 @@ "Name": "Datadog Application Key", "Regex": "^([a-f0-9]{40})$", "plural_name": false, - "Description": "An [#CAE4F1][link=https://docs.datadoghq.com/api/latest/]Datadog Application Key[/link][/#CAE4F1]", + "Description": null, "Exploit": null, "Rarity": 0, "URL": null,