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

48 Commits

Author SHA1 Message Date
Simon Tatham
3730ada5ce Run entire source base through GNU indent to tidy up the varying
coding styles of the various contributors! Woohoo!

[originally from svn r1098]
2001-05-06 14:35:20 +00:00
Simon Tatham
d27112ea87 Put the \001 prefix back on scp error messages when they're sent to
the server. (Not sure _why_ they're sent to the server; scp is
weird.) It may be pointless when sent to the screen, which is why I
removed it, but it's extremely pointful on the wire :-(

[originally from svn r1090]
2001-04-28 17:18:47 +00:00
Simon Tatham
b7844a20af Add some fflushes to make it easier for piped programs to talk to
plink and pscp

[originally from svn r1078]
2001-04-28 08:42:06 +00:00
Simon Tatham
55659a959f ssh_get_password has become ssh_get_line, so it can handle usernames
as well. This should fix the multiple-reads-on-stdin bug in plink.

[originally from svn r994]
2001-03-12 15:31:53 +00:00
Simon Tatham
1de4d29392 Remove -gui from the command-line help in pscp, because it's an
internal option only.

[originally from svn r903]
2001-01-27 15:51:41 +00:00
Simon Tatham
23dbd2d8f5 Fix build errors in PSCP after line discipline upheaval
[originally from svn r898]
2001-01-26 09:33:12 +00:00
Simon Tatham
7a79df8fe6 Rethink the whole line discipline architecture. Instead of having
multiple switchable line disciplines, we now have a single unified
one which changes its behaviour based on option settings. Each
option setting can be suggested by the back end and/or the terminal
handler, and can be forcibly overridden by the configuration. Local
echo and local line editing are separate, independently switchable,
options.

[originally from svn r895]
2001-01-24 14:08:20 +00:00
Simon Tatham
fc478e6cad Turn a rogue malloc to smalloc
[originally from svn r840]
2001-01-07 15:27:19 +00:00
Simon Tatham
826a464682 Patch from Christian Biesinger: pscp guesses your Windows username by default
[originally from svn r836]
2001-01-07 13:31:49 +00:00
Simon Tatham
d5240d4157 Make memory management uniform: _everything_ now goes through the
smalloc() macros and thence to the safemalloc() functions in misc.c.
This should allow me to plug in a debugging allocator and track
memory leaks and segfaults and things.

[originally from svn r818]
2000-12-12 10:33:13 +00:00
Simon Tatham
b9c07ac266 Prevent wildcards in source specs from matching . or ..
[originally from svn r813]
2000-11-30 21:35:28 +00:00
Simon Tatham
694fd2eedf Fix another silly segfault
[originally from svn r800]
2000-11-15 11:13:22 +00:00
Simon Tatham
6928fbb1e3 Back off a bit of that vulnerability fix, which was breaking `pscp
host:wildcard* .' and suchlike.

[originally from svn r790]
2000-10-31 09:29:05 +00:00
Simon Tatham
2cc663cafb Couple of fixes for pscp's GUI interface mode
[originally from svn r778]
2000-10-30 09:54:10 +00:00
Simon Tatham
2c9c817895 Misc bugfixes
[originally from svn r771]
2000-10-27 09:17:19 +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
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
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
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
Simon Tatham
b584238186 Create settings.c and move the load/save session code out of
windlg.c into it. Allows plink and pscp to no longer link with
windlg.c, meaning they lose some of the sillier stub functions and
also can provide a console-based form of verify_ssh_host_key().

[originally from svn r683]
2000-10-06 13:21:36 +00:00
Simon Tatham
7b6106d62a Add a parameter to write_clip() so that windlg.c need not call term_deselect
[originally from svn r681]
2000-10-06 12:32:25 +00:00
Simon Tatham
8c169b0c6d Tighten up use of "static" throughout. Module-internal things should NOT
be exported willy-nilly. It encourages people to use them.

[originally from svn r677]
2000-10-06 11:42:30 +00:00
Simon Tatham
e424247802 Fix a typo; thanks to Al Sutton
[originally from svn r667]
2000-10-04 10:02:25 +00:00
Simon Tatham
0fed43e9f4 Remove the special hooks in ssh.c for pscp. pscp now uses the standard
interface to the outside of the ssh module. This means pscp now works
without change in SSH2.

[originally from svn r638]
2000-09-27 09:36:39 +00:00
Simon Tatham
cbdd9b3ac5 Enable copying the Event Log
[originally from svn r619]
2000-09-22 14:46:26 +00:00
Simon Tatham
e70425dda6 Enable better build-time flexibility over which WinSock to include
[originally from svn r615]
2000-09-22 13:16:49 +00:00
Simon Tatham
c0ac8ab9b4 Bug fix: line discipline selection is not enabled until after ssh
authentication phase to stop user/password prompts behaving oddly

[originally from svn r614]
2000-09-22 13:10:19 +00:00
Simon Tatham
e5ef37f3f5 Prevent network errors from summarily closing the window when CoE is off
[originally from svn r613]
2000-09-22 11:04:57 +00:00
Simon Tatham
180b62b6b0 Miscellaneous ssh2 fixes. plink is now relatively sane
[originally from svn r608]
2000-09-21 14:34:32 +00:00
Simon Tatham
98d40b56fe Lars Gunnarsson's GUI interface changes
[originally from svn r598]
2000-09-15 15:54:04 +00:00
Simon Tatham
8394a48620 Added a fourth application: plink, a command line connection utility
[originally from svn r575]
2000-09-08 14:45:20 +00:00
Simon Tatham
9546cf7393 PSCP: After a password supplied with `-pw' fails to authenticate,
we should _not_ fall back to console input for a second attempt,
because this hangs batch files.

