diff options
Diffstat (limited to 'spec/fixtures')
31 files changed, 473 insertions, 50 deletions
diff --git a/spec/fixtures/api/schemas/entities/diff_viewer.json b/spec/fixtures/api/schemas/entities/diff_viewer.json index ae0fb32d3ac..b16f8d8b1a2 100644 --- a/spec/fixtures/api/schemas/entities/diff_viewer.json +++ b/spec/fixtures/api/schemas/entities/diff_viewer.json @@ -25,6 +25,12 @@ "type": [ "boolean" ] + }, + "whitespace_only": { + "type": [ + "boolean", + "null" + ] } }, "additionalProperties": false diff --git a/spec/fixtures/api/schemas/internal/pages/lookup_path.json b/spec/fixtures/api/schemas/internal/pages/lookup_path.json index 8ca71870911..fba3efc4ded 100644 --- a/spec/fixtures/api/schemas/internal/pages/lookup_path.json +++ b/spec/fixtures/api/schemas/internal/pages/lookup_path.json @@ -8,23 +8,62 @@ "prefix" ], "properties": { - "project_id": { "type": "integer" }, - "https_only": { "type": "boolean" }, - "access_control": { "type": "boolean" }, - "source": { "type": "object", - "required": ["type", "path"], - "properties" : { - "type": { "type": "string", "enum": ["file", "zip"] }, - "path": { "type": "string" }, - "global_id": { "type": "string" }, - "sha256": { "type": "string" }, - "file_size": { "type": "integer" }, - "file_count": { "type": ["integer", "null"] } + "project_id": { + "type": "integer" + }, + "https_only": { + "type": "boolean" + }, + "access_control": { + "type": "boolean" + }, + "source": { + "type": "object", + "required": [ + "type", + "path" + ], + "properties": { + "type": { + "type": "string", + "enum": [ + "file", + "zip" + ] + }, + "path": { + "type": "string" + }, + "global_id": { + "type": "string" + }, + "sha256": { + "type": "string" + }, + "file_size": { + "type": "integer" + }, + "file_count": { + "type": [ + "integer", + "null" + ] + } }, "additionalProperties": false }, - "prefix": { "type": "string" }, - "unique_domain": { "type": ["string", "null"] } + "prefix": { + "type": "string" + }, + "unique_host": { + "type": [ + "string", + "null" + ] + }, + "root_directory": { + "type": "string" + } }, "additionalProperties": false } diff --git a/spec/fixtures/emails/valid_reply_with_references_in_comma.eml b/spec/fixtures/emails/valid_reply_with_references_in_comma.eml new file mode 100644 index 00000000000..4a2d213f4cc --- /dev/null +++ b/spec/fixtures/emails/valid_reply_with_references_in_comma.eml @@ -0,0 +1,42 @@ +Return-Path: <jake@example.com> +Received: from iceking.adventuretime.ooo ([unix socket]) by iceking (Cyrus v2.2.13-Debian-2.2.13-19+squeeze3) with LMTPA; Thu, 13 Jun 2013 17:03:50 -0400 +Received: from mail-ie0-x234.google.com (mail-ie0-x234.google.com [IPv6:2607:f8b0:4001:c03::234]) by iceking.adventuretime.ooo (8.14.3/8.14.3/Debian-9.4) with ESMTP id r5DL3nFJ016967 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NOT) for <reply+59d8df8370b7e95c5a49fbf86aeb2c93@appmail.adventuretime.ooo>; Thu, 13 Jun 2013 17:03:50 -0400 +Received: by mail-ie0-f180.google.com with SMTP id f4so21977375iea.25 for <reply+59d8df8370b7e95c5a49fbf86aeb2c93@appmail.adventuretime.ooo>; Thu, 13 Jun 2013 14:03:48 -0700 +Received: by 10.0.0.1 with HTTP; Thu, 13 Jun 2013 14:03:48 -0700 +Date: Thu, 13 Jun 2013 17:03:48 -0400 +From: Jake the Dog <jake@example.com> +To: reply+59d8df8370b7e95c5a49fbf86aeb2c93@appmail.adventuretime.ooo +Message-ID: <CADkmRc+rNGAGGbV2iE5p918UVy4UyJqVcXRO2=otppgzduJSg@mail.gmail.com> +In-Reply-To: <issue_1@localhost> +References: "<reply-59d8df8370b7e95c5a49fbf86aeb2c93@localhost>,<issue_1@localhost>,<exchange@microsoft.com>" +Subject: re: [Discourse Meta] eviltrout posted in 'Adventure Time Sux' +Mime-Version: 1.0 +Content-Type: text/plain; + charset=ISO-8859-1 +Content-Transfer-Encoding: 7bit +X-Sieve: CMU Sieve 2.2 +X-Received: by 10.0.0.1 with SMTP id n7mr11234144ipb.85.1371157428600; Thu, + 13 Jun 2013 14:03:48 -0700 (PDT) +X-Scanned-By: MIMEDefang 2.69 on IPv6:2001:470:1d:165::1 + +I could not disagree more. I am obviously biased but adventure time is the +greatest show ever created. Everyone should watch it. + +- Jake out + + +On Sun, Jun 9, 2013 at 1:39 PM, eviltrout via Discourse Meta +<reply+59d8df8370b7e95c5a49fbf86aeb2c93@appmail.adventuretime.ooo> wrote: +> +> +> +> eviltrout posted in 'Adventure Time Sux' on Discourse Meta: +> +> --- +> hey guys everyone knows adventure time sucks! +> +> --- +> Please visit this link to respond: http://localhost:3000/t/adventure-time-sux/1234/3 +> +> To unsubscribe from these emails, visit your [user preferences](http://localhost:3000/user_preferences). +> diff --git a/spec/fixtures/gitlab/import_export/corrupted_project_export.tar.gz b/spec/fixtures/gitlab/import_export/corrupted_project_export.tar.gz Binary files differindex d6632c5121a..1ecfa5a80f9 100644 --- a/spec/fixtures/gitlab/import_export/corrupted_project_export.tar.gz +++ b/spec/fixtures/gitlab/import_export/corrupted_project_export.tar.gz diff --git a/spec/fixtures/gitlab/import_export/lightweight_project_export.tar.gz b/spec/fixtures/gitlab/import_export/lightweight_project_export.tar.gz Binary files differindex e5f6f195fe5..71a0ade3eba 100644 --- a/spec/fixtures/gitlab/import_export/lightweight_project_export.tar.gz +++ b/spec/fixtures/gitlab/import_export/lightweight_project_export.tar.gz diff --git a/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric.yml b/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric.yml index 520328f1041..42f9cc31c3a 100644 --- a/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric.yml +++ b/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric.yml @@ -5,7 +5,6 @@ description: product_section: product_stage: product_group: -product_category: value_type: number status: active milestone: "13.9" diff --git a/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_ee.yml b/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_ee.yml index 1942f33e043..e123056d771 100644 --- a/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_ee.yml +++ b/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_ee.yml @@ -5,7 +5,6 @@ description: product_section: product_stage: product_group: -product_category: value_type: number status: active milestone: "13.9" diff --git a/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_name_suggestions.yml b/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_name_suggestions.yml index a72ba5109cc..87c4e68f19e 100644 --- a/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_name_suggestions.yml +++ b/spec/fixtures/lib/generators/gitlab/usage_metric_definition_generator/sample_metric_with_name_suggestions.yml @@ -6,7 +6,6 @@ description: product_section: product_stage: product_group: -product_category: value_type: number status: active milestone: "13.9" diff --git a/spec/fixtures/lib/gitlab/import_export/complex/project.json b/spec/fixtures/lib/gitlab/import_export/complex/project.json index a0ac70d7d9c..cdf9395fbe6 100644 --- a/spec/fixtures/lib/gitlab/import_export/complex/project.json +++ b/spec/fixtures/lib/gitlab/import_export/complex/project.json @@ -8309,5 +8309,38 @@ "reject_unsigned_commits": true, "commit_committer_check": true, "regexp_uses_re2": true - } + }, + "approval_rules": [ + { + "approvals_required": 1, + "name": "MustContain", + "rule_type": "regular", + "scanners": [ + + ], + "vulnerabilities_allowed": 0, + "severity_levels": [ + "unknown", + "high", + "critical" + ], + "report_type": null, + "vulnerability_states": [ + "newly_detected" + ], + "orchestration_policy_idx": null, + "applies_to_all_protected_branches": false, + "approval_project_rules_protected_branches": [ + { + "protected_branch_id": 1, + "branch_name": "master" + } + ], + "approval_project_rules_users": [ + { + "user_id": 35 + } + ] + } + ] } diff --git a/spec/fixtures/lib/gitlab/import_export/complex/tree/project/protected_environments.ndjson b/spec/fixtures/lib/gitlab/import_export/complex/tree/project/protected_environments.ndjson index 55afaa8bcf6..f87fdd860c7 100644 --- a/spec/fixtures/lib/gitlab/import_export/complex/tree/project/protected_environments.ndjson +++ b/spec/fixtures/lib/gitlab/import_export/complex/tree/project/protected_environments.ndjson @@ -1 +1 @@ -{ "id": 1, "project_id": 9, "created_at": "2017-10-19T15:36:23.466Z", "updated_at": "2017-10-19T15:36:23.466Z", "name": "production", "deploy_access_levels": [ { "id": 1, "protected_environment_id": 1, "created_at": "2017-10-19T15:36:23.466Z", "updated_at": "2017-10-19T15:36:23.466Z", "access_level": 40, "user_id": 1, "group_id": null } ] } +{ "id": 1, "project_id": 9, "created_at": "2017-10-19T15:36:23.466Z", "updated_at": "2017-10-19T15:36:23.466Z", "name": "production", "deploy_access_levels": [ { "id": 1, "protected_environment_id": 1, "created_at": "2017-10-19T15:36:23.466Z", "updated_at": "2017-10-19T15:36:23.466Z", "access_level": null, "user_id": 1, "group_id": null } ] } diff --git a/spec/fixtures/lib/gitlab/import_export/designs/tree/project.json b/spec/fixtures/lib/gitlab/import_export/designs/tree/project.json new file mode 100644 index 00000000000..3adcb693aeb --- /dev/null +++ b/spec/fixtures/lib/gitlab/import_export/designs/tree/project.json @@ -0,0 +1,15 @@ +{ + "description": "Nisi et repellendus ut enim quo accusamus vel magnam.", + "import_type": "gitlab_project", + "creator_id": 123, + "visibility_level": 10, + "archived": false, + "deploy_keys": [ + + ], + "hooks": [ + + ], + "shared_runners_enabled": true, + "ci_config_path": "config/path" +} diff --git a/spec/fixtures/lib/gitlab/import_export/designs/tree/project/issues.ndjson b/spec/fixtures/lib/gitlab/import_export/designs/tree/project/issues.ndjson new file mode 100644 index 00000000000..3f767505bfb --- /dev/null +++ b/spec/fixtures/lib/gitlab/import_export/designs/tree/project/issues.ndjson @@ -0,0 +1,2 @@ +{"id":469,"title":"issue 1","author_id":1,"project_id":30,"created_at":"2019-08-07T03:57:55.007Z","updated_at":"2019-08-07T03:57:55.007Z","description":"","state":"opened","iid":1,"updated_by_id":null,"weight":null,"confidential":false,"due_date":null,"moved_to_id":null,"lock_version":0,"time_estimate":0,"relative_position":1073742323,"external_author":null,"last_edited_at":null,"last_edited_by_id":null,"discussion_locked":null,"closed_at":null,"closed_by_id":null,"state_id":1,"events":[{"id":1775,"project_id":30,"author_id":1,"target_id":469,"created_at":"2019-08-07T03:57:55.158Z","updated_at":"2019-08-07T03:57:55.158Z","target_type":"Issue","action":1}],"timelogs":[],"notes":[],"label_links":[],"resource_label_events":[],"issue_assignees":[],"designs":[{"id":38,"iid":1,"project_id":30,"issue_id":469,"filename":"chirrido3.jpg","notes":[]},{"id":39,"iid":2,"project_id":30,"issue_id":469,"filename":"jonathan_richman.jpg","notes":[]},{"id":40,"iid":3,"project_id":30,"issue_id":469,"filename":"mariavontrap.jpeg","notes":[]}],"design_versions":[{"id":24,"sha":"9358d1bac8ff300d3d2597adaa2572a20f7f8703","issue_id":469,"author_id":1,"actions":[{"design_id":38,"version_id":24,"event":0,"design":{"id":38,"iid":1,"project_id":30,"issue_id":469,"filename":"chirrido3.jpg"}}]},{"id":25,"sha":"e1a4a501bcb42f291f84e5d04c8f927821542fb6","issue_id":469,"author_id":2,"actions":[{"design_id":38,"version_id":25,"event":1,"design":{"id":38,"iid":1,"project_id":30,"issue_id":469,"filename":"chirrido3.jpg"}},{"design_id":39,"version_id":25,"event":0,"design":{"id":39,"iid":2,"project_id":30,"issue_id":469,"filename":"jonathan_richman.jpg"}}]},{"id":26,"sha":"27702d08f5ee021ae938737f84e8fe7c38599e85","issue_id":469,"author_id":1,"actions":[{"design_id":38,"version_id":26,"event":1,"design":{"id":38,"iid":1,"project_id":30,"issue_id":469,"filename":"chirrido3.jpg"}},{"design_id":39,"version_id":26,"event":2,"design":{"id":39,"iid":2,"project_id":30,"issue_id":469,"filename":"jonathan_richman.jpg"}},{"design_id":40,"version_id":26,"event":0,"design":{"id":40,"iid":3,"project_id":30,"issue_id":469,"filename":"mariavontrap.jpeg"}}]}]} +{"id":470,"title":"issue 2","author_id":1,"project_id":30,"created_at":"2019-08-07T04:15:57.607Z","updated_at":"2019-08-07T04:15:57.607Z","description":"","state":"opened","iid":2,"updated_by_id":null,"weight":null,"confidential":false,"due_date":null,"moved_to_id":null,"lock_version":0,"time_estimate":0,"relative_position":1073742823,"external_author":null,"last_edited_at":null,"last_edited_by_id":null,"discussion_locked":null,"closed_at":null,"closed_by_id":null,"state_id":1,"events":[{"id":1776,"project_id":30,"author_id":1,"target_id":470,"created_at":"2019-08-07T04:15:57.789Z","updated_at":"2019-08-07T04:15:57.789Z","target_type":"Issue","action":1}],"timelogs":[],"notes":[],"label_links":[],"resource_label_events":[],"issue_assignees":[],"designs":[{"id":42,"project_id":30,"issue_id":470,"filename":"1 (1).jpeg","notes":[]},{"id":43,"project_id":30,"issue_id":470,"filename":"2099743.jpg","notes":[]},{"id":44,"project_id":30,"issue_id":470,"filename":"a screenshot (1).jpg","notes":[]},{"id":41,"project_id":30,"issue_id":470,"filename":"chirrido3.jpg","notes":[]}],"design_versions":[{"id":27,"sha":"8587e78ab6bda3bc820a9f014c3be4a21ad4fcc8","issue_id":470,"author_id":1,"actions":[{"design_id":41,"version_id":27,"event":0,"design":{"id":41,"project_id":30,"issue_id":470,"filename":"chirrido3.jpg"}}]},{"id":28,"sha":"73f871b4c8c1d65c62c460635e023179fb53abc4","issue_id":470,"author_id":2,"actions":[{"design_id":42,"version_id":28,"event":0,"design":{"id":42,"project_id":30,"issue_id":470,"filename":"1 (1).jpeg"}},{"design_id":43,"version_id":28,"event":0,"design":{"id":43,"project_id":30,"issue_id":470,"filename":"2099743.jpg"}}]},{"id":29,"sha":"c9b5f067f3e892122a4b12b0a25a8089192f3ac8","issue_id":470,"author_id":2,"actions":[{"design_id":42,"version_id":29,"event":1,"design":{"id":42,"project_id":30,"issue_id":470,"filename":"1 (1).jpeg"}},{"design_id":44,"version_id":29,"event":0,"design":{"id":44,"project_id":30,"issue_id":470,"filename":"a screenshot (1).jpg"}}]}]}
\ No newline at end of file diff --git a/spec/fixtures/lib/gitlab/import_export/designs/tree/project/project_members.ndjson b/spec/fixtures/lib/gitlab/import_export/designs/tree/project/project_members.ndjson new file mode 100644 index 00000000000..570fd4a0c05 --- /dev/null +++ b/spec/fixtures/lib/gitlab/import_export/designs/tree/project/project_members.ndjson @@ -0,0 +1,2 @@ +{"id":95,"access_level":40,"source_id":30,"source_type":"Project","user_id":1,"notification_level":3,"created_at":"2019-08-07T03:57:32.825Z","updated_at":"2019-08-07T03:57:32.825Z","created_by_id":1,"invite_email":null,"invite_token":null,"invite_accepted_at":null,"requested_at":null,"expires_at":null,"ldap":false,"override":false,"user":{"id":1,"public_email":"admin@example.com","username":"root"}} +{"id":96,"access_level":40,"source_id":30,"source_type":"Project","user_id":2,"notification_level":3,"created_at":"2019-08-07T03:57:32.825Z","updated_at":"2019-08-07T03:57:32.825Z","created_by_id":null,"invite_email":null,"invite_token":null,"invite_accepted_at":null,"requested_at":null,"expires_at":null,"ldap":false,"override":false,"user":{"id":2,"public_email":"user_2@gitlabexample.com","username":"user_2"}}
\ No newline at end of file diff --git a/spec/fixtures/markdown.md.erb b/spec/fixtures/markdown.md.erb index 979e96e6e8e..26e5f110687 100644 --- a/spec/fixtures/markdown.md.erb +++ b/spec/fixtures/markdown.md.erb @@ -299,6 +299,32 @@ References should be parseable even inside _<%= merge_request.to_reference %>_ e v^2 + w^2 = x^2 ``` +Parsed correctly when between code blocks + +```ruby +x = 1 +``` + +$$ +a^2+b^2=c^2 +$$ + +``` +plaintext +``` + +Parsed correctly with a mixture of HTML comments and HTML blocks + +<!-- sdf --> + +$$ +a^2+b^2=c^2 +$$ + +<h1> +html +</h1> + ### Gollum Tags - [[linked-resource]] diff --git a/spec/fixtures/pages_with_custom_root.zip b/spec/fixtures/pages_with_custom_root.zip Binary files differnew file mode 100644 index 00000000000..40dea253245 --- /dev/null +++ b/spec/fixtures/pages_with_custom_root.zip diff --git a/spec/fixtures/pages_with_custom_root.zip.meta b/spec/fixtures/pages_with_custom_root.zip.meta Binary files differnew file mode 100644 index 00000000000..2cb04e0c33b --- /dev/null +++ b/spec/fixtures/pages_with_custom_root.zip.meta diff --git a/spec/fixtures/pages_with_custom_root.zip.meta0 b/spec/fixtures/pages_with_custom_root.zip.meta0 Binary files differnew file mode 100644 index 00000000000..9b348055b5f --- /dev/null +++ b/spec/fixtures/pages_with_custom_root.zip.meta0 diff --git a/spec/fixtures/scripts/test_report.json b/spec/fixtures/scripts/test_report.json index 29fd9a4bcb5..520ab3a8578 100644 --- a/spec/fixtures/scripts/test_report.json +++ b/spec/fixtures/scripts/test_report.json @@ -1,7 +1,7 @@ { "suites": [ { - "name": "rspec unit pg12", + "name": "rspec unit pg13", "total_time": 975.6635620000018, "total_count": 3811, "success_count": 3800, diff --git a/spec/fixtures/security_reports/feature-branch/gl-sast-report.json b/spec/fixtures/security_reports/feature-branch/gl-sast-report.json index 083042e19ff..f153192fed7 100644 --- a/spec/fixtures/security_reports/feature-branch/gl-sast-report.json +++ b/spec/fixtures/security_reports/feature-branch/gl-sast-report.json @@ -1,7 +1,8 @@ { - "version": "14.0.0", + "version": "15.0.0", "vulnerabilities": [ { + "id": "1", "category": "sast", "name": "Predictable pseudorandom number generator", "message": "Predictable pseudorandom number generator", @@ -29,6 +30,7 @@ ] }, { + "id": "2", "category": "sast", "name": "Predictable pseudorandom number generator", "message": "Predictable pseudorandom number generator", @@ -56,6 +58,7 @@ ] }, { + "id": "3", "category": "sast", "name": "ECB mode is insecure", "message": "ECB mode is insecure", @@ -90,6 +93,7 @@ ] }, { + "id": "4", "category": "sast", "name": "Hard coded key", "message": "Hard coded key", @@ -124,6 +128,7 @@ ] }, { + "id": "5", "category": "sast", "name": "ECB mode is insecure", "message": "ECB mode is insecure", @@ -158,8 +163,19 @@ ] } ], - "remediations": [], + "remediations": [ + + ], "scan": { + "analyzer": { + "id": "find_sec_bugs_analyzer", + "name": "Find Security Bugs Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "find_sec_bugs", "name": "Find Security Bugs", @@ -174,4 +190,4 @@ "start_time": "2022-08-10T22:37:00", "end_time": "2022-08-10T22:38:00" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/feature-branch/gl-secret-detection-report.json b/spec/fixtures/security_reports/feature-branch/gl-secret-detection-report.json index 4862a504cec..c75b9bfb9de 100644 --- a/spec/fixtures/security_reports/feature-branch/gl-secret-detection-report.json +++ b/spec/fixtures/security_reports/feature-branch/gl-secret-detection-report.json @@ -1,5 +1,33 @@ { - "version": "14.1.2", - "vulnerabilities": [], - "remediations": [] -}
\ No newline at end of file + "version": "15.0.0", + "vulnerabilities": [ + + ], + "remediations": [ + + ], + "scan": { + "analyzer": { + "id": "secret_detection_analyzer", + "name": "Secret Detection Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, + "scanner": { + "id": "secret_detection", + "name": "Secret Detection", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "0.1.0" + }, + "type": "sast", + "start_time": "2022-03-11T18:48:16", + "end_time": "2022-03-11T18:48:22", + "status": "success" + } +} diff --git a/spec/fixtures/security_reports/master/gl-sast-missing-scanner.json b/spec/fixtures/security_reports/master/gl-sast-missing-scanner.json index fcfd9b831f4..16d02490156 100644 --- a/spec/fixtures/security_reports/master/gl-sast-missing-scanner.json +++ b/spec/fixtures/security_reports/master/gl-sast-missing-scanner.json @@ -1,7 +1,23 @@ { - "version": "14.1.2", + "version": "15.0.0", + "scan": { + "analyzer": { + "id": "sast_analyzer", + "name": "SAST Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, + "type": "sast", + "start_time": "2022-03-11T18:48:16", + "end_time": "2022-03-11T18:48:22", + "status": "success" + }, "vulnerabilities": [ { + "id": "1", "category": "sast", "message": "Probable insecure usage of temp file/directory.", "cve": "python/hardcoded/hardcoded-tmp.py:52865813c884a507be1f152d654245af34aba8a391626d01f1ab6d3f52ec8779:B108", @@ -26,6 +42,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b108_hardcoded_tmp_directory.html" }, { + "id": "2", "category": "sast", "name": "Predictable pseudorandom number generator", "message": "Predictable pseudorandom number generator", @@ -53,6 +70,7 @@ "url": "https://find-sec-bugs.github.io/bugs.htm#PREDICTABLE_RANDOM" }, { + "id": "3", "category": "sast", "name": "Predictable pseudorandom number generator", "message": "Predictable pseudorandom number generator", @@ -80,6 +98,7 @@ "url": "https://find-sec-bugs.github.io/bugs.htm#PREDICTABLE_RANDOM" }, { + "id": "4", "category": "sast", "message": "Use of insecure MD2, MD4, or MD5 hash function.", "cve": "python/imports/imports-aliases.py:cb203b465dffb0cb3a8e8bd8910b84b93b0a5995a938e4b903dbb0cd6ffa1254:B303", @@ -102,6 +121,7 @@ "line": 11 }, { + "id": "5", "category": "sast", "message": "Use of insecure MD2, MD4, or MD5 hash function.", "cve": "python/imports/imports-aliases.py:a7173c43ae66bd07466632d819d450e0071e02dbf782763640d1092981f9631b:B303", @@ -124,6 +144,7 @@ "line": 12 }, { + "id": "6", "category": "sast", "message": "Use of insecure MD2, MD4, or MD5 hash function.", "cve": "python/imports/imports-aliases.py:017017b77deb0b8369b6065947833eeea752a92ec8a700db590fece3e934cf0d:B303", @@ -146,6 +167,7 @@ "line": 13 }, { + "id": "6", "category": "sast", "message": "Use of insecure MD2, MD4, or MD5 hash function.", "cve": "python/imports/imports-aliases.py:45fc8c53aea7b84f06bc4e590cc667678d6073c4c8a1d471177ca2146fb22db2:B303", @@ -168,6 +190,7 @@ "line": 14 }, { + "id": "7", "category": "sast", "message": "Pickle library appears to be in use, possible security issue.", "cve": "python/imports/imports-aliases.py:5f200d47291e7bbd8352db23019b85453ca048dd98ea0c291260fa7d009963a4:B301", @@ -190,6 +213,7 @@ "line": 15 }, { + "id": "8", "category": "sast", "name": "ECB mode is insecure", "message": "ECB mode is insecure", @@ -217,6 +241,7 @@ "url": "https://find-sec-bugs.github.io/bugs.htm#ECB_MODE" }, { + "id": "9", "category": "sast", "name": "Cipher with no integrity", "message": "Cipher with no integrity", @@ -244,6 +269,7 @@ "url": "https://find-sec-bugs.github.io/bugs.htm#CIPHER_INTEGRITY" }, { + "id": "10", "category": "sast", "message": "Probable insecure usage of temp file/directory.", "cve": "python/hardcoded/hardcoded-tmp.py:63dd4d626855555b816985d82c4614a790462a0a3ada89dc58eb97f9c50f3077:B108", @@ -268,6 +294,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b108_hardcoded_tmp_directory.html" }, { + "id": "11", "category": "sast", "message": "Probable insecure usage of temp file/directory.", "cve": "python/hardcoded/hardcoded-tmp.py:4ad6d4c40a8c263fc265f3384724014e0a4f8dd6200af83e51ff120420038031:B108", @@ -292,6 +319,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b108_hardcoded_tmp_directory.html" }, { + "id": "12", "category": "sast", "message": "Consider possible security implications associated with Popen module.", "cve": "python/imports/imports-aliases.py:2c3e1fa1e54c3c6646e8bcfaee2518153c6799b77587ff8d9a7b0631f6d34785:B404", @@ -314,6 +342,7 @@ "line": 1 }, { + "id": "13", "category": "sast", "message": "Consider possible security implications associated with pickle module.", "cve": "python/imports/imports.py:af58d07f6ad519ef5287fcae65bf1a6999448a1a3a8bc1ac2a11daa80d0b96bf:B403", @@ -336,6 +365,7 @@ "line": 2 }, { + "id": "14", "category": "sast", "message": "Consider possible security implications associated with subprocess module.", "cve": "python/imports/imports.py:8de9bc98029d212db530785a5f6780cfa663548746ff228ab8fa96c5bb82f089:B404", @@ -358,6 +388,7 @@ "line": 4 }, { + "id": "15", "category": "sast", "message": "Possible hardcoded password: 'blerg'", "cve": "python/hardcoded/hardcoded-passwords.py:97c30f1d76d2a88913e3ce9ae74087874d740f87de8af697a9c455f01119f633:B106", @@ -382,6 +413,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b106_hardcoded_password_funcarg.html" }, { + "id": "16", "category": "sast", "message": "Possible hardcoded password: 'root'", "cve": "python/hardcoded/hardcoded-passwords.py:7431c73a0bc16d94ece2a2e75ef38f302574d42c37ac0c3c38ad0b3bf8a59f10:B105", @@ -406,6 +438,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b105_hardcoded_password_string.html" }, { + "id": "17", "category": "sast", "message": "Possible hardcoded password: ''", "cve": "python/hardcoded/hardcoded-passwords.py:d2d1857c27caedd49c57bfbcdc23afcc92bd66a22701fcdc632869aab4ca73ee:B105", @@ -430,6 +463,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b105_hardcoded_password_string.html" }, { + "id": "18", "category": "sast", "message": "Possible hardcoded password: 'ajklawejrkl42348swfgkg'", "cve": "python/hardcoded/hardcoded-passwords.py:fb3866215a61393a5c9c32a3b60e2058171a23219c353f722cbd3567acab21d2:B105", @@ -454,6 +488,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b105_hardcoded_password_string.html" }, { + "id": "19", "category": "sast", "message": "Possible hardcoded password: 'blerg'", "cve": "python/hardcoded/hardcoded-passwords.py:63c62a8b7e1e5224439bd26b28030585ac48741e28ca64561a6071080c560a5f:B105", @@ -478,6 +513,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b105_hardcoded_password_string.html" }, { + "id": "20", "category": "sast", "message": "Possible hardcoded password: 'blerg'", "cve": "python/hardcoded/hardcoded-passwords.py:4311b06d08df8fa58229b341c531da8e1a31ec4520597bdff920cd5c098d86f9:B105", @@ -502,6 +538,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b105_hardcoded_password_string.html" }, { + "id": "21", "category": "sast", "message": "Consider possible security implications associated with subprocess module.", "cve": "python/imports/imports-function.py:5858400c2f39047787702de44d03361ef8d954c9d14bd54ee1c2bef9e6a7df93:B404", @@ -524,6 +561,7 @@ "line": 4 }, { + "id": "22", "category": "sast", "message": "Consider possible security implications associated with pickle module.", "cve": "python/imports/imports-function.py:dbda3cf4190279d30e0aad7dd137eca11272b0b225e8af4e8bf39682da67d956:B403", @@ -546,6 +584,7 @@ "line": 2 }, { + "id": "23", "category": "sast", "message": "Consider possible security implications associated with Popen module.", "cve": "python/imports/imports-from.py:eb8a0db9cd1a8c1ab39a77e6025021b1261cc2a0b026b2f4a11fca4e0636d8dd:B404", @@ -568,6 +607,7 @@ "line": 7 }, { + "id": "24", "category": "sast", "message": "subprocess call with shell=True seems safe, but may be changed in the future, consider rewriting without shell", "cve": "python/imports/imports-aliases.py:f99f9721e27537fbcb6699a4cf39c6740d6234d2c6f06cfc2d9ea977313c483d:B602", @@ -592,6 +632,7 @@ "url": "https://docs.openstack.org/bandit/latest/plugins/b602_subprocess_popen_with_shell_equals_true.html" }, { + "id": "25", "category": "sast", "message": "Consider possible security implications associated with subprocess module.", "cve": "python/imports/imports-from.py:332a12ab1146698f614a905ce6a6a5401497a12281aef200e80522711c69dcf4:B404", @@ -614,6 +655,7 @@ "line": 6 }, { + "id": "26", "category": "sast", "message": "Consider possible security implications associated with Popen module.", "cve": "python/imports/imports-from.py:0a48de4a3d5348853a03666cb574697e3982998355e7a095a798bd02a5947276:B404", @@ -636,6 +678,7 @@ "line": 1 }, { + "id": "27", "category": "sast", "message": "Consider possible security implications associated with pickle module.", "cve": "python/imports/imports-aliases.py:51b71661dff994bde3529639a727a678c8f5c4c96f00d300913f6d5be1bbdf26:B403", @@ -658,6 +701,7 @@ "line": 7 }, { + "id": "28", "category": "sast", "message": "Consider possible security implications associated with loads module.", "cve": "python/imports/imports-aliases.py:6ff02aeb3149c01ab68484d794a94f58d5d3e3bb0d58557ef4153644ea68ea54:B403", @@ -680,6 +724,7 @@ "line": 6 }, { + "id": "29", "category": "sast", "message": "Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120)", "cve": "c/subdir/utils.c:b466873101951fe96e1332f6728eb7010acbbd5dfc3b65d7d53571d091a06d9e:CWE-119!/CWE-120", @@ -713,6 +758,7 @@ "url": "https://cwe.mitre.org/data/definitions/119.html" }, { + "id": "30", "category": "sast", "message": "Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362)", "cve": "c/subdir/utils.c:bab681140fcc8fc3085b6bba74081b44ea145c1c98b5e70cf19ace2417d30770:CWE-362", @@ -739,6 +785,7 @@ "url": "https://cwe.mitre.org/data/definitions/362.html" }, { + "id": "31", "category": "sast", "message": "Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120)", "cve": "cplusplus/src/hello.cpp:c8c6dd0afdae6814194cf0930b719f757ab7b379cf8f261e7f4f9f2f323a818a:CWE-119!/CWE-120", @@ -772,6 +819,7 @@ "url": "https://cwe.mitre.org/data/definitions/119.html" }, { + "id": "32", "category": "sast", "message": "Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120)", "cve": "cplusplus/src/hello.cpp:331c04062c4fe0c7c486f66f59e82ad146ab33cdd76ae757ca41f392d568cbd0:CWE-120", @@ -799,4 +847,4 @@ "url": "https://cwe.mitre.org/data/definitions/120.html" } ] -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-sast-report-bandit.json b/spec/fixtures/security_reports/master/gl-sast-report-bandit.json index d0346479b85..690c58d049b 100644 --- a/spec/fixtures/security_reports/master/gl-sast-report-bandit.json +++ b/spec/fixtures/security_reports/master/gl-sast-report-bandit.json @@ -1,5 +1,5 @@ { - "version": "14.0.4", + "version": "15.0.4", "vulnerabilities": [ { "id": "985a5666dcae22adef5ac12f8a8a2dacf9b9b481ae5d87cd0ac1712b0fd64864", @@ -26,6 +26,15 @@ } ], "scan": { + "analyzer": { + "id": "find_sec_bugs_analyzer", + "name": "Find Security Bugs Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "bandit", "name": "Bandit", @@ -40,4 +49,4 @@ "end_time": "2022-03-11T00:21:50", "status": "success" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-sast-report-gosec.json b/spec/fixtures/security_reports/master/gl-sast-report-gosec.json index 4c385326c8c..ef1d06d2e4f 100644 --- a/spec/fixtures/security_reports/master/gl-sast-report-gosec.json +++ b/spec/fixtures/security_reports/master/gl-sast-report-gosec.json @@ -1,5 +1,5 @@ { - "version": "14.0.4", + "version": "15.0.4", "vulnerabilities": [ { "id": "2e5656ff30e2e7cc93c36b4845c8a689ddc47fdbccf45d834c67442fbaa89be0", @@ -51,6 +51,15 @@ } ], "scan": { + "analyzer": { + "id": "find_sec_bugs_analyzer", + "name": "Find Security Bugs Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "gosec", "name": "Gosec", @@ -65,4 +74,4 @@ "end_time": "2022-03-15T20:33:17", "status": "success" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-sast-report-minimal.json b/spec/fixtures/security_reports/master/gl-sast-report-minimal.json index 53d15224b30..d29571638ff 100644 --- a/spec/fixtures/security_reports/master/gl-sast-report-minimal.json +++ b/spec/fixtures/security_reports/master/gl-sast-report-minimal.json @@ -1,7 +1,8 @@ { - "version": "14.0.0", + "version": "15.0.0", "vulnerabilities": [ { + "id": "1", "category": "sast", "name": "Cipher with no integrity", "message": "Cipher with no integrity", @@ -49,8 +50,19 @@ } } ], - "remediations": [], + "remediations": [ + + ], "scan": { + "analyzer": { + "id": "find_sec_bugs_analyzer", + "name": "Find Security Bugs Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "find_sec_bugs", "name": "Find Security Bugs", @@ -65,4 +77,4 @@ "start_time": "2022-08-10T21:37:00", "end_time": "2022-08-10T21:38:00" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-bandit.json b/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-bandit.json index 037b9fb8d3e..c51abf46c13 100644 --- a/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-bandit.json +++ b/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-bandit.json @@ -1,5 +1,5 @@ { - "version": "14.0.4", + "version": "15.0.4", "vulnerabilities": [ { "id": "985a5666dcae22adef5ac12f8a8a2dacf9b9b481ae5d87cd0ac1712b0fd64864", @@ -54,6 +54,15 @@ } ], "scan": { + "analyzer": { + "id": "find_sec_bugs_analyzer", + "name": "Find Security Bugs Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "semgrep", "name": "Semgrep", @@ -68,4 +77,4 @@ "end_time": "2022-03-11T18:48:22", "status": "success" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-gosec.json b/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-gosec.json index 8fa85c30b56..9a6dd4190c5 100644 --- a/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-gosec.json +++ b/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-gosec.json @@ -1,5 +1,5 @@ { - "version": "14.0.4", + "version": "15.0.4", "vulnerabilities": [ { "id": "79f6537b7ec83c7717f5bd1a4f12645916caafefe2e4359148d889855505aa67", @@ -53,6 +53,15 @@ } ], "scan": { + "analyzer": { + "id": "find_sec_bugs_analyzer", + "name": "Find Security Bugs Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "semgrep", "name": "Semgrep", @@ -74,4 +83,4 @@ "end_time": "2022-03-15T20:37:05", "status": "success" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-multiple-findings.json b/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-multiple-findings.json index cbdfdb86f6b..e3659c70710 100644 --- a/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-multiple-findings.json +++ b/spec/fixtures/security_reports/master/gl-sast-report-semgrep-for-multiple-findings.json @@ -1,5 +1,5 @@ { - "version": "14.0.4", + "version": "15.0.4", "vulnerabilities": [ { "id": "985a5666dcae22adef5ac12f8a8a2dacf9b9b481ae5d87cd0ac1712b0fd64864", @@ -104,6 +104,15 @@ } ], "scan": { + "analyzer": { + "id": "semgrep_analyzer", + "name": "Semgrep Analyzer", + "url": "https://gitlab.com/", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "semgrep", "name": "Semgrep", @@ -131,4 +140,4 @@ "end_time": "2022-03-15T20:37:05", "status": "success" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-sast-report.json b/spec/fixtures/security_reports/master/gl-sast-report.json index 0ec31252e97..1bd1f241a6d 100644 --- a/spec/fixtures/security_reports/master/gl-sast-report.json +++ b/spec/fixtures/security_reports/master/gl-sast-report.json @@ -1,7 +1,8 @@ { - "version": "14.0.0", + "version": "15.0.0", "vulnerabilities": [ { + "id": "1_481ae5d87cd0ac1712b0fd64864", "category": "sast", "name": "Predictable pseudorandom number generator", "message": "Predictable pseudorandom number generator", @@ -39,6 +40,7 @@ ] }, { + "id": "2_481ae5d87cd0ac1712b0fd64864", "category": "sast", "name": "Predictable pseudorandom number generator", "message": "Predictable pseudorandom number generator", @@ -66,6 +68,7 @@ ] }, { + "id": "3_481ae5d87cd0ac1712b0fd64864", "category": "sast", "name": "ECB mode is insecure", "message": "ECB mode is insecure", @@ -100,6 +103,7 @@ ] }, { + "id": "4_481ae5d87cd0ac1712b0fd64864", "category": "sast", "name": "Hard coded key", "message": "Hard coded key", @@ -134,6 +138,7 @@ ] }, { + "id": "5_481ae5d87cd0ac1712b0fd64864", "category": "sast", "name": "Cipher with no integrity", "message": "Cipher with no integrity", @@ -181,8 +186,19 @@ } } ], - "remediations": [], + "remediations": [ + + ], "scan": { + "analyzer": { + "id": "find_sec_bugs_analyzer", + "name": "Find Security Bugs Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, "scanner": { "id": "find_sec_bugs", "name": "Find Security Bugs", @@ -197,4 +213,4 @@ "start_time": "2022-08-10T21:37:00", "end_time": "2022-08-10T21:38:00" } -}
\ No newline at end of file +} diff --git a/spec/fixtures/security_reports/master/gl-secret-detection-report.json b/spec/fixtures/security_reports/master/gl-secret-detection-report.json index cb97b60ced1..43c079e8769 100644 --- a/spec/fixtures/security_reports/master/gl-secret-detection-report.json +++ b/spec/fixtures/security_reports/master/gl-secret-detection-report.json @@ -1,5 +1,29 @@ { - "version": "14.1.2", + "version": "15.0.0", + "scan": { + "analyzer": { + "id": "secret_detection_analyzer", + "name": "Secret Detection Analyzer", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "1.0.0" + }, + "scanner": { + "id": "secret_detection", + "name": "Secret Detection", + "url": "https://gitlab.com", + "vendor": { + "name": "GitLab" + }, + "version": "0.1.0" + }, + "type": "sast", + "start_time": "2022-03-11T18:48:16", + "end_time": "2022-03-11T18:48:22", + "status": "success" + }, "vulnerabilities": [ { "id": "27d2322d519c94f803ffed1cf6d14e455df97e5a0668e229eb853fdb0d277d2c", @@ -17,7 +41,8 @@ "location": { "file": "aws-key.py", "dependency": { - "package": {} + "package": { + } }, "commit": { "sha": "e9c3a56590d5bed4155c0d128f1552d52fdcc7ae" @@ -32,5 +57,7 @@ ] } ], - "remediations": [] -}
\ No newline at end of file + "remediations": [ + + ] +} diff --git a/spec/fixtures/service_account.json b/spec/fixtures/service_account.json index 9f7f5526cf5..31ef182f8c2 100644 --- a/spec/fixtures/service_account.json +++ b/spec/fixtures/service_account.json @@ -2,7 +2,7 @@ "type": "service_account", "project_id": "demo-app-123", "private_key_id": "47f0b1700983da548af6fcd37007f42996099999", - "private_key": "-----BEGIN PRIVATE KEY-----\nABCDEFIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQDJn8w20WcN+fi5\nIhO1BEFCv7ExK8J5rW5Pc8XpJgpQoL5cfv6qC6aS+x4maI7S4AG7diqXBLCfjlnA\nqBzXwCRnnPtQhu+v1ehAj5fGNa7F51f9aacRNmKdHzNmWZEPDuLqq0I/Ewcsotu+\nnb+tCYk1o2ahyPZau8JtXFZs7oZb7SrfgoSJemccxeVreGm1Dt6SM74/3qJAeHN/\niK/v0IiQP1GS4Jxgz38XQGo+jiTpNrFcf4S0RNxKcNf+tuuEBDi57LBLwdotM7E5\nF1l9pZZMWkmQKQIxeER6+2HuE56V6QPITwkQ/u9XZFQSgl4SBIw2sHr5D/xaUxjw\n+kMy2Jt9AgMBAAECggEACL7E34rRIWbP043cv3ZQs1RiWzY2mvWmCiMEzkz0rRRv\nyqNv0yXVYtzVV7KjdpY56leLgjM1Sv0PEQoUUtpWFJAXSXdKLaewSXPrpXCoz5OD\nekMgeItnQcE7nECdyAKsCSQw/SXg4t4p0a3WGsCwt3If2TwWIrov9R4zGcn1wMZn\n922WtZDmh2NqdTZIKElWZLxNlIr/1v88mAp7oSa1DLfqWkwEEnxK7GGAiwN8ARIF\nkvgiuKdsHBf5aNKg70xN6AcZx/Z4+KZxXxyKKF5VkjCtDzA97EjJqftDPwGTkela\n2bgiDSJs0Un0wQpFFRDrlfyo7rr9Ey/Gf4rR66NWeQKBgQD7qPP55xoWHCDvoK9P\nMN67qFLNDPWcKVKr8siwUlZ6/+acATXjfNUjsJLM7vBxYLjdtFxQ/vojJTQyMxHt\n80wARDk1DTu2zhltL2rKo6LfbwjQsot1MLZFXAMwqtHTLfURaj8kO1JDV/j+4a94\nP0gzNMiBYAKWm6z08akEz2TrhQKBgQDNGfFvtxo4Mf6AA3iYXCwc0CJXb+cqZkW/\n7glnV+vDqYVo23HJaKHFD+Xqaj+cUrOUNglWgT9WSCZR++Hzw1OCPZvX2V9Z6eQh\ngqOBX6D19q9jfShfxLywEAD5pk7LMINumsNm6H+6shJQK5c67bsM9/KQbSnIlWhw\n7JBe8OlFmQKBgQDREyF2mb/7ZG0ch8N9qB0zjHkV79FRZqdPQUnn6s/8KgO90eei\nUkCFARpE9bF+kBul3UTg6aSIdE0z82fO51VZ11Qrtg3JJtrK8hznsyEKPaX2NI9V\n0h1r7DCeSxw9NS4nxLwmbr4+QqUTpA3yeaiTGiQGD+y2kSkU6nxACclPPQKBgFkb\nkVqg6YJKrjB90ZIYUY3/GzxzwLIaFumpCGretu6eIvkIhiokDExqeNBccuB+ych1\npZ7wrkzVMdjinythzFFEZQXlSdjtlhC9Cj52Bp92GoMV6EmbVwMDIPlVuNvsat3N\n3WFDV+ML5IryNVUD3gVnX/pBgyrDRsnw7VRiRGbZAoGBANxZwGKZo0zpyb5O5hS6\nxVrgJtIySlV5BOEjFXKeLwzByht8HmrHhSWix6WpPejfK1RHhl3boU6t9yeC0cre\nvUI/Y9LBhHXjSwWCWlqVe9yYqsde+xf0UYRS8IoaoJjus7YVJr9yPpCboEF28ZmQ\ndVBlpZYg6oLIar6waaLMz/1B\n-----END PRIVATE KEY-----\n", + "private_key": "-----BEGIN PRIVATE KEY-----\nMIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQDJn8w20WcN+fi5\nIhO1BEFCv7ExK8J5rW5Pc8XpJgpQoL5cfv6qC6aS+x4maI7S4AG7diqXBLCfjlnA\nqBzXwCRnnPtQhu+v1ehAj5fGNa7F51f9aacRNmKdHzNmWZEPDuLqq0I/Ewcsotu+\nnb+tCYk1o2ahyPZau8JtXFZs7oZb7SrfgoSJemccxeVreGm1Dt6SM74/3qJAeHN/\niK/v0IiQP1GS4Jxgz38XQGo+jiTpNrFcf4S0RNxKcNf+tuuEBDi57LBLwdotM7E5\nF1l9pZZMWkmQKQIxeER6+2HuE56V6QPITwkQ/u9XZFQSgl4SBIw2sHr5D/xaUxjw\n+kMy2Jt9AgMBAAECggEACL7E34rRIWbP043cv3ZQs1RiWzY2mvWmCiMEzkz0rRRv\nyqNv0yXVYtzVV7KjdpY56leLgjM1Sv0PEQoUUtpWFJAXSXdKLaewSXPrpXCoz5OD\nekMgeItnQcE7nECdyAKsCSQw/SXg4t4p0a3WGsCwt3If2TwWIrov9R4zGcn1wMZn\n922WtZDmh2NqdTZIKElWZLxNlIr/1v88mAp7oSa1DLfqWkwEEnxK7GGAiwN8ARIF\nkvgiuKdsHBf5aNKg70xN6AcZx/Z4+KZxXxyKKF5VkjCtDzA97EjJqftDPwGTkela\n2bgiDSJs0Un0wQpFFRDrlfyo7rr9Ey/Gf4rR66NWeQKBgQD7qPP55xoWHCDvoK9P\nMN67qFLNDPWcKVKr8siwUlZ6/+acATXjfNUjsJLM7vBxYLjdtFxQ/vojJTQyMxHt\n80wARDk1DTu2zhltL2rKo6LfbwjQsot1MLZFXAMwqtHTLfURaj8kO1JDV/j+4a94\nP0gzNMiBYAKWm6z08akEz2TrhQKBgQDNGfFvtxo4Mf6AA3iYXCwc0CJXb+cqZkW/\n7glnV+vDqYVo23HJaKHFD+Xqaj+cUrOUNglWgT9WSCZR++Hzw1OCPZvX2V9Z6eQh\ngqOBX6D19q9jfShfxLywEAD5pk7LMINumsNm6H+6shJQK5c67bsM9/KQbSnIlWhw\n7JBe8OlFmQKBgQDREyF2mb/7ZG0ch8N9qB0zjHkV79FRZqdPQUnn6s/8KgO90eei\nUkCFARpE9bF+kBul3UTg6aSIdE0z82fO51VZ11Qrtg3JJtrK8hznsyEKPaX2NI9V\n0h1r7DCeSxw9NS4nxLwmbr4+QqUTpA3yeaiTGiQGD+y2kSkU6nxACclPPQKBgFkb\nkVqg6YJKrjB90ZIYUY3/GzxzwLIaFumpCGretu6eIvkIhiokDExqeNBccuB+ych1\npZ7wrkzVMdjinythzFFEZQXlSdjtlhC9Cj52Bp92GoMV6EmbVwMDIPlVuNvsat3N\n3WFDV+ML5IryNVUD3gVnX/pBgyrDRsnw7VRiRGbZAoGBANxZwGKZo0zpyb5O5hS6\nxVrgJtIySlV5BOEjFXKeLwzByht8HmrHhSWix6WpPejfK1RHhl3boU6t9yeC0cre\nvUI/Y9LBhHXjSwWCWlqVe9yYqsde+xf0UYRS8IoaoJjus7YVJr9yPpCboEF28ZmQ\ndVBlpZYg6oLIar6waaLMz/1B\n-----END PRIVATE KEY-----\n", "client_email": "demo-app-account@demo-app-374914.iam.gserviceaccount.com", "client_id": "111111116847110173051", "auth_uri": "https://accounts.google.com/o/oauth2/auth", diff --git a/spec/fixtures/structure.sql b/spec/fixtures/structure.sql index 800c33bb9b9..5a7deb4fadf 100644 --- a/spec/fixtures/structure.sql +++ b/spec/fixtures/structure.sql @@ -13,12 +13,81 @@ CREATE INDEX index_users_on_public_email_excluding_null_and_empty ON users USING ALTER TABLE ONLY bulk_import_configurations ADD CONSTRAINT fk_rails_536b96bff1 FOREIGN KEY (bulk_import_id) REFERENCES bulk_imports(id) ON DELETE CASCADE; +CREATE TABLE test_table ( + id bigint NOT NULL, + integer_column integer, + integer_with_default_column integer DEFAULT 1, + smallint_column smallint, + smallint_with_default_column smallint DEFAULT 0 NOT NULL, + numeric_column numeric NOT NULL, + numeric_with_default_column numeric DEFAULT 1.0 NOT NULL, + boolean_colum boolean, + boolean_with_default_colum boolean DEFAULT true NOT NULL, + double_precision_column double precision, + double_precision_with_default_column double precision DEFAULT 1.0, + varying_column character varying, + varying_with_default_column character varying DEFAULT 'DEFAULT'::character varying NOT NULL, + varying_with_limit_column character varying(255), + varying_with_limit_and_default_column character varying(255) DEFAULT 'DEFAULT'::character varying, + text_column text NOT NULL, + text_with_default_column text DEFAULT ''::text NOT NULL, + array_column character varying(255)[] NOT NULL, + array_with_default_column character varying(255)[] DEFAULT '{one,two}'::character varying[] NOT NULL, + jsonb_column jsonb, + jsonb_with_default_column jsonb DEFAULT '[]'::jsonb NOT NULL, + timestamptz_column timestamp with time zone, + timestamptz_with_default_column timestamp(6) with time zone DEFAULT now(), + timestamp_column timestamp(6) without time zone NOT NULL, + timestamp_with_default_column timestamp(6) without time zone DEFAULT '2022-01-23 00:00:00+00'::timestamp without time zone NOT NULL, + date_column date, + date_with_default_column date DEFAULT '2023-04-05', + inet_column inet NOT NULL, + inet_with_default_column inet DEFAULT '0.0.0.0'::inet NOT NULL, + macaddr_column macaddr, + macaddr_with_default_column macaddr DEFAULT '00-00-00-00-00-000'::macaddr NOT NULL, + uuid_column uuid NOT NULL, + uuid_with_default_column uuid DEFAULT '00000000-0000-0000-0000-000000000000'::uuid NOT NULL, + bytea_column bytea, + bytea_with_default_column bytea DEFAULT '\xDEADBEEF'::bytea, + unmapped_column_type anyarray +); + CREATE TABLE ci_project_mirrors ( id bigint NOT NULL, project_id integer NOT NULL, namespace_id integer NOT NULL ); +CREATE TABLE wrong_table ( + id bigint NOT NULL, + description character varying(255) NOT NULL +); + +CREATE TABLE extra_table_columns ( + id bigint NOT NULL, + name character varying(255) NOT NULL +); + +CREATE TABLE missing_table ( + id bigint NOT NULL, + description text NOT NULL +); + +CREATE TABLE missing_table_columns ( + id bigint NOT NULL, + email character varying(255) NOT NULL +); + +CREATE TABLE operations_user_lists ( + id bigint NOT NULL, + project_id bigint NOT NULL, + created_at timestamp with time zone NOT NULL, + updated_at timestamp with time zone NOT NULL, + iid integer NOT NULL, + name character varying(255) NOT NULL, + user_xids text DEFAULT ''::text NOT NULL +); + CREATE TRIGGER trigger AFTER INSERT ON public.t1 FOR EACH ROW EXECUTE FUNCTION t1(); CREATE TRIGGER wrong_trigger BEFORE UPDATE ON public.t2 FOR EACH ROW EXECUTE FUNCTION my_function(); |