summaryrefslogtreecommitdiffhomepage
path: root/svr-chansession.c
AgeCommit message (Collapse)Author
2021-03-06Prevent multiple shells being spawnedMatt Johnston
Existing shells would be leaked. The old check only caught multiple commands, not shells.
2021-03-06small tidy of "signal" while loopMatt Johnston
2021-01-29fuzz: wrap kill()Matt Johnston
2020-10-08Avoid gnu extension conditional operatorMatt Johnston
2020-03-14Set SSH_ORIGINAL_COMMAND for "dropbear -c" too, fix build withoutMatt Johnston
DROPBEAR_SVR_PUBKEY_OPTIONS
2019-03-20Support servers without multiple user support (#76)Patrick Stewart
2018-11-14Split ChanType closehandler() and cleanup() so that dbclient doesn'tMatt Johnston
lose exit status messages
2018-02-17more linting (#55)François Perrad
* dropbear_exit: remove priority parameter confusion with dropbear_log() * const parameter
2018-02-16options: Complete the transition to numeric toggles (`#if')Michael Witten
For the sake of review, this commit alters only the code; the affiliated comments within the source files also need to be updated, but doing so now would obscure the operational changes that have been made here. * All on/off options have been switched to the numeric `#if' variant; that is the only way to make this `default_options.h.in' thing work in a reasonable manner. * There is now some very minor compile-time checking of the user's choice of options. * NO_FAST_EXPTMOD doesn't seem to be used, so it has been removed. * ENABLE_USER_ALGO_LIST was supposed to be renamed DROPBEAR_USER_ALGO_LIST, and this commit completes that work. * DROPBEAR_FUZZ seems to be a relatively new, as-yet undocumented option, which was added by the following commit: commit 6e0b539e9ca0b5628c6c5a3d118ad6a2e79e8039 Author: Matt Johnston <matt@ucc.asn.au> Date: Tue May 23 22:29:21 2017 +0800 split out checkpubkey_line() separately It has now been added to `sysoptions.h' and defined as `0' by default. * The configuration option `DROPBEAR_PASSWORD_ENV' is no longer listed in `default_options.h.in'; it is no longer meant to be set by the user, and is instead left to be defined in `sysoptions.h' (where it was already being defined) as merely the name of the environment variable in question: DROPBEAR_PASSWORD To enable or disable use of that environment variable, the user must now toggle `DROPBEAR_USE_DROPBEAR_PASSWORD'. * The sFTP support is now toggled by setting `DROPBEAR_SFTPSERVER', and the path of the sFTP server program is set independently through the usual SFTPSERVER_PATH.
2018-02-14fix compile warningsMatt Johnston
2018-02-14make signal flags volatile, simplify handlingMatt Johnston
2017-08-19Pointer parameter could be declared as pointing to const (callback)Francois Perrad
2017-08-19Pointer parameter could be declared as pointing to constFrancois Perrad
2016-11-15initialize variableFrancois Perrad
2016-05-04Convert #ifdef to #if, other build changesMatt Johnston
2016-04-12Add -c <command> option to force a specific commandJeremy Kerr
This change adds a -c option to dropbear, to force the session to use a specific command, in a similar fashion to OpenSSH's ForceCommand configuration option. This is useful to provide a simple fixed service over ssh, without requiring an authorized key file for the per-key forced_command option. This setting takes precedence over the channel session's provided command, and the per-key forced_command setting. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
2015-10-21Don't display the MOTD when an explicit command is run.Guilhem Moulin
(possibly via authorized_keys(5) restrictions), even when a pseudo-terminal has been allocated for the session. In other words, only display the MOTD when the server starts the user's default shell.
2015-06-04buf_getstring and buf_putstring now use non-unsigned char*Matt Johnston
2015-05-05Turn signame local variable into char *Gaël PORTAY
2015-05-05Turn ChanSess's cmd attribute into char *Gaël PORTAY
2015-05-05Turn type local variable into char *Gaël PORTAY
2015-05-05Turn ChanSess's tty and term attributes into char *Gaël PORTAY
2015-05-05Fix pointer differ in signess warnings [-Werror=pointer-sign]Gaël PORTAY
2015-05-05Fix unused make_connection_string() warning [-Werror=unused-function]Gaël PORTAY
This function is used when USE_VFORK is unset.
2015-02-24Revert accidental commented out signal handlersMatt Johnston
2015-02-24Free memory before exiting. Based on patch from Thorsten Horstmann.Matt Johnston
Client side is not complete.
2015-02-24Fix for old compilers, variable declarations at beginning of functionsThorsten Horstmann
and /**/ comments
2014-10-21Combine code for SSH_CONNECTION and SSH_CLIENTMatt Johnston
2014-10-20Add SSH_CLIENT environment variableRyan Cleere
2014-08-19Make keepalive handling more robust, this should now match what OpenSSH doesMatt Johnston
2014-07-28Make sure the check_close() handler runs when a server child process exitsMatt Johnston
2014-07-16Set tcp priority as follows:Matt Johnston
if (connecting || ptys || x11) tos = LOWDELAY; else if (tcp_forwards) tos = 0; else tos = BULK; TCP forwards could be either lowdelay or bulk, hence the default priority.
2014-02-15- Save errno in signal handlersMatt Johnston
- Use _exit() in segv handler
2013-12-03- Sockets are set to lowdelay priority initially to improve conneciton setupMatt Johnston
time - Set non-pty connections to bulk for client and server
2013-12-02Set IPTOS_LOWDELAY on PTY sessions onlyCatalin Patulea
2013-11-14rename random.h to dbrandom.h since some OSes have a system random.hMatt Johnston
--HG-- rename : random.c => dbrandom.c rename : random.h => dbrandom.h
2013-08-12Remove accidental one second sleep leftover from debuggingMatt Johnston
2012-06-29Improve RNG seeding.Matt Johnston
Try to read from /dev/urandom multiple times, take input from extra sources, and use /dev/random when generating private keys
2012-03-26Fixed compilation with unset ENABLE_{SVR,CLI}_AGENTFWD.Andrey Mazo
Got rid of ENABLE_AGENTFWD macro.
2012-04-09Rename HAVE_FORK to USE_VFORKMatt Johnston
It makes it a bit more obvious why there's a test there since HAVE_FORK is the normal case.
2012-04-08check for fork() and not __uClinux__Mike Frysinger
2011-12-04- Initialise sa_mask properlyMatt Johnston
2012-02-21- MergeMatt Johnston
2012-02-21- Make sure sa_mask is setMatt Johnston
2011-12-04- Fix use-after-free if multiple command requests were sent. MoveMatt Johnston
the original_command into chansess struct since that makes more sense
2011-03-31Avoid segfault when handling childpid raceMatt Johnston
--HG-- extra : convert_revision : 8845727a7e2b096015dbb76d8f3df13c9acee7da
2011-02-28Compile fix for when both client and server agent forwarding is disabledMatt Johnston
--HG-- extra : convert_revision : 8a608f0ed5e4b491dba4bf330e560636ec7376fd
2011-02-23Improve capitalisation for all logged stringsMatt Johnston
--HG-- extra : convert_revision : 997e53cec7a9efb7413ac6e17b6be60a5597bd2e
2010-03-04don't #include "utmp.h"Matt Johnston
--HG-- extra : convert_revision : a014a978f213e6ff424e7d10794ae426375f3191
2009-09-05Move remotehost into svr_ses structure since we can't look it upMatt Johnston
once we've forked (the connection socket has been closed). Fixes inetd mode. --HG-- extra : convert_revision : 7d5d152ec84fb11a188966c1400d213c908cc511