Skip to content

Commit 57a3521

Browse files
committed
Merge branch '3.5.x' into 4.0.x
Closes gh-49818
2 parents 54d923f + 72cd3b5 commit 57a3521

6 files changed

Lines changed: 6 additions & 6 deletions

File tree

buildpack/spring-boot-buildpack-platform/src/main/java/org/springframework/boot/buildpack/platform/docker/ssl/PemCertificateParser.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ private static void readCertificates(String text, CertificateFactory factory, Co
9696
}
9797

9898
private static byte[] decodeBase64(String content) {
99-
byte[] bytes = content.replaceAll("\r", "").replaceAll("\n", "").getBytes();
99+
byte[] bytes = content.replace("\r", "").replace("\n", "").getBytes();
100100
return Base64.getDecoder().decode(bytes);
101101
}
102102

buildpack/spring-boot-buildpack-platform/src/main/java/org/springframework/boot/buildpack/platform/docker/ssl/PemPrivateKeyParser.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ private static class PemParser {
244244
}
245245

246246
private static byte[] decodeBase64(String content) {
247-
byte[] contentBytes = content.replaceAll("\r", "").replaceAll("\n", "").getBytes();
247+
byte[] contentBytes = content.replace("\r", "").replace("\n", "").getBytes();
248248
return Base64.getDecoder().decode(contentBytes);
249249
}
250250

buildpack/spring-boot-buildpack-platform/src/test/java/org/springframework/boot/buildpack/platform/build/LifecycleTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -482,7 +482,7 @@ private Answer<ContainerReference> answerWithGeneratedContainerId() {
482482
return (invocation) -> {
483483
ContainerConfig config = invocation.getArgument(0, ContainerConfig.class);
484484
ArrayNode command = getCommand(config);
485-
String name = command.get(0).asString().substring(1).replaceAll("/", "-");
485+
String name = command.get(0).asString().substring(1).replace('/', '-');
486486
this.configs.put(name, config);
487487
if (invocation.getArguments().length > 2) {
488488
this.content.put(name, invocation.getArgument(2, ContainerContent.class));

buildpack/spring-boot-buildpack-platform/src/test/java/org/springframework/boot/buildpack/platform/docker/ssl/PemFileWriter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ public PemFileWriter() throws IOException {
181181
Path writeFile(String name, String... contents) throws IOException {
182182
Path path = Paths.get(this.tempDir.toString(), name);
183183
for (String content : contents) {
184-
Files.write(path, content.replaceAll(EXAMPLE_SECRET_QUALIFIER, "").getBytes(), StandardOpenOption.CREATE,
184+
Files.write(path, content.replace(EXAMPLE_SECRET_QUALIFIER, "").getBytes(), StandardOpenOption.CREATE,
185185
StandardOpenOption.APPEND);
186186
}
187187
return path;

core/spring-boot/src/main/java/org/springframework/boot/ssl/pem/PemCertificateParser.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ private static void readCertificates(String text, CertificateFactory factory, Co
9696
}
9797

9898
private static byte[] decodeBase64(String content) {
99-
byte[] bytes = content.replaceAll("\r", "").replaceAll("\n", "").getBytes();
99+
byte[] bytes = content.replace("\r", "").replace("\n", "").getBytes();
100100
return Base64.getDecoder().decode(bytes);
101101
}
102102

core/spring-boot/src/main/java/org/springframework/boot/ssl/pem/PemPrivateKeyParser.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ private static class PemParser {
244244
}
245245

246246
private static byte[] decodeBase64(String content) {
247-
byte[] contentBytes = content.replaceAll("\r", "").replaceAll("\n", "").getBytes();
247+
byte[] contentBytes = content.replace("\r", "").replace("\n", "").getBytes();
248248
return Base64.getDecoder().decode(contentBytes);
249249
}
250250

0 commit comments

Comments
 (0)