1
0
mirror of https://github.com/openbsd/src.git synced 2024-12-21 23:18:00 -08:00
openbsd-src/sbin/isakmpd
2024-11-21 10:07:30 +00:00
..
sysdep/openbsd Spacing, no object change. 2018-01-15 09:54:48 +00:00
app.c Stop assuming that in_{addr,port}_t are typedefed in <sys/types.h> and 2017-02-03 08:23:46 +00:00
app.h remove prototypes with no matching function and externs with no var 2024-05-21 05:00:47 +00:00
attribute.c Stop assuming that in_{addr,port}_t are typedefed in <sys/types.h> and 2017-02-03 08:23:46 +00:00
attribute.h
BUGS Remove listing of fixed bugs. 2017-08-22 15:03:37 +00:00
cert.c
cert.h Replace <sys/param.h> with <limits.h> and other less dirty headers where 2015-01-16 06:39:28 +00:00
conf.c Support DH groups 19 to 21 and 25 to 30, just like iked(8) does. 2017-10-27 08:29:32 +00:00
conf.h
connection.c Spacing, no object change. 2018-01-15 09:54:48 +00:00
connection.h
constants.c
constants.h
cookie.c Stop assuming that in_{addr,port}_t are typedefed in <sys/types.h> and 2017-02-03 08:23:46 +00:00
cookie.h
crypto.c Spacing, no object change. 2018-01-15 09:54:48 +00:00
crypto.h
DESIGN-NOTES
dh.c Guard use of GROUP_EC2N with #ifndef OPENSSL_NO_EC2M 2023-03-31 07:28:46 +00:00
dh.h In the final RFC 5903 the computation for the DH shared secret changed. 2017-11-08 13:33:49 +00:00
dnssec.c delete unneccessary arpa/nameser.h includes 2021-10-09 18:43:49 +00:00
dnssec.h remove duplicate defines 2024-10-23 03:14:32 +00:00
doi.c
doi.h
dpd.c Use clock_gettime(CLOCK_MONOTONIC) to schedule timers 2017-12-05 20:31:45 +00:00
dpd.h
exchange_num.cst
exchange.c Spacing, no object change. 2018-01-15 09:54:48 +00:00
exchange.h Spacing, no object change. 2018-01-15 09:54:48 +00:00
field.c Check return value of asprintf(), and don't use 0 as a char * 2017-04-02 21:23:44 +00:00
field.h
genconstants.sh
genfields.sh
hash.c The block size of HMAC-SHA2-{384,512} must be 128 bytes. 2024-11-21 10:07:30 +00:00
hash.h The block size of HMAC-SHA2-{384,512} must be 128 bytes. 2024-11-21 10:07:30 +00:00
if.c When system calls indicate an error they return -1, not some arbitrary 2019-06-28 13:32:41 +00:00
if.h remove prototypes with no matching function and externs with no var 2024-05-21 05:00:47 +00:00
ike_aggressive.c Spacing, no object change. 2018-01-15 09:54:48 +00:00
ike_aggressive.h
ike_auth.c Fix shared DH secret length in log message. 2020-07-07 17:33:40 +00:00
ike_auth.h
ike_main_mode.c Spacing, no object change. 2018-01-15 09:54:48 +00:00
ike_main_mode.h
ike_phase_1.c add missing braces implied by indentation 2018-09-20 11:49:55 +00:00
ike_phase_1.h remove prototypes with no matching function and externs with no var 2024-05-21 05:00:47 +00:00
ike_quick_mode.c Add missing NULL check after group_get() 2023-03-31 20:16:55 +00:00
ike_quick_mode.h
init.c isakmpd: remove libcrypto.c 2021-10-13 16:56:30 +00:00
init.h
ipsec_doi.h
ipsec_fld.fld
ipsec_num.cst After deleting hifn(4) the only provider for the LZS compression 2021-10-22 12:30:53 +00:00
ipsec.c Don't unset the SA tag set by ipsec_sa_tag in ipsec_sa_iface. 2023-12-20 00:34:13 +00:00
ipsec.h In the final RFC 5903 the computation for the DH shared secret changed. 2017-11-08 13:33:49 +00:00
isakmp_cfg.c Spacing, no object change. 2018-01-15 09:54:48 +00:00
isakmp_cfg.h
isakmp_doi.c
isakmp_doi.h
isakmp_fld.fld
isakmp_num.cst
isakmp.h
isakmpd.8 mop up for the pcap.3 rename; 2019-08-30 17:51:47 +00:00
isakmpd.c Delete obsolete /* ARGSUSED */ lint comments. 2023-03-08 04:43:04 +00:00
isakmpd.conf.5 have a go at documenting the Interface config statement. 2023-08-08 10:31:03 +00:00
isakmpd.policy.5 remove please from manual pages 2022-02-06 00:29:02 +00:00
key.c isakmpd: remove #ifdefs for ancient OPENSSL_VERSIONs. 2021-10-13 16:57:43 +00:00
key.h
libcrypto.h isakmpd: remove libcrypto.c 2021-10-13 16:56:30 +00:00
log.c gmtime(3) / locatime(3) can fail when timestamps are way off. 2024-04-28 16:43:42 +00:00
log.h
Makefile isakmpd: remove libcrypto.c 2021-10-13 16:56:30 +00:00
message.c Fix memory leak. Call proto_free() always to free proto. 2016-04-04 17:35:07 +00:00
message.h remove prototypes with no matching function and externs with no var 2024-05-21 05:00:47 +00:00
monitor_fdpass.c Print ssize_t with %zd; ok deraadt@ mmcc@ 2016-02-29 20:22:36 +00:00
monitor.c isakmpd: add missing void to a function definition 2023-02-08 08:03:11 +00:00
monitor.h
nat_traversal.c Use clock_gettime(CLOCK_MONOTONIC) to schedule timers 2017-12-05 20:31:45 +00:00
nat_traversal.h
pf_key_v2.c support configuring interface SAs for route-based ipsec vpns. 2023-08-07 04:01:29 +00:00
pf_key_v2.h
policy.c gmtime(3) / locatime(3) can fail when timestamps are way off. 2024-04-28 16:43:42 +00:00
policy.h remove prototypes with no matching function and externs with no var 2024-05-21 05:00:47 +00:00
prf.c
prf.h
QUESTIONS
README move links from http to https://www.openbsd.org/ 2016-09-02 12:17:32 +00:00
sa.c When it's the possessive of 'it', it's spelled "its", without the 2022-01-28 05:24:15 +00:00
sa.h support configuring interface SAs for route-based ipsec vpns. 2023-08-07 04:01:29 +00:00
timer.c Use clock_gettime(CLOCK_MONOTONIC) to schedule timers 2017-12-05 20:31:45 +00:00
timer.h Use clock_gettime(CLOCK_MONOTONIC) to schedule timers 2017-12-05 20:31:45 +00:00
TO-DO
transport.c Extern transport_list. Fixed compilation with -fno-common. 2021-01-28 01:18:44 +00:00
transport.h When it's the possessive of 'it', it's spelled "its", without the 2022-01-28 05:24:15 +00:00
udp_encap.c isakmpd: fix -Wunused-but-set-variable warnings 2022-01-16 14:30:11 +00:00
udp_encap.h
udp.c
udp.h
ui.c For open/openat, if the flags parameter does not contain O_CREAT, the 2021-10-24 21:24:15 +00:00
ui.h
util.c When system calls indicate an error they return -1, not some arbitrary 2019-06-28 13:32:41 +00:00
util.h Use clock_gettime(CLOCK_MONOTONIC) to schedule timers 2017-12-05 20:31:45 +00:00
vendor.c In the final RFC 5903 the computation for the DH shared secret changed. 2017-11-08 13:33:49 +00:00
vendor.h
virtual.c When system calls indicate an error they return -1, not some arbitrary 2019-06-28 13:32:41 +00:00
virtual.h
x509.c gmtime(3) / locatime(3) can fail when timestamps are way off. 2024-04-28 16:43:42 +00:00
x509.h

