Repository navigation
Dr.Egeria survey report and security finding commands (Egeria 6.3) - #497
Merged
Merged
Conversation
Step 4 of the odpi/egeria-workspaces#702 security annotations hand-off, in the Security Officer family: - Create/Update Survey Report (Asset Maker, SurveyReportProperties) with Purpose, Start/Completion Time and Report Subjects (ReportSubject). - Create/Update Security Finding, Vulnerability Finding and Penetration Test Finding, and Create/Update Security Posture Summary (Data Discovery). Each is created under its Survey Report (ReportedAnnotation, anchored to the report); Affected Elements (AssociatedAnnotation), Previous Finding (AnnotationExtension) and Vulnerability Type (ReferenceValueAssignment) are synced the same way as the statement of applicability links. - Severity validates against the CVSS ratings: its valid-metadata lookup is scoped to SecurityFindingAnnotation, since unscoped "severity" returns DataQualityRule's values. - Egeria stores the CVSS score, exploit/patch flags and posture counts as primitives, and a merge update that leaves one out resets it (confirmed live). The finding processor copies their current values into every merge update; ISSUE-166 gets the addendum. - Start Time / Completion Time descriptions (shared with Curation's Promise) broadened to cover reports. Verified end to end against the 2026-10-26 quickstart with a throwaway system, two runs and six annotations (since deleted, each checked by GUID). Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Step 4 of the security annotations hand-off in odpi/egeria-workspaces#702 (
design-docs/HANDOFF_pyegeria_security_annotations.md). It adds Dr.Egeria commands for cataloguing security test runs, all in the Security Officer family.Create/Update Survey Report: a SurveyReport asset, created through Asset Maker. Its attributes are Category, Purpose, Start Time and Completion Time.Report Subjectslinks the assets the run tested, through ReportSubject.Create/Update Security Finding,Vulnerability FindingandPenetration Test Finding: one annotation per finding, created under itsSurvey Report. That attribute is required; the finding is linked with ReportedAnnotation and anchored to the report.Affected Elementslinks catalogued elements through AssociatedAnnotation.Previous Findinglinks the same finding in an earlier run through AnnotationExtension.Vulnerability Typelinks a reference data value through ReferenceValueAssignment.Create/Update Security Posture Summary: the run's counts.Finding Counts By Severitytakes oneseverity: countpair per line.Merge Update: falsealso removes links the command no longer lists.Found while testing live
cvssScore,exploitAvailable,patchAvailableand the posture counts as Java primitives. A merge update that leaves one out resets it to 0 or false. I confirmed this live: a finding with CVSS 8.6 and an available exploit came back as 0.0 / false after an update that only added reproduction steps. The finding processor now copies the current values of those fields into every merge update unless the command sets them, and I verified live that the same update then keeps 8.6 / true. I've added this to ISSUE-166 inPYEGERIA_ISSUES.mdandEGERIA_OPEN_ISSUES.mdas an addendum. It moves the issue from "an unset value reads as 0" to "an update loses data".DataDiscovery.update_annotationcallers outside Dr.Egeria still need to do the same.severityvalid-metadata lookup returns DataQualityRule's values (info, warn, …), so "High" failed. The attribute now scopes the lookup toSecurityFindingAnnotation. Egeria registers nothing for that type, so validation falls back to the CVSS ratings in the spec.Start TimeandCompletion Timeare shared with Curation's Classify Promise, and their descriptions were written only for promises. I broadened both, which is why the two Classify Promise templates change.Verification
tests/dr-egeria-command-tests/dr_test_security_findings.mdend to end against a quickstart running egeria-platform:latest (2026-10-26). It covers a stand-in system, two penetration test runs, one finding of each type, a posture summary per run, a finding chained to the previous run's finding, and an update. I checked the properties and all five relationship types directly in Egeria. Everything was deleted afterwards, each element was confirmed gone by GUID, and a search for "SecTest" returns nothing.validate_compact_specs: 0 errors. Attribute-consumption audit on the family: 0 findings.test_dr_egeria_security_officer.py; the full micro-test suite passes (1518).Relationship to #495
This PR is independent of #495. It only calls SDK methods that already exist (Asset Maker, Data Discovery, Reference Data), and it doesn't touch the files #495 changes apart from separate sections of
docs/dr_egeria_manual.md. Once both are merged,View ReportwithSecurity-Findings,Penetration-Test-FindingsorSecurity-Postureshows what these commands record.🤖 Generated with Claude Code