1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-10 09:58:01 +00:00
Commit Graph

552 Commits

Author SHA1 Message Date
Simon Tatham
8fff1e4821 Fix a segfault (addr->error was unpredictable following a dotted-dec lookup)
[originally from svn r768]
2000-10-26 08:25:43 +00:00
Simon Tatham
5f73cf092f Impose a lower limit of 256 on key lengths. This is mostly because
the primegen() function doesn't work well with <100 bits, so RSA
keys need to be >=200 to be generated correctly, and I thought 256
was a nice round number beyond that just to be sure. Perhaps I
should also have a security warning on any key less than 768; or
perhaps I should let people shoot themselves in the feet if they
really want to.

[originally from svn r767]
2000-10-25 14:29:28 +00:00
Simon Tatham
fc63ad0046 Gaaah, I might have known. Split combined app cursor / app keypad
disablement option into two options so the app cursor keys and app
keypad can be controlled separately. The Pedantic Software Award in
this case goes to the Midnight Commander for its egregious failure
to just use the terminal in Perfectly Normal mode.

[originally from svn r766]
2000-10-25 14:20:47 +00:00
Simon Tatham
4aafc6e5c3 Be more sure that state->collecting_entropy can't be spuriously set
[originally from svn r765]
2000-10-25 10:25:10 +00:00
Simon Tatham
9e6dc1faa1 Fix control ID bug causing rogue Appearance title bars in other panels
[originally from svn r764]
2000-10-25 08:23:41 +00:00
Simon Tatham
f9cf0d70b7 Reintroduce random_stir()
[originally from svn r763]
2000-10-25 06:59:25 +00:00
Simon Tatham
38e7de3372 Enhance Diffie-Hellman implementation to use bignum_cmp
[originally from svn r762]
2000-10-25 06:57:36 +00:00
Simon Tatham
809bd81d5c Fix another bignum formatting problem. This one hit Diffie-Hellmann
[originally from svn r761]
2000-10-24 21:43:39 +00:00
Simon Tatham
fc9b38ed01 Add configurable option to disable application keypad/cursor keys totally
[originally from svn r760]
2000-10-24 13:49:23 +00:00
Simon Tatham
779069ccd3 Add a couple of ellipses in system menu
[originally from svn r759]
2000-10-24 13:40:19 +00:00
Simon Tatham
8f7a1e30f7 Remove a rogue diagnostic
[originally from svn r758]
2000-10-24 13:39:21 +00:00
Simon Tatham
ea0d42801a Add the Appearance panel and reorganise things a bit
[originally from svn r757]
2000-10-24 13:38:27 +00:00
Simon Tatham
372a4e1e7e Fix failure to re-enable local line discipline when TELOPT_ECHO is
turned _back off_ by the remote server. (server sends WONT)

[originally from svn r756]
2000-10-24 11:16:25 +00:00
Simon Tatham
384eeb3f76 Fix miscellaneous compiler warnings. Thanks to Jacob Nevins
[originally from svn r755]
2000-10-24 10:47:49 +00:00
Simon Tatham
5ff9cc2f1f SSH2 connections weren't closing cleanly after socket revamp. Fixed.
[originally from svn r754]
2000-10-24 09:55:45 +00:00
Simon Tatham
039103ff5d Window resizing wasn't working in SSH2
[originally from svn r753]
2000-10-24 09:49:03 +00:00
Simon Tatham
e51b4da9f7 Make the frankly ridiculous prototypes for modpow() and modmul() more sane
[originally from svn r752]
2000-10-23 16:11:31 +00:00
Simon Tatham
bf2744aabf Update DSS implementation to use new bignum routines
[originally from svn r751]
2000-10-23 16:03:21 +00:00
Simon Tatham
36156d858c Improved entropy gathering.
[originally from svn r750]
2000-10-23 15:20:05 +00:00
Simon Tatham
43304f1fca Fix a bug which was causing occasional failed-host-key-check
messages. Also left some diagnostics in, under #if 0, so that next
time this happens it'll be easier to debug.

