Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jans config fix #9448

Merged
merged 70 commits into from
Sep 10, 2024
Merged

Jans config fix #9448

merged 70 commits into from
Sep 10, 2024

Conversation

pujavs
Copy link
Contributor

@pujavs pujavs commented Sep 10, 2024

Prepare


Description

Isssue#9446: Asset delete throwing error - Internal Server error

Target issue

closes #9446

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.

pujavs added 30 commits August 5, 2024 13:15
@pujavs pujavs requested a review from devrimyatar September 10, 2024 15:23
@pujavs pujavs requested review from yuriyz and yurem as code owners September 10, 2024 15:23
Copy link

dryrunsecurity bot commented Sep 10, 2024

DryRun Security Summary

This pull request focuses on improving the asset deletion functionality in the Janssen Project application and updating the OpenAPI specification for the Jans Config API, with changes that simplify the asset deletion process, provide more detailed logging, and reflect updates to the underlying data model and API structure.

Expand for full summary

Summary:

The code changes in this pull request focus on improving the asset deletion functionality in the Janssen Project application and updating the OpenAPI specification for the Jans Config API. The changes to the AssetService class simplify the asset deletion process and provide more detailed logging information, which enhances the overall reliability and maintainability of the asset management feature. The updates to the Jans Config API specification reflect changes to the underlying data model and API structure, but do not appear to introduce any obvious security concerns.

While the changes do not raise any major security issues, it's important to review the overall application security posture periodically and ensure that all security controls, including authentication, authorization, and data validation, are functioning correctly. Additionally, thorough testing of the updated API is recommended to verify that the changes do not introduce any unintended security vulnerabilities.

Files Changed:

  1. jans-config-api/server/src/main/java/io/jans/configapi/service/auth/AssetService.java:

    • The changes simplify the asset deletion process by first removing the asset from the database and then checking if the asset was successfully deleted. This improves the reliability of the asset deletion functionality.
    • The code has been updated to provide more detailed logging information during the asset deletion process, which can aid in troubleshooting and monitoring.
  2. jans-config-api/docs/jans-config-api-swagger.yaml:

    • The changes update the Scope schema, rearranging and adding new properties such as baseDn.
    • The CustomScript schema has been updated to include a new locationPath property.
    • These changes reflect updates to the underlying Jans Config API and its data model.

Code Analysis

We ran 9 analyzers against 2 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 the comp-jans-config-api Component affected by issue or PR label Sep 10, 2024
Copy link

@yurem yurem enabled auto-merge (squash) September 10, 2024 16:29
@yurem yurem merged commit cc02c6f into main Sep 10, 2024
12 checks passed
@yurem yurem deleted the jans-config-fix branch September 10, 2024 17:47
yuriyz pushed a commit that referenced this pull request Nov 7, 2024
* fix(config-api): asset mgt endpoint fixes

Signed-off-by: pujavs <[email protected]>

* feat(config-api): asset upload mgt ehancement and fido

Signed-off-by: pujavs <[email protected]>

* feat(config-api): asset upload mgt ehancement and fido

Signed-off-by: pujavs <[email protected]>

* feat(config-api): asset upload mgt ehancement and fido

Signed-off-by: pujavs <[email protected]>

* fix(config-api): asset upload

Signed-off-by: pujavs <[email protected]>

* fix(config-api): lock review comments

Signed-off-by: pujavs <[email protected]>

* feat(config-api): lock code review comments

Signed-off-by: pujavs <[email protected]>

* feat(config-api): lock master renamed to lock server

Signed-off-by: pujavs <[email protected]>

* feat(config-api): lock master renamed to lock server

Signed-off-by: pujavs <[email protected]>

* feat(config-api): lock master renamed to lock server

Signed-off-by: pujavs <[email protected]>

* feat(config-api): lock master renamed to lock server

Signed-off-by: pujavs <[email protected]>

* feat(config-api): fido2 delete functionality

Signed-off-by: pujavs <[email protected]>

* fix(config-api): acr validation

Signed-off-by: pujavs <[email protected]>

* feat(config-api): doc(config-api): IDP schema attribute descriptions #9187

Signed-off-by: pujavs <[email protected]>

* feat(config-api): sync with main

Signed-off-by: pujavs <[email protected]>

* feat(config-api): uploading assets via API generates 2 entries #9178

Signed-off-by: pujavs <[email protected]>

* feat(config-api): asset mgt, fido and IDP changes

Signed-off-by: pujavs <[email protected]>

* feat(config-api): fido2 device endpoint

Signed-off-by: pujavs <[email protected]>

* feat(config-api): fido2 endpoint

Signed-off-by: pujavs <[email protected]>

* feat(config-api): fido2 endpoint

Signed-off-by: pujavs <[email protected]>

* feat(config-api): sync with main

Signed-off-by: pujavs <[email protected]>

* feat(config-api): sync with main

Signed-off-by: pujavs <[email protected]>

* feat(config-api): sync with main

Signed-off-by: pujavs <[email protected]>

* feat(config-api): resolved sonar review issues

Signed-off-by: pujavs <[email protected]>

* feat(config-api): sonar review comment fix

Signed-off-by: pujavs <[email protected]>

* feat(config-api): swagger spec

Signed-off-by: pujavs <[email protected]>

* feat(config-api): saml config attribute description

Signed-off-by: pujavs <[email protected]>

* doc(config-api): added SAML attribute description

Signed-off-by: pujavs <[email protected]>

* doc(config-api): added SAML attribute description

Signed-off-by: pujavs <[email protected]>

* feat(config-api): sync with main

Signed-off-by: pujavs <[email protected]>

* fix(jans-lock): code review comment fix isssue#9305

Signed-off-by: pujavs <[email protected]>

* fix(jans-lock): code review comment fix isssue#9305

Signed-off-by: pujavs <[email protected]>

* feat(config-api): lock review point

Signed-off-by: pujavs <[email protected]>

* fix(lock): code review comment

Signed-off-by: pujavs <[email protected]>

* fix(lock): code review comment

Signed-off-by: pujavs <[email protected]>

* fix(config-api): sync with main

Signed-off-by: pujavs <[email protected]>

* feat(config-api): lock endpoint fixes and SAML IDP NPE

Signed-off-by: pujavs <[email protected]>

* feat(config-api): asset enhancement

Signed-off-by: pujavs <[email protected]>

* feat(config-api): implement timer for asset mgt to fetch and deploy assets forconfig-api #9403

Signed-off-by: pujavs <[email protected]>

* fix(config-api): scope validation issue #9426

Signed-off-by: pujavs <[email protected]>

* fix(config-api): asset delete error fix

Signed-off-by: pujavs <[email protected]>

---------

Signed-off-by: pujavs <[email protected]>
Former-commit-id: cc02c6f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp-jans-config-api Component affected by issue or PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fix(config-api): asset delete error
4 participants