feat: Add --force-delete option to sc-dast scan delete#960
Open
gilseara wants to merge 2 commits intofortify:dev/v3.xfrom
Open
feat: Add --force-delete option to sc-dast scan delete#960gilseara wants to merge 2 commits intofortify:dev/v3.xfrom
gilseara wants to merge 2 commits intofortify:dev/v3.xfrom
Conversation
added 2 commits
April 1, 2026 15:57
Add --force-delete / -f option that appends forceDelete=true query parameter to the scan-action API call, enabling forced deletion of SC DAST scans via /api/v2/scans/<id>?forceDelete=true.
The kong.unirest.core package is not available in the sc-dast module's classpath. Replace the updateRequest hook with a getQueryParameters method that returns a Map, avoiding the dependency issue.
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.
The goal is to match the functionality offered on the GUI for deleting scans that are problematic (i.e. FailedToPause, etc...), see ForceDelete option below:
Summary
--force-delete/-foption tofcli sc-dast scan deletecommandforceDelete=truequery parameter to the scan-action API call (/api/v2/scans/<id>?forceDelete=true)updateRequest()hook inAbstractSCDastScanActionCommandso subclasses can customize HTTP requestsTest plan
fcli sc-dast scan delete <id>without--force-delete— should behave as beforefcli sc-dast scan delete <id> --force-delete— should include?forceDelete=truein the API callfcli sc-dast scan delete <id> -f— same as above using short flag