openbsd
9 years agoRewrite the mbtowc(3) page for clarity. Explain what needs to be done on error.
stsp [Wed, 28 Oct 2015 08:45:49 +0000 (08:45 +0000)]
Rewrite the mbtowc(3) page for clarity. Explain what needs to be done on error.
With input from jmc, zhuk, schwarze, and bentley.
ok jmc zhuk bentley

9 years agoremove old check on username length that simply makes no sense nowadays
gilles [Wed, 28 Oct 2015 07:43:44 +0000 (07:43 +0000)]
remove old check on username length that simply makes no sense nowadays

ok millert@ sunil@

9 years agodns_lookup_host() needs to remove brackets and IPv6: prefix when receiving
gilles [Wed, 28 Oct 2015 07:28:13 +0000 (07:28 +0000)]
dns_lookup_host() needs to remove brackets and IPv6: prefix when receiving
a text representation otherwise getaddrinfo_async() will choke

ok eric@

9 years agoaliases support resolving to maildir:/path
gilles [Wed, 28 Oct 2015 07:25:30 +0000 (07:25 +0000)]
aliases support resolving to maildir:/path

ok sunil@ millert@

9 years agoRemove dead code.
sunil [Wed, 28 Oct 2015 07:24:28 +0000 (07:24 +0000)]
Remove dead code.

Ok jung@ gilles@

9 years agomissing splx in error path
jsg [Wed, 28 Oct 2015 05:11:55 +0000 (05:11 +0000)]
missing splx in error path
same change made in the sparc equivalent a while ago

9 years agosupport kern.cptime also
deraadt [Wed, 28 Oct 2015 02:12:54 +0000 (02:12 +0000)]
support kern.cptime also

9 years agoadd a rcpt-to parameter to be able to use the original (probably expanded)
jung [Tue, 27 Oct 2015 21:20:11 +0000 (21:20 +0000)]
add a rcpt-to parameter to be able to use the original (probably expanded)
RCPT TO within LMTP sessions

ok gilles eric

9 years agodelivery lmtp gets fed with a message file as input which is guaranted to have
jung [Tue, 27 Oct 2015 21:11:27 +0000 (21:11 +0000)]
delivery lmtp gets fed with a message file as input which is guaranted to have
\n-terminated lines, so no need to strip \r here

also remove an unneeded len assignment while here

discussed with and ok gilles

9 years agoenqueue pledge: getmailname() needs dns, ~/dead.letter needs cpath/wpath
gilles [Tue, 27 Oct 2015 21:01:09 +0000 (21:01 +0000)]
enqueue pledge: getmailname() needs dns, ~/dead.letter needs cpath/wpath

ok jung@, ok millert@

9 years agoaliases_virtual_check() has been unneeded for a while
gilles [Tue, 27 Oct 2015 20:14:19 +0000 (20:14 +0000)]
aliases_virtual_check() has been unneeded for a while

ok jung@, ok sunil@, ok millert@

9 years agocalloc -> malloc when the memory is immediately overwritten with memcpy.
mmcc [Tue, 27 Oct 2015 18:19:33 +0000 (18:19 +0000)]
calloc -> malloc when the memory is immediately overwritten with memcpy.

ok claudio@

9 years agoadd regress test on bind(2)ing with broadcast and inexistant addresses
vgross [Tue, 27 Oct 2015 16:05:54 +0000 (16:05 +0000)]
add regress test on bind(2)ing with broadcast and inexistant addresses

9 years agoMove struct options into options.c.
nicm [Tue, 27 Oct 2015 15:58:42 +0000 (15:58 +0000)]
Move struct options into options.c.

9 years agoUse AF_UNIX instead of AF_LOCAL.
millert [Tue, 27 Oct 2015 15:23:28 +0000 (15:23 +0000)]
Use AF_UNIX instead of AF_LOCAL.

9 years agoRIP arp_ifinit().
mpi [Tue, 27 Oct 2015 15:22:58 +0000 (15:22 +0000)]
RIP arp_ifinit().

9 years agoarp_ifinit() is no longer needed.
mpi [Tue, 27 Oct 2015 15:20:13 +0000 (15:20 +0000)]
arp_ifinit() is no longer needed.

