Skip to content

Conversation

iromli
Copy link
Contributor

@iromli iromli commented Nov 13, 2024

Prepare


Description

Target issue

Closes #10128

Implementation Details


Test and Document the changes

  • Static code analysis has been run locally and issues have been fixed
  • Relevant unit and integration tests have been added/updated
  • Relevant documentation has been updated if any (i.e. user guides, installation and configuration guides, technical design docs etc)

Please check the below before submitting your PR. The PR will not be merged if there are no commits that start with docs: to indicate documentation changes or if the below checklist is not selected.

  • I confirm that there is no impact on the docs due to the code changes in this PR.

Signed-off-by: iromli <isman.firmansyah@gmail.com>
Signed-off-by: iromli <isman.firmansyah@gmail.com>
Copy link

dryrunsecurity bot commented Nov 13, 2024

DryRun Security Summary

The pull request removes support for the Couchbase persistence option from the jans-pycloudlib library, simplifying the persistence layer and focusing on a more standardized SQL-based approach to improve the security and maintainability of the application.

Expand for full summary

Summary:

The code changes in this pull request primarily focus on removing support for the Couchbase persistence option from the jans-pycloudlib library. This includes the removal of Couchbase-related functionality, configuration options, and test cases. The changes suggest that the library is moving towards a simpler, SQL-based persistence model, with a hybrid mode that allows using SQL for certain data types.

From an application security perspective, the removal of the Couchbase persistence option is generally a positive change, as it reduces the overall complexity and attack surface of the library. Simplifying the persistence layer and focusing on a more standardized SQL-based approach can help improve the security and maintainability of the application.

However, it's important to ensure that the remaining persistence functionality, including the hybrid mode, is properly tested and configured to prevent any potential security vulnerabilities. The changes also highlight the need to review the handling of sensitive data, such as passwords and salts, to ensure they are properly secured and not exposed in the codebase or test suites.

Files Changed:

  1. jans-pycloudlib/docs/api/wait.md: The changes remove references to Couchbase-related functions, simplifying the documentation.
  2. jans-pycloudlib/jans/pycloudlib/lock/__init__.py: The Couchbase lock adapter has been removed, reducing the available lock options.
  3. jans-pycloudlib/jans/pycloudlib/persistence/hybrid.py: The changes make the persistence handling more generic, removing specific references to "LDAP + Couchbase".
  4. jans-pycloudlib/jans/pycloudlib/persistence/__init__.py: The Couchbase-related code has been removed, focusing the library on Hybrid and SQL persistence.
  5. jans-pycloudlib/jans/pycloudlib/schema/__init__.py: The Couchbase-related configuration options have been removed from the schema.
  6. jans-pycloudlib/jans/pycloudlib/wait.py: The Couchbase-related functions have been removed from the wait module.
  7. jans-pycloudlib/mkdocs.yml: The "Couchbase" section has been removed from the documentation navigation menu.
  8. jans-pycloudlib/jans/pycloudlib/persistence/utils.py: The Couchbase persistence type has been removed from the PERSISTENCE_TYPES constant.
  9. jans-pycloudlib/jans/pycloudlib/validators.py: The 'couchbase' option has been removed from the list of supported persistence types.
  10. jans-pycloudlib/tests/test_validators.py: The "couchbase" persistence type has been removed from the test cases.
  11. jans-pycloudlib/tests/conftest.py: The Couchbase-related secrets have been removed from the test configuration.
  12. jans-pycloudlib/tests/test_persistence.py: The Couchbase-related code has been removed, and the focus is on simplifying the hybrid persistence mode.
  13. jans-pycloudlib/tests/test_schema.py: The tests have been updated to ensure the validation of optional scopes, FQDN, salt, and password.
  14. jans-pycloudlib/tests/test_wait.py: The Couchbase-related tests have been removed, and the focus is on the SQL and hybrid persistence modes.

Code Analysis

We ran 9 analyzers against 17 files and 0 analyzers had findings. 9 analyzers had no findings.

Riskiness

🟢 Risk threshold not exceeded.

View PR in the DryRun Dashboard.

@mo-auto mo-auto added area-documentation Documentation needs to change as part of issue or PR comp-docs Touching folder /docs comp-jans-pycloudlib kind-dependencies Pull requests that update a dependency file labels Nov 13, 2024
@mo-auto
Copy link
Member

mo-auto commented Nov 13, 2024

Error: Hi @iromli, You did not reference an open issue in your PR. I attempted to create an issue for you.
Please update that issues' title and body and make sure I correctly referenced it in the above PRs body.

Copy link

@iromli iromli self-assigned this Nov 13, 2024
@iromli iromli marked this pull request as ready for review November 13, 2024 09:00
@iromli iromli requested a review from moabu as a code owner November 13, 2024 09:00
@moabu moabu merged commit fb0f7d7 into main Nov 13, 2024
30 of 33 checks passed
@moabu moabu deleted the cn-pycloudlib-del-couchbase branch November 13, 2024 09:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-documentation Documentation needs to change as part of issue or PR comp-docs Touching folder /docs comp-jans-pycloudlib kind-dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

chore(jans-pycloudlib)!: remove couchbase support from pycloudlib
3 participants