diff options
author | Markus Friedl <markus@cvs.openbsd.org> | 2004-12-13 11:41:29 +0000 |
---|---|---|
committer | Markus Friedl <markus@cvs.openbsd.org> | 2004-12-13 11:41:29 +0000 |
commit | 3a2d9ee12807426a2ce72e596c9eefc01fea5bd7 (patch) | |
tree | 533f6f2f1e50b5cdb574d144e7581a3873daae09 | |
parent | d7abb1d498a7310b2291d18a3ae1d13e0e2915a9 (diff) |
make sure the isakmpd_s has id_r/s set; ok hshoexer, ho
-rw-r--r-- | sbin/isakmpd/dpd.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sbin/isakmpd/dpd.c b/sbin/isakmpd/dpd.c index cd9aad3873f..241aab1d38b 100644 --- a/sbin/isakmpd/dpd.c +++ b/sbin/isakmpd/dpd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dpd.c,v 1.5 2004/12/08 16:08:10 markus Exp $ */ +/* $OpenBSD: dpd.c,v 1.6 2004/12/13 11:41:28 markus Exp $ */ /* * Copyright (c) 2004 Håkan Olsson. All rights reserved. @@ -240,6 +240,8 @@ dpd_find_sa(struct sa *sa, void *v_sa) { struct sa *isakmp_sa = v_sa; + if (!isakmp_sa->id_i || !isakmp_sa->id_r) + return (0); return (sa->phase == 2 && memcmp(sa->id_i, isakmp_sa->id_i, sa->id_i_len) == 0 && memcmp(sa->id_r, isakmp_sa->id_r, sa->id_r_len) == 0); |