simon [Fri, 18 Feb 2005 18:33:31 +0000 (18:33 +0000)]
Add asynchronous callback capability to the askappend() alert box.
This was harder than verify_ssh_host_key() and askalg() put
together, because:
(a) askappend() can be called at any time, since it's a side effect
of data-logging functions. Therefore there can be an unfinished
askappend() alert at any time, and hence the OS X front end has
to be prepared to _queue_ other alerts which occur during that
time.
(b) logging.c has to do something with data that comes in while
it's waiting for an answer to askappend(). It buffers it until
it knows what the user wants done with it. This involved
something of a reorganisation of logging.c.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5344
cda61777-01e9-0310-a592-
d414129be87e
simon [Fri, 18 Feb 2005 18:19:28 +0000 (18:19 +0000)]
A few more fixes in the new asynchronous-alert-box mechanism.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5343
cda61777-01e9-0310-a592-
d414129be87e
owen [Fri, 18 Feb 2005 09:22:55 +0000 (09:22 +0000)]
We have a host key database, just not a very good one.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5340
cda61777-01e9-0310-a592-
d414129be87e
simon [Thu, 17 Feb 2005 19:31:32 +0000 (19:31 +0000)]
Adjust the semantics of cfg.remote_cmd_ptr: it is now NULL when
cfg.remote_cmd is to be used, rather than actually pointing at
cfg.remote_cmd. This change restores the ability to structure-copy
Configs without breaking them. (Though of course this is only a
temporary solution: really what wants doing is to fix
`config-struct'.)
git-svn-id: svn://svn.tartarus.org/sgt/putty@5335
cda61777-01e9-0310-a592-
d414129be87e
simon [Thu, 17 Feb 2005 18:56:37 +0000 (18:56 +0000)]
Ahem. Actually _checking_ that asynchronous askalg() worked would
have been helpful. Since async verify_ssh_host_key() worked, I
didn't think anything else could go wrong. How wrong I was.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5331
cda61777-01e9-0310-a592-
d414129be87e
simon [Thu, 17 Feb 2005 18:34:24 +0000 (18:34 +0000)]
Revamp interface to verify_ssh_host_key() and askalg(). Each of them
now returns an integer: 0 means cancel the SSH connection and 1
means continue with it. Additionally, they can return -1, which
means `front end has set an asynchronous alert box in motion, please
wait to be called back with the result', and each one is passed a
callback function pointer and context for this purpose.
I have not yet done the same to askappend() yet, because it will
take a certain amount of reorganisation of logging.c.
Importantly, this checkin means the host key dialog box now works on
OS X.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5330
cda61777-01e9-0310-a592-
d414129be87e
jacob [Thu, 17 Feb 2005 02:00:01 +0000 (02:00 +0000)]
ssh_do_close() should close any listening sockets associated with
port-forwardings.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5325
cda61777-01e9-0310-a592-
d414129be87e
jacob [Thu, 17 Feb 2005 01:47:01 +0000 (01:47 +0000)]
ssh_do_close() was only closing about half the channels. Fixed.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5324
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 16 Feb 2005 23:30:10 +0000 (23:30 +0000)]
On the Mac, support for setting the line codepage and for combining
characters. I've just used libcharset in macucs.c since there seemed
little reason not to, and implemented combining characters by naive
overprinting. It's not yet a lot of use without the ability to select
a font, of course.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5322
cda61777-01e9-0310-a592-
d414129be87e
jacob [Wed, 16 Feb 2005 12:13:27 +0000 (12:13 +0000)]
portfwd validation was sometimes not picking up a blank source port
git-svn-id: svn://svn.tartarus.org/sgt/putty@5319
cda61777-01e9-0310-a592-
d414129be87e
jacob [Wed, 16 Feb 2005 11:56:27 +0000 (11:56 +0000)]
Fix a minor valgrind issue in dynamic port-forwarding.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5318
cda61777-01e9-0310-a592-
d414129be87e
jacob [Wed, 16 Feb 2005 11:44:44 +0000 (11:44 +0000)]
Simon suggests a better solution to valgrind's complaining about
(struct Socket_tag).connected -- it should be entirely irrelevant to
listening sockets. Valgrind is still happy.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5317
cda61777-01e9-0310-a592-
d414129be87e
simon [Wed, 16 Feb 2005 09:01:45 +0000 (09:01 +0000)]
Oops! Didn't mean to check in the OS X Makefile; that is of course
built by mkfiles.pl just like all the rest. Well spotted, Jacob.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5316
cda61777-01e9-0310-a592-
d414129be87e
jacob [Wed, 16 Feb 2005 01:47:10 +0000 (01:47 +0000)]
Minor reorganisations to WinHelp support. (Done as part of a - failed -
attempt to fix `winhelp-crash', but we may as well keep them.)
git-svn-id: svn://svn.tartarus.org/sgt/putty@5314
cda61777-01e9-0310-a592-
d414129be87e
jacob [Tue, 15 Feb 2005 23:39:57 +0000 (23:39 +0000)]
Update on Mac ports.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5311
cda61777-01e9-0310-a592-
d414129be87e
owen [Tue, 15 Feb 2005 22:41:00 +0000 (22:41 +0000)]
Grouping boxes for the configuration dialogue. The System 7 version is
completely untested so far, but the Appearance Manager version works and
looks plausible. There are still some HI Guideline spacing issues to
address.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5310
cda61777-01e9-0310-a592-
d414129be87e
jacob [Tue, 15 Feb 2005 22:23:47 +0000 (22:23 +0000)]
The Windows host key dialogs now have a `Help' button that should give
appropriate context help, iff the help file is present. (Shame it's prey to
`winhelp-crash'.)
(I've perpetrated a widening of visibility of `hwnd'; the alternative, putting
it into a frontend handle, seemed too likely to cause maintenance trouble if
we don't also _use_ that frontend handle everywhere we now use the global
`hwnd'.)
git-svn-id: svn://svn.tartarus.org/sgt/putty@5309
cda61777-01e9-0310-a592-
d414129be87e
simon [Tue, 15 Feb 2005 21:45:50 +0000 (21:45 +0000)]
Initial checkin of a native Mac OS X port, sharing most of its code
with the Unix port and layering a Cocoa GUI on top. The basics all
work: there's a configuration panel and a terminal window, the
timing interface works and the select interface functions. The same
application can run both SSH (or other network) connections and
local pty sessions, and multiple sessions in the same process are
fully supported.
However, it's horribly unfinished in a wide variety of other ways;
anyone interested is invited to read README.OSX and wince at the
length and content of its `unfinished' list.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5308
cda61777-01e9-0310-a592-
d414129be87e
jacob [Tue, 15 Feb 2005 19:22:47 +0000 (19:22 +0000)]
Add a couple of other sensible button defaults in MessageBox()s.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5305
cda61777-01e9-0310-a592-
d414129be87e
jacob [Tue, 15 Feb 2005 19:10:44 +0000 (19:10 +0000)]
Martin Radford points out that the default action for the host key
confirmation dialogs should be "cancel", not "accept".
git-svn-id: svn://svn.tartarus.org/sgt/putty@5304
cda61777-01e9-0310-a592-
d414129be87e
jacob [Tue, 15 Feb 2005 17:05:58 +0000 (17:05 +0000)]
The terminal window can now indicate that PuTTY is busy in various ways, by
changing its mouse pointer. Currently this is only used in the (slightly-
arbitrarily-defined) "heavy" bits of SSH-2 key exchange. We override pointer
hiding while PuTTY is busy, but preserve pointer-hiding state.
Not yet implemented on the Mac.
Also switch to frobbing window-class cursor in Windows rather than relying on
SetCursor().
git-svn-id: svn://svn.tartarus.org/sgt/putty@5303
cda61777-01e9-0310-a592-
d414129be87e
jacob [Tue, 15 Feb 2005 12:35:59 +0000 (12:35 +0000)]
Extra note on "connection reset by peer" on Windows.
Note default circumstances of cipher warning. (I haven't bothered with the
similar kex warning since it doesn't come up in the default configuration,
and is in any case unlikely to be common.)
git-svn-id: svn://svn.tartarus.org/sgt/putty@5302
cda61777-01e9-0310-a592-
d414129be87e
jacob [Mon, 14 Feb 2005 15:30:09 +0000 (15:30 +0000)]
Initialise (struct Socket_tag).connected in sk_register().
Again, the value could do with review.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5300
cda61777-01e9-0310-a592-
d414129be87e
jacob [Mon, 14 Feb 2005 15:03:32 +0000 (15:03 +0000)]
Initialise (struct Socket_tag).connected in sk_newlistener() since Valgrind
complained.
(I _think_ this is the correct initialisation.)
git-svn-id: svn://svn.tartarus.org/sgt/putty@5299
cda61777-01e9-0310-a592-
d414129be87e
jacob [Mon, 14 Feb 2005 11:43:27 +0000 (11:43 +0000)]
Martin Prikryl points out that we weren't always initialising new "addrinfo"
members of Windows SockAddr_tag; particular in sk_nonamelookup() (proxy
resolution at far end) this was causing trouble.
Make sure they _always_ start out NULL (since the Windows getaddrinfo()
documentation doesn't make any claims about initialisation), and also
initialise 'naddresses' in sk_nonamelookup() for good measure.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5297
cda61777-01e9-0310-a592-
d414129be87e
jacob [Mon, 14 Feb 2005 11:07:52 +0000 (11:07 +0000)]
WSAECONNABORTED: Soften claims + emphasise applicability to established
connections, based on KB 819124.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5296
cda61777-01e9-0310-a592-
d414129be87e
simon [Mon, 14 Feb 2005 07:44:50 +0000 (07:44 +0000)]
Oh, and (there's always one) remove the unnecessary extra parameter
from unix_setup_config_box().
git-svn-id: svn://svn.tartarus.org/sgt/putty@5293
cda61777-01e9-0310-a592-
d414129be87e
simon [Mon, 14 Feb 2005 07:41:41 +0000 (07:41 +0000)]
Saw uxcfg.c in half down the middle, to separate out config changes
that apply to all Unix-like systems from those which apply
specifically to the GTK front end.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5292
cda61777-01e9-0310-a592-
d414129be87e
owen [Sun, 13 Feb 2005 00:00:59 +0000 (00:00 +0000)]
Display panel titles and grouping box titles.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5291
cda61777-01e9-0310-a592-
d414129be87e
owen [Fri, 11 Feb 2005 18:01:59 +0000 (18:01 +0000)]
Tidy up the host key alerts a little, and swap the Just Once and Cancel
buttons so that they appear in the standard action and cancel positions.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5288
cda61777-01e9-0310-a592-
d414129be87e
jacob [Thu, 10 Feb 2005 01:25:50 +0000 (01:25 +0000)]
Mention saving mid-session and some of its wrinkles.
Formatting tweaks in the same general area.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5284
cda61777-01e9-0310-a592-
d414129be87e
jacob [Thu, 10 Feb 2005 01:04:06 +0000 (01:04 +0000)]
Document effect of settings changes on existing connections/forwardings.
Also mention that service names can be used instead of port numbers.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5283
cda61777-01e9-0310-a592-
d414129be87e
jacob [Thu, 10 Feb 2005 01:03:08 +0000 (01:03 +0000)]
ssh_setup_portfwd() should usually be looking at the new cfg, not the old
one, so that changes to port visibility are honoured in new forwardings.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5282
cda61777-01e9-0310-a592-
d414129be87e
jacob [Thu, 10 Feb 2005 00:16:59 +0000 (00:16 +0000)]
Slightly gratuitous logeventf() crusade and purge of fixed-length buffers.
Also a bonus sfree().
git-svn-id: svn://svn.tartarus.org/sgt/putty@5281
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 9 Feb 2005 21:18:44 +0000 (21:18 +0000)]
Add some host key dialogue boxes. These still look a little rough around
the edges and need to have all their controls properly aligned and spaced
according to the HI guidelines. Also, fix store_host_key() so that it
replaces a host key correctly when the host key has changed and the user
opts to update the cached one.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5280
cda61777-01e9-0310-a592-
d414129be87e
simon [Wed, 9 Feb 2005 15:57:07 +0000 (15:57 +0000)]
Improve documentation of the SCP wildcard safety issue: in
particular, mention that doing an SCP wildcard download into a clean
directory is adequate protection against a malicious server trying
to overwrite your files.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5279
cda61777-01e9-0310-a592-
d414129be87e
jacob [Wed, 9 Feb 2005 15:42:28 +0000 (15:42 +0000)]
Missing {Question}
git-svn-id: svn://svn.tartarus.org/sgt/putty@5278
cda61777-01e9-0310-a592-
d414129be87e
ben [Tue, 8 Feb 2005 14:13:57 +0000 (14:13 +0000)]
We _really_ don't need to hear about WSAECONNABORTED any more.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5276
cda61777-01e9-0310-a592-
d414129be87e
ben [Tue, 8 Feb 2005 12:40:51 +0000 (12:40 +0000)]
Mention that a common reason for keys' being rejected is dodgy permissions.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5274
cda61777-01e9-0310-a592-
d414129be87e
simon [Mon, 7 Feb 2005 23:43:03 +0000 (23:43 +0000)]
Add the new mk.mpw to the ignore list.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5272
cda61777-01e9-0310-a592-
d414129be87e
simon [Mon, 7 Feb 2005 20:24:13 +0000 (20:24 +0000)]
Revert my LF->CR change following Owen's comment that it actually
breaks netatalk-based setups (which _swap_ LF and CR). Instead,
setfile.sh (which I have to run _anyway_ on OS X) copies mkputty.mpw
to mk.mpw and then makes that CR-based.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5271
cda61777-01e9-0310-a592-
d414129be87e
jacob [Mon, 7 Feb 2005 15:23:45 +0000 (15:23 +0000)]
Comment explaining location in top-level directory.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5270
cda61777-01e9-0310-a592-
d414129be87e
jacob [Mon, 7 Feb 2005 12:23:10 +0000 (12:23 +0000)]
Petri Kero pointed out a FreeLibrary() call that should be guarded by NO_IPV6.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5268
cda61777-01e9-0310-a592-
d414129be87e
owen [Mon, 7 Feb 2005 10:47:48 +0000 (10:47 +0000)]
Add a comment about the deficiencies of the host key cache implementation.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5263
cda61777-01e9-0310-a592-
d414129be87e
simon [Sun, 6 Feb 2005 15:52:00 +0000 (15:52 +0000)]
Reinstate the broken -e option in pterm. Also I've just worked out a
much better way of handling pty_argv which doesn't require uxpty.c
to be linked in to Unix PuTTY and PuTTYtel.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5262
cda61777-01e9-0310-a592-
d414129be87e
simon [Sun, 6 Feb 2005 15:14:34 +0000 (15:14 +0000)]
Encapsulated most of the pty backend's variables into a proper data
structure, in preparation for wanting more than one of them in a
single process. This can't be done cleanly, because the whole
business with pty_pre_init pre-allocating the pty rather assumes we
want a known number of the things before we drop privileges; so
there's a horrid hack to make pty_pre_init work on platforms that
have at most one pty instance per process, but at the same time
things ought to work sensibly with more than one per process _if_
pty_pre_init isn't required.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5261
cda61777-01e9-0310-a592-
d414129be87e
owen [Sun, 6 Feb 2005 15:00:36 +0000 (15:00 +0000)]
First stab at a host key cache on the Mac.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5260
cda61777-01e9-0310-a592-
d414129be87e
simon [Sun, 6 Feb 2005 13:33:41 +0000 (13:33 +0000)]
The pty backend won't _always_ be running under X, so it should be
possible to compile it without the WINDOWID variable.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5259
cda61777-01e9-0310-a592-
d414129be87e
simon [Sat, 5 Feb 2005 15:33:36 +0000 (15:33 +0000)]
When allocating BSD-style ptys, we should not be satisfied with a
/dev/ptyXX we can open: we must also check that we can open and use
the corresponding /dev/ttyXX, because if it's been left in the wrong
mode then we will look terribly silly when we fork and _then_
discover our pty is unusable.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5257
cda61777-01e9-0310-a592-
d414129be87e
owen [Sat, 5 Feb 2005 14:50:42 +0000 (14:50 +0000)]
Implement refreshing the whole dialogue box with dlg_refresh, so that
if you load a session all the panels in the configuration dialogue
reflect the new settings. However, there's a glitch which paints a white
rectangle between the Saved Sessions listbox and the Close-on-exit radios.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5256
cda61777-01e9-0310-a592-
d414129be87e
simon [Sat, 5 Feb 2005 14:46:39 +0000 (14:46 +0000)]
Added a small shell script to run enough SetFile commands to make
MPW builds work after checking out on Mac OS X.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5255
cda61777-01e9-0310-a592-
d414129be87e
simon [Sat, 5 Feb 2005 14:39:22 +0000 (14:39 +0000)]
This file needs to have CR line endings for MPW to be happy with it.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5254
cda61777-01e9-0310-a592-
d414129be87e
simon [Sat, 5 Feb 2005 10:55:09 +0000 (10:55 +0000)]
Mac PuTTY.ppc wouldn't compile for me until I added this prototype.
Not sure why it's been working for Owen and not me, but the
prototype ought to be there anyway, so *shrug*.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5251
cda61777-01e9-0310-a592-
d414129be87e
owen [Sat, 5 Feb 2005 00:29:20 +0000 (00:29 +0000)]
Times and dates in the event log, fixing ltime() in the process.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5250
cda61777-01e9-0310-a592-
d414129be87e
owen [Sat, 5 Feb 2005 00:14:24 +0000 (00:14 +0000)]
mac_pollterm() is no longer useful and can be retired.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5249
cda61777-01e9-0310-a592-
d414129be87e
ben [Wed, 2 Feb 2005 23:51:58 +0000 (23:51 +0000)]
Implement anti-replay protection for XDM-AUTHORIZATION-1, as required by
the specification. We keep a cache of tickets we've seen recently and
reject duplicates. Once a ticket in our cache is old enough that we
wouldn't accept a duplicate anyway, we expire it.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5236
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 2 Feb 2005 21:33:13 +0000 (21:33 +0000)]
Flashing things now work as a natural consequence of the timing interface.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5235
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 2 Feb 2005 21:18:39 +0000 (21:18 +0000)]
Make ot_recv less voracious.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5234
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 2 Feb 2005 19:56:29 +0000 (19:56 +0000)]
Update the configuration when the window is resized.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5233
cda61777-01e9-0310-a592-
d414129be87e
owen [Sun, 30 Jan 2005 14:59:47 +0000 (14:59 +0000)]
Hide/show the scrollbar
git-svn-id: svn://svn.tartarus.org/sgt/putty@5230
cda61777-01e9-0310-a592-
d414129be87e
owen [Sun, 30 Jan 2005 14:10:05 +0000 (14:10 +0000)]
The HI guidelines seem adamant that the File menu should never be called
anything but File, and two Mac users expressed profound distress at the
thought of it being called Session. File it is.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5229
cda61777-01e9-0310-a592-
d414129be87e
owen [Sat, 29 Jan 2005 22:50:18 +0000 (22:50 +0000)]
Another compiler pickiness. It feels wrong to be doing this to
perfectly idiomatic code, somehow, and I half wonder whether the
Mac compilers are too stupid to be allowed to treat warnings as
errors.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5228
cda61777-01e9-0310-a592-
d414129be87e
owen [Sat, 29 Jan 2005 22:46:43 +0000 (22:46 +0000)]
Make Change Settings do something.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5227
cda61777-01e9-0310-a592-
d414129be87e
owen [Fri, 28 Jan 2005 23:39:38 +0000 (23:39 +0000)]
Enable the Open Transport networking implementation unless NO_OT is defined.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5224
cda61777-01e9-0310-a592-
d414129be87e
ben [Fri, 28 Jan 2005 13:47:37 +0000 (13:47 +0000)]
Split discussion of diabling rekeys between time-based and data-based, since
disabling the former is much more useful, and much safer, than disabling the
latter. The new wording on data-based rekeys might need some polishing.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5222
cda61777-01e9-0310-a592-
d414129be87e
owen [Fri, 28 Jan 2005 11:50:56 +0000 (11:50 +0000)]
sfree the memory dupprintf allocated
git-svn-id: svn://svn.tartarus.org/sgt/putty@5221
cda61777-01e9-0310-a592-
d414129be87e
ben [Fri, 28 Jan 2005 11:47:33 +0000 (11:47 +0000)]
Use AF_UNIX, not AF_LOCAL, since the former is in POSIX and the latter is not.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5220
cda61777-01e9-0310-a592-
d414129be87e
ben [Fri, 28 Jan 2005 11:39:45 +0000 (11:39 +0000)]
Overhaul of client-side XDM-AUTHORIZATION-1:
* Make sk_getxdmdata() return an arbitrary string rather than two integers.
This better matches the spec, even if the current version always returns
six bytes
* On Unix, for PF_UNIX sockets, return a counter rather than a constant along
with the PID. This should allow multiple clients to connect within one
second, and is what Xlib does.
* On Unix, interpret AF_INET6 addresses like Xlib does, returning the
embedded IPv4 address for v4-mapped addresses, and six bytes of zeroes
otherwise. The latter is silly, but if I'm going to do anything more sane
I need to check that X servers won't reject it.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5219
cda61777-01e9-0310-a592-
d414129be87e
ben [Wed, 26 Jan 2005 23:49:56 +0000 (23:49 +0000)]
Buffer overruns are embarassing (even if caused by user error), so assert
that this one can't happen until I actually fix it.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5217
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 26 Jan 2005 23:30:34 +0000 (23:30 +0000)]
Add a Change Settings dialogue box. Doesn't do anything yet.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5216
cda61777-01e9-0310-a592-
d414129be87e
ben [Wed, 26 Jan 2005 20:18:33 +0000 (20:18 +0000)]
Move sockaddr_is_loopback() to before sk_address_is_local(), and define the
latter in terms of the former. Also adjust the definition of
ipv4_is_loopback() to avoid using the non-standard inet_netof() and
IN_LOOPBACKNET, and move it next to its remaining uses.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5215
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 26 Jan 2005 19:05:50 +0000 (19:05 +0000)]
Move sk_poll() inside (!gotevent), which is more logical but doesn't have
any actual beneficial effect on event handling, sadly.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5214
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 26 Jan 2005 19:04:42 +0000 (19:04 +0000)]
Add ssh.h for prototypes for the X display stubs
git-svn-id: svn://svn.tartarus.org/sgt/putty@5213
cda61777-01e9-0310-a592-
d414129be87e
owen [Wed, 26 Jan 2005 18:11:28 +0000 (18:11 +0000)]
Make a few things static
git-svn-id: svn://svn.tartarus.org/sgt/putty@5212
cda61777-01e9-0310-a592-
d414129be87e
owen [Sun, 23 Jan 2005 15:01:21 +0000 (15:01 +0000)]
Give the config window a title.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5181
cda61777-01e9-0310-a592-
d414129be87e
ben [Sun, 23 Jan 2005 14:31:08 +0000 (14:31 +0000)]
When checking if a connection comes from localhost, don't assume it's an IPv4
connection. Instead, correctly check IPv4 and IPv6 connections, assume that
AF_LOCAL is always local, and anything else is always remote.
This makes trivial local-to-remote forwarding work on my system.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5180
cda61777-01e9-0310-a592-
d414129be87e
ben [Sat, 22 Jan 2005 16:06:21 +0000 (16:06 +0000)]
Don't abuse a remote channel number of (unsigned)(-1) to indicate a channel
for which we don't yet have a remote number, and instead add a flag to indicate
this fact. Fixes bug ssh-remoteid-minusone.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5171
cda61777-01e9-0310-a592-
d414129be87e
ben [Sat, 22 Jan 2005 15:32:10 +0000 (15:32 +0000)]
When calling getaddrinfo() for a listening socket, pass in a suggested type
of SOCK_STREAM, since that's what we'll be using.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5170
cda61777-01e9-0310-a592-
d414129be87e
ben [Sat, 22 Jan 2005 15:20:35 +0000 (15:20 +0000)]
Stupid typo, spotted by GCC.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5168
cda61777-01e9-0310-a592-
d414129be87e
ben [Sat, 22 Jan 2005 15:19:21 +0000 (15:19 +0000)]
If getaddrinfo() fails, it's not safe to dereference the struct addrinfo* it
passes back to us, so don't.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5167
cda61777-01e9-0310-a592-
d414129be87e
simon [Sat, 22 Jan 2005 14:51:29 +0000 (14:51 +0000)]
Owen's just pointed out that random_stir() is capable of recursion.
I'm sure I didn't mean that to happen! Added a lock to stop it.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5166
cda61777-01e9-0310-a592-
d414129be87e
ben [Sat, 22 Jan 2005 14:01:01 +0000 (14:01 +0000)]
Explicitly ignore SCI rather than translating it into DECID. Should fix
bug sci-is-not-decid.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5164
cda61777-01e9-0310-a592-
d414129be87e
ben [Sat, 22 Jan 2005 13:32:41 +0000 (13:32 +0000)]
Probable support for first_kex_packet_follows in KEXINIT. Not significantly
tested since none of the common key-exchange protocols starts with a packet
from the server, so I don't have a server that implements this.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5162
cda61777-01e9-0310-a592-
d414129be87e
owen [Fri, 21 Jan 2005 00:02:59 +0000 (00:02 +0000)]
Colours now work properly, including 256-colour stuff.
Timing stuff now there, but almost certainly bogus.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5160
cda61777-01e9-0310-a592-
d414129be87e
ben [Thu, 20 Jan 2005 21:45:42 +0000 (21:45 +0000)]
Dispose of a variable whose only use was being set to zero.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5156
cda61777-01e9-0310-a592-
d414129be87e
owen [Thu, 20 Jan 2005 16:42:25 +0000 (16:42 +0000)]
Fix/bludgeon Mac compile wrinkles.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5154
cda61777-01e9-0310-a592-
d414129be87e
ben [Wed, 19 Jan 2005 23:30:38 +0000 (23:30 +0000)]
Add an assertion so that short-rsa2-key-crash at least avoids segfaulting
while we come up with a better solution.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5146
cda61777-01e9-0310-a592-
d414129be87e
ben [Wed, 19 Jan 2005 17:41:21 +0000 (17:41 +0000)]
While we're here, pad USERAUTH_INFO_RESPONSEs to 256 bytes too.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5145
cda61777-01e9-0310-a592-
d414129be87e
ben [Wed, 19 Jan 2005 12:34:52 +0000 (12:34 +0000)]
Make the outgoing SSH2 sequence number unsigned, so as to avoid depending
on overflow behaviour of signed integers.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5142
cda61777-01e9-0310-a592-
d414129be87e
simon [Wed, 19 Jan 2005 10:07:58 +0000 (10:07 +0000)]
Add a lengthy comment warning future front-end implementors about
the right and wrong way to implement the timing interface.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5137
cda61777-01e9-0310-a592-
d414129be87e
owen [Tue, 18 Jan 2005 22:01:25 +0000 (22:01 +0000)]
Bits and pieces, mostly stubs, for the Mac port.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5136
cda61777-01e9-0310-a592-
d414129be87e
owen [Tue, 18 Jan 2005 19:09:02 +0000 (19:09 +0000)]
Yes we do mean assignment. Bah.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5135
cda61777-01e9-0310-a592-
d414129be87e
owen [Tue, 18 Jan 2005 19:04:59 +0000 (19:04 +0000)]
The terminal reengineering of r4609 left an unused `start' lying around.
Remove it.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5134
cda61777-01e9-0310-a592-
d414129be87e
owen [Tue, 18 Jan 2005 09:38:58 +0000 (09:38 +0000)]
ssh_pkt_getstring wants a boring int rather than an unsigned int. Let's
give it one.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5129
cda61777-01e9-0310-a592-
d414129be87e
ben [Mon, 17 Jan 2005 16:38:55 +0000 (16:38 +0000)]
Currentish ssh.com supports single-DES in SSH2 as "des-cbc@ssh.com". It
seems to be entirely the same as "des-cbc", so supporting it is trivial
and we may as well do so. If nothing else, it makes it clear whose fault
it is.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5128
cda61777-01e9-0310-a592-
d414129be87e
owen [Mon, 17 Jan 2005 10:07:13 +0000 (10:07 +0000)]
Change some function arguments to void * to placate picky compilers.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5124
cda61777-01e9-0310-a592-
d414129be87e
ben [Mon, 17 Jan 2005 00:50:35 +0000 (00:50 +0000)]
In SSH2, rather than sending an SSH_MSG_IGNORE after every password, just
pad the packet out to 256 bytes. Much simpler.
This leavs ssh2_pkt_defer() unused, so ifdef it out.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5122
cda61777-01e9-0310-a592-
d414129be87e
ben [Sun, 16 Jan 2005 14:43:12 +0000 (14:43 +0000)]
Be a little less enthusiastic about sending SSH_MSG_CHANNEL_WINDOW_ADJUST:
only send it when it will significantly increase the server's idea of our
window. This avoids the slew of one-byte WINDOW_ADJUSTs that an interactive
shell typically generates.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5121
cda61777-01e9-0310-a592-
d414129be87e
owen [Sun, 16 Jan 2005 14:33:43 +0000 (14:33 +0000)]
Mac SC compiler whinges about trailing commas in enums
git-svn-id: svn://svn.tartarus.org/sgt/putty@5120
cda61777-01e9-0310-a592-
d414129be87e
simon [Sun, 16 Jan 2005 14:29:34 +0000 (14:29 +0000)]
Support for falling back through the list of addresses returned from
a DNS lookup, whether they're IPv4, v6 or a mixture of both.
git-svn-id: svn://svn.tartarus.org/sgt/putty@5119
cda61777-01e9-0310-a592-
d414129be87e