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

feat: harden headers security #592

Merged
merged 10 commits into from
Sep 22, 2023
Merged

feat: harden headers security #592

merged 10 commits into from
Sep 22, 2023

Conversation

Jabolol
Copy link
Contributor

@Jabolol Jabolol commented Sep 16, 2023

Work in progress. See #591 for the relevant discussion.

Copy link
Contributor

@iuioiua iuioiua left a comment

Choose a reason for hiding this comment

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

Good start! See if this is valuable to you in this PR.

middleware/headers.ts Outdated Show resolved Hide resolved
middleware/headers.ts Outdated Show resolved Hide resolved
@Jabolol
Copy link
Contributor Author

Jabolol commented Sep 17, 2023

Good start! See if this is valuable to you in this PR.

Oh I completely missed that section of the docs! It’s most useful, thanks for the heads up. I’ll implement the changes requested ASAP.

@Jabolol
Copy link
Contributor Author

Jabolol commented Sep 20, 2023

Once denoland/fresh#1787 lands we will be able to achieve an A+ score

@iuioiua
Copy link
Contributor

iuioiua commented Sep 20, 2023

Once denoland/fresh#1787 lands we will be able to achieve an A+ score

Let's add a @todo in this PR. I'd like to merge this PR sooner rather than depend on that PR.

Copy link
Contributor

@iuioiua iuioiua left a comment

Choose a reason for hiding this comment

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

Looking better! Can you please add a test?

plugins/security_headers.ts Outdated Show resolved Hide resolved
@Jabolol
Copy link
Contributor Author

Jabolol commented Sep 20, 2023

Looking better! Can you please add a test?

Done! Comment improved and added a test case. Let me know if I should add something else

@iuioiua
Copy link
Contributor

iuioiua commented Sep 20, 2023

Test logic looks good! However, are we able to do this in a /plugins/security_headers_test.ts file?

@Jabolol
Copy link
Contributor Author

Jabolol commented Sep 20, 2023

Test logic looks good! However, are we able to do this in a /plugins/security_headers_test.ts file?

Yeah, that's better indeed. Moved it.

@iuioiua
Copy link
Contributor

iuioiua commented Sep 21, 2023

Is this ready for review?

@iuioiua iuioiua marked this pull request as ready for review September 22, 2023 02:41
Copy link
Contributor

@iuioiua iuioiua left a comment

Choose a reason for hiding this comment

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

I'm going to assume this PR is ready to go. I tested it on my local machine, and it works without hiccups! LGTM! Thank you, @Jabolol.

@iuioiua iuioiua merged commit d3bc49b into denoland:main Sep 22, 2023
6 checks passed
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.

2 participants