-
Notifications
You must be signed in to change notification settings - Fork 36
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
We need a Policy object #592
Comments
If we refactor the Decision Point Group schema to pull out the |
Any resolution of this issue (#592) should take into account solutions to |
So I have a sketch of this in a local branch. The structure is as follows: class DecisionFramework(_Versioned, _Namespaced, _Base, BaseModel):
"""
The DecisionFramework class is a model for decisions in SSVC.
It is a collection of decision points and outcomes, and a mapping of decision points to outcomes.
The mapping is generated by the PolicyGenerator class, and stored as a dictionary.
The mapping dict keys are decision point namespace:key:version:value.
The mapping dict values are outcome group name:version:value.
"""
decision_point_group: SsvcDecisionPointGroup
outcome_group: OutcomeGroup
mapping: dict[str, str]
def __init__(self, **data):
super().__init__(**data)
if not self.mapping:
self.mapping = self.generate_mapping()
... I'm leaving out the I am attaching an example based on the decision point group for the Supplier model, except using a different ("MoSCoW") outcome set to make it clear that this is an example. It's far too large to include directly in this comment. Concerns I can see already:
|
Based items 3, 4, 5 above, we might transform "ssvc:E:1.0.0:None,ssvc:U:1.0.1:Laborious,ssvc:TI:1.0.0:Total,ssvc:A:2.0.0:No,ssvc:VD:1.0.0:Concentrated,ssvc:SI:1.0.0:Major": "Must, Should, Could, Won't:1.0.0:Won't",
"ssvc:E:1.0.0:None,ssvc:U:1.0.1:Laborious,ssvc:TI:1.0.0:Total,ssvc:A:2.0.0:No,ssvc:VD:1.0.0:Concentrated,ssvc:SI:1.0.0:Hazardous": "Must, Should, Could, Won't:1.0.0:Could",
"ssvc:E:1.0.0:None,ssvc:U:1.0.1:Laborious,ssvc:TI:1.0.0:Total,ssvc:A:2.0.0:No,ssvc:VD:1.0.0:Concentrated,ssvc:SI:1.0.0:Catastrophic": "Must, Should, Could, Won't:1.0.0:Should", into: "ssvc:E:None,ssvc:U:Laborious,ssvc:TI:Total,ssvc:A:No,ssvc:VD:Concentrated,ssvc:SI:Major": "Must, Should, Could, Won't:Won't",
"ssvc:E:None,ssvc:U:Laborious,ssvc:TI:Total,ssvc:A:No,ssvc:VD:Concentrated,ssvc:SI:Hazardous": "Must, Should, Could, Won't:Could",
"ssvc:E:None,ssvc:U:Laborious,ssvc:TI:Total,ssvc:A:No,ssvc:VD:Concentrated,ssvc:SI:Catastrophic": "Must, Should, Could, Won't:Should", We could further shrink this by:
and bring it down to (different example rows, but you get the idea) "ssvc:E:A,ssvc:U:S,ssvc:TI:T,ssvc:A:N,ssvc:VD:D,ssvc:SI:N": "MOSCOW:C",
"ssvc:E:A,ssvc:U:S,ssvc:TI:T,ssvc:A:N,ssvc:VD:D,ssvc:SI:M": "MOSCOW:S",
"ssvc:E:A,ssvc:U:S,ssvc:TI:T,ssvc:A:N,ssvc:VD:D,ssvc:SI:J": "MOSCOW:S",
"ssvc:E:A,ssvc:U:S,ssvc:TI:T,ssvc:A:N,ssvc:VD:D,ssvc:SI:H": "MOSCOW:M", which, again assuming that this list ONLY appears in the context of a The risk is that these strings start looking like CVSS vectors again, and they may get copied outside of the context of the json blob we're talking about. In which case there could be some ambiguity over time as decision points or outcome groups bump versions. |
Thanks Allan! Can we think about the display issue as a usability issue? Even if it is just usability for developers and people working with the software, we still might want to look at it from a usability lens to make sure that the tasks the users want to accomplish are easy. We may need to somehow get to a usability discussion for leadership reviewing and approving a risk stance that might be better addressed through a visualization, not text. If that's the case, compressing the string to look more like a CVSS string may not be the best solution to the usability issue. But I am noting the convergent evolution forces that maybe lead to a CVSS vector string. |
I agree there's a usability concern here if we were to expect humans to be working directly with that JSON object in the course of "doing SSVC". I don't think that's the case here. I am thinking of this as a machinable object that happens to be human-readable by experts but is not intended for most folks to ever directly see. I'm going to suggest that if anyone but a programmer or programmer-adjacent role is looking at this data representation, they're in the wrong place, and we should be able to redirect them to an alternative way of presenting this object that is actually human-consumable. So yes, we need a way of presenting this object to an "SSVC user" who expects to see text in tables or formatted lists etc., but not raw JSON. But I think that's more in the "Policy Explorer" UI side than it is about this object model. And yes, the "carcinization, but for CVSS" thing is not lost on me. 🦀 |
I agree with this; we would need a way to redirect folks who are not programmers. In addition, programmers are humans and have usability needs. The usability needs on producing accurate, functional, and review-able code are non-trivial. What solution best meets those usability needs? (or different / additional usability needs that may be better). And meets them for a wide group of different programmers. |
Describe the solution you'd like
The PolicyGenerator object can be used to generate a CSV formatted policy, but we should really have a separate object to represent a policy.
See also #591
The text was updated successfully, but these errors were encountered: