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

feat(jans-fido2): major FIDO2 / Passkeys upgrade ProjectPasskeys #10080

Draft
wants to merge 225 commits into
base: main
Choose a base branch
from

Conversation

moabu
Copy link
Member

@moabu moabu commented Nov 7, 2024

This PR completely revamps jans-fido2, to enable support for passkeys, and bring the server up to spec.

So far changes:

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.

Closes #10079,

Prev. PR #9120

mo-auto and others added 30 commits November 7, 2024 10:22
Bumps commons-text from 1.9 to 1.10.0.

---
updated-dependencies:
- dependency-name: org.apache.commons:commons-text
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [postgresql](https://github.com/pgjdbc/pgjdbc) from 42.5.0 to 42.5.1.
- [Release notes](https://github.com/pgjdbc/pgjdbc/releases)
- [Changelog](https://github.com/pgjdbc/pgjdbc/blob/master/CHANGELOG.md)
- [Commits](pgjdbc/pgjdbc@REL42.5.0...REL42.5.1)

---
updated-dependencies:
- dependency-name: org.postgresql:postgresql
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
shekhar16 and others added 6 commits November 7, 2024 10:47
…tion and assertion API calls #9248 (#9974)

* feat(jans-fido2): add origin parameter in Fido2ExternalAuthenticator script for attestation and assertion API calls

Signed-off-by: imran-ishaq <[email protected]>

* refactor(docs): add origin parameter in Fido2ExternalAuthenticator script for attestation and assertion API calls #9248

Signed-off-by: imran-ishaq <[email protected]>

* fix(jans-fido2): handle origin if http or https is missing #9248

Signed-off-by: imran-ishaq <[email protected]>

---------

Signed-off-by: imran-ishaq <[email protected]>
Signed-off-by: imran-ishaq <[email protected]>
@mo-auto mo-auto added area-documentation Documentation needs to change as part of issue or PR comp-docker-jans-fido2 comp-docs Touching folder /docs comp-jans-auth-server Component affected by issue or PR comp-jans-casa Touching folder /jans-casa comp-jans-cli-tui Component affected by issue or PR comp-jans-config-api Component affected by issue or PR comp-jans-core Component affected by issue or PR comp-jans-fido2 Component affected by issue or PR labels Nov 7, 2024
Copy link

sonarcloud bot commented Nov 7, 2024

Copy link

dryrunsecurity bot commented Nov 7, 2024

DryRun Security Summary

The provided code changes focus on improving the security, maintainability, and usability of the Janssen FIDO2 implementation, including updates to the FIDO2 configuration, enhancement of the attestation and assertion processes, removal of unused features, and improvement of the documentation.

Expand for full summary

Summary:

The provided code changes cover various updates and improvements to the Janssen FIDO2 (Fast IDentity Online) implementation, which is a crucial component for secure user authentication. The changes span across multiple files and address several aspects of the FIDO2 configuration, implementation, and documentation.

The key security-related changes include:

  1. Updating FIDO2 configuration parameters to align with the FIDO2 specification and improve clarity.
  2. Enhancing the handling of FIDO2 attestation and assertion processes, including the use of structured data types and input validation.
  3. Removing unused or deprecated FIDO2 features, such as the SuperGluu-specific endpoints, to simplify the API and reduce the attack surface.
  4. Improving the documentation and examples related to the FIDO2 implementation, which can help developers and administrators better understand and configure the FIDO2 functionality securely.

Overall, the changes appear to be focused on improving the security, maintainability, and usability of the Janssen FIDO2 implementation. However, it's essential to thoroughly review the entire codebase and ensure that the FIDO2 functionality is implemented and configured in accordance with best practices for secure authentication and authorization.

Files Changed:

  1. docker-jans-fido2/scripts/upgrade.py: Changes the FIDO2 configuration to set the "attestationMode" to "monitor", which may impact the security of the attestation process.
  2. docs/janssen-server/config-guide/fido2-config/janssen-fido2-configuration.md: Updates the FIDO2 configuration parameter names to align with the FIDO2 specification.
  3. docs/janssen-server/fido/logs.md: Describes changes to the FIDO2 configuration, including the renaming of parameters and the update of the enabledFidoAlgorithms and rp (Relying Party) settings.
  4. docs/janssen-server/fido/config.md: Summarizes the changes to the FIDO2 configuration, including updates to the attestation mode, metadata service handling, and user auto-enrollment settings.
  5. docs/janssen-server/fido/vendor-metadata.md: Discusses the changes to the FIDO2 metadata validation configuration, including the option to disable metadata validation.
  6. jans-auth-server/server/src/main/webapp/auth/fido2/js/webauthn.js: Adds a new function, getAssertionConditional(), to handle the FIDO2 assertion flow with conditional mediation.
  7. docs/script-catalog/person_authentication/fido2-external-authenticator/Fido2ExternalAuthenticator.py: Describes the implementation of the FIDO2 external authenticator, including the handling of the authentication and enrollment flows.
  8. docs/janssen-server/reference/json/properties/fido2-properties.md: Documents the updated FIDO2 configuration properties, including changes to the naming and descriptions of the parameters.
  9. jans-auth-server/server/src/main/webapp/auth/fido2/passkeys.xhtml: Updates the FIDO2 login functionality, including the use of the webauthn.getAssertionConditional function for the authentication process.
  10. jans-cli-tui/cli_tui/plugins/020_fido/main.py: Modifies the FIDO2 configuration parameters, renaming requestedParties to rp (Relying Party) and requestedCredentialTypes to enabledFidoAlgorithms.
  11. jans-config-api/plugins/fido2-plugin/src/test/resources/feature/fido2/dynamiconf.json: Updates the FIDO2 configuration parameters, including the renaming of requestedParties to rp, requestedCredentialTypes to enabledFidoAlgorithms, and userAutoEnrollment to debugUserAutoEnrollment.
  12. jans-config-api/plugins/docs/fido2-plugin-swagger.yaml: Renames FIDO2 configuration parameters, such as requestedCredentialTypes to enabledFidoAlgorithms and `request

Code Analysis

We ran 9 analyzers against 30 files and 2 analyzers had findings. 7 analyzers had no findings.

Analyzer Findings
Sensitive Files Analyzer 1 finding
Authn/Authz Analyzer 4 findings

Riskiness

🟢 Risk threshold not exceeded.

View PR in the DryRun Dashboard.

…y, publicKeyAlgorithm, publicKeyId, transport to the newly created cred object.
#10101 property name changed and not reflected in the template

Signed-off-by: Madhumita Subramaniam <[email protected]>
Copy link

sonarcloud bot commented Nov 11, 2024

Copy link

sonarcloud bot commented Nov 11, 2024

Copy link

sonarcloud bot commented Nov 11, 2024

Copy link

sonarcloud bot commented Nov 13, 2024

Copy link

sonarcloud bot commented Nov 13, 2024

@ossdhaval ossdhaval changed the title (jans-fido2): major FIDO2 / Passkeys upgrade ProjectPasskeys feat(jans-fido2): major FIDO2 / Passkeys upgrade ProjectPasskeys Nov 13, 2024
@mo-auto mo-auto added the kind-feature Issue or PR is a new feature request label Nov 13, 2024
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-docker-jans-fido2 comp-docs Touching folder /docs comp-jans-auth-server Component affected by issue or PR comp-jans-casa Touching folder /jans-casa comp-jans-cli-tui Component affected by issue or PR comp-jans-config-api Component affected by issue or PR comp-jans-core Component affected by issue or PR comp-jans-fido2 Component affected by issue or PR kind-feature Issue or PR is a new feature request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fix: (jans-fido2): major FIDO2 / Passkeys upgrade ProjectPasskeys -autocreated