Skip to content

Consistent "Close old findings" between UI and API#12774

Merged
valentijnscholten merged 1 commit into
DefectDojo:devfrom
fopina:fix/close_old_labels
Jul 14, 2025
Merged

Consistent "Close old findings" between UI and API#12774
valentijnscholten merged 1 commit into
DefectDojo:devfrom
fopina:fix/close_old_labels

Conversation

@fopina

@fopina fopina commented Jul 11, 2025

Copy link
Copy Markdown
Contributor

Description

If we look at the import scan result screen in the UI:

image

If we look at the API description for the same fields:

image

I found this confusing the first time I saw and it made me check the code to make sure they were setting the same fields (and they are).

This PR tries to put them in sync, by rephrasing the ones in the UI (as those seem the furthest from the actual variable intent).

I think it could be done the other way around or even switching the field to choices field (Do not close, Close at engagement level, Close at product level) but those would impact API consumers...

Checklist

This checklist is for your information.

  • Make sure to rebase your PR against the very latest dev.
  • Features/Changes should be submitted against the dev.
  • Bugfixes should be submitted against the bugfix branch.
  • Give a meaningful name to your PR, as it may end up being used in the release notes.
  • Your code is flake8 compliant.
  • Your code is python 3.11 compliant.
  • If this is a new feature and not a bug fix, you've included the proper documentation in the docs at https://github.com/DefectDojo/django-DefectDojo/tree/dev/docs as part of this PR.
  • Model changes must include the necessary migrations in the dojo/db_migrations folder.
  • Add applicable tests to the unit tests.
  • Add the proper label to categorize your PR.

@fopina fopina requested review from Maffooch and mtesauro as code owners July 11, 2025 19:12
@fopina fopina marked this pull request as draft July 11, 2025 19:12
@dryrunsecurity

dryrunsecurity Bot commented Jul 11, 2025

Copy link
Copy Markdown

DryRun Security

🔴 Risk threshold exceeded.

This pull request contains a sensitive edit to the file "dojo/forms.py" which requires configuration in the .dryrunsecurity.yaml file, but is currently not blocking the pull request.

🔴 Configured Codepaths Edit in dojo/forms.py
Vulnerability Configured Codepaths Edit
Description Sensitive edits detected for this file. Sensitive file paths and allowed authors can be configured in .dryrunsecurity.yaml.

We've notified @mtesauro.


All finding details can be found in the DryRun Security Dashboard.

@fopina fopina changed the title x Consistent "Close old findings" between UI and API Jul 11, 2025
@fopina fopina force-pushed the fix/close_old_labels branch from 1f52cb2 to 8627254 Compare July 11, 2025 22:33
@fopina fopina marked this pull request as ready for review July 11, 2025 22:33
@Maffooch Maffooch requested review from blakeaowens and dogboat July 11, 2025 23:43

@mtesauro mtesauro left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved

@valentijnscholten valentijnscholten added this to the 2.49.0 milestone Jul 14, 2025
@valentijnscholten valentijnscholten merged commit 96ddf1c into DefectDojo:dev Jul 14, 2025
85 checks passed
@fopina fopina deleted the fix/close_old_labels branch July 15, 2025 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants