j3graham commented on code in PR #370: URL: https://github.com/apache/httpcomponents-client/pull/370#discussion_r880025041
########## httpclient5-testing/src/main/java/org/apache/hc/client5/testing/auth/BasicAuthTokenExtractor.java: ########## @@ -49,9 +47,9 @@ public String extract(final String challengeResponse) throws HttpException { final String s = challengeResponse.substring(i + 1).trim(); try { final byte[] credsRaw = s.getBytes(StandardCharsets.US_ASCII); - final BinaryDecoder codec = new Base64(); + final Base64 codec = new Base64(); return new String(codec.decode(credsRaw), StandardCharsets.US_ASCII); - } catch (final DecoderException ex) { Review Comment: Although `BinaryDecoder.decode` declares this exception, the Base64 subclasses did not actually ever throw the exception. I've left the handling in place as a reminder of how invalid inputs can be handled. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@hc.apache.org For additional commands, e-mail: dev-h...@hc.apache.org