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

Add Examples of OSCAL Actions Assembly #139

Conversation

aj-stein-nist
Copy link
Contributor

@aj-stein-nist aj-stein-nist commented Sep 7, 2022

Committer Notes

This PR closes #130.

Depends on usnistgov/metaschema#240 and usnistgov/metaschema#241

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Have you squashed any non-relevant commits and commit messages? [instructions]
  • Do all automated CI/CD checks pass?

Changes to Core Features:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you included examples of how to use your new feature(s)?
  • Have you written new tests for your core changes, as applicable?

@aj-stein-nist aj-stein-nist added Scope: Content A task issue to create or modify OSCAL content and examples. LoE: Small The issue will require up to 8 hours to address. labels Sep 7, 2022
@aj-stein-nist aj-stein-nist self-assigned this Sep 7, 2022
@aj-stein-nist aj-stein-nist changed the base branch from main to develop September 7, 2022 15:00
@aj-stein-nist aj-stein-nist changed the title Add Examples of OSCAL Actions Assembly [WIP] Add Examples of OSCAL Actions Assembly Sep 7, 2022
@aj-stein-nist
Copy link
Contributor Author

@david-waltermire-nist, sorry, I cannot change it to draft back bc of perms/I am the author the PR. This is WIP until otherwise stated, can you help me change it back? :-)

@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch from 2d4e427 to 6bb77d9 Compare September 7, 2022 20:50
aj-stein-nist added a commit to aj-stein-nist/OSCAL-forked that referenced this pull request Sep 8, 2022
@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch from e4b56d3 to f46dc3a Compare September 8, 2022 13:58
@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch from b337a98 to b5b1bd9 Compare September 9, 2022 18:56
@aj-stein-nist
Copy link
Contributor Author

aj-stein-nist commented Sep 11, 2022

OK, so I talked with Wendell through a potential bug in the supermodel -> converter generator -> running the OSCAL XML to JSON converter on some example files in here, specifically oscal_leveraging-example_ssp.xml. This is causing this error with examples file in the updated pipelines in this branch using more current develop OSCAL and in it develop metaschema submodule updates.

<nm:ERROR xmlns:err="http://www.w3.org/2005/xqt-errors" xmlns:nm="http://csrc.nist.gov/ns/metaschema" code="err:FOJS0006">xml-to-json: Child elements of &lt;map&gt; must have a key attribute</nm:ERROR>

It would seem this has something to do with how specifically this system-id without a type URI is handled with the current supermodel analysis in making the converters with the converter generator. I am having trouble piecing together where the model analysis occurs in the pipeline and the super model itself is generated, but I finally noticed the key difference I was not noticing on Friday.

The system-id in the generated supermodel:

      <group in-json="ARRAY" key="system-ids">
         <field collapsible="no" as-type="string" name="system-id" gi="system-id"><!-- NOTE: the field should have an in-json="SCALAR" attribute or something sensible, but it does not. -->
            <value as-type="string" key="id" in-json="string">saas_system_iaas_customer</value>
         </field>
      </group>

I will potentially convert this into a metaschema bug report when I am sure it is a bug and know more when discussing with Wendell on Monday or early next week.

Some other examples in the example document instance converted to the supermodel I hadn't noticed before. (Interesting and also of note: the field definition for system-id is the only one not in the SSP metaschema definition but imported through a module, maybe something worth tracking down?

                     <group in-json="ARRAY" key="information-type-ids">
                        <field collapsible="no" as-type="string" name="information-type-id"
                           gi="information-type-id" in-json="SCALAR">
                           <value as-type="string" in-json="string">C.3.5.8</value>
                        </field>
                     </group>
            <group in-json="ARRAY" key="role-ids">
               <field collapsible="no" as-type="token" name="role-id" gi="role-id" in-json="SCALAR">
                  <value as-type="token" in-json="string">admin</value>
               </field>
            </group>
                  <group in-json="ARRAY" key="functions-performed">
                     <field collapsible="no" as-type="string" name="function-performed"
                        gi="function-performed" in-json="SCALAR">
                        <value as-type="string" in-json="string">Manages the components within the
                           SaaS.</value>
                     </field>
                  </group>
                  <group in-json="ARRAY" key="values">
                     <field collapsible="no" as-type="string" name="parameter-value" gi="value"
                        in-json="SCALAR">
                        <value as-type="string" in-json="string">privileged and
                           non-privileged</value>
                     </field>
                  </group>

