Skip to content
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

Remove non standard header findings and add deprecated headers findings #3127

Merged
merged 12 commits into from
Jul 5, 2024

Conversation

noamblitz
Copy link
Contributor

@noamblitz noamblitz commented Jun 24, 2024

Changes

Remove findings from non standard headers as stated in #2731

Issue link

Closes #2731

Demo

Please add some proof in the form of screenshots or screen recordings to show (off) new functionality, if there are interesting new features for end-users.

QA notes

Please add some information for QA on how to test the newly created code.


Code Checklist

  • All the commits in this PR are properly PGP-signed and verified.
  • This PR only contains functionality relevant to the issue.
  • I have written unit tests for the changes or fixes I made.
  • I have checked the documentation and made changes where necessary.
  • I have performed a self-review of my code and refactored it to the best of my abilities.
  • Tickets have been created for newly discovered issues.
  • For any non-trivial functionality, I have added integration and/or end-to-end tests.
  • I have informed others of any required .env changes files if required and changed the .env-dist accordingly.
  • I have included comments in the code to elaborate on what is not self-evident from the code itself, including references to issues and discussions online, or implicit behavior of an interface.

Checklist for code reviewers:

Copy-paste the checklist from the docs/source/templates folder into your comment.


Checklist for QA:

Copy-paste the checklist from the docs/source/templates folder into your comment.

@noamblitz noamblitz requested a review from a team as a code owner June 24, 2024 13:43
ammar92
ammar92 previously approved these changes Jun 25, 2024
Copy link
Contributor

@ammar92 ammar92 left a comment

Choose a reason for hiding this comment

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

No remarks

@underdarknl
Copy link
Contributor

underdarknl commented Jun 25, 2024

Seeing that these headers are not longer required, they are however still not-standard.
Maybe we should introduce a finding for those (if don't already have one) and raise that for all of these non-standard headers.
The following not standard headers would warrant this I'd think:

There's also the deprecated headers that might warrant a similar warning

@noamblitz noamblitz changed the title Remove non standard header findings Remove non standard header findings and add deprecated headers findings Jun 25, 2024
@underdarknl
Copy link
Contributor

Nice! looks good to me.

@stephanie0x00
Copy link
Contributor

As discussed with @noamblitz the title of the finding is renamed to "KAT-NONSTANDARD-HEADERS" for all these headers to include the headers listed below. In the future it would be nice to have these split into two categories: Non-standard findings and deprecated findings.

Seeing that these headers are not longer required, they are however still not-standard. Maybe we should introduce a finding for those (if don't already have one) and raise that for all of these non-standard headers. The following not standard headers would warrant this I'd think:

* [X-Forwarded-For](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For)

* [X-Forwarded-Host](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-Host)

* [X-Forwarded-Proto](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-Proto)

* [X-DNS-Prefetch-Control](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-DNS-Prefetch-Control)

* [X-Robots-Tag](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Robots-Tag)

There's also the deprecated headers that might warrant a similar warning

* [Pragma](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Pragma)

* [Warning](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Warning)

@stephanie0x00
Copy link
Contributor

Checklist for QA:

  • I have checked out this branch, and successfully ran a fresh make reset.
  • I confirmed that there are no unintended functional regressions in this branch:
    • I have managed to pass the onboarding flow
    • Objects and Findings are created properly
    • Tasks are created and completed properly
  • I confirmed that the PR's advertised feature or hotfix works as intended.
  • I checked the logs for errors and/or warnings and made issues where necessary

What works:

Looks good. Manually added the various deprecated and non-standard hosts. They are now all gathered under the'Non-standard header' finding. Created a new ticket to split these into non-standard and deprecated headers, as that would be more ideal. #3188

What doesn't work:

n/a

Bug or feature?:

n/a

@underdarknl underdarknl merged commit 57ba182 into main Jul 5, 2024
20 checks passed
@underdarknl underdarknl deleted the remove-nonstandard-headers branch July 5, 2024 09:30
jpbruinsslot added a commit that referenced this pull request Jul 16, 2024
* main: (31 commits)
  Refactor Task List and filters with error handlers for Scheduler  (#1957)
  Fix filtering on plugin_id for normalizers (#3226)
  Implement `structlog` (#3175)
  Gather BIT metrics [implementation] (#3122)
  Add observation data to observation table in OOI detail page (#3186)
  cve-2024-6387 from RickGeex (#3194)
  Recalculate bit when a config object changes (#3206)
  Use more concise regexes (#3181)
  Updated Django (#3217)
  Updated `zipp` (#3215)
  Feature/boefje normalizer config models (#3118)
  Updated `certifi` (#3209)
  Add pluginToggler.js to Aggregate Report (#3202)
  Update to Django 5.0 (#2939)
  Update Dockerfile, fix Sonarcloud issue (#3180)
  Better default list of world writable domains in CSP checker (#3165)
  Update 1.16 release notes (#3195)
  Remove non standard header findings and add deprecated headers findings (#3127)
  Fix/sonarcloud https redirect dockerfiles (#3185)
  Bump docker/build-push-action from 5 to 6 (#3164)
  ...
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.

Non-standard HTTP headers are finding recommendations
4 participants