Add audit events for fork unlink action
What does this MR do and why?
This MR intends to add a project level audit event when the user removes the fork relationship.
- Related issue: #272532 (closed)
Adds a new EE scoped service UnlinkForkService
that overrides the execute
method in https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/services/projects/unlink_fork_service.rb service - This adds a project level audit event for fork unlink
action.
- Referred docs: https://docs.gitlab.com/ee/development/audit_event_guide/
Screenshots or screen recordings
After the removal of fork relationship::
How to set up and validate locally
- Checkout to this feature branch
- Fork a project
- In the forked project, unlink the fork relationship from
Settings
->General
->Advanced section
click Remove fork relationship button - Navigate to
Security & Compliance
-> Audit events section - Notice that the fork unlink action is logged in the audit events list
NoteL Audit events feature is only available for paid tiers.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by sameer shaik