-
Notifications
You must be signed in to change notification settings - Fork 7
UID2-5482 Use handleWithAudit for auth middleware #173
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
Conversation
4dabb1c to
38f7d2c
Compare
| public static final String OptOutDeleteExpiredProp = "optout_delete_expired"; | ||
| public static final String PartnersConfigPathProp = "partners_config_path"; | ||
| public static final String PartnersMetadataPathProp = "partners_metadata_path"; | ||
| public static final String EnableAuditLoggingProp = "enable_audit_logging"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we want the Auditlog to be enabled always for optout. So this config may become redundant later.
e02b247 to
440476a
Compare
440476a to
f632b86
Compare
| final String jwtAudience = jsonConfig.getString(Const.Config.OptOutUrlProp); | ||
| final String jwtIssuer = jsonConfig.getString(Const.Config.CorePublicUrlProp); | ||
| Boolean enforceJwt = jsonConfig.getBoolean(Const.Config.EnforceJwtProp, true); | ||
| Boolean enforceJwt = jsonConfig.getBoolean(Const.Config.EnforceJwtProp, false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this intentional to keep default value false ?
| Handler<RoutingContext> handler = internalAuth.handleWithAudit(nextHandler); | ||
| handler.handle(routingContext); | ||
| verifyNoInteractions(nextHandler); | ||
| verify(routingContext).fail(401); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you add a positive test case as well ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
No description provided.