mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2025-08-06 18:24:26 +08:00
Add cleartext option to sessions
This commit is contained in:

committed by
Ansgar Becker

parent
6641b82a43
commit
0facfaa5cc
@ -141,7 +141,7 @@ type
|
||||
asWrapLongLines, asDisplayBLOBsAsText, asSingleQueries, asMemoEditorWidth, asMemoEditorHeight, asMemoEditorMaximized,
|
||||
asMemoEditorWrap, asDelimiter, asSQLHelpWindowLeft, asSQLHelpWindowTop, asSQLHelpWindowWidth,
|
||||
asSQLHelpWindowHeight, asSQLHelpPnlLeftWidth, asSQLHelpPnlRightTopHeight, asHost,
|
||||
asUser, asPassword, asWindowsAuth, asLoginPrompt, asPort,
|
||||
asUser, asPassword, asCleartextPluginEnabled, asWindowsAuth, asLoginPrompt, asPort,
|
||||
asPlinkExecutable, asSSHtunnelHost, asSSHtunnelHostPort, asSSHtunnelPort, asSSHtunnelUser,
|
||||
asSSHtunnelPassword, asSSHtunnelTimeout, asSSHtunnelPrivateKey, asSSLActive, asSSLKey,
|
||||
asSSLCert, asSSLCA, asSSLCipher, asNetType, asCompressed, asLocalTimeZone, asQueryTimeout, asKeepAlive,
|
||||
@ -2627,7 +2627,7 @@ var
|
||||
rx: TRegExpr;
|
||||
ExeName, SessName, Host, User, Pass, Socket,
|
||||
SSLPrivateKey, SSLCACertificate, SSLCertificate, SSLCipher: String;
|
||||
Port, NetType, WindowsAuth, WantSSL: Integer;
|
||||
Port, NetType, WindowsAuth, WantSSL, CleartextPluginEnabled: Integer;
|
||||
AbsentFiles: TStringList;
|
||||
|
||||
function GetParamValue(ShortName, LongName: String): String;
|
||||
@ -2692,6 +2692,7 @@ begin
|
||||
Host := GetParamValue('h', 'host');
|
||||
User := GetParamValue('u', 'user');
|
||||
Pass := GetParamValue('p', 'password');
|
||||
CleartextPluginEnabled := StrToIntDef(GetParamValue('cleartextenabled', 'cleartextenabled'), -1);
|
||||
Socket := GetParamValue('S', 'socket');
|
||||
Port := StrToIntDef(GetParamValue('P', 'port'), 0);
|
||||
WindowsAuth := StrToIntDef(GetParamValue('W', 'winauth'), -1);
|
||||
@ -2716,6 +2717,8 @@ begin
|
||||
if Host <> '' then ConnectionParams.Hostname := Host;
|
||||
if User <> '' then ConnectionParams.Username := User;
|
||||
if Pass <> '' then ConnectionParams.Password := Pass;
|
||||
if CleartextPluginEnabled in [0,1] then
|
||||
ConnectionParams.CleartextPluginEnabled := Boolean(CleartextPluginEnabled);
|
||||
if Port <> 0 then ConnectionParams.Port := Port;
|
||||
if Socket <> '' then begin
|
||||
ConnectionParams.Hostname := Socket;
|
||||
@ -3521,6 +3524,7 @@ begin
|
||||
InitSetting(asHost, 'Host', 0, False, '127.0.0.1', True);
|
||||
InitSetting(asUser, 'User', 0, False, '', True);
|
||||
InitSetting(asPassword, 'Password', 0, False, '', True);
|
||||
InitSetting(asCleartextPluginEnabled, 'CleartextPluginEnabled' 0, False, '', True);
|
||||
InitSetting(asWindowsAuth, 'WindowsAuth', 0, False, '', True);
|
||||
InitSetting(asLoginPrompt, 'LoginPrompt', 0, False, '', True);
|
||||
InitSetting(asPort, 'Port', 0, False, '', True);
|
||||
|
Reference in New Issue
Block a user