Skip to content

Capability to bypass URL in Role based authentication filter#1205

Merged
bharatmotwani merged 3 commits intomasterfrom
Allow-byPass-availablities-endpoint
Sep 30, 2021
Merged

Capability to bypass URL in Role based authentication filter#1205
bharatmotwani merged 3 commits intomasterfrom
Allow-byPass-availablities-endpoint

Conversation

@bharatmotwani
Copy link
Copy Markdown
Contributor

I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.

*/
protected boolean isByPassURL(List<String> allowedUrls, ContainerRequestContext containerRequestContext) {
String url = containerRequestContext.getUriInfo().getAbsolutePath().getPath();
return allowedUrls.stream().anyMatch(path -> path.startsWith(url));
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Don't do starts with, use Java Pattern class to process the result.

@bharatmotwani bharatmotwani merged commit cc6f286 into master Sep 30, 2021
@bharatmotwani bharatmotwani deleted the Allow-byPass-availablities-endpoint branch September 30, 2021 20:57
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