summaryrefslogtreecommitdiff
path: root/usr.bin/mail
AgeCommit message (Collapse)Author
2021-03-08Add some references, most of these were removed when we stopped buildingJonathan Gray
and installing USD/SMM/PSD docs. jmc@ agrees with the direction, ok millert@ on an earlier diff
2021-01-26satisfy -fno-common, by (1) copying all the variable decls fromTheo de Raadt
indent_globs.h to indent.c, and (2) changing all the same decls in indent_globs.h to be extern ok mortimer
2020-12-15the name aux is a reserved filename on windowsDaniel Dickman
NetBSD renamed this file to support.c in 2001, while FreeBSD chose to rename this file to util.c in 2009. We go the FreeBSD route and pick util.c since our implementation is closer to the FreeBSD codebase. Helps get us closer to being able to check out OpenBSD source code on Windows as requested by John Carmack. This issue thoroughly researched by jsg@ ok deraadt@, sthen@, "go ahead" jsg@
2019-09-06More Version 1 AT&T UNIX history.Ingo Schwarze
This became possible because copies of the original v1 manuals have shown up on the Internet some time ago. Reminded by Sevan Janiyan <venture37 at geeklan dot co dot uk>.
2019-06-28When system calls indicate an error they return -1, not some arbitraryTheo de Raadt
value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
2019-03-19When running sendmail, set argv[0] to "sendmail" not "send-mail".Todd C. Miller
This was a historical oddity that dates back to back to the days of delivermail.
2018-09-16Replace the local getname() and getuserid() functions with callsTodd C. Miller
to user_from_uid(3) and uid_from_user(3). This requires sprinkling const in a few places to match the return value of user_from_uid(3). OK tb@
2018-04-26Use <fcntl.h> instead of <sys/file.h> for open() and friends.Philip Guenther
Delete a bunch of unnecessary #includes and sort to match style(9) while doing the above cleanup. ok deraadt@ krw@
2018-03-16improve markup quality in the cases found by the new "--" style messageIngo Schwarze
2017-06-28Replace usage of TIOCSTI in mail while editing headers using a more commonanton
IO-loop where ICANON is disabled and a single char of input is read at a time. This requires the line editing capabilities provided when ICANON is enabled to be implemented. ok deraadt@
2017-05-29tweak previous to read a little better;Jason McIntyre
2017-05-29remove mention of Berknet and mailaddr.7Ted Unangst
2017-03-28Prevent edit'ing a message from corrupting the mailbox. In an mbox fileMartin Natano
every message is terminated by an empty line, so we have to make sure it is preserved. Otherwise the message is combined with the next one. joint effort with deraadt and millert
2016-07-28these programs probably do not need to use TMPDIR. ok florianTed Unangst
2016-07-19Cleanup close(open idioms.Theo de Raadt
ok krw
2016-03-30for some time now mandoc has not required MLINKS to functionJason McIntyre
correctly - logically complete that now by removing MLINKS from base; authors need only to ensure there is an entry in NAME for any function/ util being added. MLINKS will still work, and remain for perl to ease upgrades; ok nicm (curses) bcook (ssl) ok schwarze, who provided a lot of feedback and assistance ok tb natano jung
2015-11-24missing pledge "getpw"Theo de Raadt
2015-11-16pledge "stdio rpath wpath cpath tmppath fattr tty flock proc exec"Theo de Raadt
2015-11-11creat() -> open equiv; from Frederic NowakTheo de Raadt
2015-10-16Cast isspace() argument to unsigned char.mmcc
ok jca@
2015-10-16Modernize allocation by:mmcc
* removing unneeded casts of void* return values * replacing varied and creative error messages with the allocation function's name * replacing errx() with err() so that the errno string is reported ok beck@, jung@, millert@
2015-10-13To alter just the atime of the mailspool, use utimensat()+UTIME_OMIT insteadPhilip Guenther
of stat()+utimes(). Prefer clock_gettime() over gettimeofday() to avoid timeval->timespec conversion ok millert@
2015-09-07add missing file system path (.Pa) macros.Igor Sobrado
2015-02-08in getopt() blocks, stop incrementing flag variable which are supposedTheo de Raadt
to just be 0/1 ok miod florian
2015-01-24Fix getopt string; the -N flag doesn't take an argument.Todd C. Miller
From Matthew Clarke
2015-01-22Only allow the -r flag when sending a message; from Martin BrandenburgTodd C. Miller
2015-01-20tweak previous;Jason McIntyre
2015-01-20Add support for the "-r fromaddr" flag now that we don't supportTodd C. Miller
sendmail flags on the command line. Also allow "from" to be set in mailrc. Use sendmail's "-t" flag when executing sendmail instead of specifying the list of recipients in argv. The "-f" flag will be used to set the from address if specified.
2015-01-16Replace <sys/param.h> with <limits.h> and other less dirty headers whereTheo de Raadt
possible. Annotate <sys/param.h> lines with their current reasons. Switch to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc. Change MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where sensible to avoid pulling in the pollution. These are the files confirmed through binary verification. ok guenther, millert, doug (helped with the verification protocol)
2015-01-07It is the copy command that is abbreviated as 'c', not chdir.Todd C. Miller
Also document that cd is an alias for chdir. From Kaspars Bankovskis.
2015-01-07Document the '=' command; from trondd at gmailTodd C. Miller
2014-12-16Don't pass options after the to address to sendmail. The onlyTodd C. Miller
legitiate use of this is to set the sender name which should be handled specifically by a different option.
2014-12-16Add new "expandaddr" flag (disabled by default) to enable recipientTodd C. Miller
address expansion and document it. Previously, this behavior was always enabled. Also document how address expansion is performed, which used to only be described in the (no longer installed) Mail Reference Manual. CVE-2014-7844
2014-12-16Use glob() to expand filenames instead of passing it to the shell'sTodd C. Miller
echo command for expansion which could result in arbitrary command execution. CVE-2004-2771
2014-11-24Change "will write" back to "writes" in -f description. From jmc@Todd C. Miller
2014-11-24The handling of the -f option is a hack. Instead of fooling aroundTodd C. Miller
with argv behind getopt()'s back we can just treat the remainder of argv[] after option processing as the file name for -f. It is not possible to use -f in sending mode so there is no ambiguity. OK tobias@
2014-11-24Remove undocumented and obsolete -T option. It was intended forTodd C. Miller
use with old netnews. OK sobrado@ tobias@
2014-10-26Prefer mkostemp(O_CLOEXEC) over mkstemp()+fcntl(F_SETFD)Philip Guenther
Prefer fopen("re") over fopen("r")+fcntl(F_SETFD) ok otto@ millert@
2014-08-15Use O_CLOEXEC wherever we open a file and then call fcntl(F_SETFD, FD_CLOEXEC)Philip Guenther
on it, simplifying error checking, reducing system calls, and improving thread-safety for libraries. ok miod@
2014-07-22Repair two deep targets mistakenly called as afterinstall, ratherTheo de Raadt
than distribution. These would modify files in /etc, part of the base set, but still... that makes it harder to discern their sets placement.
2014-05-20Use errc/warnc to simplify code.Philip Guenther
Also, in 'ftp', always put the error message last, after the hostname/ipaddr. ok jsing@ krw@ millert@
2014-03-27make this page less sendmail-centric; ok gillesJason McIntyre
2014-03-16lint is dead (long live the lint!), so stop using it as a cpp conditionalPhilip Guenther
(namespace pollution!) or talking about its opinion on code. ok krw@
2014-03-10pedantic word change;Jason McIntyre
2014-01-20Obvious .Xr fixes, found while testing mandocdb(8).Ingo Schwarze
2014-01-17ctype and other sign extension fixes.Okan Demirmen
with deraadt and millert, ok millert
2014-01-08flesh out STANDARDS somewhat; help/ok sobradoJason McIntyre
this was also ok millert some time ago
2013-07-18document the :c selectors; from Sunil NimmagaddaJason McIntyre
2013-04-29use FD_CLOEXEC instead of 1; from David HillOkan Demirmen
ok otto
2012-11-14use F_OK macro instead of 0 in access() when checking by file existence. ↵Gleydson Soares
make the code easier to read. no functional change. OK millert@