$OpenBSD: README,v 1.20 2016/09/02 12:17:32 tb Exp $
$EOM: README,v 1.28 1999/10/10 22:53:24 angelos Exp $

This is isakmpd, a BSD-licensed ISAKMP/Oakley (a.k.a. IKE)
implementation.  It's written by Niklas Hallqvist and Niels Provos,
funded by Ericsson Radio Systems AB.  Isakmpd's home is in the
OpenBSD main source tree under src/sbin/isakmpd.  Look at
https://www.openbsd.org/ for details on how to get OpenBSD source.

Isakmpd is being developed under OpenBSD, with OpenBSD as its primary
target, however, it is ported to Linux with FreeS/WAN IPsec.  The
makefile support assumes a BSD environment nonetheless as it is not too
hard to get such an environment to work under other operating systems.
For example, Red Hat 5.2 shipped with pmake installed.  Read sysdep/README
for further details about this issue.  Other systems isakmpd has been
ported to, but no code has been made available for, includes Solaris
and Win32s.  I mention this just because it shows that the code is
fairly portable.

First edit the Makefile in a manner you see fit.  Specifically the OS
define is important to get right of course.
Assuming you have an OpenBSD /usr/share/mk and use the OpenBSD (or
similar) make(1), you build isakmpd this way:

make obj && make depend && make

Then obj/isakmpd will be the daemon.  I suggest you try it by running
under gdb with args similar to:
	-d -n -p5000 -DA=99 -f/tmp/isakmpd.fifo -csamples/VPN-east.conf

That will run isakmpd in the foreground, not connected to any application
(like an IPsec implementation) logging to stderr with full debugging output,
listening on UDP port 5000, accepting control commands via the named pipe
called /tmp/isakmpd.fifo and reading its configuration from the
VPN-east.conf file (found in the isakmpd/samples directory).

If you are root you can try to run without -n -p5000 thus getting it to
talk to your IPsec stack and use the standard port 500 instead.

The logging classes are Miscellaneous = 0, Transports = 1, Messages = 2,
Crypto = 3, Timers = 4, System Dependencies = 5, Security Associations = 6,
and Exchanges = 7.  The debug levels increase in verbosity from 0 (off) to
99 (max). Read log.[ch] and ui.c to see how to alter the debugging levels.

Now you have setup your daemon and can watch incoming negotiations.
But how do you get such?  Either use http://isakmp-test.ssh.fi/,
there's an excellent service, just waiting for you.  Or you can try to
start another isakmpd on another port (say -p5001 or so, instead)
and another fifo (let's say /tmp/other.fifo).  Then edit the config
file to have some peer descriptions that fit your need and issue a
command like this:

$ echo "c IPsec-east-west" >/tmp/other.fifo

and watch.  You can turn on debugging on that isakmpd too of course, for
greater fun.  This rudimentary user interface is slightly described in
DESIGN-NOTES.  If you are going to look at the config file, don't be scared,
the man page isakmpd.conf(5) covers every detail, and the flexibility will
be hidden under a userfriendlier layer in a later release.  I did this
first config-file syntax just because it should be easy to parse. The man
page isakmpd.policy(5) describes the policy model used in conjunction with
KeyNote.

Happy IKEing!

Niklas Hallqvist <niklas@openbsd.org>
Niels Provos <provos@openbsd.org>
H<>kan Olsson <ho@openbsd.org>