Open marlontaylor opened 10 years ago
I don't think python-cybox should try to validate the strings. I do think python-cybox should pass the xsi:type along into the dictionary/JSON and object structures so developers can decide how to handle them.
In #203, the error was by only relying on hard coded xsi:type
it was later fixed by commit https://github.com/CybOXProject/python-cybox/commit/37cfe419ce83c3b4670f43a4fa7683cad50c79fe.
The new version handles this case; however, addressing #201 would fix the general case. Since
python-cybox
only uses the vocab terms it 'knows', developers will have to wait for an update inpython-cybox
to correctly round-trip (and/or slightly modify) a STIX document which uses the latestschema
.
Specific Case:
'package_intents'
( STIX_Package/STIX_Header/Package_Intent) vs'type'
(STIX_Package/STIX_Header/Information_Source/Tools/Tool/Type)'package_intents'
is a list of objects containing a 'value' and 'xsi:type'where as
'type'
is a list of strings.Personally, I prefer the list of objects (makes things easier for other developers).