From c097024499dcf2526e47664e2ccd0ac90015bb49 Mon Sep 17 00:00:00 2001 From: Dave Cramer Date: Tue, 13 Oct 2020 12:38:46 -0400 Subject: [PATCH] add allow to the gssEncMode property and correct the comment in GSSEncMode enum (#1920) --- pgjdbc/src/main/java/org/postgresql/PGProperty.java | 4 ++-- pgjdbc/src/main/java/org/postgresql/jdbc/GSSEncMode.java | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pgjdbc/src/main/java/org/postgresql/PGProperty.java b/pgjdbc/src/main/java/org/postgresql/PGProperty.java index 342d01e171..3f4cad6724 100644 --- a/pgjdbc/src/main/java/org/postgresql/PGProperty.java +++ b/pgjdbc/src/main/java/org/postgresql/PGProperty.java @@ -184,10 +184,10 @@ public enum PGProperty { GSS_ENC_MODE( "gssEncMode", - "prefer", + "allow", "Force Encoded GSS Mode", false, - new String[] {"disable", "prefer", "require"} + new String[] {"disable", "allow", "prefer", "require"} ), /** diff --git a/pgjdbc/src/main/java/org/postgresql/jdbc/GSSEncMode.java b/pgjdbc/src/main/java/org/postgresql/jdbc/GSSEncMode.java index a43583f1d5..10367129d0 100644 --- a/pgjdbc/src/main/java/org/postgresql/jdbc/GSSEncMode.java +++ b/pgjdbc/src/main/java/org/postgresql/jdbc/GSSEncMode.java @@ -48,7 +48,7 @@ public boolean requireEncryption() { public static GSSEncMode of(Properties info) throws PSQLException { String gssEncMode = PGProperty.GSS_ENC_MODE.get(info); - // If gssEncMode is not set, fallback to prefer + // If gssEncMode is not set, fallback to allow if (gssEncMode == null) { return ALLOW; }