-
Notifications
You must be signed in to change notification settings - Fork 1.7k
feat(RiskAcc-Eng): Clean RiskAcc-Eng mapping + Allow correct handling by API #12361
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
base: dev
Are you sure you want to change the base?
Conversation
I think the initial idea was that a Risk Acceptance could apply to more than just one engagement. For example accept the risk of a CVE that occurs in multiple branches. I think via the UI you cannot actually do this, but it might be possible via the API? |
API would not be broken; there is a checker correctly (see below). In fact, API needs to be fixed - you can create RiskAcc (via
I'm not strictly to one or another option. Both might make sense. It is the reason why I didn't continue with the implementation, but raised the question. Regarding breaking the current setup - I do not think so because we would just extend current abilities (but please correct me if I'm wrong). It might not be true about future use cases. But it is the reason why I'm asking about original intentions. |
f462a9d
to
96a904f
Compare
This pull request introduces potential risks in database migration and model relationships, including null reference scenarios, incomplete migration logic, unintended data deletion through CASCADE strategy, and changes to data relationships that could impact existing data tracking between Engagement and Risk_Acceptance models. 💭 Unconfirmed Findings (4)
All finding details can be found in the DryRun Security Dashboard. |
Hi @kiblik, thank you for pausing on this feature before continuing any further. Risk Exceptions are one of those features that is used a little differently by everyone. As Val pointed out, we don't want to break any current use cases, or point ourselves into a corner for future use cases. Minimizing changes to the risk exception object would be the best move we could make at this time |
Thank you @Maffooch. I will prepare the implementation, which will:
|
3e2f9df
to
9f3cf6d
Compare
98ca98d
to
ba53851
Compare
ba53851
to
e4d0be7
Compare
This PR is trying to fix "not the best" implementation of mapping between Engagements and RiskAcc.
Until now, it was set as
ManyToManyField
inEngagements
, and fromRiskAcc
, it was just using the first possible match. This implementation is eventually a one-to-many relation, which should be solved viaForeignKey
inRiskAcc
.