summaryrefslogtreecommitdiffstats
path: root/contrib/telnet/telnetd/state.c
Commit message (Collapse)AuthorAgeFilesLines
* Make sure that each va_start has one and only one matching va_end,kevlo2012-09-281-1/+3
| | | | especially in error cases.
* Don't attempt authentication at all if it has been disabled via '-a off'.jhb2008-07-281-2/+4
| | | | | | | | | This works around a bug in HP-UX's telnet client and also gives a much saner user experience when using FreeBSD's telnet client. PR: bin/19405 Submitted by: Joel Ray Holveck joelh of gnu.org MFC after: 1 month
* Use __FBSDID vs. rcsid[]. Also protect sccs[] and copyright[] from GCC 3.3.obrien2003-05-041-4/+4
|
* Catch up with "base" telnet.markm2002-09-251-3/+3
| | | | s/FALL THROUGH/FALLTHROUGH/ for lint(1).
* Very large style makeover.markm2001-11-301-63/+47
| | | | | | | | | | | | | 1) ANSIfy. 2) Clean up ifdefs so that a) ones that never/always apply are appropriately either fully removed, or just the #if junk is removed. b) change #if defined(FOO) for appropiate values of FOO. (currently AUTHENTICATION and ENCRYPTION) 3) WARNS=2 fixing 4) GC other unused stuff This code can now be unifdef(1)ed to make non-crypto telnet.
* Manually unifdef(1) CRAY, UNICOS, hpux and sun uselsess code.markm2001-08-291-18/+0
|
* Code merge and diff reduce with "base" telnet. This is the "later"markm2001-08-201-0/+5
| | | | | telnet, so it was treated as the reference code, except where later commits were made to "base" telnet.
* output_data(), output_datalen() and netflush() didn't actually guaranteekris2001-07-231-22/+28
| | | | | | | | | | | | | to do what they are supposed to: under some circumstances output data would be truncated, or the buffer would not actually be flushed (possibly leading to overflows when the caller assumes the operation succeeded). Change the semantics so that these functions ensure they complete the operation before returning. Comment out diagnostic code enabled by '-D reports' which causes an infinite recursion and an eventual crash. Patch developed with assistance from ru and assar.
* More potential buffer overflow fixes.ru2001-07-201-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | o Fixed `nfrontp' calculations in output_data(). If `remaining' is initially zero, it was possible for `nfrontp' to be decremented. Noticed by: dillon o Replaced leaking writenet() with output_datalen(): : * writenet : * : * Just a handy little function to write a bit of raw data to the net. : * It will force a transmit of the buffer if necessary : * : * arguments : * ptr - A pointer to a character string to write : * len - How many bytes to write : */ : void : writenet(ptr, len) : register unsigned char *ptr; : register int len; : { : /* flush buffer if no room for new data) */ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ : if ((&netobuf[BUFSIZ] - nfrontp) < len) { : /* if this fails, don't worry, buffer is a little big */ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ : netflush(); : } : : memmove(nfrontp, ptr, len); : nfrontp += len; : : } /* end of writenet */ What an irony! :-) o Optimized output_datalen() a bit.
* vsnprintf() can return a value larger than the buffer size.ru2001-07-191-1/+1
| | | | | Submitted by: assar Obtained from: OpenBSD
* Fixed the exploitable remote buffer overflow.ru2001-07-191-13/+48
| | | | | | Reported on: bugtraq Obtained from: Heimdal, NetBSD Reviewed by: obrien, imp
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* MFC: no \n in syslog strings. Change -P to -p in flags. EOF -> -1. Use err(3).charnier1997-12-081-1/+5
|
* Bring the FreeBSD changes to the virgin sources.markm1997-09-071-1/+4
|
* Initial import of BSD telnet. This will be used to build the kerberisedmarkm1997-09-041-0/+1612
telnet, and after userland diffs have been merged in, will be used to build the non-kerberised sources as well. (See unifdef(1) for details)
OpenPOWER on IntegriCloud