9 years agoarp_ifinit() is no longer needed.
mpi [Tue, 27 Oct 2015 15:07:56 +0000 (15:07 +0000)]
arp_ifinit() is no longer needed.

9 years agoNo more TMPDIR.
nicm [Tue, 27 Oct 2015 14:51:35 +0000 (14:51 +0000)]
No more TMPDIR.

9 years agoFix manpage for empty pidfile. Pointed out by millert@
sthen [Tue, 27 Oct 2015 14:47:17 +0000 (14:47 +0000)]
Fix manpage for empty pidfile. Pointed out by millert@

9 years agoDon't use a pidfile in unbound by default. Retain the ability in unbound.conf
sthen [Tue, 27 Oct 2015 14:45:52 +0000 (14:45 +0000)]
Don't use a pidfile in unbound by default. Retain the ability in unbound.conf
to set one if needed.  ok millert@

9 years agofix fallout from chacha changes.
dlg [Tue, 27 Oct 2015 13:58:45 +0000 (13:58 +0000)]
fix fallout from chacha changes.

9 years agoBreak the common process set up, event loop and imsg dispatch code
nicm [Tue, 27 Oct 2015 13:23:24 +0000 (13:23 +0000)]
Break the common process set up, event loop and imsg dispatch code
between server and client out into a separate internal API. This will
make it easier to add another process.

9 years agoRemove wrong line.
renato [Tue, 27 Oct 2015 13:14:44 +0000 (13:14 +0000)]
Remove wrong line.

9 years agoCheck that RTM_GET works without RTAX_GATEWAY argument for multipath
mpi [Tue, 27 Oct 2015 12:48:14 +0000 (12:48 +0000)]
Check that RTM_GET works without RTAX_GATEWAY argument for multipath
route entries.

9 years agochange cipher-server-preference to be on by default. It can be disabled with
benno [Tue, 27 Oct 2015 12:27:54 +0000 (12:27 +0000)]
change cipher-server-preference to be on by default. It can be disabled with
 no cipher-server-preference
this makes more clients select ciphers with pfs.
requested and ok by reyk@

9 years agoRewrite in_ouraddr() to not use ``rt_ifa'' since it is not obvious that
mpi [Tue, 27 Oct 2015 12:06:37 +0000 (12:06 +0000)]
Rewrite in_ouraddr() to not use ``rt_ifa'' since it is not obvious that
the lifetime of an ``ifa'' is tied to a route entry, so it might no
longer be valid after calling rtfree(9).

While here put a KERNEL_LOCK() around the per-ifp address list iteration.

ok bluhm@

9 years agoUse verbose defines instead of hardcoded values for clarity when
mikeb [Tue, 27 Oct 2015 12:00:25 +0000 (12:00 +0000)]
Use verbose defines instead of hardcoded values for clarity when
initializing hash objects.  No binary or functional change.

9 years agoConsistency in error messages.
jca [Tue, 27 Oct 2015 11:47:17 +0000 (11:47 +0000)]
Consistency in error messages.

No functional change.

9 years agoSync chacha_ivsetup to the version in ssh so that we could
mikeb [Tue, 27 Oct 2015 11:13:06 +0000 (11:13 +0000)]
Sync chacha_ivsetup to the version in ssh so that we could
specify custom counter value when setting up Chacha context.

ok reyk djm

9 years agoMove code around for clarity, no functional change.
mpi [Tue, 27 Oct 2015 10:54:52 +0000 (10:54 +0000)]
Move code around for clarity, no functional change.

ok bluhm@

9 years agoUse rt_ifidx rather than rt_ifp.
mpi [Tue, 27 Oct 2015 10:52:17 +0000 (10:52 +0000)]
Use rt_ifidx rather than rt_ifp.

ok bluhm@

9 years agoCount brackets in #{?...} so that nested conditional formats work, from
nicm [Tue, 27 Oct 2015 09:28:31 +0000 (09:28 +0000)]
Count brackets in #{?...} so that nested conditional formats work, from
Daniel De Graaf.

9 years agoThe format callback may not always succeed, so we need to check for
nicm [Tue, 27 Oct 2015 09:18:06 +0000 (09:18 +0000)]
The format callback may not always succeed, so we need to check for
NULL. From Patrick Palka.

