From afb19629532f75c8a92b66bc7f92a9752c561c14 Mon Sep 17 00:00:00 2001 From: Noah Date: Fri, 17 May 2024 20:37:59 +0000 Subject: [PATCH] Squashed commit of the following MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit commit a06c8cba Author: Noah Paige Date: Fri May 17 2024 16:37:05 GMT-0400 (Eastern Daylight Time) Merge share logs PR commit aee98cf7 Author: Noah Paige Date: Fri May 17 2024 16:34:24 GMT-0400 (Eastern Daylight Time) Merge share logs PR commit 5ca55303 Author: Sofia Sazonova Date: Wed May 15 2024 11:57:41 GMT-0400 (Eastern Daylight Time) remove unused imports commit 8f8bf3dd Author: Sofia Sazonova Date: Wed May 15 2024 11:56:39 GMT-0400 (Eastern Daylight Time) restrict access to the share logs commit 9137da9b Author: Sofia Sazonova Date: Wed May 15 2024 11:28:32 GMT-0400 (Eastern Daylight Time) share Logs button is available only for dataset Admins and stewards commit fcb16bd9 Author: Sofia Sazonova Date: Wed May 15 2024 10:46:25 GMT-0400 (Eastern Daylight Time) getShareLogs query commit 0503a3bb Author: Sofia Sazonova Date: Wed May 15 2024 10:21:25 GMT-0400 (Eastern Daylight Time) Logs modal in Share View commit bab2f3e6 Author: Sofia Sazonova Date: Mon May 13 2024 09:09:18 GMT-0400 (Eastern Daylight Time) Add confirmation pop-ups for deletion of team roles and groups (#1231) ### Feature or Bugfix - Feature ### Detail Pop ups added for: - deletion team from environment - deletion of the consumption role - deletion of group from Organization ### Relates - #942 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. Co-authored-by: Sofia Sazonova commit 93ff7725 Author: Sofia Sazonova Date: Mon May 13 2024 08:00:38 GMT-0400 (Eastern Daylight Time) Update version.json (#1264) Release info update commit e718d861 Author: Sofia Sazonova Date: Mon May 13 2024 07:29:27 GMT-0400 (Eastern Daylight Time) fix permission query (#1263) ### Feature or Bugfix - Bugfix ### Detail - The filter -- array of permissions' NAMES, so in order to query policies correctly we need to add join - The filter 'share_type' and 'share_item_status' must be string - IMPORTANT: in block "finally" the param session was used, but session was defined only in "try" block. So, the lock failed to be released. ### Relates - ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Sofia Sazonova commit 479b8f3f Author: mourya-33 <134511711+mourya-33@users.noreply.github.com> Date: Wed May 08 2024 10:29:36 GMT-0400 (Eastern Daylight Time) Add encryption and tag immutability to ECR repository (#1224) ### Feature or Bugfix - Bugfix ### Detail - Currently the ecr repository created do not have encryption and tag immutability enabled which is identified by checkov scans. This fix is to enable both. ### Relates [- ](https://github.com/data-dot-all/dataall/issues/1200) ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes N/A - Is the input sanitized? N/A - What precautions are you taking before deserializing the data you consume? N/A - Is injection prevented by parametrizing queries? N/A - Have you ensured no `eval` or similar functions are used? N/A - Does this PR introduce any functionality or component that requires authorization? N/A - How have you ensured it respects the existing AuthN/AuthZ mechanisms? N/A - Are you logging failed auth attempts? N/A - Are you using or adding any cryptographic features? N/A - Do you use a standard proven implementations? N/A - Are the used keys controlled by the customer? Where are they stored? No. This is with default encryption - Are you introducing any new policies/roles/users? N/A - Have you used the least-privilege principle? How? N/A By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 2f885773 Author: Sofia Sazonova Date: Wed May 08 2024 09:22:40 GMT-0400 (Eastern Daylight Time) Multiple permission roots (#1259) ### Feature or Bugfix - Bugfix ### Detail - GET_DATASET_TABLE (FOLDER) permissions are granted to the group only if they are not granted already - these permissions are removed if group is not admin|steward and there are no other shares of this item. ### Relates - #1174 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Sofia Sazonova commit c4cc07ee Author: Petros Kalos Date: Wed May 08 2024 08:54:02 GMT-0400 (Eastern Daylight Time) explicitly specify dataset_client s3 endpoint_url (#1260) * AWS requires that the endpoint_url should be explicitly specified for some regions * Remove misleading CORS error message, the upload step can fail for many reason ### Feature or Bugfix - Bugfix ### Detail Resolves #778 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 40defe8e Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Tue May 07 2024 11:52:17 GMT-0400 (Eastern Daylight Time) Generic dataset module and specific s3_datasets module - part 1 (Rename datasets as s3_datasets) (#1250) ### Feature or Bugfix - Refactoring ### Detail - Rename `datasets` module to `s3_datasets` module This PR is the first step to extract a generic datasets_base module that implements the undifferentiated concepts of Dataset in data.all. s3_datasets will use this base module to implement the specific implementation for S3 datatasets. ### Relates - #1123 - #955 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 74a303cb Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue May 07 2024 02:26:09 GMT-0400 (Eastern Daylight Time) Bump werkzeug from 3.0.1 to 3.0.3 in /tests (#1253) Bumps [werkzeug](https://github.com/pallets/werkzeug) from 3.0.1 to 3.0.3.
Release notes

Sourced from werkzeug's releases.

3.0.3

This is the Werkzeug 3.0.3 security release, which fixes security issues and bugs but does not otherwise change behavior and should not result in breaking changes.

PyPI: https://pypi.org/project/Werkzeug/3.0.3/ Changes: https://werkzeug.palletsprojects.com/en/3.0.x/changes/#version-3-0-3 Milestone: https://github.com/pallets/werkzeug/milestone/35?closed=1

  • Only allow localhost, .localhost, 127.0.0.1, or the specified hostname when running the dev server, to make debugger requests. Additional hosts can be added by using the debugger middleware directly. The debugger UI makes requests using the full URL rather than only the path. GHSA-2g68-c3qc-8985
  • Make reloader more robust when "" is in sys.path. #2823
  • Better TLS cert format with adhoc dev certs. #2891
  • Inform Python < 3.12 how to handle itms-services URIs correctly, rather than using an overly-broad workaround in Werkzeug that caused some redirect URIs to be passed on without encoding. #2828
  • Type annotation for Rule.endpoint and other uses of endpoint is Any. #2836

3.0.2

This is a fix release for the 3.0.x feature branch.

Changelog

Sourced from werkzeug's changelog.

Version 3.0.3

Released 2024-05-05

  • Only allow localhost, .localhost, 127.0.0.1, or the specified hostname when running the dev server, to make debugger requests. Additional hosts can be added by using the debugger middleware directly. The debugger UI makes requests using the full URL rather than only the path. :ghsa:2g68-c3qc-8985

  • Make reloader more robust when "" is in sys.path. :pr:2823

  • Better TLS cert format with adhoc dev certs. :pr:2891

  • Inform Python < 3.12 how to handle itms-services URIs correctly, rather than using an overly-broad workaround in Werkzeug that caused some redirect URIs to be passed on without encoding. :issue:2828

  • Type annotation for Rule.endpoint and other uses of endpoint is Any. :issue:2836

  • Make reloader more robust when "" is in sys.path. :pr:2823

Version 3.0.2

Released 2024-04-01

  • Ensure setting merge_slashes to False results in NotFound for repeated-slash requests against single slash routes. :issue:2834
  • Fix handling of TypeError in TypeConversionDict.get() to match ValueError. :issue:2843
  • Fix response_wrapper type check in test client. :issue:2831
  • Make the return type of MultiPartParser.parse more precise. :issue:2840
  • Raise an error if converter arguments cannot be parsed. :issue:2822
Commits
  • f9995e9 release version 3.0.3
  • 3386395 Merge pull request from GHSA-2g68-c3qc-8985
  • 890b6b6 only require trusted host for evalex
  • 71b69df restrict debugger trusted hosts
  • d2d3869 endpoint type is Any (#2895)
  • 7080b55 endpoint type is Any
  • 7555eff remove iri_to_uri redirect workaround (#2894)
  • 97fb2f7 remove _invalid_iri_to_uri workaround
  • 249527f make cn field a valid single hostname, and use wildcard in SANs field. (#2892)
  • 793be47 update adhoc tls dev cert format
  • Additional commits viewable in compare view

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=werkzeug&package-manager=pip&previous-version=3.0.1&new-version=3.0.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) ---
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/data-dot-all/dataall/network/alerts).
Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> commit 2f33320c Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue May 07 2024 02:25:03 GMT-0400 (Eastern Daylight Time) Bump werkzeug from 3.0.1 to 3.0.3 in /backend/dataall/base/cdkproxy (#1252) Bumps [werkzeug](https://github.com/pallets/werkzeug) from 3.0.1 to 3.0.3.
Release notes

Sourced from werkzeug's releases.

3.0.3

This is the Werkzeug 3.0.3 security release, which fixes security issues and bugs but does not otherwise change behavior and should not result in breaking changes.

PyPI: https://pypi.org/project/Werkzeug/3.0.3/ Changes: https://werkzeug.palletsprojects.com/en/3.0.x/changes/#version-3-0-3 Milestone: https://github.com/pallets/werkzeug/milestone/35?closed=1

  • Only allow localhost, .localhost, 127.0.0.1, or the specified hostname when running the dev server, to make debugger requests. Additional hosts can be added by using the debugger middleware directly. The debugger UI makes requests using the full URL rather than only the path. GHSA-2g68-c3qc-8985
  • Make reloader more robust when "" is in sys.path. #2823
  • Better TLS cert format with adhoc dev certs. #2891
  • Inform Python < 3.12 how to handle itms-services URIs correctly, rather than using an overly-broad workaround in Werkzeug that caused some redirect URIs to be passed on without encoding. #2828
  • Type annotation for Rule.endpoint and other uses of endpoint is Any. #2836

3.0.2

This is a fix release for the 3.0.x feature branch.

Changelog

Sourced from werkzeug's changelog.

Version 3.0.3

Released 2024-05-05

  • Only allow localhost, .localhost, 127.0.0.1, or the specified hostname when running the dev server, to make debugger requests. Additional hosts can be added by using the debugger middleware directly. The debugger UI makes requests using the full URL rather than only the path. :ghsa:2g68-c3qc-8985

  • Make reloader more robust when "" is in sys.path. :pr:2823

  • Better TLS cert format with adhoc dev certs. :pr:2891

  • Inform Python < 3.12 how to handle itms-services URIs correctly, rather than using an overly-broad workaround in Werkzeug that caused some redirect URIs to be passed on without encoding. :issue:2828

  • Type annotation for Rule.endpoint and other uses of endpoint is Any. :issue:2836

  • Make reloader more robust when "" is in sys.path. :pr:2823

Version 3.0.2

Released 2024-04-01

  • Ensure setting merge_slashes to False results in NotFound for repeated-slash requests against single slash routes. :issue:2834
  • Fix handling of TypeError in TypeConversionDict.get() to match ValueError. :issue:2843
  • Fix response_wrapper type check in test client. :issue:2831
  • Make the return type of MultiPartParser.parse more precise. :issue:2840
  • Raise an error if converter arguments cannot be parsed. :issue:2822
Commits
  • f9995e9 release version 3.0.3
  • 3386395 Merge pull request from GHSA-2g68-c3qc-8985
  • 890b6b6 only require trusted host for evalex
  • 71b69df restrict debugger trusted hosts
  • d2d3869 endpoint type is Any (#2895)
  • 7080b55 endpoint type is Any
  • 7555eff remove iri_to_uri redirect workaround (#2894)
  • 97fb2f7 remove _invalid_iri_to_uri workaround
  • 249527f make cn field a valid single hostname, and use wildcard in SANs field. (#2892)
  • 793be47 update adhoc tls dev cert format
  • Additional commits viewable in compare view

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=werkzeug&package-manager=pip&previous-version=3.0.1&new-version=3.0.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) ---
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/data-dot-all/dataall/network/alerts).
Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> commit 0b49633f Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue May 07 2024 02:24:34 GMT-0400 (Eastern Daylight Time) Bump werkzeug from 3.0.1 to 3.0.3 in /tests_new/integration_tests (#1254) Bumps [werkzeug](https://github.com/pallets/werkzeug) from 3.0.1 to 3.0.3.
Release notes

Sourced from werkzeug's releases.

3.0.3

This is the Werkzeug 3.0.3 security release, which fixes security issues and bugs but does not otherwise change behavior and should not result in breaking changes.

PyPI: https://pypi.org/project/Werkzeug/3.0.3/ Changes: https://werkzeug.palletsprojects.com/en/3.0.x/changes/#version-3-0-3 Milestone: https://github.com/pallets/werkzeug/milestone/35?closed=1

  • Only allow localhost, .localhost, 127.0.0.1, or the specified hostname when running the dev server, to make debugger requests. Additional hosts can be added by using the debugger middleware directly. The debugger UI makes requests using the full URL rather than only the path. GHSA-2g68-c3qc-8985
  • Make reloader more robust when "" is in sys.path. #2823
  • Better TLS cert format with adhoc dev certs. #2891
  • Inform Python < 3.12 how to handle itms-services URIs correctly, rather than using an overly-broad workaround in Werkzeug that caused some redirect URIs to be passed on without encoding. #2828
  • Type annotation for Rule.endpoint and other uses of endpoint is Any. #2836

3.0.2

This is a fix release for the 3.0.x feature branch.

Changelog

Sourced from werkzeug's changelog.

Version 3.0.3

Released 2024-05-05

  • Only allow localhost, .localhost, 127.0.0.1, or the specified hostname when running the dev server, to make debugger requests. Additional hosts can be added by using the debugger middleware directly. The debugger UI makes requests using the full URL rather than only the path. :ghsa:2g68-c3qc-8985

  • Make reloader more robust when "" is in sys.path. :pr:2823

  • Better TLS cert format with adhoc dev certs. :pr:2891

  • Inform Python < 3.12 how to handle itms-services URIs correctly, rather than using an overly-broad workaround in Werkzeug that caused some redirect URIs to be passed on without encoding. :issue:2828

  • Type annotation for Rule.endpoint and other uses of endpoint is Any. :issue:2836

  • Make reloader more robust when "" is in sys.path. :pr:2823

Version 3.0.2

Released 2024-04-01

  • Ensure setting merge_slashes to False results in NotFound for repeated-slash requests against single slash routes. :issue:2834
  • Fix handling of TypeError in TypeConversionDict.get() to match ValueError. :issue:2843
  • Fix response_wrapper type check in test client. :issue:2831
  • Make the return type of MultiPartParser.parse more precise. :issue:2840
  • Raise an error if converter arguments cannot be parsed. :issue:2822
Commits
  • f9995e9 release version 3.0.3
  • 3386395 Merge pull request from GHSA-2g68-c3qc-8985
  • 890b6b6 only require trusted host for evalex
  • 71b69df restrict debugger trusted hosts
  • d2d3869 endpoint type is Any (#2895)
  • 7080b55 endpoint type is Any
  • 7555eff remove iri_to_uri redirect workaround (#2894)
  • 97fb2f7 remove _invalid_iri_to_uri workaround
  • 249527f make cn field a valid single hostname, and use wildcard in SANs field. (#2892)
  • 793be47 update adhoc tls dev cert format
  • Additional commits viewable in compare view

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=werkzeug&package-manager=pip&previous-version=3.0.1&new-version=3.0.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) ---
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/data-dot-all/dataall/network/alerts).
Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> commit 08862420 Author: mourya-33 <134511711+mourya-33@users.noreply.github.com> Date: Tue May 07 2024 02:15:15 GMT-0400 (Eastern Daylight Time) Updated lambda_api.py to add encryption for lambda env vars for custo… (#1255) Feature or Bugfix Bugfix Detail The environment variables for the lambda functions are not encrypted in cdk which are identified by checkov scans. This fix is to enable kms encryption for the lambda environment variables. Relates Security Please answer the questions below briefly where applicable, or write N/A. Based on [OWASP 10](https://owasp.org/Top10/en/). Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? N/A Is the input sanitized? N/A What precautions are you taking before deserializing the data you consume? N/A Is injection prevented by parametrizing queries? N/A Have you ensured no eval or similar functions are used? N/A Does this PR introduce any functionality or component that requires authorization? N/A How have you ensured it respects the existing AuthN/AuthZ mechanisms? N/A Are you logging failed auth attempts? N/A Are you using or adding any cryptographic features? N/A Do you use a standard proven implementations? N/A Are the used keys controlled by the customer? Where are they stored? the KMS keys are generated by cdk and are used to encrypt the environment variables for all lambda functions in the lambda-api stack Are you introducing any new policies/roles/users? - N/A Have you used the least-privilege principle? How? N/A By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit ed7cc3eb Author: Noah Paige <69586985+noah-paige@users.noreply.github.com> Date: Mon May 06 2024 09:32:30 GMT-0400 (Eastern Daylight Time) Add order_by for paginated queries (#1249) ### Feature or Bugfix - Bugfix ### Detail - This PR aims to solve the following - (1) for particular queries (identified as ones that perform `.outerjoin()` operations and have results paginated with `paginate()` function - sometimes the returned query results is *less than* the limit set by the pageSize of the paginate function even when the total count is greater than the pageSize - Ex 1: 11 envs total, `query_user_environments()` returning 9 envs on 1st page + 2 on 2nd page - Ex 2: 10 envs total, `query_user_environments()` returning 9 envs on 1st page + no 2nd page - Believe this is to be happening due to the way SQLAlchemy is "uniquing" the records resulted from an outerjoin and then returning that result back to the frontend - Adding a `.distinct()` check on the query ensures each distinct record is returned (tested successfully) - (2) Currently we often times do not implement an `.order_by()` condition for the query used in `paginate()` and do not have a stable way of preserving order of the items returned from a query (i.e. when navigating through pages of response) - A generally good practice seems to include an `order_by()` on a column or set of columns - For each query used in `paginate()` this PR adds an `order_by()` condition (full list in comments below) Can read a bit more context from related issue linked below ### Relates - https://github.com/data-dot-all/dataall/issues/1241 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 98e67fa8 Author: Sofia Sazonova Date: Fri May 03 2024 12:21:57 GMT-0400 (Eastern Daylight Time) fix: DATASET_READ_TABLE read permissions (#1237) ### Feature or Bugfix - Bugfix ### Detail - backfill DATASET_READ_TABLE permissions - delete this permissions, when dataset tables are revoked or deteled - ### Relates - #1173 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Sofia Sazonova commit 18e2f509 Author: Noah Paige <69586985+noah-paige@users.noreply.github.com> Date: Fri May 03 2024 10:14:52 GMT-0400 (Eastern Daylight Time) Fix local test groups listing for listGroups query (#1239) ### Feature or Bugfix - Bugfix ### Detail - Locally when trying to invite a team to Env or Org we call listGroups and the returned `LOCAL_TEST_GROUPS` is not returning the proper data type expected ### Relates N/A ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit a0be03c4 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Fri May 03 2024 10:12:34 GMT-0400 (Eastern Daylight Time) Refactor: uncouple datasets and dataset_sharing modules - part 2-5 FINAL DELETE DATASETS_BASE (#1242) ### Feature or Bugfix - Refactoring ### Detail After all the previous PRs are merged, there should be no circular dependencies between `datasets` and `datasets_sharing`. We can now proceed to: - move `datasets_base` models, repositories, permissions and enums to `datasets` - adjust the `__init__` files to establish the `datasets_sharing` depends on `datasets` - adjust the Module interfaces to ensure that all necessary dataset models... are imported in the interface for sharing Next steps: - share_notifications paramter to dataset_sharing in config.json ### Relates #955 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit b68b40c1 Author: Sofia Sazonova Date: Fri May 03 2024 10:12:11 GMT-0400 (Eastern Daylight Time) bugfix: EnvironmentGroup can remove other groups (#1234) ### Feature or Bugfix - Bugfix ### Detail - Now, if the group can't update other group, it also can not remove them. - ### Relates - #1212 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Sofia Sazonova commit 264539b5 Author: Noah Paige <69586985+noah-paige@users.noreply.github.com> Date: Fri May 03 2024 05:23:11 GMT-0400 (Eastern Daylight Time) Fix Alembic Migration: has table checks (#1240) ### Feature or Bugfix - Bugfix ### Detail - Fix `has_table()` check to ensure dropping the tables if the exists as part of alembic migration upgrade - Fix `DatasetLock nullable=True` ### Relates - https://github.com/data-dot-all/dataall/issues/1165 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? No - Is the input sanitized? N/A - What precautions are you taking before deserializing the data you consume? N/A - Is injection prevented by parametrizing queries? N/A - Have you ensured no `eval` or similar functions are used? N/A - Does this PR introduce any functionality or component that requires authorization? No - How have you ensured it respects the existing AuthN/AuthZ mechanisms? N/A - Are you logging failed auth attempts? N/A - Are you using or adding any cryptographic features? No - Do you use a standard proven implementations? N/A - Are the used keys controlled by the customer? Where are they stored? N/A - Are you introducing any new policies/roles/users? No - Have you used the least-privilege principle? How? N/A By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 42a5f6bd Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Fri May 03 2024 02:24:09 GMT-0400 (Eastern Daylight Time) Refactor: uncouple datasets and dataset_sharing modules - part 2-4 (#1214) ### Feature or Bugfix - Refactoring ⚠️ MERGE AFTER https://github.com/data-dot-all/dataall/pull/1213 ### Detail This is needed as explained in full PR [AFTER 2.4] Refactor: uncouple datasets and dataset_sharing modules #1179 - [X] Use interface to resolve dataset roles related to datasets shared and implement logic in the dataset_sharing module - [X] Extend and clean-up stewards share permissions through interface ### Relates - #1179 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 6d3f2d45 Author: Sofia Sazonova Date: Thu May 02 2024 10:55:00 GMT-0400 (Eastern Daylight Time) [After 2.4]Core Refactoring part5 (#1194) ### Feature or Bugfix - Refactoring ### Detail - focus on core/environments - move logic from resolvers to services - create s3_client in base/aws --> TO BE REFACTORED. Needs to be merged with dataset_sharind/aws/s3_client ### Relates - #741 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Sofia Sazonova commit 2ea24cbb Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Thu May 02 2024 08:22:12 GMT-0400 (Eastern Daylight Time) Refactor: uncouple datasets and dataset_sharing modules - part 2-3 (#1213) ### Feature or Bugfix - Refactoring ⚠️ MERGE AFTER https://github.com/data-dot-all/dataall/pull/1187 ### Detail This is needed as explained in full PR [AFTER 2.4] Refactor: uncouple datasets and dataset_sharing modules #1179 - [X] Creates an interface to execute checks and clean-ups of data sharing objects when dataset objects are deleted (initially it was going to be an db interface, but I think it is better in the service) - [X] Move listDatasetShares query to dataset_sharing module in https://github.com/data-dot-all/dataall/pull/1185 ### Relates - #1179 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 750a5ec8 Author: Anushka Singh Date: Wed May 01 2024 12:28:18 GMT-0400 (Eastern Daylight Time) Feature:1221 - Make visibility of auto-approval toggle configurable based on confidentiality (#1223) ### Feature or Bugfix - Feature ### Detail - Users should be able to disable visibility of auto-approval toggle with code. For example, at our company, we require that shares always go through approval process if their confidentiality classification is Secret. We dont even want to give the option to users to be able to set autoApproval enabled to ensure they dont do so by mistake and end up over sharing. Video demo: https://github.com/data-dot-all/dataall/issues/1221#issuecomment-2077412044 ### Relates - https://github.com/data-dot-all/dataall/issues/1221 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 82044689 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Wed May 01 2024 12:26:42 GMT-0400 (Eastern Daylight Time) Refactor: uncouple datasets and dataset_sharing modules - part 2-2 (#1187) ### Feature or Bugfix - Refactoring ⚠️ MERGE AFTER https://github.com/data-dot-all/dataall/pull/1185 ### Detail This is needed as explained in full PR [AFTER 2.4] Refactor: uncouple datasets and dataset_sharing modules #1179 - Split the getDatasetAssumeRole API into 2 APIs, one for dataset owners role (in datasets module) and another one for share requester roles (in datasets_sharing module) ### Relates - #1179 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 5173419f Author: Noah Paige <69586985+noah-paige@users.noreply.github.com> Date: Wed May 01 2024 12:24:42 GMT-0400 (Eastern Daylight Time) Fix so listValidEnvironments called only once (#1238) ### Feature or Bugfix - Bugfix ### Detail - When request access to a share on data.all the query to `listValidEnvironments` used to be called twice which (depending on how long for query results to return) could cause the environment initially selected to disappear ### Relates - Continuation of https://github.com/data-dot-all/dataall/issues/916 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 7656ea86 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Tue Apr 30 2024 07:13:01 GMT-0400 (Eastern Daylight Time) Add integration tests on a real API client and integrate the tests in CICD (#1219) ### Feature or Bugfix - Feature ### Detail Add integration tests that use a real Client to execute different validation actions. - Define the Client and the way API calls are posted to API Gateway in the conftest - Define the Cognito users and the different fixtures needed for all tests - Write tests for the Organization core module as example - Add feature flag in `cdk.json` called `with_approval_tests` that can be defined at the deployment environment level. If set to True, a CodeBuild stage running the tests is created. ### Relates - https://github.com/data-dot-all/dataall/issues/1220 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit b963fe81 Author: Sofia Sazonova Date: Mon Apr 29 2024 09:26:36 GMT-0400 (Eastern Daylight Time) Notification link routes to a share request page (#1227) ### Feature or Bugfix - Feature ### Detail - in notification object field `target_uri = 'shareUri|DataSetUri'` - this value is parsed and used to redirect user to a relevant Share Request page ### Relates - #1115 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. Co-authored-by: Sofia Sazonova commit 6386fe14 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Mon Apr 29 2024 07:32:00 GMT-0400 (Eastern Daylight Time) Refactor: uncouple datasets and dataset_sharing modules - part 2 (#1185) ### Feature or Bugfix - Refactoring ### Detail Remove and move logic from dataset to datasets_sharing module. This is needed as explained in full PR [AFTER 2.4] Refactor: uncouple datasets and dataset_sharing modules #1179 - [X] Moves the verify dataset shares mutation to the datasets_sharing module - [X] Move dataset_subscription task to dataset_sharing - [X] Move listDatasetShares query to dataset_sharing module - [X] Remove unused `shares` field from the Dataset graphql type as it was not used in the frontend: listDatasets, listOwnedDatasets, listDatasetsOwnedByEnvGroup, listDatasetsCreatedInEnvironment and getDataset - [x] Move getSharedDatasetTables to data_sharing module and fix reference to DatasetService I am aware that some of the queries and mutations that this PR moves look a bit odd in the dataset_sharing module, but this will be solved once data sharing is divided into dataset_sharing_base and s3_dataset_sharing. ### Relates #1179 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit d7a95180 Author: mourya-33 <134511711+mourya-33@users.noreply.github.com> Date: Mon Apr 29 2024 07:21:54 GMT-0400 (Eastern Daylight Time) Enable encryption for lambda environment variables (#1225) ### Feature or Bugfix - Bugfix ### Detail - The environment variables for the lambda functions are not encrypted in cdk which are identified by checkov scans. This fix is to enable kms encryption for the lambda environment variables. ### Relates - [ ](https://github.com/data-dot-all/dataall/issues/1201) ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? N/A - Is the input sanitized? N/A - What precautions are you taking before deserializing the data you consume? N/A - Is injection prevented by parametrizing queries? N/A - Have you ensured no `eval` or similar functions are used? N/A - Does this PR introduce any functionality or component that requires authorization? N/A - How have you ensured it respects the existing AuthN/AuthZ mechanisms? N/A - Are you logging failed auth attempts? N/A - Are you using or adding any cryptographic features? N/A - Do you use a standard proven implementations? N/A - Are the used keys controlled by the customer? Where are they stored? the KMS keys are generated by cdk and are used to encrypt the environment variables for all lambda functions in the lambda-api stack - Are you introducing any new policies/roles/users? - N/A - Have you used the least-privilege principle? How? N/A By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit ca44e49f Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Mon Apr 29 2024 02:10:57 GMT-0400 (Eastern Daylight Time) Refactor: uncouple datasets and dataset_sharing modules - part 3 (#1186) ### Feature or Bugfix - Refactoring ### Detail Remove and move logic from dataset to datasets_sharing module. This is needed as explained in full PR [AFTER 2.4] Refactor: uncouple datasets and dataset_sharing modules https://github.com/data-dot-all/dataall/pull/1179 - [X] Split the KMS client and create one dedicated KMS client for datasets ### Relates https://github.com/data-dot-all/dataall/pull/1179 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). `N/A` - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit e691b0e2 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Fri Apr 26 2024 07:13:11 GMT-0400 (Eastern Daylight Time) Refactor: uncouple datasets and dataset_sharing modules - part 1 (#1184) ### Feature or Bugfix - Refactoring ### Detail - Split the DatasetAlarm service into the alarms related to datasets and those related to sharing. This is needed as explained in full PR #1179 ### Relates - #1179 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). `N/A` - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit e15df15a Author: Sofia Sazonova Date: Thu Apr 25 2024 11:34:26 GMT-0400 (Eastern Daylight Time) Profiling job fix (#1222) ### Feature or Bugfix - Bugfix ### Detail - ColumnProfilerRunner must be imported from pydeequ.profiles - Workaround about missing SPARK_VERSION ### Relates - #1216 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. Co-authored-by: Sofia Sazonova commit 5df61006 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Thu Apr 25 2024 08:51:25 GMT-0400 (Eastern Daylight Time) Update version to 2.4 (#1193) ### Feature or Bugfix - Feature ### Detail PR to be merged right before releasing 2.4.0. It updates the version in the repository. ### Relates Release 2.4.0 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 083272cf Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Thu Apr 25 2024 08:14:32 GMT-0400 (Eastern Daylight Time) Documentation in userguide for release 2.4 (#1218) ### Feature or Bugfix Documentation ### Detail Explaining some changes for multiple environments in same account ### Relates #1203 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 652fe923 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Tue Apr 23 2024 11:29:26 GMT-0400 (Eastern Daylight Time) Fix: sagemaker tagging permissions (#1211) ### Feature or Bugfix - Bugfix ### Detail - Fix value of key-value conditions for tags in SageMaker - Add permissions for tags coming from creation of resources in sagemaker: https://docs.aws.amazon.com/sagemaker/latest/dg/security_iam_id-based-policy-examples.html#access-tag-policy ### Relates - #1208 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit c68d2090 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Mon Apr 22 2024 11:20:40 GMT-0400 (Eastern Daylight Time) Fix reference to locationUri (#1209) ### Feature or Bugfix - Bugfix ### Detail This PR corrects the uri used to update the shared folders permissions. Instead of using the locationUri which is a field of StorageLocation objects, it uses the itemUri, which is a field of the ShareObjectItem object ### Relates - release 2.4 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit cf6f461c Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Mon Apr 22 2024 07:18:53 GMT-0400 (Eastern Daylight Time) Fix: unnecessary permission check in resolve_stack functions (failure in list datasets when there are shared datasets) (#1205) ### Feature or Bugfix - Bugfix ### Detail The function `get_stack_with_cfn_resources` from `StackService` is used to resolve the CFN stack details of several stacks in data.all. It is a private function that is not used directly as resolver by any GraphQL query/mutation, so the permissions are checked indirectly by applying the permissions in the main API. Better with an example: API Query: `GetNotebook` (what we want) - 1. calls the service `get_notebook` decorated to check user `GET_NOTEBOOK` permissions on that Notebook1 - 2. calls `get_stack_with_cfn_resources` to resolve CFN details of the Notebook API Query: `GetNotebook` (what we currently have) - 1. calls the service `get_notebook` decorated to check user `GET_NOTEBOOK` permissions on that Notebook1 - 2. calls `get_stack_with_cfn_resources` - 3. inside `get_stack_with_cfn_resources` we call find_environment, which checks the `GET_ENVIRONMENT` permissions of the user In this PR I revert to pass the environmentUri instead of passing the environment. Instead of using the EnvironmentService, it uses the EnvironmentRepository ### Relates - https://github.com/data-dot-all/dataall/pull/1181/files ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 35f498aa Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Mon Apr 22 2024 04:38:40 GMT-0400 (Eastern Daylight Time) Fix missing $ in CDK custom policy (#1204) ### Feature or Bugfix - Bugfix ### Detail Add missing $ in parameter reference in CDK execution role custom policy CloudFormation template ### Relates - #1202 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 3f788038 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Fri Apr 19 2024 10:56:41 GMT-0400 (Eastern Daylight Time) Fix missing session in resolve_environment (#1199) ### Feature or Bugfix - Bugfix ### Detail `EnvironmentService.get_environment_by_uri` receives `session` and `environment_uri` as inputs. In one of the calls `session` was missing ### Relates - ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 96e8ee54 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Fri Apr 19 2024 06:12:44 GMT-0400 (Eastern Daylight Time) Fix: Remove creation of log-groups in Lambdas (#1192) ### Feature or Bugfix - Bugfix ### Detail In #1134 log groups are created explicitly for each Lambda in the backend, which results in errors when the log-groups do not exist. (see #1190 ) This PR removes the `log_group` parameter from the definition of the Lambdas. It reverts back to the previous (2.3) settings. Tested: on a fresh deployment, making sure that no log-groups were previously created, the stack creates the log-groups with the Lambda name. For example `/aws/lambda/--esproxy`. Update: we need to explicitly define the log groups to avoid the log retention lambdas and their roles and policies that CDK automatically creates. So to cope with existing groups and non-existing groups this PR adds a CfnCondition to the creation of the log-group ### Relates - #1134 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). `n/a` - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 8e157291 Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Fri Apr 19 2024 05:50:54 GMT-0400 (Eastern Daylight Time) Fix: Update CDK exec role Policy name with region in template (#1197) ### Feature or Bugfix - Feature ### Detail - Adds region as part of the policy name of the CDK exec role - Updates cdk bootstrap command accordingly Backwards compatibility. If not using multi-region, users won't notice any difference because their CDKToolkit will continue working as usual. - If at any moment they want to onboard a second environment in the same account, they can create the second environment using the new template without affecting the first cdkToolkit. - If they want to use the new template, they can just update their CDK Toolkit and the cdk exec role will be updated (new policy attached). Since no roles are deleted and re-created, users and existing resources (e.g. KMS keys...) won't be impacted. Testing: - [X] Creation of the stack DataallCustomExecRolePolicy stack + creation of CDKToolkit with this stack + creation of second environment ### Relates - #1196 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit 1f5e641f Author: dlpzx <71252798+dlpzx@users.noreply.github.com> Date: Fri Apr 19 2024 05:37:28 GMT-0400 (Eastern Daylight Time) Fix input parameters for get credentials get environment group (#1198) ### Feature or Bugfix - Bugfix ### Detail - fix order of parameters in function ### Relates ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit d4819ef5 Author: Sofia Sazonova Date: Tue Apr 16 2024 15:51:46 GMT-0400 (Eastern Daylight Time) Refactoring env stack part4 (#1181) ### Feature or Bugfix - Refactoring ### Detail - detangle StackRepository & StackService & EnvironmentService - Move logic from resolvers and repositories to services - Remove unused params ### Relates - #741 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Sofia Sazonova commit 356a8a7f Author: Petros Kalos Date: Tue Apr 16 2024 07:13:50 GMT-0400 (Eastern Daylight Time) run db migrations in a custom resource (#1177) ### Feature or Bugfix - Bugfix ### Detail Currently the DB is being initialised in the DBMigrations pipeline stage (using CodeBuild) which runs after the BackendStage. The SavePermissions TriggerFunction runs during the deployment of Backend, just after deployment of the DBCluster. As a result on clean deployments the SavePermissions step will fail because the DB is uninitialized. To resolve that in this PR we do the following * remove DBMigrations stage based on CodeBuild * run DBMigrations as part of a TriggerFunction/CustomResource after the DB deployment * run SavePermissions TriggerFunction after the DBMigrations TriggerFunction ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. commit b634b417 Author: Sofia Sazonova Date: Tue Apr 16 2024 06:27:23 GMT-0400 (Eastern Daylight Time) Refactor core/environment&stack module - part 3 (#1178) ### Feature or Bugfix - Refactoring ### Detail - Detangle stack_helper and Environment module ### Relates - #741 ### Security Please answer the questions below briefly where applicable, or write `N/A`. Based on [OWASP 10](https://owasp.org/Top10/en/). - Does this PR introduce or modify any input fields or queries - this includes fetching data from storage outside the application (e.g. a database, an S3 bucket)? - Is the input sanitized? - What precautions are you taking before deserializing the data you consume? - Is injection prevented by parametrizing queries? - Have you ensured no `eval` or similar functions are used? - Does this PR introduce any functionality or component that requires authorization? - How have you ensured it respects the existing AuthN/AuthZ mechanisms? - Are you logging failed auth attempts? - Are you using or adding any cryptographic features? - Do you use a standard proven implementations? - Are the used keys controlled by the customer? Where are they stored? - Are you introducing any new policies/roles/users? - Have you used the least-privilege principle? How? By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. --------- Co-authored-by: Sofia Sazonova --- Makefile | 2 +- UserGuide.pdf | Bin 20272831 -> 20622385 bytes .../modules/dataset_sharing/api/queries.py | 9 ++ .../modules/dataset_sharing/api/resolvers.py | 8 ++ .../modules/dataset_sharing/api/types.py | 16 +++ .../services/share_object_service.py | 65 ++++++++++ .../DeleteObjectWithFrictionModal.js | 1 + .../components/EnvironmentTeams.js | 46 +++++-- .../components/OrganizationTeams.js | 23 +++- .../modules/Shares/components/ShareLogs.js | 119 ++++++++++++++++++ .../modules/Shares/services/getShareObject.js | 1 + .../src/modules/Shares/views/ShareView.js | 29 +++++ .../graphql/ShareObject/getShareLogs.js | 15 +++ .../src/services/graphql/ShareObject/index.js | 1 + 14 files changed, 326 insertions(+), 9 deletions(-) create mode 100644 frontend/src/modules/Shares/components/ShareLogs.js create mode 100644 frontend/src/services/graphql/ShareObject/getShareLogs.js diff --git a/Makefile b/Makefile index 2dc6fd25a..9188d2d12 100644 --- a/Makefile +++ b/Makefile @@ -49,7 +49,7 @@ check-security: upgrade-pip install-backend install-cdkproxy pip install bandit pip install safety bandit -lll -r backend - safety check --ignore=51668 + safety check --ignore=51668,67599 test: export PYTHONPATH=./backend:/./tests && \ diff --git a/UserGuide.pdf b/UserGuide.pdf index 5c6e6319ec9ab39b728d39f689346021e8b45396..c55a267e0e9c7f58aec394c4f3c1fcc60358e5d0 100644 GIT binary patch delta 40002 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-Ld+f#7AD+R)%{GZ7Hb+y-B0zoJ)wAU&PFJ z+7}3P08-M{pWBn9^|#mDr(HDMYj2PjT551SY;U0RO7oCMtI?&%Td6jeY|+)q$r~-- zw#d7^;V;+8*FQx$4)SQ|7Wp_b!`tts8+ekD%Z5g$Fn{RU&x5i%mbes5Z*M{h^Sj(k zd+o3|Qt>@0t{SX^?ti(fc bool: role_name = share.principalIAMRoleName @@ -590,3 +603,55 @@ def attach_dataset_folder_read_permission(session, share): log.info( f'Resource permission policy {DATASET_FOLDER_READ} to table {location.itemUri} for group {share.groupUri} already exists. Skip... ' ) + + @staticmethod + def get_share_logs_name_query(shareUri): + log.info(f'Get share Logs stream name for share {shareUri}') + + query = """fields @logStream + |filter @message like 'bmm02skg' + | sort @timestamp desc + | limit 1 + """ + return query + + @staticmethod + def get_share_logs_query(log_stream_name): + query = f"""fields @timestamp, @message, @logStream, @log as @logGroup + | sort @timestamp asc + | filter @logStream like "{log_stream_name}" + """ + return query + + @staticmethod + def get_share_logs(shareUri): + context = get_context() + if not ShareObjectService.check_view_log_permissions(context.username, context.groups, shareUri): + raise exceptions.ResourceUnauthorized( + username=context.username, + action='view logs', + resource_uri=shareUri, + ) + + envname = os.getenv('envname', 'local') + log_group_name = f"/{Parameter().get_parameter(env=envname, path='resourcePrefix')}/{envname}/ecs/share-manager" + + query_for_name = ShareObjectService.get_share_logs_name_query(shareUri=shareUri) + name_query_result = CloudWatch.run_query( + query=query_for_name, + log_group_name=log_group_name, + days=1, + ) + if len(name_query_result) == 0: + return [] + + name = name_query_result[0]['logStream'] + + query = ShareObjectService.get_share_logs_query(log_stream_name=name) + results = CloudWatch.run_query( + query=query, + log_group_name=log_group_name, + days=1, + ) + log.info(f'Running Logs query {query} for log_group_name={log_group_name}') + return results diff --git a/frontend/src/design/components/DeleteObjectWithFrictionModal.js b/frontend/src/design/components/DeleteObjectWithFrictionModal.js index b7a610bdf..06f3c1449 100644 --- a/frontend/src/design/components/DeleteObjectWithFrictionModal.js +++ b/frontend/src/design/components/DeleteObjectWithFrictionModal.js @@ -29,6 +29,7 @@ export const DeleteObjectWithFrictionModal = (props) => { const handleChange = (event) => { setConfirmValue(event.target.value); }; + return ( diff --git a/frontend/src/modules/Environments/components/EnvironmentTeams.js b/frontend/src/modules/Environments/components/EnvironmentTeams.js index 52b2a3775..228fcbaea 100644 --- a/frontend/src/modules/Environments/components/EnvironmentTeams.js +++ b/frontend/src/modules/Environments/components/EnvironmentTeams.js @@ -34,6 +34,7 @@ import { HiUserRemove } from 'react-icons/hi'; import { VscChecklist } from 'react-icons/vsc'; import { Defaults, + DeleteObjectWithFrictionModal, Label, Pager, RefreshTableMenu, @@ -65,6 +66,16 @@ function TeamRow({ team, environment, fetchItems }) { const [accessingConsole, setAccessingConsole] = useState(false); const [loadingCreds, setLoadingCreds] = useState(false); const [isTeamEditModalOpen, setIsTeamEditModalOpen] = useState(false); + const [isDeleteTeamModalOpen, setIsDeleteTeamModalOpen] = useState(false); + + const handleDeleteTeamModalOpen = () => { + setIsDeleteTeamModalOpen(true); + }; + + const handleDeleteTeamModalClose = () => { + setIsDeleteTeamModalOpen(false); + }; + const handleTeamEditModalClose = () => { setIsTeamEditModalOpen(false); }; @@ -215,7 +226,7 @@ function TeamRow({ team, environment, fetchItems }) { )} {team.groupUri !== environment.SamlGroupName && ( - removeGroup(team.groupUri)}> + handleDeleteTeamModalOpen()}> )} + removeGroup(team.groupUri)} + /> ); @@ -252,6 +271,14 @@ export const EnvironmentTeams = ({ environment }) => { const [inputValueRoles, setInputValueRoles] = useState(''); const [isTeamInviteModalOpen, setIsTeamInviteModalOpen] = useState(false); const [isAddRoleModalOpen, setIsAddRoleModalOpen] = useState(false); + const [isDeleteRoleModalOpenId, setIsDeleteRoleModalOpen] = useState(0); + const handleDeleteRoleModalOpen = (id) => { + setIsDeleteRoleModalOpen(id); + }; + const handleDeleteRoleModalClosed = (id) => { + setIsDeleteRoleModalOpen(0); + }; + const handleTeamInviteModalOpen = () => { setIsTeamInviteModalOpen(true); }; @@ -424,10 +451,6 @@ export const EnvironmentTeams = ({ environment }) => { setRowModesModel({ ...rowModesModel, [id]: { mode: GridRowModes.View } }); }; - const handleDeleteClick = (id) => () => { - removeConsumptionRole(id); - }; - const handleCancelClick = (id) => () => { setRowModesModel({ ...rowModesModel, @@ -711,7 +734,8 @@ export const EnvironmentTeams = ({ environment }) => { flex: 0.5, type: 'actions', cellClassName: 'actions', - getActions: ({ id }) => { + getActions: ({ id, ...props }) => { + const name = props.row.consumptionRoleName; const isInEditMode = rowModesModel[id]?.mode === GridRowModes.Edit; @@ -745,8 +769,16 @@ export const EnvironmentTeams = ({ environment }) => { } label="Delete" - onClick={handleDeleteClick(id)} + onClick={() => handleDeleteRoleModalOpen(id)} color="inherit" + />, + handleDeleteRoleModalClosed(id)} + onClose={() => handleDeleteRoleModalClosed(id)} + open={isDeleteRoleModalOpenId === id} + isAWSResource={false} + deleteFunction={() => removeConsumptionRole(id)} /> ]; } diff --git a/frontend/src/modules/Organizations/components/OrganizationTeams.js b/frontend/src/modules/Organizations/components/OrganizationTeams.js index f4288c02f..2b7887ba8 100644 --- a/frontend/src/modules/Organizations/components/OrganizationTeams.js +++ b/frontend/src/modules/Organizations/components/OrganizationTeams.js @@ -26,6 +26,7 @@ import { HiUserRemove } from 'react-icons/hi'; import { VscChecklist } from 'react-icons/vsc'; import { Defaults, + DeleteObjectWithFrictionModal, Label, Pager, RefreshTableMenu, @@ -49,6 +50,16 @@ function TeamRow({ team, organization, fetchItems }) { const theme = useTheme(); const { enqueueSnackbar } = useSnackbar(); const [isPermissionModalOpen, setIsPermissionsModalOpen] = useState(false); + const [isDeleteGroupModalOpen, setIsDeleteGroupModalOpenId] = useState(false); + + const handleDeleteGroupModalClosed = () => { + setIsDeleteGroupModalOpenId(false); + }; + + const handleDeleteGroupModalOpen = () => { + setIsDeleteGroupModalOpenId(true); + }; + const handlePermissionsModalClose = () => { setIsPermissionsModalOpen(false); }; @@ -125,7 +136,7 @@ function TeamRow({ team, organization, fetchItems }) { {team.groupUri !== organization.SamlGroupName && ( - removeGroup(team.groupUri)}> + handleDeleteGroupModalOpen()}> )} + {team.groupUri !== organization.SamlGroupName && ( + handleDeleteGroupModalClosed()} + onClose={() => handleDeleteGroupModalClosed()} + open={isDeleteGroupModalOpen} + isAWSResource={false} + deleteFunction={() => removeGroup(team.groupUri)} + /> + )} diff --git a/frontend/src/modules/Shares/components/ShareLogs.js b/frontend/src/modules/Shares/components/ShareLogs.js new file mode 100644 index 000000000..05d9b57bc --- /dev/null +++ b/frontend/src/modules/Shares/components/ShareLogs.js @@ -0,0 +1,119 @@ +import Editor from '@monaco-editor/react'; +import { RefreshRounded } from '@mui/icons-material'; +import { + Box, + Button, + CircularProgress, + Dialog, + Grid, + Typography +} from '@mui/material'; +import PropTypes from 'prop-types'; +import React, { useCallback, useEffect, useState } from 'react'; +import { THEMES, useSettings } from 'design'; +import { SET_ERROR, useDispatch } from 'globalErrors'; +import { getShareLogs, useClient } from 'services'; + +export const ShareLogs = (props) => { + const { shareUri, onClose, open } = props; + const { settings } = useSettings(); + const client = useClient(); + const dispatch = useDispatch(); + const [logs, setLogs] = useState(null); + const [loading, setLoading] = useState(true); + + const getLogs = useCallback(async () => { + setLoading(true); + try { + const response = await client.query(getShareLogs(shareUri)); + if (response && !response.errors) { + setLogs(response.data.getShareLogs.map((l) => l.message)); + } else { + dispatch({ type: SET_ERROR, error: response.errors[0].message }); + } + } catch (e) { + dispatch({ type: SET_ERROR, error: e.message }); + } + setLoading(false); + }, [client, dispatch, shareUri]); + + useEffect(() => { + if (client) { + getLogs().catch((e) => dispatch({ type: SET_ERROR, error: e.message })); + } + }, [client, dispatch, getLogs]); + + return ( + + + + + + Logs for share {shareUri} + + + + + + + + + {loading ? ( + + ) : ( + + {logs && ( + +
+ 0 + ? logs.join('\n') + : 'No logs available for the last 24 hours. Logs may take few minutes after the share is processed...' + } + options={{ minimap: { enabled: false } }} + theme="vs-dark" + inDiffEditor={false} + height="35rem" + language="text" + showPrintMargin + showGutter + highlightActiveLine + editorProps={{ + $blockScrolling: Infinity + }} + setOptions={{ + enableBasicAutocompletion: true, + enableLiveAutocompletion: true, + enableSnippets: true, + showLineNumbers: true, + tabSize: 2 + }} + /> +
+
+ )} +
+ )} +
+
+
+ ); +}; + +ShareLogs.propTypes = { + shareUri: PropTypes.string.isRequired +}; diff --git a/frontend/src/modules/Shares/services/getShareObject.js b/frontend/src/modules/Shares/services/getShareObject.js index 728ae4b8b..579aeaa37 100644 --- a/frontend/src/modules/Shares/services/getShareObject.js +++ b/frontend/src/modules/Shares/services/getShareObject.js @@ -15,6 +15,7 @@ export const getShareObject = ({ shareUri, filter }) => ({ requestPurpose rejectPurpose userRoleForShareObject + canViewLogs consumptionData { s3AccessPointName sharedGlueDatabase diff --git a/frontend/src/modules/Shares/views/ShareView.js b/frontend/src/modules/Shares/views/ShareView.js index 151d72362..82912f68a 100644 --- a/frontend/src/modules/Shares/views/ShareView.js +++ b/frontend/src/modules/Shares/views/ShareView.js @@ -1,4 +1,5 @@ import { + Article, BlockOutlined, CheckCircleOutlined, CopyAllOutlined, @@ -73,6 +74,7 @@ import { UpdateRequestReason } from '../components'; import { generateShareItemLabel } from 'utils'; +import { ShareLogs } from '../components/ShareLogs'; function ShareViewHeader(props) { const { @@ -89,6 +91,8 @@ function ShareViewHeader(props) { const [rejecting, setRejecting] = useState(false); const [submitting, setSubmitting] = useState(false); const [isRejectShareModalOpen, setIsRejectShareModalOpen] = useState(false); + const [openLogsModal, setOpenLogsModal] = useState(null); + const submit = async () => { setSubmitting(true); const response = await client.mutate( @@ -133,6 +137,13 @@ function ShareViewHeader(props) { } }; + const handleOpenLogsModal = () => { + setOpenLogsModal(true); + }; + const handleCloseOpenLogs = () => { + setOpenLogsModal(false); + }; + const handleRejectShareModalOpen = () => { setIsRejectShareModalOpen(true); }; @@ -246,6 +257,17 @@ function ShareViewHeader(props) { > Refresh + {share.canViewLogs && ( + + )} {(share.userRoleForShareObject === 'Approvers' || share.userRoleForShareObject === 'ApproversAndRequesters') && ( <> @@ -319,6 +341,13 @@ function ShareViewHeader(props) { rejectFunction={reject} /> )} + {share.canViewLogs && ( + + )} ); } diff --git a/frontend/src/services/graphql/ShareObject/getShareLogs.js b/frontend/src/services/graphql/ShareObject/getShareLogs.js new file mode 100644 index 000000000..8940f69dd --- /dev/null +++ b/frontend/src/services/graphql/ShareObject/getShareLogs.js @@ -0,0 +1,15 @@ +import { gql } from 'apollo-boost'; + +export const getShareLogs = (shareUri) => ({ + variables: { + shareUri + }, + query: gql` + query getShareLogs($shareUri: String!) { + getShareLogs(shareUri: $shareUri) { + message + timestamp + } + } + ` +}); diff --git a/frontend/src/services/graphql/ShareObject/index.js b/frontend/src/services/graphql/ShareObject/index.js index 033e2b72f..62e364ada 100644 --- a/frontend/src/services/graphql/ShareObject/index.js +++ b/frontend/src/services/graphql/ShareObject/index.js @@ -1,2 +1,3 @@ export * from './createShareObject'; export * from './getShareRequestsToMe'; +export * from './getShareLogs';