lp:~vcs-imports/putty/master

Created by Colin Watson on 2016-10-02 and last modified on 2019-04-20
Get this branch:
bzr branch lp:~vcs-imports/putty/master

Branch merges

Related bugs

Related blueprints

Branch information

Owner:
VCS imports
Project:
PuTTY
Status:
Development

Import details

Import Status: Reviewed

This branch is an import of the HEAD branch of the Git repository at git://git.tartarus.org/simon/putty.git.

The next import is scheduled to run in 3 hours.

Last successful import was 2 hours ago.

Import started 2 hours ago on izar and finished 2 hours ago taking 20 seconds — see the log
Import started 8 hours ago on alnitak and finished 8 hours ago taking 25 seconds — see the log
Import started 14 hours ago on alnitak and finished 14 hours ago taking 20 seconds — see the log
Import started 20 hours ago on izar and finished 20 hours ago taking 20 seconds — see the log
Import started on 2019-04-19 on alnitak and finished on 2019-04-19 taking 20 seconds — see the log
Import started on 2019-04-19 on alnitak and finished on 2019-04-19 taking 20 seconds — see the log
Import started on 2019-04-19 on alnitak and finished on 2019-04-19 taking 20 seconds — see the log
Import started on 2019-04-18 on izar and finished on 2019-04-18 taking 15 seconds — see the log
Import started on 2019-04-18 on alnitak and finished on 2019-04-18 taking 20 seconds — see the log
Import started on 2019-04-18 on izar and finished on 2019-04-18 taking 20 seconds — see the log

Recent revisions

5455. By Simon Tatham <email address hidden> 8 hours ago

Uppity: free the packet protocol layers on exit.

This bug and the one in the previous commit combined to mean that when
an SSH-1 connection through Uppity is terminated, the pty backend for
its main session channel was never cleaned up. (Firstly because
ssh1_connection_free never got called, and secondly because that in
turn forgot to free its mainchan.)

The effect of that in turn was that a _subsequent_ connection to the
same Uppity (using the new listening-socket mode) would likely reuse
the same fd for its pty, and the insertions into the ptyfds tree in
uxpty.c would silently fail because an existing Pty was already
occupying them, leading to a segfault when that Pty in turn responded
to events on a pty it didn't really own and tried to call back to a
seat that didn't exist any more.

5454. By Simon Tatham <email address hidden> 8 hours ago

SSH-1: free mainchan_chan on destruction.

We went through the tree234 of ordinary channels freeing the thing at
the other end of each one, but of course in SSH-1 the main session
channel is not stored in that tree due to its totally different shape
in the protocol. So naturally I forgot to free _that_ one.

5453. By Simon Tatham <email address hidden> 8 hours ago

SSH-1: disable trust sigils after session starts.

This exactly replicates the way it's done in SSH-2: at the start of
the connection layer we set the trust status to untrusted, and if that
reports that it didn't give any indication to the user, we fall back
to presenting an interactive anti-spoofing prompt.

I don't know how I forgot to do that in SSH-1, and even more, how we
haven't noticed for a month. We noticed the same bug in _Rlogin_
within a day of the 0.71 release, after all!

5452. By Simon Tatham <email address hidden> 8 hours ago

ssh2connection: missing free of antispoof_prompt.

Just noticed that if the session were to abort while that variable
contains some allocated data, it wouldn't be freed.

5451. By Simon Tatham <email address hidden> 8 hours ago

mainchan.c: rewrite handling of open-failure aborts.

This is another case where a stale pointer bug could have arisen from
a toplevel callback going off after an object was freed.

But here, just adding delete_callbacks_for_context wouldn't help. The
actual context parameter for the callback wasn't mainchan itself; it
was a tiny separate object, allocated to hold just the parameters of
the function the callback wanted to call. So if _those_ parameters
became stale before the callback was triggered, then even
delete_callbacks_for_context wouldn't have been able to help.

Also, mainchan itself would have been freed moments after this
callback was queued, so moving it to be a callback on mainchan itself
wouldn't help.

Solution: move the callback right out to Ssh, by introducing a new
ssh_sw_abort_deferred() which is just like ssh_sw_abort but does its
main work in a toplevel callback. Then ssh.c's existing call to
delete_callbacks_for_context will clean it up if necessary.

5450. By Simon Tatham <email address hidden> 9 hours ago

Add further missing delete_callbacks_for_context.

Having explicitly _stated_ in commit 4dcc0fddf the principle that if
you ever queue a toplevel callback on a freeable object then you
should also call delete_callbacks_for_context on that object before
freeing it, I realised I'd never actually gone through and checked
methodically at every call site of queue_toplevel_callback. So I did,
and naturally, I found several missing ones.

5449. By Simon Tatham <email address hidden> 10 hours ago

ssh2connection: clean up callbacks on exit.

We use a toplevel callback in the SSH-2 connection layer for checking
whether it's time to close the whole SSH session after a channel
closes. If the channel close itself, or something close enough to it,
involves a protocol error severe enough to abort the session and free
the connection layer, then that callback can fire anyway on stale
data.

The fix is the same as it always is in these situations: any object
which is ever used as the context parameter to queue_toplevel_callback
should also be passed to delete_callbacks_for_context before freeing it.

5448. By Jacob Nevins <email address hidden> on 2019-04-19

UDP: the 'mac' directory no longer exists.

5447. By Jacob Nevins <email address hidden> on 2019-04-19

Docs: tweaks in Feedback for the modern world.

5446. By Jacob Nevins <email address hidden> on 2019-04-19

FAQ: misc tweaks for the modern world.

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
This branch contains Public information 
Everyone can see this information.

Subscribers