3rd (variadic) mode_t parameter is irrelevant. Many developers in the past
have passed mode_t (0, 044, 0644, or such), which might lead future people
to copy this broken idiom, and perhaps even believe this parameter has some
meaning or implication or application. Delete them all.
This comes out of a conversation where tb@ noticed that a strange (but
intentional) pledge behaviour is to always knock-out high-bits from
mode_t on a number of system calls as a safety factor, and his bewilderment
that this appeared to be happening against valid modes (at least visually),
but no sorry, they are all irrelevant junk. They could all be 0xdeafbeef.
ok millert
Information (RFC 3046) options. While at there change the naming of the
remote destination parameters: instead of "server" call it "destination".
ok reyk@
information instead of passing multiple different parameters. This also
prepares the dhcrelay code to receive new features, like: IPv6, layer 2
relaying.
ok jca@
drop requests that have already been relayed. To allow usage in the
middle of a chain, remove this check and only set giaddr if it has not
been set yet. This giaddr will be used by the DHCP server to identify
which subnet the client is connected to.
RFC 1542 specifies that we should increase the hop counter every time
we relay a request. If we receive a request whose hop counter exceeds
the value of 16 we must silently drop it.
ok jca@
we SHOULD forward the packet not only as L3 broadcast, but also as
L2 broadcast. Apparently that helps on older machines that can't
handle L2 unicast replies.
ok jca@
rdaemon() works like daemon(3) but requires its caller to pre-open
/dev/null. This makes it possible to go in the background after
a chroot(2), allowing for more error checking. The pattern is basically
- open /dev/null
- chroot
- privdrop
- rdaemon
"design" initialy discussed with semarie@ a while ago, ok dlg@
gateway address. This is a problem if your DHCP relay is running
on something that's not your network gateway.
It is purely informational from the relay to the client so we can
safely clear it.
stupid vmware.
ok krw@ beck@
and make it possible to bind sockets (including listening sockets!)
to rtables and not just rdomains. This changes the name of the
system calls, socket option, and ioctl. After building with this
you should remove the files /usr/share/man/cat2/[gs]etrdomain.0.
Since this removes the existing [gs]etrdomain() system calls, the
libc major is bumped.
Written by claudio@, criticized^Wcritiqued by me
Agent Information Option) and RFC 3456 (DHCP Configuration of IPsec
Tunnel Mode). This allows to configure various IPsec clients
dynamically via DHCP; dhcrelay needs to listen on enc0 and forward
requests to a DHCP server that supports RFC 3046, like I recently did
for dhcpd(8).
ok krw@