projects
/
u
/
mdw
/
putty
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Mention PocketPC in the WinCE question. I'm not sure how similar WinCE and
[u/mdw/putty]
/
windlg.c
diff --git
a/windlg.c
b/windlg.c
index
b512b1c
..
474a054
100644
(file)
--- a/
windlg.c
+++ b/
windlg.c
@@
-512,8
+512,10
@@
enum { IDCX_ABOUT =
IDC_BUGGYMAC,
IDC_SSH2DES,
IDC_SSHPROTSTATIC,
IDC_BUGGYMAC,
IDC_SSH2DES,
IDC_SSHPROTSTATIC,
+ IDC_SSHPROT1ONLY,
IDC_SSHPROT1,
IDC_SSHPROT2,
IDC_SSHPROT1,
IDC_SSHPROT2,
+ IDC_SSHPROT2ONLY,
IDC_CMDSTATIC,
IDC_CMDEDIT,
IDC_COMPRESS,
IDC_CMDSTATIC,
IDC_CMDEDIT,
IDC_COMPRESS,
@@
-890,8
+892,10
@@
char *help_context_cmd(int id)
case IDC_BUGGYMAC:
return "JI(`',`ssh.buggymac')";
case IDC_SSHPROTSTATIC:
case IDC_BUGGYMAC:
return "JI(`',`ssh.buggymac')";
case IDC_SSHPROTSTATIC:
+ case IDC_SSHPROT1ONLY:
case IDC_SSHPROT1:
case IDC_SSHPROT2:
case IDC_SSHPROT1:
case IDC_SSHPROT2:
+ case IDC_SSHPROT2ONLY:
return "JI(`',`ssh.protocol')";
case IDC_CMDSTATIC:
case IDC_CMDEDIT:
return "JI(`',`ssh.protocol')";
case IDC_CMDSTATIC:
case IDC_CMDEDIT:
@@
-1149,8
+1153,10
@@
static void init_dlg_ctrls(HWND hwnd, int keepsess)
CheckDlgButton(hwnd, IDC_SSH2DES, cfg.ssh2_des_cbc);
CheckDlgButton(hwnd, IDC_AGENTFWD, cfg.agentfwd);
CheckDlgButton(hwnd, IDC_CHANGEUSER, cfg.change_username);
CheckDlgButton(hwnd, IDC_SSH2DES, cfg.ssh2_des_cbc);
CheckDlgButton(hwnd, IDC_AGENTFWD, cfg.agentfwd);
CheckDlgButton(hwnd, IDC_CHANGEUSER, cfg.change_username);
- CheckRadioButton(hwnd, IDC_SSHPROT1, IDC_SSHPROT2,
- cfg.sshprot == 1 ? IDC_SSHPROT1 : IDC_SSHPROT2);
+ CheckRadioButton(hwnd, IDC_SSHPROT1ONLY, IDC_SSHPROT2ONLY,
+ cfg.sshprot == 1 ? IDC_SSHPROT1 :
+ cfg.sshprot == 2 ? IDC_SSHPROT2 :
+ cfg.sshprot == 3 ? IDC_SSHPROT2ONLY : IDC_SSHPROT1ONLY);
CheckDlgButton(hwnd, IDC_AUTHTIS, cfg.try_tis_auth);
CheckDlgButton(hwnd, IDC_AUTHKI, cfg.try_ki_auth);
SetDlgItemText(hwnd, IDC_PKEDIT, cfg.keyfile);
CheckDlgButton(hwnd, IDC_AUTHTIS, cfg.try_tis_auth);
CheckDlgButton(hwnd, IDC_AUTHKI, cfg.try_ki_auth);
SetDlgItemText(hwnd, IDC_PKEDIT, cfg.keyfile);
@@
-1808,7
+1814,7
@@
static void create_controls(HWND hwnd, int dlgtype, int panel)
}
if (panel == sshpanelstart) {
}
if (panel == sshpanelstart) {
- /* The SSH panel. Accelerators used: [acgoh] r pe12i sd */
+ /* The SSH panel. Accelerators used: [acgoh] r pe12
n
i sd */
struct ctlpos cp;
ctlposinit(&cp, hwnd, 80, 3, 13);
if (dlgtype == 0) {
struct ctlpos cp;
ctlposinit(&cp, hwnd, 80, 3, 13);
if (dlgtype == 0) {
@@
-1823,8
+1829,10
@@
static void create_controls(HWND hwnd, int dlgtype, int panel)
checkbox(&cp, "Don't allocate a &pseudo-terminal", IDC_NOPTY);
checkbox(&cp, "Enable compr&ession", IDC_COMPRESS);
radioline(&cp, "Preferred SSH protocol version:",
checkbox(&cp, "Don't allocate a &pseudo-terminal", IDC_NOPTY);
checkbox(&cp, "Enable compr&ession", IDC_COMPRESS);
radioline(&cp, "Preferred SSH protocol version:",
- IDC_SSHPROTSTATIC, 2,
- "&1", IDC_SSHPROT1, "&2", IDC_SSHPROT2, NULL);
+ IDC_SSHPROTSTATIC, 4,
+ "1 on&ly", IDC_SSHPROT1ONLY,
+ "&1", IDC_SSHPROT1, "&2", IDC_SSHPROT2,
+ "2 o&nly", IDC_SSHPROT2ONLY, NULL);
checkbox(&cp, "&Imitate SSH 2 MAC bug in commercial <= v2.3.x",
IDC_BUGGYMAC);
endbox(&cp);
checkbox(&cp, "&Imitate SSH 2 MAC bug in commercial <= v2.3.x",
IDC_BUGGYMAC);
endbox(&cp);
@@
-3086,14
+3094,20
@@
static int GenericMainDlgProc(HWND hwnd, UINT msg,
cfg.ssh_cipherlist, CIPHER_MAX,
0, hwnd, wParam, lParam);
break;
cfg.ssh_cipherlist, CIPHER_MAX,
0, hwnd, wParam, lParam);
break;
+ case IDC_SSHPROT1ONLY:
case IDC_SSHPROT1:
case IDC_SSHPROT2:
case IDC_SSHPROT1:
case IDC_SSHPROT2:
+ case IDC_SSHPROT2ONLY:
if (HIWORD(wParam) == BN_CLICKED ||
HIWORD(wParam) == BN_DOUBLECLICKED) {
if (HIWORD(wParam) == BN_CLICKED ||
HIWORD(wParam) == BN_DOUBLECLICKED) {
+ if (IsDlgButtonChecked(hwnd, IDC_SSHPROT1ONLY))
+ cfg.sshprot = 0;
if (IsDlgButtonChecked(hwnd, IDC_SSHPROT1))
cfg.sshprot = 1;
else if (IsDlgButtonChecked(hwnd, IDC_SSHPROT2))
cfg.sshprot = 2;
if (IsDlgButtonChecked(hwnd, IDC_SSHPROT1))
cfg.sshprot = 1;
else if (IsDlgButtonChecked(hwnd, IDC_SSHPROT2))
cfg.sshprot = 2;
+ else if (IsDlgButtonChecked(hwnd, IDC_SSHPROT2ONLY))
+ cfg.sshprot = 3;
}
break;
case IDC_AUTHTIS:
}
break;
case IDC_AUTHTIS:
@@
-3126,7
+3140,8
@@
static int GenericMainDlgProc(HWND hwnd, UINT msg,
of.lStructSize = sizeof(of);
#endif
of.hwndOwner = hwnd;
of.lStructSize = sizeof(of);
#endif
of.hwndOwner = hwnd;
- of.lpstrFilter = "All Files\0*\0\0\0";
+ of.lpstrFilter = "PuTTY Private Key Files\0*.PPK\0"
+ "AllFiles\0*\0\0\0";
of.lpstrCustomFilter = NULL;
of.nFilterIndex = 1;
of.lpstrFile = filename;
of.lpstrCustomFilter = NULL;
of.nFilterIndex = 1;
of.lpstrFile = filename;