Skip to content

Commit

Permalink
log
Browse files Browse the repository at this point in the history
  • Loading branch information
jan-olaveide committed Dec 6, 2023
1 parent 767a1fc commit 449cfb7
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ static List<JwtToken> retrieveUnvalidatedTokens(MultiIssuerConfiguration config,

private static List<JwtToken> getTokensFromHeader(MultiIssuerConfiguration config, HttpRequest request) {
try {
LOG.debug("Checking authorization header for tokens");
LOG.debug("Checking authorization header for tokens using config " + config);

var issuers = config.getIssuers();
Optional<IssuerConfiguration> issuer = issuers.values().stream().filter(it -> request.getHeader(it.getHeaderName()) != null).findFirst();
Expand Down Expand Up @@ -76,4 +76,4 @@ private static List<String> extractBearerTokens(String... headerValues) {
.map(pair -> pair[1].trim())
.toList();
}
}
}
11 changes: 11 additions & 0 deletions token-validation-jaxrs/src/test/resources/logback.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<configuration>
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d{YYYY-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root level="info">
<appender-ref ref="STDOUT"/>
</root>
<logger name="no.nav.security" level="trace"/>
</configuration>

0 comments on commit 449cfb7

Please sign in to comment.