summaryrefslogtreecommitdiff
path: root/sbin/ipsecadm
diff options
context:
space:
mode:
authorAngelos D. Keromytis <angelos@cvs.openbsd.org>1999-02-26 10:04:06 +0000
committerAngelos D. Keromytis <angelos@cvs.openbsd.org>1999-02-26 10:04:06 +0000
commit5e52df371ae475e301360313a6e4083254457500 (patch)
treedda3cd6962406b4a33222312f82416284c2b8331 /sbin/ipsecadm
parentdc5b763cdf3c6cadfe7d212f26dec81f0fda3547 (diff)
Print warning when using DES or Skipjack for encryption.
Diffstat (limited to 'sbin/ipsecadm')
-rw-r--r--sbin/ipsecadm/ipsecadm.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/sbin/ipsecadm/ipsecadm.c b/sbin/ipsecadm/ipsecadm.c
index d83737ad810..b168928c8cf 100644
--- a/sbin/ipsecadm/ipsecadm.c
+++ b/sbin/ipsecadm/ipsecadm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ipsecadm.c,v 1.10 1999/02/26 02:04:52 angelos Exp $ */
+/* $OpenBSD: ipsecadm.c,v 1.11 1999/02/26 10:04:05 angelos Exp $ */
/*
* The authors of this code are John Ioannidis (ji@tla.org),
* Angelos D. Keromytis (kermit@csd.uch.gr) and
@@ -159,7 +159,12 @@ isvalid(char *option, int type, int mode)
if (!strcmp(option, xf[i].name) &&
(xf[i].flags & CMD_MASK) == type &&
(xf[i].flags & mode))
- return xf[i].id;
+ {
+ if (!strcmp(option, "des") || !strcmp(option, "skipjack"))
+ fprintf(stderr, "Warning: use of %s is strongly discouraged due to cryptographic weaknesses\n", option);
+
+ return xf[i].id;
+ }
return 0;
}