4 * Copyright (C) 2000-2001 by Darren Reed.
6 * See the IPFILTER.LICENCE file for details on licencing.
8 * Id: optname.c,v 1.3.4.1 2006/06/16 17:21:07 darrenr Exp
14 u_32_t
optname(cp
, sp
, linenum
)
19 struct ipopt_names
*io
, *so
;
25 for (s
= strtok(**cp
, ","); s
; s
= strtok(NULL
, ",")) {
26 for (io
= ionames
; io
->on_name
; io
++)
27 if (!strcasecmp(s
, io
->on_name
)) {
32 fprintf(stderr
, "%d: unknown IP option name %s\n",
36 if (!strcasecmp(s
, "sec-class"))
40 if (sec
&& !*(*cp
+ 1)) {
41 fprintf(stderr
, "%d: missing security level after sec-class\n",
48 for (s
= strtok(**cp
, ","); s
; s
= strtok(NULL
, ",")) {
49 for (so
= secclass
; so
->on_name
; so
++)
50 if (!strcasecmp(s
, so
->on_name
)) {
56 "%d: no such security level: %s\n",