- stevesk@cvs.openbsd.org 2009/12/25 19:40:21
[readconf.c servconf.c misc.h ssh-keyscan.c misc.c]
validate routing domain is in range 0-RT_TABLEID_MAX.
'Looks right' deraadt@
diff --git a/servconf.c b/servconf.c
index 729f23b..8b8518a 100644
--- a/servconf.c
+++ b/servconf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: servconf.c,v 1.197 2009/10/28 16:38:18 reyk Exp $ */
+/* $OpenBSD: servconf.c,v 1.198 2009/12/25 19:40:21 stevesk Exp $ */
/*
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
* All rights reserved
@@ -1298,7 +1298,16 @@
case sRDomain:
intptr = &options->rdomain;
- goto parse_int;
+ arg = strdelim(&cp);
+ if (!arg || *arg == '\0')
+ fatal("%s line %d: missing rdomain value.",
+ filename, linenum);
+ if ((value = a2rdomain(arg)) == -1)
+ fatal("%s line %d: invalid rdomain value.",
+ filename, linenum);
+ if (*intptr == -1)
+ *intptr = value;
+ break;
case sDeprecated:
logit("%s line %d: Deprecated option %s",