On 03/06/2026 11:36, [email protected] wrote:
This is an automated email from the ASF dual-hosted git repository.

markt-asf pushed a commit to branch 11.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/11.0.x by this push:
      new 26f3b1d1ad Improve readability
26f3b1d1ad is described below

commit 26f3b1d1adafacfbd9c7e59ea66e73320d651240
Author: Mark Thomas <[email protected]>
AuthorDate: Wed Jun 3 11:36:21 2026 +0100

     Improve readability

This is interesting...

I made the above change because I couldn't find where init was set to true when I first looked at the method.

The first AI review (Cursor with Sonnet 4.6) says this is correct and is a good fix.

The second AI review (CoPilot with GPT-5.4) says this introduces a regression with an infinite loop.

I posted the above not to show how one AI model is better than another but to remind those of us using AI that it isn't perfect and that we should review any AI provided data (code reviews, patches, vulnerability reports etc) at least as carefully as we review any human provided input.

I'm off to check which model is correct. I suspect it GPT is correct but we'll see.

Mark



---
  .../util/net/openssl/ciphers/OpenSSLCipherConfigurationParser.java     | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git 
a/java/org/apache/tomcat/util/net/openssl/ciphers/OpenSSLCipherConfigurationParser.java
 
b/java/org/apache/tomcat/util/net/openssl/ciphers/OpenSSLCipherConfigurationParser.java
index 121807860e..0df4c298bd 100644
--- 
a/java/org/apache/tomcat/util/net/openssl/ciphers/OpenSSLCipherConfigurationParser.java
+++ 
b/java/org/apache/tomcat/util/net/openssl/ciphers/OpenSSLCipherConfigurationParser.java
@@ -493,7 +493,6 @@ public class OpenSSLCipherConfigurationParser {
          addListAlias(aSRP, filterByAuthentication(allCiphers, 
Collections.singleton(Authentication.SRP)));
          addListAlias(kSRP, filterByKeyExchange(allCiphers, 
Collections.singleton(KeyExchange.SRP)));
          addListAlias(SRP, filterByKeyExchange(allCiphers, 
Collections.singleton(KeyExchange.SRP)));
-        initialized = true;
          addListAlias(DEFAULT, 
parse("ALL:!eNULL:!aNULL:!DES:!RC2:!RC4:!DSS:!SEED:!IDEA:!CAMELLIA:!AESCCM:!3DES:!ARIA"));
          // COMPLEMENTOFDEFAULT is also not exactly as defined by the docs
          LinkedHashSet<Cipher> complementOfDefault =
@@ -512,6 +511,8 @@ public class OpenSSLCipherConfigurationParser {
          complementOfDefault.addAll(aliases.get(ARIA));
          defaultSort(complementOfDefault);
          addListAlias(COMPLEMENTOFDEFAULT, complementOfDefault);
+
+        initialized = true;
      }
static void addListAlias(String alias, Set<Cipher> ciphers) {


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to