9 years agoUse copy-mode -et= in WheelUpPane binding, from Patrick Palka.
nicm [Tue, 27 Oct 2015 09:15:21 +0000 (09:15 +0000)]
Use copy-mode -et= in WheelUpPane binding, from Patrick Palka.

9 years agofix execv arguments in a way less likely to cause grief for -portable;
djm [Tue, 27 Oct 2015 08:54:52 +0000 (08:54 +0000)]
fix execv arguments in a way less likely to cause grief for -portable;
ok dtucker@

9 years agoFix nsd and unbound's error checking with SSL_CTX_set_options().
doug [Tue, 27 Oct 2015 07:58:00 +0000 (07:58 +0000)]
Fix nsd and unbound's error checking with SSL_CTX_set_options().

LibreSSL, BoringSSL and OpenSSL have all been redefining SSL_OP_* flags to
be 0 when support is removed.  This breaks the error checking that nsd and
unbound were doing.  It should check against the flag value itself to allow
for 0.

input deraadt@, jsing@
tweak + ok miod@, guenther@

9 years agotweak previous;
jmc [Tue, 27 Oct 2015 07:33:42 +0000 (07:33 +0000)]
tweak previous;

9 years agotweak previous;
jmc [Tue, 27 Oct 2015 07:26:43 +0000 (07:26 +0000)]
tweak previous;

9 years agoWrap the remaining math functions in libc: __fpclassify*(), __flt_rounds(),
guenther [Tue, 27 Oct 2015 05:54:49 +0000 (05:54 +0000)]
Wrap the remaining math functions in libc: __fpclassify*(), __flt_rounds(),
and ldexp().

ok millert@

9 years agoFree the received radius packet when it is duplicated.
yasuoka [Tue, 27 Oct 2015 04:48:06 +0000 (04:48 +0000)]
Free the received radius packet when it is duplicated.

diff from Yuuichi Someya

9 years agoThe fd of the passwd database is marked close-on-exec now
guenther [Tue, 27 Oct 2015 04:41:18 +0000 (04:41 +0000)]
The fd of the passwd database is marked close-on-exec now

Incorrect text pointed out by tedu@
ok deraadt@ millert@ tedu@

9 years agoInitialize module_radius_req before use it.
yasuoka [Tue, 27 Oct 2015 04:30:44 +0000 (04:30 +0000)]
Initialize module_radius_req before use it.

diff from Yuuichi Someya

9 years agoSet O_NONBLOCK for UDP sockets not to block on recv(). Actually
yasuoka [Tue, 27 Oct 2015 04:27:01 +0000 (04:27 +0000)]
Set O_NONBLOCK for UDP sockets not to block on recv().  Actually
block had happened if an error of the socket is handled by send().

diff from Yuuichi Someya.

9 years agoFix radiusd module to set O_NONBLOCK properly.
yasuoka [Tue, 27 Oct 2015 04:18:36 +0000 (04:18 +0000)]
Fix radiusd module to set O_NONBLOCK properly.

diff from Yuuichi Someya.

9 years agoAdd a man page for eigrpd.conf.
renato [Tue, 27 Oct 2015 03:33:56 +0000 (03:33 +0000)]
Add a man page for eigrpd.conf.

9 years agoMinor tweaks.
renato [Tue, 27 Oct 2015 03:30:23 +0000 (03:30 +0000)]
Minor tweaks.

9 years agoWhenever a summary route is activated, install a respective blackhole
renato [Tue, 27 Oct 2015 03:27:35 +0000 (03:27 +0000)]
Whenever a summary route is activated, install a respective blackhole
route in the FIB.

9 years agoIntroduce a new flag to identify "self" neighbors attached to local interfaces.
renato [Tue, 27 Oct 2015 03:25:55 +0000 (03:25 +0000)]
Introduce a new flag to identify "self" neighbors attached to local interfaces.

9 years agoPrint a missing "metric" before the actual metric when printing a
renato [Tue, 27 Oct 2015 03:23:30 +0000 (03:23 +0000)]
Print a missing "metric" before the actual metric when printing a
redistribute line.

