summaryrefslogtreecommitdiffstats
path: root/contrib/telnet
Commit message (Collapse)AuthorAgeFilesLines
* MFC r274364:ngie2014-12-0510-134/+199
| | | | | | | | | | | | | | Add baud rate support to telnet(1) This implements part of RFC-2217 It's based off a patch originally written by Sujal Patel at Isilon, and contributions from other Isilon employees. PR: 173728 Phabric: D995 Reviewed by: markj, markm Sponsored by: EMC / Isilon Storage Division
* Fix "automatic" login, broken by revision 69825 (12 years, 5 months ago).marcel2013-05-311-14/+10
| | | | | | | | | | | | | | | | | | | | | | | | | The "automatic" login feature is described as follows: The USER environment variable holds the name of the person telnetting in. This is the username of the person on the client machine. The traditional behaviour is to execute login(1) with this username first, meaning that login(1) will prompt for the password only. If login fails, login(1) will retry, but now prompt for the username before prompting for the password. This feature got broken by how the environment got scrubbed. Before the change in r69825 we removed variables that we deemed dangerous. Starting with r69825 we only keep those variable we know to be safe. The USER environment variable fell through the cracks. It suddenly got scrubbed (i.e. removed from the environment) while still being checked for. It also got explicitly removed from the environment to handle the failed login case. The fix is to obtain the value of the USER environment variable before we scrub the environment and used the "cached" in subsequent checks. This guarantees that the environment does not contain the USER variable in the end, while still being able to implement "automatic" login. Obtained from: Juniper Networks, Inc.
* Make sure that each va_start has one and only one matching va_end,kevlo2012-09-281-1/+3
| | | | especially in error cases.
* Remove superfluous paragraph macro.joel2012-06-171-2/+0
|
* - Do not use deprecated krb5 error message reporting functions in libtelnet.stas2012-04-061-53/+55
|
* Fix a problem whereby a corrupt DNS record can cause named to crash. [11:06]cperciva2011-12-231-0/+3
| | | | | | | | | | | | | | | | | | | | Add an API for alerting internal libc routines to the presence of "unsafe" paths post-chroot, and use it in ftpd. [11:07] Fix a buffer overflow in telnetd. [11:08] Make pam_ssh ignore unpassphrased keys unless the "nullok" option is specified. [11:09] Add sanity checking of service names in pam_start. [11:10] Approved by: so (cperciva) Approved by: re (bz) Security: FreeBSD-SA-11:06.bind Security: FreeBSD-SA-11:07.chroot Security: FreeBSD-SA-11:08.telnetd Security: FreeBSD-SA-11:09.pam_ssh Security: FreeBSD-SA-11:10.pam
* In contrib/telnet/telnet/utilities.c, fix a few warnings about formatdim2011-12-171-4/+4
| | | | | | strings not being literals. MFC after: 1 week
* In contrib/telnet/telnetd/utility.c, fix a few warnings about formatdim2011-12-161-4/+4
| | | | | | strings not being literals. MFC after: 1 week
* In contrib/telnet/libtelnet/sra.c, use the correct number of bytes todim2011-12-161-1/+1
| | | | | | zero the password buffer. MFC after: 1 week
* telnet: Fix infinite loop if local output generates SIGPIPE.jilles2010-04-306-16/+17
| | | | | | | | | | | | | | | | | Instead of catching SIGPIPE and jumping out of the signal handler with longjmp, ignore it and handle write errors to the local output by exiting from there. I have changed the error message to mention the local output instead of NetBSD's wrong "Connection closed by foreign host". Write errors to the network were already handled by exiting immediately and this now applies to EPIPE too. The code assumed that SIGPIPE could only be generated by the network connection; if it was generated by the local output, it would longjmp out of the signal handler and write an error message which caused another SIGPIPE. PR: 19773 Obtained from: NetBSD MFC after: 1 week
* Forgot a part that was missing in the previous commit.ed2010-01-131-1/+0
| | | | | There is no need to call trimdomain() anymore now that ut_host is big enough to fit decent hostnames.
* Let telnetd build without utmp and logwtmp(3).ed2010-01-132-19/+1
| | | | | | | Just like rlogind, there is no need to change the ownership of the terminal during shutdown anymore. Also don't call logwtmp, because the login(1)/PAM is responsible for doing this. Also use SHUT_RDWR instead of 2.
* Remove unneeded inclusion of <utmp.h> and dead variables.ed2009-12-271-14/+0
|
* Use <termios.h> instead of <sys/termios.h>.ed2009-11-281-1/+1
| | | | <sys/termios.h> only works on FreeBSD by accident.
* Rename all symbols in libmp(3) to mp_*, just like Solaris.ed2009-02-261-43/+43
| | | | | | | | | | | | The function pow() in libmp(3) clashes with pow(3) in libm. We could rename this single function, but we can just take the same approach as the Solaris folks did, which is to prefix all function names with mp_. libmp(3) isn't really popular nowadays. I suspect not a single application in ports depends on it. There's still a chance, so I've increased the SHLIB_MAJOR and __FreeBSD_version. Reviewed by: deischen, rdivacky
* Correctly scrub telnetd's environment.cperciva2009-02-161-4/+19
| | | | | Approved by: so (cperciva) Security: FreeBSD-SA-09:05.telnetd
* Use strlcpy() instead of strcpy().ed2008-11-131-1/+2
| | | | Requested by: mlaier
* Convert telnetd(8) to use posix_openpt(2).ed2008-11-132-36/+21
| | | | | | | | | | | | | | | | | | Some time ago I got some reports MPSAFE TTY broke telnetd(8). Even though it turned out to be a different problem within the TTY code, I spotted a small issue with telnetd(8). Instead of allocating PTY's using openpty(3) or posix_openpt(2), it used its own PTY allocation routine. This means that telnetd(8) still uses /dev/ptyXX-style devices. I've also increased the size of line[]. Even though 16 should be enough, we already use 13 bytes ("/dev/pts/999", including '\0'). 32 bytes gives us a little more freedom. Also enable -DSTREAMSPTY. Otherwise telnetd(8) strips the PTY's pathname to the latest slash instead of just removing "/dev/" (e.g. /dev/pts/0 -> 0, instead of pts/0). Reviewed by: rink
* Fix TELOPT(opt) when opt > TELOPT_TN3270E.antoine2008-09-131-2/+2
| | | | | | PR: 127194 Submitted by: Joost Bekkers MFC after: 1 month
* List authentication types supported with "-X" taken from the libtelnettrhodes2008-08-291-1/+10
| | | | | | code. PR: 121721
* Don't attempt authentication at all if it has been disabled via '-a off'.jhb2008-07-282-7/+11
| | | | | | | | | 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
* Commit IPv6 support for FAST_IPSEC to the tree.gnn2007-07-011-1/+1
| | | | | | | | This commit includes all remaining changes for the time being including user space updates. Submitted by: bz Approved by: re
* Markup nits.ru2006-09-291-2/+2
|
* Remove bogus casts of valid integer ioctl() arguments.ru2006-09-261-4/+4
|
* o Mention .telnetrc DEFAULT keyword.maxim2006-09-181-1/+8
| | | | | | PR: bin/100496 (sort of) Obtained from: NetBSD, heas@netbsd MFC after: 3 weeks
* NI_WITHSCOPEID cleanupume2005-05-211-1/+1
|
* Correct a pair of buffer overflows in the telnet(1) command:nectar2005-03-281-6/+24
| | | | | | | | | | | | | | | | | | | | (CAN-2005-0468) A heap buffer overflow in env_opt_add() and related functions. (CAN-2005-0469) A global uninitialized data section buffer overflow in slc_add_reply() and related functions. As a result of these vulnerabilities, it may be possible for a malicious telnet server or active network attacker to cause telnet(1) to execute arbitrary code with the privileges of the user running it. Security: CAN-2005-0468, CAN-2005-0469 Security: FreeBSD-SA-05:01.telnet Security: http://www.idefense.com/application/poi/display?id=220&type=vulnerabilities Security: http://www.idefense.com/application/poi/display?id=221&type=vulnerabilities These fixes are based in part on patches Submitted by: Solar Designer <solar@openwall.com>
* Increase usefulness of telnet(1) as a protocol tester. By prependingtobez2005-02-283-4/+23
| | | | | | | | | | "+" to the port number, disable option negotiation and allow transferring of data with high bit set. OKed by: markm (maintainer) PR: 52032 Submitted by: Valentin Nechayev <netch maybe-at netch stop kiev stop ua> MFC After: 2 weeks
* - Soften sentence breaks.ru2005-01-212-71/+112
| | | | | - Remove double whitespace. - Sort sections.
* o Make telnet[d] -S (IP TOS) flag really work. We do not havemaxim2005-01-093-10/+32
| | | | | | | | | /etc/iptos implementation so only numeric values supported. o telnetd.8: steal the -S flag description from telnet.1, bump the date of the document. MFC after: 6 weeks
* o Add -4 and -6 flags to a man page and usage(). Bump the man pagemaxim2005-01-052-3/+12
| | | | date.
* o Remove -t flag from getopt(3), it was killed in rev. 1.15 threemaxim2005-01-051-1/+1
| | | | years ago.
* o Print a correct status for unix domain sockets.maxim2005-01-041-0/+2
| | | | | | | | | o Restore input mode when return from the command one. PR: bin/49983 Submitted by: Volker Stolz OK in general from: markm MFC after: 1 month
* Add missing () to function invocation.kan2004-07-281-1/+1
|
* Switch Advanced Sockets API for IPv6 from RFC2292 to RFC3542ume2003-10-241-16/+9
| | | | | | | | | | (aka RFC2292bis). Though I believe this commit doesn't break backward compatibility againt existing binaries, it breaks backward compatibility of API. Now, the applications which use Advanced Sockets API such as telnet, ping6, mld6query and traceroute6 use RFC3542 API. Obtained from: KAME
* EAI_ADDRFAMILY and EAI_NODATA was deprecated in RFC3493ume2003-10-231-2/+2
| | | | | | | | (aka RFC2553bis). Now, getaddrinfo(3) returns EAI_NONAME instead of EAI_NODATA. Our getaddrinfo(3) nor getnameinfo(3) didn't use EAI_ADDRFAMILY. Obtained from: KAME
* Implement what has been documented for a long time: make -debug switchharti2003-08-131-0/+5
| | | | | | on socket debugging. Okay'ed by: markm
* Fix up external variables named "debug" that have a horrible habitmarkm2003-05-115-8/+8
| | | | | | | | of conflicting with other, similarly named functions in static libraries. This is done mostly by renaming the var if it is shared amongst modules, or making it static otherwise. OK'ed by: re(scottl)
* Use __FBSDID vs. rcsid[]. Also protect sccs[] and copyright[] from GCC 3.3.obrien2003-05-0419-81/+79
|
* Unbreak Kerberos 5 authentication in telnet.nectar2003-03-061-0/+24
| | | | | | (Credential forwarding is still broken.) PR: bin/45397
* Background:nectar2003-01-292-14/+2
| | | | | | | | | | | | | | | | | | | | | When libdes was replaced with OpenSSL's libcrypto, there were a few interfaces that the former implemented but the latter did not. Because some software in the base system still depended upon these interfaces, we simply included them in our libcrypto (rnd_keys.c). Now, finally get around to removing the dependencies on these interfaces. There were basically two cases: des_new_random_key -- This is just a wrapper for des_random_key, and these calls were replaced. des_init_random_number_generator et. al. -- A few functions were used by the application to seed libdes's PRNG. These are not necessary when using libcrypto, as OpenSSL internally seeds the PRNG from /dev/random. These calls were simply removed. Again, some of the Kerberos 4 files have been taken off the vendor branch. I do not expect there to be future imports of KTH Kerberos 4.
* add more RFC defined telnet optionsbillf2003-01-181-3/+8
| | | | Reviewed by: ps
* Merge argument parsing changes into this copy of telnet.eric2002-11-271-2/+6
| | | | | Submitted by: markm Approved by: bmah
* Permit the argument to the -s option to be a hostname. I see nodd2002-10-021-1/+0
| | | | | | | | reason to restrict this to a numeric address. PR: 41841 Submitted by: Dmitry Pryanishnikov <dmitry@atlantis.dp.ua>, Maxim Maximov <mcsi@agava.com>
* Catch up with "base" telnet.markm2002-09-251-3/+3
| | | | s/FALL THROUGH/FALLTHROUGH/ for lint(1).
* Catch up with "base" telnet.markm2002-09-253-12/+8
| | | | | s/FALL THROUGH/FALLTHROUGH/ for lint(1). s/Usage/usage/ for consistency.
* From the requestor:markm2002-09-251-1/+1
| | | | | | | | "Could you do me a favor and fix sys_bsd.c to get the howmany() macro from <sys/param.h>, instead of <sys/types.h>? This will save me from having to worry about the unsync'd bits before making the change." Requested by: mike
* Encrypted strings (after hex decoding) aren't null terminated, becausensayer2002-08-221-4/+0
| | | | | | | | 0 might simply be part of the ciphertext. PR: bin/40266 Submitted by: andr@dgap.mipt.ru MFC after: 3 days
* Warnings fixes. Sort out some variable types.markm2002-06-261-6/+7
|
* Help fix warnings by marking an argument as unused.markm2002-06-261-0/+1
|
OpenPOWER on IntegriCloud