History log of /openbsd/sys/net/if_enc.c (Results 1 – 25 of 79)
Revision Date Author Comments
# 18a44669 29-Aug-2022 bluhm <bluhm@openbsd.org>

Use struct refcnt for interface address reference counting.
There was a crash due to use after free of the ifa although it is
ref counted. As ifa_refcnt was a simple integer increment, there
may be

Use struct refcnt for interface address reference counting.
There was a crash due to use after free of the ifa although it is
ref counted. As ifa_refcnt was a simple integer increment, there
may be a path where multiple CPUs access it concurrently. So change
to struct refcnt which is MP safe and provides dt(4) leak debugging.
Link level address for IPsec enc(4) and various MPLS interfaces is
special. There ifa is part of struct sc. Use refcount anyway and
add a panic to detect use after free.
bug report stsp@; OK mvs@

show more ...


# 4c9d0427 28-Dec-2020 kn <kn@openbsd.org>

Remove unused start routine

enc(4) does not use the ifqueue API at all; IPsec packets are directly
transformed in the IP input/output routines.

enc_start() is never called (by design) so remove it

Remove unused start routine

enc(4) does not use the ifqueue API at all; IPsec packets are directly
transformed in the IP input/output routines.

enc_start() is never called (by design) so remove it for clarity.

OK mpi

show more ...


# 63bcfa73 10-Jul-2020 patrick <patrick@openbsd.org>

Change users of IFQ_DEQUEUE(), IFQ_ENQUEUE() and IFQ_LEN() to use the
"new" API.

ok dlg@ tobhe@


# 854a1b2d 24-Jan-2020 jsg <jsg@openbsd.org>

cleanup unused headers generated by config

ok tedu@ krw@ deraadt@


# 8a828045 14-Jul-2019 florian <florian@openbsd.org>

newlen was a dead store, but what we could use is oldlen to
simplify the code.
Pointed out by daniel@ with the help of their friend gcc9
OK kn


# 210de69c 17-Jun-2019 mpi <mpi@openbsd.org>

free(9) sizes.

ok reyk@


# e1bf84fa 08-Jul-2018 jca <jca@openbsd.org>

"id" is too generic, rename to "rdomain" for clarity and easier grepping

ok benno@ mpi@


# fcd035e8 08-Jul-2018 jca <jca@openbsd.org>

Use the same test pattern as for enc_ifps, for consistency

ok denis@


# c4b18f90 25-Jun-2018 denis <denis@openbsd.org>

Fix a kernelpanic when using rdomain(4) and enc(4)

OK jca@ mpi@


# 78767d47 16-Oct-2017 mpi <mpi@openbsd.org>

Last changes before running IPsec w/o KERNEL_LOCK().

Put more NET_ASSERT_LOCK() and document which globals it protects.

Add a mutex for pfkeyv2 globals.

Convert ipsp_delete_acquire() to timeout_se

Last changes before running IPsec w/o KERNEL_LOCK().

Put more NET_ASSERT_LOCK() and document which globals it protects.

Add a mutex for pfkeyv2 globals.

Convert ipsp_delete_acquire() to timeout_set_proc().

Tested by Hrvoje Popovski, ok bluhm@ visa@

show more ...


# aa28b9a6 11-Aug-2017 mpi <mpi@openbsd.org>

Remove NET_LOCK()'s argument.

Tested by Hrvoje Popovski, ok bluhm@


# ad5900fa 28-May-2017 mpi <mpi@openbsd.org>

Protect the global array of interfaces with the NET_LOCK().

ok sashan@


# 99bf4b5f 23-Jan-2017 mpi <mpi@openbsd.org>

Flag pseudo-interfaces as such in order to call add_net_randomness()
only once per packet.

Fix a regression introduced when if_input() started to be called by
every pseudo-driver.

ok claudio@, dlg@


# 4bee61c4 20-Jan-2017 mpi <mpi@openbsd.org>

No need to handle SIOCAIFADDR in drivers, it's never passed down to
them.

ok claudio@


# 3aae6309 04-Sep-2016 krw <krw@openbsd.org>

Make enc_output() return EAFNOSUPPORT after dropping the packet,
instead of 0. Makes it consistent with other similar interfaces.

ok mpi@ vgross@


# 55d3f402 09-Nov-2015 dlg <dlg@openbsd.org>

use IFQ_DEQUEUE to pull of the send queue.


# 7ffb277f 30-Oct-2015 bluhm <bluhm@openbsd.org>

Rename rtrequest1() to rtrequest().
OK mpi@


# 03def9c5 22-Oct-2015 mpi <mpi@openbsd.org>

Kill link_rtrequest(), introduce in 1990 to "fix" the result
of rt_getifa() when adding link level route from outside the
kernel.

ok claudio@


# c7b7b779 22-Oct-2015 bluhm <bluhm@openbsd.org>

Inspired by satosin(), use inline functions to convert sockaddr dl.
Instead of casts they check wether the incoming object has the
expected type. So introduce satosdl() and sdltosa() in the kernel.

Inspired by satosin(), use inline functions to convert sockaddr dl.
Instead of casts they check wether the incoming object has the
expected type. So introduce satosdl() and sdltosa() in the kernel.
OK mpi@

show more ...


# 21dab745 14-Mar-2015 jsg <jsg@openbsd.org>

Remove some includes include-what-you-use claims don't
have any direct symbols used. Tested for indirect use by compiling
amd64/i386/sparc64 kernels.

ok tedu@ deraadt@


# f8238f3e 13-Dec-2014 doug <doug@openbsd.org>

yet more mallocarray() changes.

ok tedu@ deraadt@


# 88be4c56 08-Dec-2014 mpi <mpi@openbsd.org>

There's no good reason to keep into "struct ifnet" a pointer that's only
used by enc(4) devices to attach their routes.

ok sthen@, mikeb@


# 0deb6685 05-Dec-2014 mpi <mpi@openbsd.org>

Explicitly include <net/if_var.h> instead of pulling it in <net/if.h>.

ok mikeb@, krw@, bluhm@, tedu@


# a370214e 08-Sep-2014 jsg <jsg@openbsd.org>

remove uneeded route.h includes
ok miod@ mpi@


# dd168dc2 12-Jul-2014 tedu <tedu@openbsd.org>

add a size argument to free. will be used soon, but for now default to 0.
after discussions with beck deraadt kettenis.


1234