@aj-stein-nist
Copy link
Contributor Author

aj-stein-nist commented Sep 29, 2022

To move this along for now: I rebased this off of the current PR #144 for #116. Since that is a branch off my fork, I cannot really point that as the target of this PR. If the CI/CD fixes land, I can rebase again, examples will validate, and builds will work when this work is reviewed and merged as well.

@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch 6 times, most recently from ed3f0d1 to a3b2752 Compare October 5, 2022 18:51
@aj-stein-nist aj-stein-nist changed the title [WIP] Add Examples of OSCAL Actions Assembly Add Examples of OSCAL Actions Assembly Oct 14, 2022
@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch 3 times, most recently from eceb818 to 7c203f2 Compare October 14, 2022 03:49
@aj-stein-nist
Copy link
Contributor Author

This still needs rebasing after usnistgov/metaschema#240 and usnistgov/metaschema#241 are merged into usnistgov/OSCAL and the submodule can be updated to touch up CI/CD issues, but the example content is in a good place for the NIST team and OSCAL community to review the examples content on its merits separate of those issues.

@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch from f775f71 to db43fbe Compare January 3, 2023 20:19
@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch 3 times, most recently from 3fad845 to c9c6223 Compare January 4, 2023 04:54
@aj-stein-nist aj-stein-nist force-pushed the 130-examples-of-actions-in-metadata-assembly-of-different-oscal-model-instances branch from c9c6223 to 26f0fe1 Compare January 4, 2023 20:07
aj-stein-nist added a commit to usnistgov/metaschema that referenced this pull request Jan 6, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
aj-stein-nist added a commit to usnistgov/OSCAL that referenced this pull request Jan 6, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
aj-stein-nist added a commit to usnistgov/OSCAL that referenced this pull request Jan 6, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
david-waltermire pushed a commit to usnistgov/metaschema that referenced this pull request Jan 9, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
david-waltermire pushed a commit to usnistgov/OSCAL that referenced this pull request Jan 9, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
@david-waltermire
Copy link
Contributor

@aj-stein-nist As we discussed today, this needs to be rebased to address the CI problems. Let me know when this is done and I can merge this PR.

@aj-stein-nist
Copy link
Contributor Author

aj-stein-nist commented Mar 2, 2023

This is blocked by #183 and any pending work that must be resolved and completed as marked by the resolution of #116. Moving to Sprint 65 tentatively.

aj-stein-nist added a commit to usnistgov/OSCAL that referenced this pull request Apr 4, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
aj-stein-nist added a commit to usnistgov/OSCAL that referenced this pull request Apr 4, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
aj-stein-nist added a commit to usnistgov/OSCAL that referenced this pull request Apr 14, 2023
* Update metaschema for current datatype regexes for #1703.

* Back-port Metaschema XSD relocation.

As part of the OSCAL build process, we validate the structure of the
metaschema definitions of the OSCAL models themselves against the schema
of Metaschema definitions XSD from the metaschema repo. Recently, a path
update was fixed in the OSCAL develop branch but not in the release-1.0
branch or main because these changes occurred after 1.0.4 publication.
The files were relocated and reorganized. This adjustment must be made
to account for that.

Pull release/main back into develop should be minor and a rebase may not
be necessary. If so, we will adjust accordingly. In develop, see This
commit:

84d2d46

* Workaround maven.restlet.org service cert expiry. (#1602)

This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1

* Update metaschema submodule again.
nikitawootten-nist pushed a commit to nikitawootten-nist/metaschema-xslt that referenced this pull request Jul 21, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
aj-stein-nist added a commit to galtm/OSCAL that referenced this pull request Sep 28, 2023
This is pulling over workaround as reported in usnistgov/oscal-content#139 with the WIP workaround submodule.

usnistgov/oscal-content@26f0fe1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
LoE: Small The issue will require up to 8 hours to address. Scope: Content A task issue to create or modify OSCAL content and examples.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Examples of Actions in Metadata Assembly of Different OSCAL Model Instances
3 participants