/*
* Copyright (C) 2004, 2005, 2007, 2012-2014 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1998-2002 Internet Software Consortium.
*
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
* REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
* LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
* OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id$ */
/* Reviewed: Thu Mar 16 14:06:44 PST 2000 by gson */
/* RFC2671 */
#ifndef RDATA_GENERIC_OPT_41_C
#define RDATA_GENERIC_OPT_41_C
static inline isc_result_t
/*
* OPT records do not have a text format.
*/
return (ISC_R_NOTIMPLEMENTED);
}
static inline isc_result_t
isc_region_t r;
/*
* OPT records do not have a text format.
*/
dns_rdata_toregion(rdata, &r);
while (r.length > 0) {
option = uint16_fromregion(&r);
isc_region_consume(&r, 2);
length = uint16_fromregion(&r);
isc_region_consume(&r, 2);
if (length > 0) {
or = r;
isc_region_consume(&r, length);
}
if (r.length > 0)
}
return (ISC_R_SUCCESS);
}
static inline isc_result_t
unsigned int total;
total = 0;
return (ISC_R_UNEXPECTEDEND);
total += 4;
return (ISC_R_UNEXPECTEDEND);
switch (opt) {
case DNS_OPT_CLIENT_SUBNET: {
if (length < 4)
return (DNS_R_FORMERR);
switch (family) {
case 1:
return (DNS_R_FORMERR);
break;
case 2:
return (DNS_R_FORMERR);
break;
}
return (DNS_R_FORMERR);
break;
}
default:
break;
}
}
return (ISC_R_NOSPACE);
return (ISC_R_SUCCESS);
}
static inline isc_result_t
}
static inline int
}
static inline isc_result_t
return (ISC_R_UNEXPECTEDEND);
}
return (ISC_R_UNEXPECTEDEND);
}
static inline isc_result_t
isc_region_t r;
dns_rdata_toregion(rdata, &r);
return (ISC_R_NOMEMORY);
return (ISC_R_SUCCESS);
}
static inline void
return;
}
static inline isc_result_t
return (ISC_R_SUCCESS);
}
static inline isc_result_t
/*
* OPT records are not digested.
*/
return (ISC_R_NOTIMPLEMENTED);
}
static inline isc_boolean_t
}
static inline isc_boolean_t
return (ISC_TRUE);
}
#endif /* RDATA_GENERIC_OPT_41_C */