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

Support XPath for XML and JSON Pointer for JSON/YAML in validation output in CLI default and SARIF output modes #32

Open
7 tasks
aj-stein-gsa opened this issue Sep 16, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@aj-stein-gsa
Copy link
Contributor

User Story:

As a developer of OSCAL-based tools, in order to transition between different formats more seamlessly in general and processing validation results in particular, I would like the ability to switch from the default Metapaths in constraints' validation results from Metapath to XPath (1.0 or 3.0 flavors TBD) and JSON Pointer

Goals:

Support for:

  • emitting paths in constraint validation results in pure XPath (1.0 or 3.0 up for discussion and confirmation with oscal-cli maintainers)
  • emitting path in constraint validation results in pure JSON Pointer (RFC6901)
  • capability to automatically switch between them based on input document type (auto-sense XPath for XML, JSON Pointer for JSON/YAML)
  • a command-line option at runtime to explicitly mandate the output of one over the other

Dependencies:

{Describe any previous issues or related work that must be completed to start or complete this issue.}

Acceptance Criteria

  • All website and readme documentation affected by the changes in this issue have been updated.
  • A Pull Request (PR) is submitted that fully addresses the goals of this User Story. This issue is referenced in the PR.
  • The CI-CD build process runs without any reported errors on the PR. This can be confirmed by reviewing that all checks have passed in the PR.
@aj-stein-gsa aj-stein-gsa added the enhancement New feature or request label Sep 16, 2024
@aj-stein-gsa
Copy link
Contributor Author

NOTE: Per previous discussions, I believe the current preference for JSON/YAML to be JSON Pointer, not JSON Path. However, JSON Path recently achieved RFC status in IETF and also has implementation support. Despite being more recent, it has syntax more in alignment with XPath, so I just wanted to surface this for discussion, see more details below in the relevant docs:

/cc @david-waltermire

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Backlog
Development

No branches or pull requests

1 participant