浏览代码

Update to commons-codec:1.15

Closes gh-9575
Josh Cummings 4 年之前
父节点
当前提交
7da6077727

+ 1 - 1
dependencies/spring-security-dependencies.gradle

@@ -22,7 +22,7 @@ dependencies {
 		api "com.squareup.okhttp3:mockwebserver:3.14.9"
 		api "com.squareup.okhttp3:okhttp:3.14.9"
 		api "com.unboundid:unboundid-ldapsdk:4.0.14"
-		api "commons-codec:commons-codec:1.14"
+		api "commons-codec:commons-codec:1.15"
 		api "commons-collections:commons-collections:3.2.2"
 		api "commons-logging:commons-logging:1.2"
 		api "io.projectreactor.tools:blockhound:1.0.6.RELEASE"

+ 2 - 1
saml2/saml2-service-provider/core/src/main/java/org/springframework/security/saml2/provider/service/web/Saml2AuthenticationTokenConverter.java

@@ -23,6 +23,7 @@ import java.util.zip.InflaterOutputStream;
 
 import javax.servlet.http.HttpServletRequest;
 
+import org.apache.commons.codec.CodecPolicy;
 import org.apache.commons.codec.binary.Base64;
 
 import org.springframework.core.convert.converter.Converter;
@@ -45,7 +46,7 @@ import org.springframework.util.Assert;
  */
 public final class Saml2AuthenticationTokenConverter implements AuthenticationConverter {
 
-	private static Base64 BASE64 = new Base64(0, new byte[] { '\n' });
+	private static Base64 BASE64 = new Base64(0, new byte[] { '\n' }, false, CodecPolicy.STRICT);
 
 	private final Converter<HttpServletRequest, RelyingPartyRegistration> relyingPartyRegistrationResolver;