Home | History | Annotate | Line # | Download | only in includes
      1 /*	$NetBSD: ns_name.h,v 1.4 2022/04/03 01:10:58 christos Exp $	*/
      2 
      3 /*
      4  * Copyright (C) 2004-2022 Internet Systems Consortium, Inc. ("ISC")
      5  * Copyright (c) 2001-2003 by Internet Software Consortium
      6  *
      7  * This Source Code Form is subject to the terms of the Mozilla Public
      8  * License, v. 2.0. If a copy of the MPL was not distributed with this
      9  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
     10  *
     11  * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
     12  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
     13  * MERCHANTABILITY AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR
     14  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
     15  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
     16  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
     17  * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
     18  *
     19  *   Internet Systems Consortium, Inc.
     20  *   PO Box 360
     21  *   Newmarket, NH 03857 USA
     22  *   <info (at) isc.org>
     23  *   http://www.isc.org/
     24  */
     25 #ifndef NS_NAME_H
     26 #define NS_NAME_H
     27 
     28 #include "cdefs.h"
     29 #include "osdep.h"
     30 
     31 /*
     32  * Based on the Dynamic DNS reference implementation by Viraj Bais
     33  * <viraj_bais (at) ccm.fm.intel.com>
     34  */
     35 
     36 int MRns_name_len(const unsigned char *, const unsigned char *);
     37 int MRns_name_compress(const char *, u_char *, size_t, const unsigned char **,
     38 		       const unsigned char **);
     39 int MRns_name_unpack(const unsigned char *, const unsigned char *,
     40 		     const unsigned char *, unsigned char *, size_t);
     41 int MRns_name_pack (const unsigned char *, unsigned char *,
     42 		    unsigned, const unsigned char **, const unsigned char **);
     43 int MRns_name_ntop(const unsigned char *, char *, size_t);
     44 int MRns_name_pton(const char *, u_char *, size_t);
     45 int MRns_name_uncompress_list(const unsigned char*, int buflen, char*, size_t);
     46 int MRns_name_compress_list(const char*, int buflen, unsigned char*, size_t);
     47 
     48 #endif /* NS_NAME_H */
     49