From 833dbb0a409c5861df647f166adfe70572e7ca7c Mon Sep 17 00:00:00 2001 From: Hiroshi Inoue Date: Thu, 24 Aug 2017 20:19:36 +0900 Subject: [PATCH] Remove the GssAuthUseGssapi option completely. --- connection.c | 4 ---- dlg_specific.c | 22 ---------------------- dlg_specific.h | 4 ---- dlg_wingui.c | 2 -- psqlodbc.h | 1 - psqlodbc.rc | 4 ---- 6 files changed, 37 deletions(-) diff --git a/connection.c b/connection.c index a901d12..dbe703b 100644 --- a/connection.c +++ b/connection.c @@ -2712,10 +2712,6 @@ LIBPQ_connect(ConnectionClass *self) { opts[cnt] = "password"; vals[cnt++] = SAFE_NAME(ci->password); } - if (ci->gssauth_use_gssapi) - { - opts[cnt] = "gsslib"; vals[cnt++] = "gssapi"; - } if (ci->disable_keepalive) { opts[cnt] = "keepalives"; vals[cnt++] = "0"; diff --git a/dlg_specific.c b/dlg_specific.c index 5a4e68a..3fc1ea5 100644 --- a/dlg_specific.c +++ b/dlg_specific.c @@ -352,9 +352,6 @@ MYLOG(1, "hlen=" FORMAT_SSIZE_T "\n", hlen); INI_LOWERCASEIDENTIFIER "=%d;" "%s" /* INI_PQOPT */ "%s" /* INIKEEPALIVE TIME/INTERVAL */ -#ifdef WIN32 - INI_GSSAUTHUSEGSSAPI "=%d;" -#endif /* WIN32 */ #ifdef _HANDLE_ENLIST_IN_DTC_ INI_XAOPT "=%d" /* XAOPT */ #endif /* _HANDLE_ENLIST_IN_DTC_ */ @@ -387,9 +384,6 @@ MYLOG(1, "hlen=" FORMAT_SSIZE_T "\n", hlen); ,ci->lower_case_identifier ,makeBracketConnectString(&pqoptStr, ci->pqopt, INI_PQOPT) ,makeKeepaliveConnectString(keepaliveStr, sizeof(keepaliveStr), ci, FALSE) -#ifdef WIN32 - ,ci->gssauth_use_gssapi -#endif /* WIN32 */ #ifdef _HANDLE_ENLIST_IN_DTC_ ,ci->xa_opt #endif /* _HANDLE_ENLIST_IN_DTC_ */ @@ -446,8 +440,6 @@ MYLOG(1, "hlen=" FORMAT_SSIZE_T "\n", hlen); flag |= BIT_USESERVERSIDEPREPARE; if (ci->lower_case_identifier) flag |= BIT_LOWERCASEIDENTIFIER; - if (ci->gssauth_use_gssapi) - flag |= BIT_GSSAUTHUSEGSSAPI; if (ci->sslmode[0]) { @@ -567,7 +559,6 @@ unfoldCXAttribute(ConnInfo *ci, const char *value) ci->bytea_as_longvarbinary = (char)((flag & BIT_BYTEAASLONGVARBINARY) != 0); ci->use_server_side_prepare = (char)((flag & BIT_USESERVERSIDEPREPARE) != 0); ci->lower_case_identifier = (char)((flag & BIT_LOWERCASEIDENTIFIER) != 0); - ci->gssauth_use_gssapi = (char)((flag & BIT_GSSAUTHUSEGSSAPI) != 0); } BOOL @@ -669,8 +660,6 @@ copyConnAttributes(ConnInfo *ci, const char *attribute, const char *value) ci->use_server_side_prepare = atoi(value); else if (stricmp(attribute, INI_LOWERCASEIDENTIFIER) == 0 || stricmp(attribute, ABBR_LOWERCASEIDENTIFIER) == 0) ci->lower_case_identifier = atoi(value); - else if (stricmp(attribute, INI_GSSAUTHUSEGSSAPI) == 0 || stricmp(attribute, ABBR_GSSAUTHUSEGSSAPI) == 0) - ci->gssauth_use_gssapi = atoi(value); else if (stricmp(attribute, INI_KEEPALIVETIME) == 0 || stricmp(attribute, ABBR_KEEPALIVETIME) == 0) ci->keepalive_idle = atoi(value); else if (stricmp(attribute, INI_KEEPALIVEINTERVAL) == 0 || stricmp(attribute, ABBR_KEEPALIVEINTERVAL) == 0) @@ -800,7 +789,6 @@ getCiDefaults(ConnInfo *ci) ci->bytea_as_longvarbinary = DEFAULT_BYTEAASLONGVARBINARY; ci->use_server_side_prepare = DEFAULT_USESERVERSIDEPREPARE; ci->lower_case_identifier = DEFAULT_LOWERCASEIDENTIFIER; - ci->gssauth_use_gssapi = DEFAULT_GSSAUTHUSEGSSAPI; STRCPY_FIXED(ci->sslmode, DEFAULT_SSLMODE); ci->force_abbrev_connstr = 0; ci->fake_mss = 0; @@ -1014,9 +1002,6 @@ MYLOG(0, "drivername=%s\n", drivername); if (SQLGetPrivateProfileString(DSN, INI_LOWERCASEIDENTIFIER, NULL_STRING, temp, sizeof(temp), ODBC_INI) > 0) ci->lower_case_identifier = atoi(temp); - if (SQLGetPrivateProfileString(DSN, INI_GSSAUTHUSEGSSAPI, NULL_STRING, temp, sizeof(temp), ODBC_INI) > 0) - ci->gssauth_use_gssapi = atoi(temp); - if (SQLGetPrivateProfileString(DSN, INI_KEEPALIVETIME, NULL_STRING, temp, sizeof(temp), ODBC_INI) > 0) if (0 == (ci->keepalive_idle = atoi(temp))) ci->keepalive_idle = -1; @@ -1285,11 +1270,6 @@ writeDSNinfo(const ConnInfo *ci) INI_LOWERCASEIDENTIFIER, temp, ODBC_INI); - ITOA_FIXED(temp, ci->gssauth_use_gssapi); - SQLWritePrivateProfileString(DSN, - INI_GSSAUTHUSEGSSAPI, - temp, - ODBC_INI); SQLWritePrivateProfileString(DSN, INI_SSLMODE, ci->sslmode, @@ -1727,7 +1707,6 @@ CC_conninfo_init(ConnInfo *conninfo, UInt4 option) conninfo->accessible_only = -1; conninfo->ignore_round_trip_time = -1; conninfo->disable_keepalive = -1; - conninfo->gssauth_use_gssapi = -1; conninfo->keepalive_idle = -1; conninfo->keepalive_interval = -1; conninfo->wcs_debug = -1; @@ -1824,7 +1803,6 @@ CC_copy_conninfo(ConnInfo *ci, const ConnInfo *sci) CORR_VALCPY(accessible_only); CORR_VALCPY(ignore_round_trip_time); CORR_VALCPY(disable_keepalive); - CORR_VALCPY(gssauth_use_gssapi); CORR_VALCPY(extra_opts); CORR_VALCPY(keepalive_idle); CORR_VALCPY(keepalive_interval); diff --git a/dlg_specific.h b/dlg_specific.h index bedb103..e28cc69 100644 --- a/dlg_specific.h +++ b/dlg_specific.h @@ -157,8 +157,6 @@ extern "C" { #define ABBR_SSLMODE "CA" #define INI_EXTRAOPTIONS "AB" #define INI_LOGDIR "Logdir" -#define INI_GSSAUTHUSEGSSAPI "GssAuthUseGSS" -#define ABBR_GSSAUTHUSEGSSAPI "D0" #define INI_KEEPALIVETIME "KeepaliveTime" #define ABBR_KEEPALIVETIME "D1" #define INI_KEEPALIVEINTERVAL "KeepaliveInterval" @@ -212,7 +210,6 @@ extern "C" { #define BIT_BYTEAASLONGVARBINARY (1L<<24) #define BIT_USESERVERSIDEPREPARE (1L<<25) #define BIT_LOWERCASEIDENTIFIER (1L<<26) -#define BIT_GSSAUTHUSEGSSAPI (1L<<27) #define EFFECTIVE_BIT_COUNT 28 @@ -262,7 +259,6 @@ extern "C" { #define DEFAULT_USESERVERSIDEPREPARE 1 #define DEFAULT_LOWERCASEIDENTIFIER 0 #define DEFAULT_SSLMODE SSLMODE_DISABLE -#define DEFAULT_GSSAUTHUSEGSSAPI 0 #ifdef _HANDLE_ENLIST_IN_DTC_ #define DEFAULT_XAOPT 1 diff --git a/dlg_wingui.c b/dlg_wingui.c index 0d31ded..8bae363 100644 --- a/dlg_wingui.c +++ b/dlg_wingui.c @@ -495,7 +495,6 @@ ds_options_update(HWND hdlg, ConnInfo *ci) ci->use_server_side_prepare = IsDlgButtonChecked(hdlg, DS_SERVERSIDEPREPARE); ci->bytea_as_longvarbinary = IsDlgButtonChecked(hdlg, DS_BYTEAASLONGVARBINARY); /*ci->lower_case_identifier = IsDlgButtonChecked(hdlg, DS_LOWERCASEIDENTIFIER);*/ - ci->gssauth_use_gssapi = IsDlgButtonChecked(hdlg, DS_GSSAUTHUSEGSSAPI); /* OID Options */ ITOA_FIXED(ci->fake_oid_index, IsDlgButtonChecked(hdlg, DS_FAKEOIDINDEX)); @@ -626,7 +625,6 @@ ds_options2Proc(HWND hdlg, CheckDlgButton(hdlg, DS_SERVERSIDEPREPARE, ci->use_server_side_prepare); CheckDlgButton(hdlg, DS_BYTEAASLONGVARBINARY, ci->bytea_as_longvarbinary); /*CheckDlgButton(hdlg, DS_LOWERCASEIDENTIFIER, ci->lower_case_identifier);*/ - CheckDlgButton(hdlg, DS_GSSAUTHUSEGSSAPI, ci->gssauth_use_gssapi); EnableWindow(GetDlgItem(hdlg, DS_FAKEOIDINDEX), atoi(ci->show_oid_column)); diff --git a/psqlodbc.h b/psqlodbc.h index b4d5465..7b6452e 100644 --- a/psqlodbc.h +++ b/psqlodbc.h @@ -612,7 +612,6 @@ typedef struct signed char accessible_only; signed char ignore_round_trip_time; signed char disable_keepalive; - signed char gssauth_use_gssapi; signed char wcs_debug; UInt4 extra_opts; Int4 keepalive_idle; diff --git a/psqlodbc.rc b/psqlodbc.rc index b0aeea8..96a3119 100644 --- a/psqlodbc.rc +++ b/psqlodbc.rc @@ -199,8 +199,6 @@ BEGIN PUSHBUTTON "“K—p",IDAPPLY,128,ENDLINE_Y,50,14 CONTROL "bytea‚ðLO‚Æ‚µ‚Ĉµ‚¤",DS_BYTEAASLONGVARBINARY,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,15,85,87,10 - /* CONTROL "Kerberos‰ž“š‚ÉGSSAPI—˜—p",DS_GSSAUTHUSEGSSAPI,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,139,85,110,10 */ END #define DTC_GRP_X 10 @@ -604,8 +602,6 @@ BEGIN BS_AUTOCHECKBOX | WS_TABSTOP,163,71,90,10 CONTROL "bytea as LO",DS_BYTEAASLONGVARBINARY,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,16,84,87,10 - CONTROL "use gssapi for GSS request",DS_GSSAUTHUSEGSSAPI,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,163,84,110,10 GROUPBOX "Int8 As",IDC_STATIC,5,97,256,25 CONTROL "default",DS_INT8_AS_DEFAULT,"Button",BS_AUTORADIOBUTTON | WS_GROUP,12,107,40,10 -- 2.39.5