[originally from svn r513]
2000-07-21 09:17:05 +00:00
Simon Tatham
2832ef1e75 Joris van Rantwijk's unified SSH code suitable for PuTTY and PSCP
[originally from svn r504]
[this commit reordered to come after creation of 0.49 tag]
2000-06-22 12:18:34 +00:00
Simon Tatham
8bce06889d "pscp" was spelled "scp" in usage message
[originally from svn r497]
2000-06-06 09:51:27 +00:00
Simon Tatham
66f6a6dc24 Add -ls to online help bit
[originally from svn r436]
2000-04-04 14:40:44 +00:00
Simon Tatham
0ac9df8251 Add the -ls option to execute `ls -la' on a directory instead of
trying to copy anything. Likely to be useful for GUI front ends.

[originally from svn r435]
2000-04-03 19:54:31 +00:00
Simon Tatham
9922072a8d Peter Schellenbach's patch: re-implement the PuTTY cryptographic
functions as calls to the MS Crypto API. Not integrated into the
Makefile yet, but should eventually allow building of an SSH-enabled
PuTTY which contains no native crypto code, so it can be used
everywhere (and anyone who can get the MS encryption pack can still
use the SSH parts).

[originally from svn r425]
2000-03-24 09:45:49 +00:00
Simon Tatham
11821d4d27 Fix some picky compiler warnings kindly provided by Borland C++ 5.5
[originally from svn r396]
2000-03-08 10:21:13 +00:00
Simon Tatham
ee038a773e Fix an error message in pscp
[originally from svn r390]
2000-02-21 14:20:19 +00:00
Simon Tatham
c793ad69f7 Joris van Rantwijk's fix for pscp -P
[originally from svn r375]
2000-01-28 20:20:58 +00:00
Simon Tatham
cc98ca9aea Avoid recursing into . and .. when in -r mode
[originally from svn r332]
1999-11-30 11:53:42 +00:00
Simon Tatham
8446532e4a Cleanups to remove warnings for GNU/mingw32 compilation
[originally from svn r325]
1999-11-22 10:07:24 +00:00
Simon Tatham
e0baec8159 Fix a slightly picky compiler warning
[originally from svn r317]
1999-11-17 10:39:17 +00:00
Simon Tatham
1d837144c4 Update from Joris van Rantwijk: command line options to specify
port and password in scp

[originally from svn r312]
1999-11-16 09:26:19 +00:00
Simon Tatham
3c9b8bff57 Clean up scp client - re-indent to my coding style and remove
compiler warnings

[originally from svn r280]
1999-11-08 11:22:45 +00:00
Simon Tatham
4df919c784 Added Joris van Rantwijk's scp client
[originally from svn r205]
1999-08-31 09:20:48 +00:00