eric [Fri, 28 Dec 2018 15:09:28 +0000 (15:09 +0000)]
introduce table_dump() and tweak format
ok gilles@
bluhm [Fri, 28 Dec 2018 14:32:47 +0000 (14:32 +0000)]
Fix mbuf releated crashes in switch(4). They have been found by
syzkaller as pool corruption panic. It is unclear which bug caused
what, but it should be better now.
- Check M_PKTHDR with assertion before accessing m_pkthdr.
- Do not access oh_length without m_pullup().
- After checking if there is space at the end of the mbuf, don't
overwrite the data at the beginning. Append the new content.
- Do not set m_len and m_pkthdr.len when it is unclear whether
the ofp_error header fits at all. Use m_makespace() to adjust
the mbuf.
Reported-by: syzbot+6efc0a9d5b700b54392e@syzkaller.appspotmail.com
test akoshibe@; OK claudio@
denis [Fri, 28 Dec 2018 14:28:52 +0000 (14:28 +0000)]
set conf.capabilities.mp to 0 by default
OK claudio@
eric [Fri, 28 Dec 2018 14:21:02 +0000 (14:21 +0000)]
type static tables on the fly when the first element is added
ok gilles@
eric [Fri, 28 Dec 2018 13:47:54 +0000 (13:47 +0000)]
simplify code
ok gilles@
denis [Fri, 28 Dec 2018 13:38:15 +0000 (13:38 +0000)]
report right function name in error message
eric [Fri, 28 Dec 2018 12:47:28 +0000 (12:47 +0000)]
zap unused code
denis [Fri, 28 Dec 2018 11:54:10 +0000 (11:54 +0000)]
print well-known SAFI name instead of value
OK claudio@ sthen@
eric [Fri, 28 Dec 2018 11:40:29 +0000 (11:40 +0000)]
remove the tag workaround for table_create() and table_find(),
now that static tables handle their updates internally.
ok gilles@
tb [Fri, 28 Dec 2018 11:40:23 +0000 (11:40 +0000)]
getgruid_r -> getgrgid_r
from Lauri Tirkkonen
gilles [Fri, 28 Dec 2018 11:35:25 +0000 (11:35 +0000)]
rename smtp_session's hostname field to rdns, to make it clear what it
stores and differentiate it further from smtpname and listener->hostname
ok eric@
eric [Fri, 28 Dec 2018 11:13:58 +0000 (11:13 +0000)]
remove unused members in struct table
eric [Fri, 28 Dec 2018 11:11:36 +0000 (11:11 +0000)]
fix logging of list entries
eric [Fri, 28 Dec 2018 10:42:18 +0000 (10:42 +0000)]
use private data structure for managing static table content
ok gilles@
gilles [Fri, 28 Dec 2018 07:29:49 +0000 (07:29 +0000)]
move the smtp_mailaddr() calls _before_ filters indirection as filters MUST
only receive valid MAIL FROM and RCPT TO parameters.
tedu [Thu, 27 Dec 2018 23:53:47 +0000 (23:53 +0000)]
add some notes about using col and ul to process the ascii markup
since these may not be commonly known utilities.
with schwarze
djm [Thu, 27 Dec 2018 23:02:11 +0000 (23:02 +0000)]
Request RSA-SHA2 signatures for rsa-sha2-{256|512}-cert-v01@openssh.com
cert algorithms; ok markus@
remi [Thu, 27 Dec 2018 20:23:24 +0000 (20:23 +0000)]
Check if a control socket or address is already in use befor using it.
If it is used abort startup or let a reload fail.
Sockets are now not unlinked anymore on regular shutdown.
This helps a lot when one tries to do a config check without -n.
Inputs and OK claudio@
anton [Thu, 27 Dec 2018 19:51:30 +0000 (19:51 +0000)]
When netbooting a vm using the `-B net' option, set the hostname DHCP
option in the lease to the name of the vm. Makes it easier to use
dedicated autoinstall response files for different vms.
ok ccardenas@
anton [Thu, 27 Dec 2018 19:38:01 +0000 (19:38 +0000)]
Cope with latest change to KIOENABLE. While here, make it possible to test
different trace modes.
anton [Thu, 27 Dec 2018 19:33:08 +0000 (19:33 +0000)]
Make KIOENABLE accept a mode argument, currently limited to KCOV_MODE_TRACE_PC.
Thanks to jmc@ for improving the manual bits.
ok deraadt@ mpi@
eric [Thu, 27 Dec 2018 19:13:18 +0000 (19:13 +0000)]
remove unused file
tedu [Thu, 27 Dec 2018 18:00:15 +0000 (18:00 +0000)]
fifo isn't really the right data structure for varying expirations.
convert to a simple rbtree ordered by expiration time.
ok anton
tedu [Thu, 27 Dec 2018 17:57:58 +0000 (17:57 +0000)]
must remember to unref device if setting the task isn't done.
ok anton
jmc [Thu, 27 Dec 2018 17:45:36 +0000 (17:45 +0000)]
too many words in previous;
krw [Thu, 27 Dec 2018 17:33:15 +0000 (17:33 +0000)]
Rename ufdesc to udpfd to make the code slightly more intuitive.
tedu [Thu, 27 Dec 2018 17:27:23 +0000 (17:27 +0000)]
convert to unsigned variables to avoid some overflows.
analysis and patch from David Fifield
tedu [Thu, 27 Dec 2018 17:22:45 +0000 (17:22 +0000)]
port ranges can be ambiguous with hypenated port-names.
specify that ranges must be numeric, and only check for range if
first argument is a digit.
identified by danj, fix suggest by sthen
krw [Thu, 27 Dec 2018 17:19:56 +0000 (17:19 +0000)]
Rename routehandler() to routefd_handler() to make the code slightly
more intuitive.
krw [Thu, 27 Dec 2018 17:02:03 +0000 (17:02 +0000)]
Rename bfdesc to bpffd and packethandler() to bpffd_handler() to make
the code slightly more intuitive.
kn [Thu, 27 Dec 2018 16:54:01 +0000 (16:54 +0000)]
Check for main ruleset explicitly
All rulesets reference their parent anchor, except for the special cased
main anchor containing the main ruleset, which's reference is always NULL
since initialization and never changes.
Replacing nullity tests with clearer equality checks makes the code less
ambigious and easier to understand.
OK sashan
kn [Thu, 27 Dec 2018 16:33:44 +0000 (16:33 +0000)]
Zap duplicate struct declaration
These are in <net/pfvar.h> already.
OK sashan
krw [Thu, 27 Dec 2018 16:15:10 +0000 (16:15 +0000)]
No need to return early when setting the tick stop.
gilles [Thu, 27 Dec 2018 15:41:50 +0000 (15:41 +0000)]
extract subaddress from last resolved node, not from dest or rcpt address
which was incorrect and can lead to ambiguous cases, this will affect the
people who were using subaddresses within aliases themselves AND expected
deliveries to a maildir subdir of the recipient user.
ok eric@
eric [Thu, 27 Dec 2018 15:04:59 +0000 (15:04 +0000)]
table_fetch() always expect a valid dst pointer.
ok gilles@
eric [Thu, 27 Dec 2018 14:41:45 +0000 (14:41 +0000)]
move the iterator variable in the private handle.
it is now correctly reset between updates.
ok gilles@
eric [Thu, 27 Dec 2018 14:23:41 +0000 (14:23 +0000)]
introduce dump() and add() table methods, only implemented for static tables.
ok gilles@
claudio [Thu, 27 Dec 2018 11:09:17 +0000 (11:09 +0000)]
Convert K&R function definitions to modern C. clang is more picky about
them.
OK otto@ deraadt@
claudio [Thu, 27 Dec 2018 11:06:38 +0000 (11:06 +0000)]
Move away from K&R style function definitions. clang is rather picky about
them especially if char and short arguments are used.
OK otto@ deraadt@
claudio [Thu, 27 Dec 2018 11:04:41 +0000 (11:04 +0000)]
Do not assign node to itself. Instead move the earlier initialisation into
the for loop. Makes clang happier.
OK otto@, deraadt@
gilles [Thu, 27 Dec 2018 10:35:26 +0000 (10:35 +0000)]
remove dead code, we will only support ramstat stat backend
ok eric@
anton [Thu, 27 Dec 2018 10:10:13 +0000 (10:10 +0000)]
sort and rename tests
anton [Thu, 27 Dec 2018 10:04:16 +0000 (10:04 +0000)]
Separate kcov descriptor state and trace mode as a first step towards supporting
different trace modes.
ok mpi@
eric [Thu, 27 Dec 2018 09:30:29 +0000 (09:30 +0000)]
pass the table pointer to the lookup()/fecth() methods
ok gilles@
eric [Thu, 27 Dec 2018 08:57:03 +0000 (08:57 +0000)]
change the close() method to take the table pointer
ok gilles
eric [Thu, 27 Dec 2018 08:08:06 +0000 (08:08 +0000)]
Make the backend open method return an int to report success.
The implementation is responsible for setting the handle pointer
as needed.
ok gilles@
djm [Thu, 27 Dec 2018 03:37:49 +0000 (03:37 +0000)]
ssh_packet_set_state() now frees ssh->kex implicitly, so don't
do explicit kex_free() beforehand
djm [Thu, 27 Dec 2018 03:25:24 +0000 (03:25 +0000)]
move client/server SSH-* banners to buffers under ssh->kex and factor
out the banner exchange. This eliminates some common code from the
client and server.
Also be more strict about handling \r characters - these should only
be accepted immediately before \n (pointed out by Jann Horn).
Inspired by a patch from Markus Schmidt.
(lots of) feedback and ok markus@
eric [Wed, 26 Dec 2018 20:13:43 +0000 (20:13 +0000)]
reorder parameters for consistency
denis [Wed, 26 Dec 2018 18:32:38 +0000 (18:32 +0000)]
uncouple AF_MPLS and AF_INET
input and OK mpi@
eric [Wed, 26 Dec 2018 17:37:15 +0000 (17:37 +0000)]
simplify code
ok gilles@
anton [Wed, 26 Dec 2018 16:14:59 +0000 (16:14 +0000)]
document kern.pool_debug; ok tedu@
eric [Wed, 26 Dec 2018 15:55:09 +0000 (15:55 +0000)]
introduce a table_match() function to check for a key in a table
ok gilles@
tb [Wed, 26 Dec 2018 15:11:04 +0000 (15:11 +0000)]
Make AES CCM available in tables.
Omission reported by reyk and Alice Wonder.
ok bcook jsing
sthen [Wed, 26 Dec 2018 14:49:45 +0000 (14:49 +0000)]
sync
eric [Wed, 26 Dec 2018 14:15:12 +0000 (14:15 +0000)]
get rid of the unused dict argument in table lookup and fetch api.
ok gilles@
denis [Wed, 26 Dec 2018 13:24:28 +0000 (13:24 +0000)]
unbreak VPN routes installation into FIB
OK claudio@
eric [Wed, 26 Dec 2018 11:53:02 +0000 (11:53 +0000)]
move the table backend name in the backend struct.
remove unused function.
ok gilles@
fcambus [Wed, 26 Dec 2018 11:33:57 +0000 (11:33 +0000)]
Remove the rasops24_erasecols and rasops24_eraserows functions from
rasops(9).
We only build rasops24 functions on amd64 (for EFI support in QEMU) and
on armv7 and arm64, and we can safely use the generic functions on those
platforms, like we do for all other color depths. No other platform uses
rasops24, Miod explains why here [1].
No performance regression observed when testing with QEMU in EFI mode.
[1] https://marc.info/?l=openbsd-ppc&m=
118664346819989&w=2
OK kettenis@
gilles [Wed, 26 Dec 2018 11:29:13 +0000 (11:29 +0000)]
when passing message to filters, do not worry yet about handling DATA
errors as this requires more work and is caught on stream back anyways
bru [Wed, 26 Dec 2018 11:08:02 +0000 (11:08 +0000)]
Use estimates of speed to improve gesture detection.
ok mpi@ (to the concept)
phessler [Wed, 26 Dec 2018 07:01:22 +0000 (07:01 +0000)]
revert "kill a region if 'delete' or 'backspace' is pressed"
This caused a change of behaviour in the search case, and isn't yet ready.
Committing on the behalf of lum@
OK lum@
anton [Tue, 25 Dec 2018 22:57:58 +0000 (22:57 +0000)]
test dying kcov descriptor logic
anton [Tue, 25 Dec 2018 21:56:53 +0000 (21:56 +0000)]
In the kcov ioctl(KIOSETBUFSIZE) path, malloc() can sleep. Double check that
someone else didn't win the race.
ok mpi@
denis [Tue, 25 Dec 2018 19:28:25 +0000 (19:28 +0000)]
rework icmp6_error() to be closer to icmp_error()
input & OK mpi@
krw [Tue, 25 Dec 2018 17:05:56 +0000 (17:05 +0000)]
No need for magic tick_msg(NULL,..) call to
set stop time. The stop time is always
config->link_timeout seconds after the
first call to tick_msg().
claudio [Tue, 25 Dec 2018 09:25:04 +0000 (09:25 +0000)]
Remove unused static function since clang errors out because of this.
OK visa@, mpi@, guenther@
claudio [Tue, 25 Dec 2018 09:20:49 +0000 (09:20 +0000)]
Use the same additional arch specific files for sparc64 as is done for mips
or aarch64. Needed to build userland with clang.
OK visa@ kettenis@
schwarze [Tue, 25 Dec 2018 00:05:38 +0000 (00:05 +0000)]
bugfix: make the static class buffer long enough
for .Bl -bullet -compact -offset indent
krw [Mon, 24 Dec 2018 23:28:20 +0000 (23:28 +0000)]
Always use log_getverbose() instead of sometimes checking OPT_VERBOSE
flag.
tedu [Mon, 24 Dec 2018 20:42:03 +0000 (20:42 +0000)]
mandoc.css lives in /usr/share/misc now; use full paths to indicate this.
ok schwarze
schwarze [Mon, 24 Dec 2018 19:59:17 +0000 (19:59 +0000)]
install /usr/share/misc/mandoc.css
users of -T html normally need this file,
so the source tree should not be the only place to get it
pointed out by millert@, OK millert@ deraadt@ tedu@
krw [Mon, 24 Dec 2018 18:36:24 +0000 (18:36 +0000)]
tick_msg() needs to note that it has called go_daemon(), since
dhclient could have been started with '-d'. Which means go_daemon()
may not actually daemonize. Which means isatty(STDERR_FILENO) may
always return 1. Which means "... sleeping" messages would be
emitted forever. e.g. running with '-d' and never successfully
obtaining a lease.
schwarze [Mon, 24 Dec 2018 10:07:22 +0000 (10:07 +0000)]
Make this page much more readable by deleting as much text as possible
about functions that are deprecated, identical to other functions, and
never made sense in the first place.
As deraadt@ points out, we should not hide the information that
matters in a heap of clutter. It would waste reader's time and
make confusion and accidental misuse more likely.
OK deraadt@ jmc@
jsg [Mon, 24 Dec 2018 08:45:57 +0000 (08:45 +0000)]
Adjust cpsw for linux 4.20 device tree changes. The location of the phy
is now found via phy-handle instead of phy_id.
patrick [Sun, 23 Dec 2018 22:48:19 +0000 (22:48 +0000)]
Add support for generating a REPEATED START on operations where we first
write the register address and then read the register data in one go.
ok kettenis@
schwarze [Sun, 23 Dec 2018 22:03:17 +0000 (22:03 +0000)]
Finally, stop abusing .Ss and .Sx to mark up macros, use .Ic instead
since these are clearly commands in a domain-specific language. As
a nice side effect, the resulting list allows including the synopsis
for each macro in the item head, reducing some repetitive verbiage.
schwarze [Sun, 23 Dec 2018 16:55:01 +0000 (16:55 +0000)]
Simplify and clarify instructions for .Ql, and deprecate .Li.
The macros .Ql, .Dl, and .Bd -literal leave no room for any
valid use case for .Li whatsoever.
General direction discussed with jmc@.
eric [Sun, 23 Dec 2018 16:37:53 +0000 (16:37 +0000)]
remove dead code
ok gilles@
gilles [Sun, 23 Dec 2018 16:06:24 +0000 (16:06 +0000)]
the tree_* and dict_* api's in smtpd can be used standalone, do not have
them depend on smtpd.h, it makes it hard to reuse them elsewhere
ok eric@
eric [Sun, 23 Dec 2018 15:53:24 +0000 (15:53 +0000)]
Simplify the table backend interface: lookup results are returned
as strings, and parsing is handled by the upper layer.
ok gilles@
gilles [Sun, 23 Dec 2018 15:49:04 +0000 (15:49 +0000)]
when a filter chain is only used once, no need to create a named chain, it
can now be inlined on listen lines: listen on all filter { foo1, foo2 }
gilles [Sun, 23 Dec 2018 15:48:16 +0000 (15:48 +0000)]
when passing mail-from parameter to filters, pass the '<' '>' free version
schwarze [Sun, 23 Dec 2018 15:32:10 +0000 (15:32 +0000)]
Deprecate .Lp, use .Pp instead.
Simplicity matters, and fewer macros is simpler.
OK jmc@
gilles [Sun, 23 Dec 2018 15:14:49 +0000 (15:14 +0000)]
simplify builtins
gilles [Sun, 23 Dec 2018 14:26:02 +0000 (14:26 +0000)]
revive filters tracing (-T filters) to make it easier understand what is
happening at filters level
natano [Sun, 23 Dec 2018 11:23:21 +0000 (11:23 +0000)]
Add regress suite for the noperm mfs mount flag. Protection of the root vnode
should be effective now. Let's make sure it stays that way.
natano [Sun, 23 Dec 2018 10:46:51 +0000 (10:46 +0000)]
Rectify some issues with the noperm mount flag; the root vnode was not
protected properly and files without any x bit set were accidentaly considered
executable when checked with access(2).
Issues found and reported by deraadt, halex, reyk, tb
ok deraadt
tb [Sun, 23 Dec 2018 08:35:14 +0000 (08:35 +0000)]
EVP_MD_CTX_cleanup() is deprecated and doesn't free, so recommend using
EVP_MD_CTX_free() instead if the goal is to avoid leaking memory.
From my corresponding upstream commit, reminded by schwarze
schwarze [Sat, 22 Dec 2018 23:19:53 +0000 (23:19 +0000)]
Document EVP_PKEY_new_mac_key(3);
from Matt Caswell <matt at openssl dot org>
via OpenSSL commit
d45a97f4 Mar 5 17:41:49 2018 +0000.
schwarze [Sat, 22 Dec 2018 19:48:46 +0000 (19:48 +0000)]
In the TOC, close <a> before opening <ul>.
Simplified version of a bugfix patch from rapha@.
deraadt [Sat, 22 Dec 2018 17:33:39 +0000 (17:33 +0000)]
sync
claudio [Sat, 22 Dec 2018 16:12:40 +0000 (16:12 +0000)]
bgpctl can cause bgpd to do a lot of work (e.g. dumping all of the RIB)
but then bgpctl can quickly exit and bgpd still has to do all the work.
Instead introduce a terminate imsg to stop such long running commands if
bgpctl closes the connection before the run is over.
OK benno@, sthen@, deraadt@
kettenis [Sat, 22 Dec 2018 14:42:29 +0000 (14:42 +0000)]
Avoid using m_trailingspace(9) on an mbuf allocated with MGET(9) as it relies
on header fields that aren't initialized, which may trigger an assertion.
Check whether the control message doesn't exceed MLEN instead and turn the
check into a KASSERT as the driver should not generate control messages
that are larger.
with help form claudio@ (who points out that the driver should not use
MT_CONTROL here).
ok patrick@
gilles [Sat, 22 Dec 2018 13:09:05 +0000 (13:09 +0000)]
introduce 'rcpt-to' builtin filter, can only be used on 'rcpt-to' hook
gilles [Sat, 22 Dec 2018 12:31:40 +0000 (12:31 +0000)]
introduce 'mail-from' builtin filter, can be applied on the 'mail-from',
'rcpt-to', 'data' and 'commit' phases.
gilles [Sat, 22 Dec 2018 12:17:16 +0000 (12:17 +0000)]
introduce 'helo' builtin filter, can be used on any hook but 'connect'
gilles [Sat, 22 Dec 2018 11:32:43 +0000 (11:32 +0000)]
remove lka_filter_response() which is no longer used, and reshuffle a bit
the functions within the file to make it easier to read
gilles [Sat, 22 Dec 2018 11:28:11 +0000 (11:28 +0000)]
simplify filter_protocol / filter_protocol_next by factoring code
while at it comment both filter_protocol_internal and filter_data_internal,
the gilles@ that will read this in six months will thank me.
gilles [Sat, 22 Dec 2018 10:39:16 +0000 (10:39 +0000)]
simplify filter_data() and filter_data_next() by factoring logic