9 years agolog certificate serial in verbose() messages to match the main
djm [Tue, 27 Oct 2015 01:44:45 +0000 (01:44 +0000)]
log certificate serial in verbose() messages to match the main
auth success/fail message; ok dtucker@

9 years agoavoid de-const warning & shrink; ok dtucker@
djm [Tue, 27 Oct 2015 00:49:53 +0000 (00:49 +0000)]
avoid de-const warning & shrink; ok dtucker@

9 years agoIf a mouse event has no key binding, pass it through to the pane it
nicm [Mon, 26 Oct 2015 23:16:18 +0000 (23:16 +0000)]
If a mouse event has no key binding, pass it through to the pane it
happened in, not the active pane like normal key presses. Fixes problems
seen by Enrico Ghirardi.

9 years agoDefault bindings for mouse wheel on status line to change window (like
nicm [Mon, 26 Oct 2015 23:06:18 +0000 (23:06 +0000)]
Default bindings for mouse wheel on status line to change window (like
we had before), from Patrick Palka.

9 years agoTidy up error() levels: merge COMPILE and COMPILE2, and kill ERROR (unused)
jca [Mon, 26 Oct 2015 22:24:44 +0000 (22:24 +0000)]
Tidy up error() levels: merge COMPILE and COMPILE2, and kill ERROR (unused)

ok tobias@

9 years agoUse error(FATAL) instead of what was previously err(1,...)
jca [Mon, 26 Oct 2015 22:22:56 +0000 (22:22 +0000)]
Use error(FATAL) instead of what was previously err(1,...)

ok tobias@

9 years agomiscellaneous cruft:
naddy [Mon, 26 Oct 2015 22:03:06 +0000 (22:03 +0000)]
miscellaneous cruft:
* remove lint
* unifdef S_IFLNK, S_ISFIFO, S_ISLNK, S_ISSOCK, O_APPEND
* remove 0, NOTUSED, notdef -- untouched since original import
* remove IIASA

9 years agoHandle unknown keys more gracefully, return a string instead of NULL.
nicm [Mon, 26 Oct 2015 22:03:04 +0000 (22:03 +0000)]
Handle unknown keys more gracefully, return a string instead of NULL.

9 years agoremove the profiling and debugging ifdefs; ok zhuk@
naddy [Mon, 26 Oct 2015 21:57:42 +0000 (21:57 +0000)]
remove the profiling and debugging ifdefs; ok zhuk@

9 years agodocument the -p and -l file enquiries and explicitly do not document -s
naddy [Mon, 26 Oct 2015 20:44:00 +0000 (20:44 +0000)]
document the -p and -l file enquiries and explicitly do not document -s
with/ok schwarze@

9 years agoThe hostname variable is not used since r1.99. Remove it and use
rpe [Mon, 26 Oct 2015 19:24:04 +0000 (19:24 +0000)]
The hostname variable is not used since r1.99. Remove it and use
stripcom() output directly with the hostname command.

OK deraadt@ krw@

9 years agoupdate regress suite for pledge
semarie [Mon, 26 Oct 2015 18:52:19 +0000 (18:52 +0000)]
update regress suite for pledge

9 years agoadd tests for whitespace surrounding properties
jasper [Mon, 26 Oct 2015 18:09:32 +0000 (18:09 +0000)]
add tests for whitespace surrounding properties

9 years agoDon't reject properties with no whitespace after the colon; it's perfectly
jasper [Mon, 26 Oct 2015 18:08:44 +0000 (18:08 +0000)]
Don't reject properties with no whitespace after the colon; it's perfectly
valid to have a line like 'Requires:requiree'.

Confirmed with fd.o and this fixes using the libczmq pc file

9 years agotweak previous;
jmc [Mon, 26 Oct 2015 18:05:25 +0000 (18:05 +0000)]
tweak previous;

9 years agono more TMPDIR;
jmc [Mon, 26 Oct 2015 17:56:20 +0000 (17:56 +0000)]
no more TMPDIR;

9 years agoPut repquota in line with other utilities: you either wants list everyting,
zhuk [Mon, 26 Oct 2015 17:55:32 +0000 (17:55 +0000)]
Put repquota in line with other utilities: you either wants list everyting,
effectively using -a, or you specify filesystems one-by-one. Doing both
resulted in a funny error messages, so just don't allow that silly behaviour.

okay millert@

9 years agoAdd ppoll() to "stdio"
deraadt [Mon, 26 Oct 2015 17:52:19 +0000 (17:52 +0000)]
Add ppoll() to "stdio"

9 years agoUse axf's hashsize as a block size in the authenticated encryption routine.
mikeb [Mon, 26 Oct 2015 17:22:50 +0000 (17:22 +0000)]
Use axf's hashsize as a block size in the authenticated encryption routine.
No change for GCM, however upcoming changes will rely on this.

9 years agoSome extra logging of where keys are actually going.
nicm [Mon, 26 Oct 2015 17:17:06 +0000 (17:17 +0000)]
Some extra logging of where keys are actually going.

9 years agoRather than setpassent(1) for the lifetime of the program, use two smaller
deraadt [Mon, 26 Oct 2015 16:57:13 +0000 (16:57 +0000)]
Rather than setpassent(1) for the lifetime of the program, use two smaller
windows of setpassent(1) + entpwent()
ok tedu millert

9 years agoFix makemap(8) for values containing a '#'.
sunil [Mon, 26 Oct 2015 16:38:06 +0000 (16:38 +0000)]
Fix makemap(8) for values containing a '#'.

Ok millert@ gilles@

9 years agoGive dhclient(8) the ability to use option 119, a.k.a. "Domain
krw [Mon, 26 Oct 2015 16:32:33 +0000 (16:32 +0000)]
Give dhclient(8) the ability to use option 119, a.k.a. "Domain
Search" if supplied by the server.

Requested by a few. Original diff from Ray Lai via tech@.

Tested & ok claudio@

9 years agoRemove the #define Strfoo() s_strfoo() redirection and move everything
naddy [Mon, 26 Oct 2015 16:31:09 +0000 (16:31 +0000)]
Remove the #define Strfoo() s_strfoo() redirection and move everything
directly to Strfoo().  Purely mechanical.  ok deraadt@

9 years agoClean up cruft made visible by the NLS unifdefing:
naddy [Mon, 26 Oct 2015 16:27:04 +0000 (16:27 +0000)]
Clean up cruft made visible by the NLS unifdefing:
* remove setlocale() calls
* remove write-only variable AsciiOnly
* remove now unused string constants STRLANG, STRLC_CTYPE
* remove hardcoded support for ISO8859-1

ok millert@

9 years agoRemove TMPDIR support, it is not really useful in crontab.
millert [Mon, 26 Oct 2015 15:50:06 +0000 (15:50 +0000)]
Remove TMPDIR support, it is not really useful in crontab.
OK deraadt@

9 years agoUse rt_ifidx rather than rt_ifp.
mpi [Mon, 26 Oct 2015 15:49:13 +0000 (15:49 +0000)]
Use rt_ifidx rather than rt_ifp.

ok bluhm@

9 years agoPut off some "notyet" dust from login.c.
zhuk [Mon, 26 Oct 2015 15:29:17 +0000 (15:29 +0000)]
Put off some "notyet" dust from login.c.

okay millert@ and deraadt@

9 years agoUse SOCK_NONBLOCK and SOCK_CLOEXEC instead of fcntl() calls.
millert [Mon, 26 Oct 2015 15:16:30 +0000 (15:16 +0000)]
Use SOCK_NONBLOCK and SOCK_CLOEXEC instead of fcntl() calls.
OK guenther@

9 years agoAdd GPT editing. Based on GSOC 2014 work by Markus Muller.
krw [Mon, 26 Oct 2015 15:08:26 +0000 (15:08 +0000)]
Add GPT editing. Based on GSOC 2014 work by Markus Muller.

9 years agodon't keep the passwd database open; callers do not expect that they will
tedu [Mon, 26 Oct 2015 15:04:51 +0000 (15:04 +0000)]
don't keep the passwd database open; callers do not expect that they will
become responsible for calling endpwent.
ok deraadt

9 years agounifdef BUILTIN (unused), NLS (always set), SHORT_STRINGS (always set)
naddy [Mon, 26 Oct 2015 15:01:15 +0000 (15:01 +0000)]
unifdef BUILTIN (unused), NLS (always set), SHORT_STRINGS (always set)
and remove a few unused defines; no binary changes; ok tedu@ zhuk@

9 years ago(char *)0 -> NULL
mmcc [Mon, 26 Oct 2015 14:48:54 +0000 (14:48 +0000)]
(char *)0 -> NULL

ok tedu@

9 years agoFlesh out GPT info and tweak other verbiage to be less MBR specific.
krw [Mon, 26 Oct 2015 14:37:50 +0000 (14:37 +0000)]
Flesh out GPT info and tweak other verbiage to be less MBR specific.

9 years agoRemove some useless defines and the set_cron_uid() function.
millert [Mon, 26 Oct 2015 14:27:41 +0000 (14:27 +0000)]
Remove some useless defines and the set_cron_uid() function.
OK jung@

9 years agoLet SLIST_REMOVE invalidate the pointer in more cases.
bluhm [Mon, 26 Oct 2015 14:12:13 +0000 (14:12 +0000)]
Let SLIST_REMOVE invalidate the pointer in more cases.
OK jsing@

9 years agoRename err() to error() to prevent confusion with the stdlib function.
mmcc [Mon, 26 Oct 2015 14:08:47 +0000 (14:08 +0000)]
Rename err() to error() to prevent confusion with the stdlib function.

Discussed with jca@.

9 years agoremove the silly username cache here and use libc user_from_uid.
tedu [Mon, 26 Oct 2015 13:56:18 +0000 (13:56 +0000)]
remove the silly username cache here and use libc user_from_uid.
libc isn't (yet) any better, but it can improve with time.

9 years agoremove TMPDIR support
deraadt [Mon, 26 Oct 2015 13:12:10 +0000 (13:12 +0000)]
remove TMPDIR support

9 years agosync
deraadt [Mon, 26 Oct 2015 13:11:42 +0000 (13:11 +0000)]
sync

9 years agorip6query goes to the attic. Hopefully route6d (rip6d?) will get some
deraadt [Mon, 26 Oct 2015 13:07:13 +0000 (13:07 +0000)]
rip6query goes to the attic.  Hopefully route6d (rip6d?) will get some
love instead, prod prod.
ok claudio jca mpi

9 years agoremove TMPDIR support. ok millert
tedu [Mon, 26 Oct 2015 12:52:27 +0000 (12:52 +0000)]
remove TMPDIR support. ok millert

9 years agoprint uptime too. ok deraadt
tedu [Mon, 26 Oct 2015 12:44:22 +0000 (12:44 +0000)]
print uptime too. ok deraadt

9 years agoone second amnesty for timeouts so we don't spin with short timeouts
tedu [Mon, 26 Oct 2015 12:24:48 +0000 (12:24 +0000)]
one second amnesty for timeouts so we don't spin with short timeouts

9 years agoset listening sockets to nonblocking, then handle as many incoming requests
tedu [Mon, 26 Oct 2015 12:23:40 +0000 (12:23 +0000)]
set listening sockets to nonblocking, then handle as many incoming requests
as we can in the loop instead of keventing per request.

9 years agodns check needs to be done on the kernel address after copyin
tedu [Mon, 26 Oct 2015 12:17:03 +0000 (12:17 +0000)]
dns check needs to be done on the kernel address after copyin

9 years agoAllow NET_RT_IFLIST in pledge "dns" as well
deraadt [Mon, 26 Oct 2015 12:13:45 +0000 (12:13 +0000)]
Allow NET_RT_IFLIST in pledge "dns" as well

9 years agoKernel got fixed we no longer need to check if rtm_pid is 0 to filter out
claudio [Mon, 26 Oct 2015 11:46:25 +0000 (11:46 +0000)]
Kernel got fixed we no longer need to check if rtm_pid is 0 to filter out
route messages that are not from us.

9 years agoIf the system call is entirely unpermitted, code will be 0, and there is
deraadt [Mon, 26 Oct 2015 11:17:52 +0000 (11:17 +0000)]
If the system call is entirely unpermitted, code will be 0, and there is
no pledge to recommend.

9 years agoadd setreuid/setregid to "id"
deraadt [Mon, 26 Oct 2015 11:11:45 +0000 (11:11 +0000)]
add setreuid/setregid to "id"