security: non-breaking: Add option "allowInsecureRedirect"#30
Closed
legobeat wants to merge 2 commits intocypress-io:masterfrom
Closed
security: non-breaking: Add option "allowInsecureRedirect"#30legobeat wants to merge 2 commits intocypress-io:masterfrom
legobeat wants to merge 2 commits intocypress-io:masterfrom
Conversation
3 tasks
legobeat
commented
Mar 25, 2023
tests/test-redirect.js
Outdated
| }) | ||
| }) | ||
|
|
||
| tape('http to https redirect should fail without the explicit "allowInsecureRedirect" option', function (t) { |
Author
There was a problem hiding this comment.
would be good to check for the inverse (https to http) as well if anyone feels up for adding it.
796f02d to
6d4e013
Compare
Closed
ewoelfel
approved these changes
Aug 1, 2023
ewoelfel
approved these changes
Aug 1, 2023
- Addresses CVE-2023-28155 - Existing behavior allows malicios redirects between protocols - Set default behavior to disable this vector (breaking) - Add new option `allowInsecureRedirect` where `true` reverts to old behavior - Ported from request#3444
6d4e013 to
3323308
Compare
3 tasks
|
note that to properly resolve GHSA-p8p7-x288-28g6 this behaviour needs to be enabled by default - given the usecase of this library and that it's a security issue I think it would be fair to argue this is a bug and so valid to change in a patch version with it enabled by default (i.e. #28) |
|
Closing in favor of #28 |
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.
PR Checklist:
npm testlocally and all tests are passing.PR Description
allowInsecureRedirectwherefalsedisables this behaviorThis is intended as a non-breaking alternative to #28. The only functional difference is that this version retains the default behavior and
allowInsecureRedirectneeds to be set explicitly to disable cross-protocol redirects.