summaryrefslogtreecommitdiff
path: root/usr.bin/ssh/sftp.c
AgeCommit message (Collapse)Author
2008-06-21use optopt to get invalid flag, instead of return value of getopt,Martynas Venckus
which is always '?'; ok djm@
2008-06-08Have the sftp client store the statvfs replies in wire format,Darren Tucker
which prevents problems when the server's native sizes exceed the client's. Also extends the sizes of the remaining 32bit wire format to 64bit, they're specified as unsigned long in the standard.
2008-04-18introduce sftp extension methods statvfs@openssh.com andDamien Miller
fstatvfs@openssh.com that implement statvfs(2)-like operations, based on a patch from miklos AT szeredi.hu (bz#1399) also add a "df" command to the sftp client that uses the statvfs@openssh.com to produce a df(1)-like display of filesystem space and inode utilisation ok markus@
2008-01-20When uploading, correctly handle the case of an unquoted filename withDamien Miller
glob metacharacters that match a file exactly but not as a glob, e.g. a file called "[abcd]". report and test cases from duncan2nd AT gmx.de
2007-12-12unbreak lls command and add a regress test that would have caught theDamien Miller
breakage; spotted by mouring@
2007-10-24rework argument splitting and parsing to cope correctly with common shellDamien Miller
escapes and make handling of escaped characters consistent with sh(1) and between sftp commands (especially between ones that glob their arguments and ones that don't). parse command flags using getopt(3) rather than hand-rolled parsers. ok dtucker@
2007-01-03ARGSUSED for lintKevin Steves
2007-01-03spacesKevin Steves
2006-11-23Don't access buf[strlen(buf) - 1] for zero-length strings.Ray Lai
``ok by me'' djm@.
2006-09-30Clear errno before calling the strtol functions.Ray Lai
From Paul Stoeber <x0001 at x dot de1 dot cc>. OK deraadt@.
2006-09-19Use S_IS* macros insted of masking with S_IF* flags. The latter mayOtto Moerbeek
have multiple bits set, which lead to surprising results. Spotted by Paul Stoeber, more to come. ok millert@ pedro@ jaredy@ djm@
2006-08-03almost entirely get rid of the culture of ".h files that include .h files"Theo de Raadt
ok djm, sort of ok stevesk makes the pain stop in one easy step
2006-08-01move #include <stdio.h> out of includes.hKevin Steves
2006-07-26move #include <stdlib.h> out of includes.hKevin Steves
2006-07-26move #include <sys/param.h> out of includes.hKevin Steves
2006-07-22move #include <string.h> out of includes.hKevin Steves
2006-07-17move #include <unistd.h> out of includes.hKevin Steves
2006-07-11move #include <errno.h> out of includes.h; ok markus@Kevin Steves
2006-07-10buffer.h only needed in sftp-common.h and remove some unneededKevin Steves
user includes; ok djm@
2006-07-08move #include <sys/socket.h> out of includes.hKevin Steves
2006-05-17fix leak; coverity via Kylene Jo HallMarkus Friedl
2006-04-20Switch from using pipes to socketpairs for communication betweenDamien Miller
sftp/scp and ssh, and between sshd and its subprocesses. This saves a file descriptor per session and apparently makes userland ppp over ssh work; ok markus@ deraadt@
2006-03-27always use a format string for addargs; spotted by mouring@Damien Miller
2006-03-25Put $OpenBSD$ tags back (as comments) to replace the RCSID()s thatDamien Miller
Theo nuked - our scripts to sync -portable need them in the files
2006-03-25"abormally" is a perfectly cromulent word, but "abnormally" is betterDamien Miller
2006-03-19RCSID() can dieTheo de Raadt
2006-03-19more memory leaks detected by Coverity via elad AT netbsd.org;Damien Miller
deraadt@ ok
2006-02-20move #include <sys/stat.h> out of includes.h; ok markus@Kevin Steves
2006-02-20move #include <signal.h> out of includes.h; ok markus@Kevin Steves
2006-02-10move #include <sys/wait.h> out of includes.h; ok markus@Kevin Steves
2006-02-10move #include <sys/ioctl.h> out of includes.h; ok markus@Kevin Steves
2006-02-08move #include <paths.h> out of includes.h; ok markus@Kevin Steves
2006-01-31fix local arbitrary command execution vulnerability on local/local andDamien Miller
remote/remote copies (CVE-2006-0225, bz #1094), patch by t8m AT centrum.cz, polished by dtucker@ and myself; ok markus@
2005-12-06Add support for tun(4) forwarding over OpenSSH, based on an idea andReyk Floeter
initial channel code bits by markus@. This is a simple and easy way to use OpenSSH for ad hoc virtual private network connections, e.g. administrative tunnels or secure wireless access. It's based on a new ssh channel and works similar to the existing TCP forwarding support, except that it depends on the tun(4) network interface on both ends of the connection for layer 2 or layer 3 tunneling. This diff also adds support for LocalCommand in the ssh(1) client. ok djm@, markus@, jmc@ (manpages), tested and discussed with others
2005-10-31Fix sorting with "ls -1" command. From Robert Tsai, "looks right" deraadt@Darren Tucker
2005-09-13ensure that stdio fds are attached; ok deraadt@Damien Miller
2005-08-08sftp prompt enhancements:Jared Yanovich
- in non-interactive mode, do not print an empty prompt at the end before finishing - print newline after EOF in editline mode - call el_end() in editline mode ok dtucker djm
2005-07-17knf says that a 2nd level indent is four (not three or five) spacesDamien Miller
2005-06-17make this -Wsign-compare clean; ok avsm@ markus@Damien Miller
2005-03-10spacingTheo de Raadt
2005-02-20turn on ssh batch mode when in sftp batch mode, patch from jdmossh AT nand.net;Damien Miller
ok markus@
2005-01-24Have scp and sftp wait for the spawned ssh to exit before they exitDarren Tucker
themselves. This prevents ssh from being unable to restore terminal modes (not normally a problem on OpenBSD but common with -Portable on POSIX platforms). From peak at argo.troja.mff.cuni.cz (bz#950); ok djm@ markus@
2004-12-10- fix globbed ls for paths the same lenght as the globbed path whenFederico G. Schwindt
we have a unique matching. - fix globbed ls in case of a directory when we have a unique matching. - as a side effect, if the path does not exist error (used to silently ignore). - don't do extra do_lstat() if we only have one matching file. djm@ ok
2004-11-29Some small fixes from moritz@jodeit.org. ok deraadt@Damien Miller
2004-11-25leak; from mpechMarkus Friedl
2004-11-05command editing and history support via libedit; ok markus@Damien Miller
thanks to hshoexer@ and many testers on tech@ too
2004-07-11spacesTheo de Raadt
2004-06-25bz #875: fix bad escape char error message; reported by f_mohr AT yahoo.deDamien Miller
2004-06-22don't show .files by default in ls, add -a option to turn them back on;Damien Miller
ok markus
2004-06-21prefix ls option flags with LS_Damien Miller