Граф коммитов

2751 Коммитов

Автор SHA1 Сообщение Дата
Jacob Nevins 5d5abbf8d4 Apparently some SSH servers object to our claiming port-forwarded connections
to be from IP "client-side-connection". Claiming "0.0.0.0" instead seems to
work. Spotted by Brant Thomsen.

[originally from svn r6477]
[this svn revision also touched putty-wishlist]
2005-12-07 18:01:40 +00:00
Jacob Nevins 8a785bd34d Institutional failure to memset() things pointed at rather than pointers.
Things should now be zeroed and memory not leaked. Spotted by Brant Thomsen.

[originally from svn r6476]
2005-12-07 00:24:45 +00:00
Jacob Nevins d8b7de5435 Improvements from Spyros Blanas to the MSVC optimisations of r6469:
don't do a function call for each divmod, and don't rely on details of
the calling convention.
(This didn't actually make any measurable difference to runtime in any
of my tests, but we may as well keep it as it's neater.)
Also document some general caveats of the divmod macro.

[originally from svn r6475]
[r6469 == d72e4b718c]
2005-12-06 23:18:27 +00:00
Jacob Nevins 67b68bf145 SSH-2 rekey bug compatibility setting wasn't being saved
(but _was_ being loaded).

[originally from svn r6473]
[this svn revision also touched putty-wishlist]
2005-12-01 16:41:49 +00:00
Jacob Nevins d72e4b718c An MSVC version of the 16->32-bit bignum optimisation, derived from part of
a patch by Lionel Fourquaux. Seems to be about a factor of four improvement
(see wishlist item for details).
I don't claim to understand this in detail, so I can't vouch for its
correctness, but it didn't fall over immediately. It also produces some
compiler warnings, unfortunately.

[originally from svn r6469]
[this svn revision also touched putty-wishlist]
2005-11-23 21:26:05 +00:00
Jacob Nevins 407ed0d2f4 Missing close parenthesis.
[originally from svn r6461]
2005-11-14 09:41:42 +00:00
Jacob Nevins de945281fc r6437 broke the case where Pageant is running but contains no SSH-2 keys
that the SSH-2 server is happy with. Fixed, and since I'm here, fix
`pubkeyfile-and-pageant' as well (for SSH-1 and SSH-2).
Also, in SSH-2, we now reexamine "methods that can continue" for every
Pageant key offer, which is technically more correct although it seems
unlikely that it was causing any real problems.
(It's not entirely pretty, but neither was the old code. We could probably
do with some sort of abstraction for public/private keys to avoid carting
lots of fiddly bits of data around.)

[originally from svn r6459]
[r6437 == 8719f92c14]
[this svn revision also touched putty-wishlist]
2005-11-13 16:06:41 +00:00
Jacob Nevins 59dca370bb Oops, used \I where I meant \i. I think this is the only instance.
[originally from svn r6454]
2005-11-13 12:13:09 +00:00
Jacob Nevins c4b2b493ff I broke the ability to cope with multiple consecutive k-i INFO_REQUESTS
in r6437. This ought to be better (but I can't test that case).

[originally from svn r6451]
[r6437 == 8719f92c14]
2005-11-09 23:19:33 +00:00
Jacob Nevins 29f1ae8a7e Fix minor hiccup in SSH-1 p-k auth.
[originally from svn r6447]
2005-11-04 23:31:11 +00:00
Jacob Nevins 4496d752a9 Placate a compiler warning introduced in r6437.
(I forgot we usually compile with -Werror on Unix, oops.)

[originally from svn r6446]
[r6437 == 8719f92c14]
2005-11-04 23:21:42 +00:00
Jacob Nevins 041e93f508 Fix for `ssh2-password-expiry'. Success case tested.
(Much easier since r6437, and actually works to boot.)

[originally from svn r6445]
[r6437 == 8719f92c14]
[this svn revision also touched putty-wishlist]
2005-11-04 14:49:22 +00:00
Jacob Nevins f164b330ae When a userpass interaction has finished, make sure the 'prompts' structure
is safe for re-use.

[originally from svn r6444]
2005-11-02 23:15:43 +00:00
Jacob Nevins 6724e01956 (do_ssh2_authconn_state).method is redundant since r6437; remove.
Remove FIXMEs from .type assignments, as they look fine.

[originally from svn r6442]
[r6437 == 8719f92c14]
2005-10-31 22:43:51 +00:00
Jacob Nevins 8719f92c14 Revamp SSH authentication code so that user interaction is more
abstracted out; replace loops structured around a single interaction
per loop with less tortuous code (fixes: `ki-multiprompt-crash',
`ssh1-bad-passphrase-crash'; makes `ssh2-password-expiry' and
`proxy-password-prompt' easier).

The new interaction abstraction has a lot of fields that are unused in
the current code (things like window captions); this is groundwork for
`gui-auth'. However, ssh.c still writes directly to stderr; that may
want to be fixed.

In the GUI apps, user interaction is moved to terminal.c. This should
make it easier to fix things like UTF-8 username entry, although I
haven't attempted to do so. Also, control character filtering can be
tailored to be appropriate for individual front-ends; so far I don't
promise anything other than not having made it any worse.

I've tried to test this fairly exhaustively (although Mac stuff is
untested, as usual). It all seems to basically work, but I bet there
are new bugs. (One I know about is that you can no longer make the
PuTTY window go away with a ^D at the password prompt; this should be
fixed.)

[originally from svn r6437]
[this svn revision also touched putty-wishlist]
2005-10-30 20:24:09 +00:00
Jacob Nevins d6c13bd154 In Unix PuTTYgen, existing SSH-1 key comments were coming out as "(null)"
for operations not performing decryption (e.g., "puttygen rsa1.ppk -L")
(A use for r6434 -- wasn't expecting that.)

[originally from svn r6436]
[r6434 == c14f259ba2]
2005-10-30 19:13:43 +00:00
Jacob Nevins ff05fb7ccc Fixes to make r6434 actually useful.
[originally from svn r6435]
[r6434 == c14f259ba2]
2005-10-30 16:28:45 +00:00
Jacob Nevins c14f259ba2 Allow rsakey_pubblob() to return the key comment.
(like r6433 but for SSH-1)

[originally from svn r6434]
[r6433 == 49d2cf19ac]
2005-10-30 15:16:42 +00:00
Jacob Nevins 49d2cf19ac Add ability for ssh2_userkey_loadpub() to return the key comment.
(Not actually used currently, but it makes life easier for a patch I'm
working on.)

[originally from svn r6433]
2005-10-30 13:42:36 +00:00
Jacob Nevins 69ac38c1a8 Fix an error I introduced into SSH packet logging in r5642: some outgoing
packets over about 256 bytes would be logged with 12 bytes of preceding
garbage. (But the rest of the packet was logged in its entirety. This
holds for packets where (int(len/256)%2)==1, with an appropriate fudge
factor applied to `len'.) Ahem.

[originally from svn r6429]
[r5642 == c09d885b27]
2005-10-26 22:18:11 +00:00
Jacob Nevins 24bd4cfdde Comment explaining back->sendok() semantics from Simon.
[originally from svn r6428]
2005-10-26 20:58:01 +00:00
Jacob Nevins f2c17e2df8 Tweak to r6392: spell "MAC" thus.
[originally from svn r6399]
[r6392 == 8fb9bd0216]
2005-10-13 22:51:44 +00:00
Ben Harris 9d31462c52 Fix 256-colours-match-xterm, based on 256colres.pl from xterm-205.
Largely untested -- may not even compile on Windows.

[originally from svn r6393]
2005-10-13 21:56:43 +00:00
Ben Harris 8fb9bd0216 Make SSH_MSG_DISCONNECT reasons less scary (without removing useful content).
[originally from svn r6392]
2005-10-13 21:51:38 +00:00
Simon Tatham 309ddb5cad Failed to call set_erase_char() after processing SCO colour sequences.
[originally from svn r6379]
2005-10-08 09:09:50 +00:00
Jacob Nevins 4d48ba62e8 `win-versioninfo': all builds of all Windows binaries now contain
a VERSIONINFO resource. The versioning scheme is described in
windows/version.rc2.

Some .rc files are now #included in others. In order to keep MSVC
project files working, these have been renamed to .rc2; there may exist
a better solution.

(This checkin also includes the documentation tweak missing from r6367.)

Testing performed:
 - MinGW (cross-compiler): works
 - VC nmake: works (tested with VC6)
 - VC project files: builds with VERSIONINFO resource (no VER variable though)
 - Borland: an old version of this patch was tested with it and more or
   less worked, except that some of the VERSIONINFO strings were apparently
   not terminated properly. Not attempted to work around this.
 - LCC: not tested. Some fixes are in there from the last time we tried
   this, but then the build ultimately failed and I haven't tried this
   since that was fixed.
 - Dev-C++: untested. (Haven't done anything special.)
 - Unix Gtk/autoconf Makefiles work as before.

[originally from svn r6374]
[r6367 == f86ad059db]
[this svn revision also touched putty-wishlist]
2005-10-04 14:13:28 +00:00
Simon Tatham 9d3ab46800 UTF-8 processing was discarding a valid character which interrupted
an otherwise legal sequence, if that valid character was the last
thing in a term_out() run. Spotted by Egmont Koblinger.

[originally from svn r6373]
2005-10-03 11:38:30 +00:00
Jacob Nevins 6b4cf8f443 thinko
[originally from svn r6372]
2005-10-03 10:24:06 +00:00
Jacob Nevins f86ad059db Split out SVN_REV from SNAPSHOT define. This is to support `win-versioninfo',
but since Simon's made the corresponding change to the build process, this bit
needs checking in now (it should be harmless).

(The documentation in Recipe is slightly out of date; with luck I'll be
checking in `win-versioninfo' changes soon, and I can't be bothered to
disentangle the relevant changes in the meantime.)

[originally from svn r6367]
2005-10-01 12:36:46 +00:00
Simon Tatham 8726e30389 A swathe of new FAQ questions, along the general theme of `will you
sign something for us / give us assurances / give us indemnity'.

[originally from svn r6365]
2005-10-01 11:40:26 +00:00
Jacob Nevins 843998f07d Mention SSH-2 rekeys in the keepalive section.
[originally from svn r6363]
2005-09-30 14:54:03 +00:00
Jacob Nevins a4b189172f A first stab at guidance for those lost souls who email us asking for
login names and/or passwords. Feel free to hack.
(NB, renumbers a section of the FAQ.)

[originally from svn r6355]
2005-09-24 18:33:06 +00:00
Simon Tatham 8cde1bc7fe dlg_listbox_select() now scrolls the list box to ensure that the
item it's just selected is visible.

[originally from svn r6338]
2005-09-21 17:09:07 +00:00
Owen Dunn 5408f0a545 Platform-independent support for zooming around session list by typing
in the session name box.  Thwarted on Unix by GTK not automatically
scrolling the listbox to the selected item, but we can fix that in
the platform-specific side later.

[originally from svn r6337]
2005-09-21 14:53:32 +00:00
Jacob Nevins af0d8cf872 Mention that sessions can be saved from "Change Settings" in using.but.
[originally from svn r6332]
2005-09-19 14:34:01 +00:00
Ben Harris f0dfa73982 AIX 5.1 has <utmpx.h> but no updwtmpx(). Treat the latter as a reason to
OMIT_UTMP.  Reported by Mike Protts.

[originally from svn r6311]
2005-09-14 11:00:34 +00:00
Ben Harris 3bfb6ad651 Some systems (HP-UX) don't yet have <sys/select.h>, putting select() in
<sys/time.h>.  Cope with this.  Where <sys/select.h> _is_ available, though,
use it (since it's where POSIX puts select()).  Problem reported by Mike
Protts.

[originally from svn r6310]
2005-09-14 10:53:39 +00:00
Ben Harris f2d8fd97d0 When asked to malloc zero bytes, malloc one byte instead. This ensures
that we get a unique pointer rather than NULL (which ANSI C otherwise permits).
Problem pointed out by Mike Protts.

[originally from svn r6308]
2005-09-13 20:17:10 +00:00
Ben Harris 059e409c82 The ANSI-C constant FILENAME_MAX is ludicrously small on some systems.
Use the POSIX PATH_MAX if it exists, and fall back to 1024 otherwise.
We should really allocate filenames dynamically if PATH_MAX isn't defined.

[originally from svn r6307]
2005-09-13 20:08:25 +00:00
Ben Harris e115d1cc90 Some hosts don't have TIOCSCTTY. Don't try to use it on them.
Patch from Mike Protts.

[originally from svn r6306]
2005-09-13 19:57:37 +00:00
Ben Harris 4598889284 A couple of places in sk_newlistener were using AF_INET6 even with NO_IPV6.
Correct them.

[originally from svn r6305]
2005-09-13 19:54:01 +00:00
Ben Harris 7a763b358d Nothing seems to use the "int64" type, and it apparently causes conflicts
on some platform, so remove it.  Thanks to Mike Protts for spotting this.

[originally from svn r6304]
2005-09-13 19:24:35 +00:00
Jacob Nevins 6e889dc4e2 Apparently the OS X port is stalled.
[originally from svn r6302]
[this svn revision also touched putty-wishlist]
2005-09-13 14:12:16 +00:00
Ben Harris 456ba58329 When the first element in a preference list was unrecognised, PuTTY would
hang when reading it because strtok() kept getting the full list passed in.
Fix this, and add an assert() for an assumption documented in a comment while
I'm in the area.

[originally from svn r6294]
2005-09-12 15:45:29 +00:00
Ben Harris b65e905572 Mention relationship between terminal types, keyboard sequences, and
termcap/terminfo.  Suggested by Joachim Durchholz.

[originally from svn r6285]
2005-09-10 17:36:52 +00:00
Ben Harris c0d36aa00a Implement hmac-sha1-96. It's RECOMMENDED in the current transport draft,
and we don't have any strong reason not to implement it, for all that it's
rather pointless.

[originally from svn r6284]
2005-09-10 16:19:53 +00:00
Ben Harris 9131914278 Add support for diffie-hellman-group-exchange-sha256. Tested against a
patched OpenSSH server.  This is controlled by the same user settings
as diffie-hellman-group-exchange-sha1, which may not be optimal, especially
given that they're both referred to as dh-gex-sha1 in saved sessions.

[originally from svn r6272]
2005-09-04 14:53:39 +00:00
Ben Harris 7d800b7c2a Mention xp-wont-run.
[originally from svn r6264]
2005-09-03 17:29:28 +00:00
Ben Harris bcf547a069 Now that my arcfour-fixes draft has been approved by the IESG, use the
IANA-assigned names for its modes.

[originally from svn r6263]
2005-09-03 17:03:49 +00:00
Ben Harris a42d103cf9 Restructure things so that a single entry in the KEX preference list can
correspond to multiple SSH-2 KEX algorithms.  We already do the equivalent
for cipher algorithms.

[originally from svn r6262]
2005-09-03 13:41:43 +00:00