From 4d04ea079fc4e7f46c9f751fccde8f18c33b9e13 Mon Sep 17 00:00:00 2001 From: zach rice Date: Tue, 12 Nov 2019 22:32:15 -0500 Subject: [PATCH] fixing test data --- test_data/test_local_owner_aws_leak.json | 260 +++++++++++++++++++++++ test_data/test_local_repo_two_leaks.json | 52 +++++ 2 files changed, 312 insertions(+) diff --git a/test_data/test_local_owner_aws_leak.json b/test_data/test_local_owner_aws_leak.json index 261ce2b3..030ca8c6 100644 --- a/test_data/test_local_owner_aws_leak.json +++ b/test_data/test_local_owner_aws_leak.json @@ -25,6 +25,19 @@ "date": "2019-10-25T13:12:32-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "f61cd8587b7ac1d75a89a0c9af870a2f24c60263", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "rm secrets again\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:32-04:00", + "tags": "key, API, generic" + }, { "line": " const AWSKEY = \"AKIALALEMEL33243OLIBE\"", "offender": "AKIALALEMEL33243OLIB", @@ -38,6 +51,19 @@ "date": "2019-10-25T13:12:08-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "b2eb34a61c988afd9b4aaa9dd58c8dd7d5f14dba", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "adding another one\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:08-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -51,6 +77,19 @@ "date": "2019-10-25T13:07:41-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "996865bb912f3bc45898a370a13aadb315014b55", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "committing pem\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:07:41-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -64,6 +103,19 @@ "date": "2019-10-25T13:01:27-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "17471a5fda722a9e423f1a0d3f0d267ea009d41c", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "wait this is actually adding an aws secret\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:01:27-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: AKIALALEMEL33243OLIAE", "offender": "AKIALALEMEL33243OLIA", @@ -103,6 +155,19 @@ "date": "2019-10-25T13:54:26-04:00", "tags": "key, AWS" }, + { + "line": "const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "cd5eb8bef855f73c46b97b4c088badffdc40ebe9", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "rm secrets\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:54:26-04:00", + "tags": "key, API, generic" + }, { "line": "const AWSKEY = \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -116,6 +181,19 @@ "date": "2019-10-25T13:54:08-04:00", "tags": "key, AWS" }, + { + "line": "const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "84ac4e80d4dbf2c968b64e9d4005f5079795bb81", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "more secrets\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:54:08-04:00", + "tags": "key, API, generic" + }, { "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -129,6 +207,19 @@ "date": "2019-10-25T13:36:22-04:00", "tags": "key, AWS" }, + { + "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "64cfcee9aad1c84581631636bfc54f2050718d1a", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "rm secrets\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:36:22-04:00", + "tags": "key, API, generic" + }, { "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -142,6 +233,19 @@ "date": "2019-10-25T13:35:03-04:00", "tags": "key, AWS" }, + { + "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "deea550dd6c7acaf0e59432600593533984a2125", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "dev branch\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:35:03-04:00", + "tags": "key, API, generic" + }, { "line": " const AWSKEY = \"AKIALALEMEL33243OLIBE\"", "offender": "AKIALALEMEL33243OLIB", @@ -155,6 +259,19 @@ "date": "2019-10-25T13:12:32-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "f61cd8587b7ac1d75a89a0c9af870a2f24c60263", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "rm secrets again\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:32-04:00", + "tags": "key, API, generic" + }, { "line": " const AWSKEY = \"AKIALALEMEL33243OLIBE\"", "offender": "AKIALALEMEL33243OLIB", @@ -168,6 +285,19 @@ "date": "2019-10-25T13:12:08-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "b2eb34a61c988afd9b4aaa9dd58c8dd7d5f14dba", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "adding another one\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:08-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -181,6 +311,19 @@ "date": "2019-10-25T13:07:41-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "996865bb912f3bc45898a370a13aadb315014b55", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "committing pem\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:07:41-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -194,6 +337,19 @@ "date": "2019-10-25T13:01:27-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "17471a5fda722a9e423f1a0d3f0d267ea009d41c", + "repo": "test_repo_3", + "rule": "Generic Credential", + "commitMessage": "wait this is actually adding an aws secret\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:01:27-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: AKIALALEMEL33243OLIAE", "offender": "AKIALALEMEL33243OLIA", @@ -233,6 +389,19 @@ "date": "2019-10-25T13:54:26-04:00", "tags": "key, AWS" }, + { + "line": "const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "cd5eb8bef855f73c46b97b4c088badffdc40ebe9", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "rm secrets\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:54:26-04:00", + "tags": "key, API, generic" + }, { "line": "const AWSKEY = \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -246,6 +415,19 @@ "date": "2019-10-25T13:54:08-04:00", "tags": "key, AWS" }, + { + "line": "const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "84ac4e80d4dbf2c968b64e9d4005f5079795bb81", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "more secrets\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:54:08-04:00", + "tags": "key, API, generic" + }, { "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -259,6 +441,19 @@ "date": "2019-10-25T13:36:22-04:00", "tags": "key, AWS" }, + { + "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "64cfcee9aad1c84581631636bfc54f2050718d1a", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "rm secrets\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:36:22-04:00", + "tags": "key, API, generic" + }, { "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -272,6 +467,19 @@ "date": "2019-10-25T13:35:03-04:00", "tags": "key, AWS" }, + { + "line": "AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "deea550dd6c7acaf0e59432600593533984a2125", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "dev branch\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:35:03-04:00", + "tags": "key, API, generic" + }, { "line": " const AWSKEY = \"AKIALALEMEL33243OLIBE\"", "offender": "AKIALALEMEL33243OLIB", @@ -285,6 +493,19 @@ "date": "2019-10-25T13:12:32-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "f61cd8587b7ac1d75a89a0c9af870a2f24c60263", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "rm secrets again\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:32-04:00", + "tags": "key, API, generic" + }, { "line": " const AWSKEY = \"AKIALALEMEL33243OLIBE\"", "offender": "AKIALALEMEL33243OLIB", @@ -298,6 +519,19 @@ "date": "2019-10-25T13:12:08-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "b2eb34a61c988afd9b4aaa9dd58c8dd7d5f14dba", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "adding another one\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:08-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -311,6 +545,19 @@ "date": "2019-10-25T13:07:41-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "996865bb912f3bc45898a370a13aadb315014b55", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "committing pem\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:07:41-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -324,6 +571,19 @@ "date": "2019-10-25T13:01:27-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "17471a5fda722a9e423f1a0d3f0d267ea009d41c", + "repo": "test_repo_4", + "rule": "Generic Credential", + "commitMessage": "wait this is actually adding an aws secret\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:01:27-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: AKIALALEMEL33243OLIAE", "offender": "AKIALALEMEL33243OLIA", diff --git a/test_data/test_local_repo_two_leaks.json b/test_data/test_local_repo_two_leaks.json index 136bb6eb..187e7afb 100644 --- a/test_data/test_local_repo_two_leaks.json +++ b/test_data/test_local_repo_two_leaks.json @@ -12,6 +12,19 @@ "date": "2019-10-25T13:12:32-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "f61cd8587b7ac1d75a89a0c9af870a2f24c60263", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "rm secrets again\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:32-04:00", + "tags": "key, API, generic" + }, { "line": " const AWSKEY = \"AKIALALEMEL33243OLIBE\"", "offender": "AKIALALEMEL33243OLIB", @@ -25,6 +38,19 @@ "date": "2019-10-25T13:12:08-04:00", "tags": "key, AWS" }, + { + "line": " const AWSSECRET = \"99432bfewaf823ec3294e231\"", + "offender": "SECRET = \"99432bfewaf823ec3294e231\"", + "commit": "b2eb34a61c988afd9b4aaa9dd58c8dd7d5f14dba", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "adding another one\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:12:08-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -38,6 +64,19 @@ "date": "2019-10-25T13:07:41-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "996865bb912f3bc45898a370a13aadb315014b55", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "committing pem\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:07:41-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", "offender": "AKIALALEMEL33243OLIA", @@ -51,6 +90,19 @@ "date": "2019-10-25T13:01:27-04:00", "tags": "key, AWS" }, + { + "line": "Here's an AWS secret: \"AKIALALEMEL33243OLIAE\"", + "offender": "secret: \"AKIALALEMEL33243OLIAE\"", + "commit": "17471a5fda722a9e423f1a0d3f0d267ea009d41c", + "repo": "test_repo_2", + "rule": "Generic Credential", + "commitMessage": "wait this is actually adding an aws secret\n", + "author": "zach rice", + "email": "zricer@protonmail.com", + "file": "secrets.md", + "date": "2019-10-25T13:01:27-04:00", + "tags": "key, API, generic" + }, { "line": "Here's an AWS secret: AKIALALEMEL33243OLIAE", "offender": "AKIALALEMEL33243OLIA",