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 X-Powered-By header #1111

Merged
merged 2 commits into from Mar 25, 2024
Merged

Remove X-Powered-By header #1111

merged 2 commits into from Mar 25, 2024

Conversation

lognaturel
Copy link
Member

Follows the OWASP recommendation: https://cheatsheetseries.owasp.org/cheatsheets/HTTP_Headers_Cheat_Sheet.html#x-powered-by

This is not super important because there are many other ways to learn about the stack but it does get flagged by some security scanners.

What has been done to verify that this works as intended?

Ran it, looked at headers in console

Why is this the best possible solution? Were any other approaches considered?

I think this is the only approach!

How does this change affect users? Describe intentional changes to behavior and behavior that could have accidentally been affected by code changes. In other words, what are the regression risks?

Should have no risk of negative effect.

Does this change require updates to the API documentation? If so, please update docs/api.md as part of this PR.

No.

Before submitting this PR, please make sure you have:

  • run make test and confirmed all checks still pass OR confirm CircleCI build passes
  • verified that any code from external sources are properly credited in comments or that everything is internally sourced

Copy link
Contributor

@alxndrsn alxndrsn left a comment

Choose a reason for hiding this comment

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

LGTM. Added a test for this at #1112

const { headers } = await service.get('/v1/users/current');
should(headers['x-powered-by']).be.undefined();
}));
});
Copy link
Contributor

Choose a reason for hiding this comment

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

Looks familiar 😁

Copy link
Member Author

Choose a reason for hiding this comment

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

Haha, yeah, I cherry picked. The commit says it's authored by you so not sure why it's showing my face!

@lognaturel lognaturel merged commit 428ebdd into getodk:master Mar 25, 2024
1 check passed
@lognaturel lognaturel deleted the powered-by branch March 25, 2024 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ✅ done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants