Open medcrypt-matt opened 6 months ago
Thanks @medcrypt-matt for reporting this. This should be a straightforward fix, but it may be a while before I get to it myself. If you want to create a PR, I can review / merge otherwise I'll take a look once I finish the 3.0 upgrades to the library.
If a SPDX 2.3 tag/value file contains
PrimaryPackagePurpose: OPERATING-SYSTEM
then attempts to convert the file, or to deserialize it usingSpdxToolsHelper.deserializeDocument
will fail withorg.spdx.tag.InvalidSpdxTagFileException: Unknown Package Purpose: OPERATING-SYSTEM
This value is perfectly valid according to the spec: https://spdx.github.io/spdx-spec/v2.3/package-information/#724-primary-package-purpose-field
The problem seems to be that the enum member is named OPERATING_SYSTEM (note the underscore)