You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2024/01/03 11:29:45 UTC
(tomcat) 02/12: GCM doesn't need padding so test using NoPadding
This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit ebf01c056e92117d5b85725261c7c055eb2f810d
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Wed Jan 3 09:15:08 2024 +0000
GCM doesn't need padding so test using NoPadding
---
.../group/interceptors/TestEncryptInterceptor.java | 17 ++++-------------
1 file changed, 4 insertions(+), 13 deletions(-)
diff --git a/test/org/apache/catalina/tribes/group/interceptors/TestEncryptInterceptor.java b/test/org/apache/catalina/tribes/group/interceptors/TestEncryptInterceptor.java
index b52c1ee66c..2b211c425b 100644
--- a/test/org/apache/catalina/tribes/group/interceptors/TestEncryptInterceptor.java
+++ b/test/org/apache/catalina/tribes/group/interceptors/TestEncryptInterceptor.java
@@ -19,7 +19,6 @@ package org.apache.catalina.tribes.group.interceptors;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
-import java.security.NoSuchAlgorithmException;
import java.security.Security;
import java.util.ArrayList;
import java.util.Collection;
@@ -272,18 +271,10 @@ public class TestEncryptInterceptor {
@Test
public void testGCM() throws Exception {
- try {
- src.setEncryptionAlgorithm("AES/GCM/PKCS5Padding");
- src.start(Channel.SND_TX_SEQ);
- dest.setEncryptionAlgorithm("AES/GCM/PKCS5Padding");
- dest.start(Channel.SND_TX_SEQ);
- } catch (ChannelException ce) {
- Assume.assumeFalse("Skipping testGCM due to lack of JVM support",
- ce.getCause() instanceof NoSuchAlgorithmException
- && ce.getCause().getMessage().contains("GCM"));
-
- throw ce;
- }
+ src.setEncryptionAlgorithm("AES/GCM/NoPadding");
+ src.start(Channel.SND_TX_SEQ);
+ dest.setEncryptionAlgorithm("AES/GCM/NoPadding");
+ dest.start(Channel.SND_TX_SEQ);
String testInput = "The quick brown fox jumps over the lazy dog.";
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org