[originally from svn r749]
2000-10-23 15:18:37 +00:00
Simon Tatham
b5c41a473b Oops. A field like `sending_oob' in the Socket structure really
deserves to be initialised to something sane at creation time.

[originally from svn r748]
2000-10-23 12:31:54 +00:00
Simon Tatham
d0635e9d39 Plink and PSCP were failing to load the `Default Settings' options
when connecting to an arbitrary hostname. In particular, setting a
default user name didn't work. Now it does.

[originally from svn r747]
2000-10-23 12:20:53 +00:00
Simon Tatham
5d27e5775c Remove the NO_SECURITY define I accidentally copied from Pageant
[originally from svn r746]
2000-10-23 11:57:41 +00:00
Simon Tatham
988c1974ea Created a shiny new abstraction for the socket handling. Has many
advantages:
 - protocol modules can call sk_write() without having to worry
   about writes blocking, because blocking writes are handled in the
   abstraction layer and retried later.
 - `Lost connection while sending' is a thing of the past.
 - <winsock.h> is no longer needed in most modules, because
   "putty.h" doesn't have to declare `SOCKET' variables any more,
   only the abstracted `Socket' type.
 - select()-equivalent between multiple sockets will now be handled
   sensibly, which opens the way for things like SSH port
   forwarding.

[originally from svn r745]
2000-10-23 11:55:11 +00:00
Simon Tatham
bbbda4110b Created a shiny new abstraction for the socket handling. Has many
advantages:
 - protocol modules can call sk_write() without having to worry
   about writes blocking, because blocking writes are handled in the
   abstraction layer and retried later.
 - `Lost connection while sending' is a thing of the past.
 - <winsock.h> is no longer needed in most modules, because
   "putty.h" doesn't have to declare `SOCKET' variables any more,
   only the abstracted `Socket' type.
 - select()-equivalent between multiple sockets will now be handled
   sensibly, which opens the way for things like SSH port
   forwarding.

[originally from svn r744]
2000-10-23 10:32:37 +00:00
Simon Tatham
882f653081 Ooh. Actually, that vulnerability is further-reaching than I
thought. As well as the ".." attack in recursive copies, the name
sent by the client was also trusted in a single-file implicit-
destination copy such as "pscp host:foo .". (The result was ./foo,
where foo is what the server claimed the file was rather than what
the user asked for. I think it's not unreasonable that if the user
requests file `foo' from the host, he should get the result in a
file called `foo' no matter what the host thinks.)

[originally from svn r743]
2000-10-21 17:52:54 +00:00
Simon Tatham
b78c5699d1 Fix a potential vulnerability in incoming `pscp -r'. The server
sends filenames of things in the directory being copied. A malicious
server could have sent, for example, "..\..\windows\system\foo.dll"
and overwritten something crucial. The filenames are now vetted to
ensure they don't contain slashes or backslashes.

[originally from svn r742]
2000-10-21 17:36:44 +00:00
Simon Tatham
6eb613e3c4 Three new configurable options:
- Robert de Bath's Compose key is now off by default and configurable on
 - The ages-old controversy over whether ALT by itself should bring the
   System menu up is now controllable by a config option
 - You can now independently configure whether scrollback resets on a
   keypress _and_ whether it resets on screen activity.

[originally from svn r741]
2000-10-21 16:30:58 +00:00
Simon Tatham
77c8e3c17c Chinese support patch from zmx@cdpa.nsysu.edu.tw
[originally from svn r740]
2000-10-20 18:36:15 +00:00
Simon Tatham
964e6407e1 Remember to close key files when rsakey_encrypted meets a bogus one
[originally from svn r739]
2000-10-20 17:57:47 +00:00
Simon Tatham
17cea8353f Put back the code that ensures "Default Settings" is always in the
session list even if it isn't in the Registry. This got deleted
overenthusiastically because I didn't have a comment explaining what
it was doing there. Now there's a comment, so I probably won't
remove it again.

