CSAF::...ryTests(3pm)
π CSAF::Validator::MandatoryTests β bestie edition π
okay so this is a page from the User Contributed Perl Documentation, and the module is CSAF::Validator::MandatoryTests (the page name gets all truncated to CSAF::...ryTests(3pm) which is honestly so dramatic of it π
). sit down, grab a strawberry, we're doing CSAF validation together πβ¨
πΈ NAME πΈ
CSAF::Validator::MandatoryTests β the tests that MUST NOT fail, fr fr. no cap. π«Ά
β¨ SYNOPSIS β¨
here's the whole vibe, copy-paste ready:
use CSAF::Validator::MandatoryTests;
my $v = CSAF::Validator::MandatoryTests->new( csaf => $csaf );
$v->exec_test('6.1.5');
$v->TEST_6_1_5;
like, you make one, you run a test by its number, or you call the method directly. both work, both slay. π
π¦ DESCRIPTION π¦
so the whole point: mandatory tests MUST NOT fail at a valid CSAF document. that's not me being cute, that's the spec, and it's giving "non-negotiable." π
here's the full roster of mandatory tests, all 33 of them, with the 6.1.27 profile tests nested inside like little baby tests π§:
6.1.1 Missing Definition of Product ID
6.1.2 Multiple Definition of Product ID
6.1.3 Circular Definition of Product ID
6.1.4 Missing Definition of Product Group ID
6.1.5 Multiple Definition of Product Group ID
6.1.6 Contradicting Product Status
6.1.7 Multiple Scores with same Version per Product
6.1.8 Invalid CVSS
6.1.9 Invalid CVSS computation
6.1.10 Inconsistent CVSS
6.1.11 CWE
6.1.12 Language
6.1.13 PURL
6.1.14 Sorted Revision History
6.1.15 Translator
6.1.16 Latest Document Version
6.1.17 Document Status Draft
6.1.18 Released Revision History
6.1.19 Revision History Entries for Pre-release Versions
6.1.20 Non-draft Document Version
6.1.21 Missing Item in Revision History
6.1.22 Multiple Definition in Revision History
6.1.23 Multiple Use of Same CVE
6.1.24 Multiple Definition in Involvements
6.1.25 Multiple Use of Same Hash Algorithm
6.1.26 Prohibited Document Category Name
6.1.27 Profile Tests
6.1.27.1 Document Notes
6.1.27.2 Document References
6.1.27.3 Vulnerabilities
6.1.27.4 Product Tree
6.1.27.5 Vulnerability Notes
6.1.27.6 Product Status
6.1.27.7 VEX Product Status
6.1.27.8 Vulnerability ID
6.1.27.9 Impact Statement
6.1.27.10 Action Statement
6.1.27.11 Vulnerabilities
6.1.28 Translation
6.1.29 Remediation without Product Reference
6.1.30 Mixed Integer and Semantic Versioning
6.1.31 Version Range in Product Version
6.1.32 Flag without Product Reference
6.1.33 Multiple Flags with VEX Justification Codes per Product
π METHODS π
CSAF::Validator::MandatoryTests inherits all methods from CSAF::Validator::Base β like, everything, it's all yours β and then it implements these new ones below. each one is basically a test with a glow-up. π
TEST_6_1_1β Missing Definition of Product IDTEST_6_1_2β Multiple Definition of Product IDTEST_6_1_3β Circular Definition of Product IDTEST_6_1_4β Missing Definition of Product Group IDTEST_6_1_5β Multiple Definition of Product Group IDTEST_6_1_6β Contradicting Product StatusTEST_6_1_7β Multiple Scores with same Version per ProductTEST_6_1_8β Invalid CVSSTEST_6_1_9β Invalid CVSS computationTEST_6_1_10β Inconsistent CVSSTEST_6_1_11β CWETEST_6_1_12β LanguageTEST_6_1_13β PURLTEST_6_1_14β Sorted Revision HistoryTEST_6_1_15β TranslatorTEST_6_1_16β Latest Document VersionTEST_6_1_17β Document Status DraftTEST_6_1_18β Released Revision HistoryTEST_6_1_19β Revision History Entries for Pre-release VersionsTEST_6_1_20β Non-draft Document VersionTEST_6_1_21β Missing Item in Revision HistoryTEST_6_1_22β Multiple Definition in Revision HistoryTEST_6_1_23β Multiple Use of Same CVETEST_6_1_24β Multiple Definition in InvolvementsTEST_6_1_25β Multiple Use of Same Hash AlgorithmTEST_6_1_26β Prohibited Document Category NameTEST_6_1_27_1β Profile Test - Document NotesTEST_6_1_27_2β Profile Test - Document ReferencesTEST_6_1_27_3β Profile Test - VulnerabilitiesTEST_6_1_27_4β Profile Test - Product TreeTEST_6_1_27_5β Profile Test - Vulnerability NotesTEST_6_1_27_6β Profile Test - Product StatusTEST_6_1_27_7β Profile Test - VEX Product StatusTEST_6_1_27_8β Profile Test - Vulnerability IDTEST_6_1_27_9β Profile Test - Impact StatementTEST_6_1_27_10β Profile Test - Action StatementTEST_6_1_27_11β Profile Test - VulnerabilitiesTEST_6_1_28β TranslationTEST_6_1_29β Remediation without Product ReferenceTEST_6_1_30β Mixed Integer and Semantic VersioningTEST_6_1_31β Version Range in Product VersionTEST_6_1_32β Flag without Product ReferenceTEST_6_1_33β Multiple Flags with VEX Justification Codes per Product
π«Ά SUPPORT π«Ά
π Bugs / Feature Requests
found a bug? want a feature? please report it through the issue tracker at <https://github.com/giterlizzi/perl-CSAF/issues>. and the best part β you get notified automatically of any progress on your issue. no refreshing, no stalking the thread, it just comes to you. main character treatment honestly. π
π¦ Source Code
this is open source software, bestie. the code repo is out there for public review and contribution, under the terms of the license. come vibe with it π
<https://github.com/giterlizzi/perl-CSAF>
git clone https://github.com/giterlizzi/perl-CSAF.git
π AUTHOR π
- Giuseppe Di Terlizzi <gdt@cpan.org>
π LICENSE AND COPYRIGHT π
this software is copyright (c) 2023-2025 by Giuseppe Di Terlizzi.
it's free software β you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. periodt. π
and that's the whole page, bestie. go validate something and make it flawless. β¨
signing off from perl v5.40.1, dated 2025-09-03, on the CSAF::...ryTests(3pm) page π
π¦ where this page comes from
- ubuntu resolute: libcsaf-perl 0.26-1 Β· Artistic-2.0
- ubuntu stonking: libcsaf-perl 0.26-1 Β· Artistic-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms