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.
Fixes for Cookie Authentication. This builds on top of the changes done as part of the issue #8683 (PR #8689) and #9710. The changes done as part of that PR don't work (both setting the Cookie as well as resetting it).
Description
Motivation and Context
The Cookie based Authentication was not working in at least Safari. Neither was the cookie being set, nor was was it being unset (after fixing the setting part). This was causing the API testing of Cookie Authentication based endpoints impossible.
The official Mozilla Developer Documentation on document.cookie was followed to implement the fix.
Swagger UI's official documentation states that cross domain Cookie Auth is not supported. While that may still be the case after this fix is released because of CORS blocks, this fix will work if the swagger UI is loaded from the same domain, where the APIs reside.
Fixes for removing the set Cookies have also been added
How Has This Been Tested?
persistAuthorization
configuration field was set to trueCookie
Request Header was verified to have an entry for the authentication cookieScreenshots (if appropriate):
Checklist
My PR contains...
src/
is unmodified: changes to documentation, CI, metadata, etc.)package.json
)My changes...
Documentation
Automated tests