[originally from svn r733]
2000-10-20 15:20:53 +00:00
Simon Tatham
51b05a4438 Rename "Stored Sessions" to "Saved Sessions" for consistency
[originally from svn r732]
2000-10-20 15:09:56 +00:00
Simon Tatham
4b08041d42 Some better IDC_* names for the controls on the Colours panel
[originally from svn r731]
2000-10-20 15:09:35 +00:00
Simon Tatham
cbf38bc831 Add the LBS_NOTIFY style to the list box in colouredit(), which was
vital to it working right

[originally from svn r730]
2000-10-20 14:45:16 +00:00
Simon Tatham
e32603347c Introduce a sane interface function, from_backend(), for backends to
use when they have data from the network. Replaces the utterly daft
inbuf / inbuf_head / term_out() interface, which only made sense
when feeding to terminal.c. (terminal.c now implements
from_backend() as a small function that gateways to the old
interface.)

As a side effect, from_backend() also has an `is_stderr' parameter,
so scp can once again separate the server's pronouncements on stderr
from the actual protocol progress on stdout.

[originally from svn r729]
2000-10-20 13:51:46 +00:00
Simon Tatham
31374678c0 Trim trailing whitespace off saved session names on the command line
[originally from svn r728]
2000-10-20 13:23:24 +00:00
Simon Tatham
a80fa10287 Remember to update scrollbar when scrollback is reset
[originally from svn r727]
2000-10-20 12:31:02 +00:00
Simon Tatham
0432fabf20 Replace the 8859-2 -> Win1250 translation which I accidentally blew away
[originally from svn r726]
2000-10-20 11:16:58 +00:00
Simon Tatham
26ff0d4e75 A couple of UI tweaks in puttygen
[originally from svn r725]
2000-10-20 10:47:46 +00:00
Simon Tatham
450905f02c Removed TODO comment after verifying that generated keys work
[originally from svn r724]
2000-10-20 10:44:17 +00:00
Simon Tatham
58cdc03c68 Entropy fix after better statistical analysis
[originally from svn r723]
2000-10-20 10:42:31 +00:00
Simon Tatham
92deca11dd Variable key size in PuTTYgen. Also required adding WM_VSCROLL to the
window style in bigeditctrl() in winctrls.c.

[originally from svn r722]
2000-10-20 10:07:53 +00:00
Simon Tatham
2743ab90f5 Add a PuTTYgen icon
[originally from svn r721]
2000-10-20 09:50:56 +00:00
Simon Tatham
8c138ebd41 Check whether key was actually saved, and warn if not
[originally from svn r720]
2000-10-20 09:43:58 +00:00
Simon Tatham
918c9ddfc5 Save Key now prompts before overwriting an existing file
[originally from svn r719]
2000-10-20 09:41:13 +00:00
Simon Tatham
e0ad00f264 Adjust the title of the PuTTYgen window
[originally from svn r718]
2000-10-20 09:36:11 +00:00
Simon Tatham
76638e62be Add a second passphrase prompt to protect against typos
[originally from svn r717]
2000-10-20 09:31:16 +00:00
Simon Tatham
0210709520 We must InitCommonControls() or the progress bar doesn't work on 95
[originally from svn r716]
2000-10-20 09:24:44 +00:00
Simon Tatham
8d0bee8629 PuTTYgen initial version. Still to do are basic user-friendliness
features (prompt for passphrase twice, prompt before overwriting a
file, check the key file was actually saved OK), testing of the
generated keys to make sure I got the file format right, and support
for a variable key size. I think what's already here is basically
sound though.

[originally from svn r715]
2000-10-19 15:43:08 +00:00
Simon Tatham
8e7a270f7f Miscellaneous cleanups and reorgs in preparation for building
PuTTYgen. In particular, moved self-managing controls stuff out of
windlg.c into the new and reusable winctrls.c.

[originally from svn r714]
2000-10-18 15:36:32 +00:00