1 .\" $NetBSD: hesiod.3,v 1.1 1999/01/25 03:43:04 lukem Exp $
2 .\" $FreeBSD: src/lib/libc/net/hesiod.3,v 1.3 2001/10/01 16:08:55 ru Exp $
4 .\" from: #Id: hesiod.3,v 1.9.2.1 1997/01/03 21:02:23 ghudson Exp #
6 .\" Copyright 1988, 1996 by the Massachusetts Institute of Technology.
8 .\" Permission to use, copy, modify, and distribute this
9 .\" software and its documentation for any purpose and without
10 .\" fee is hereby granted, provided that the above copyright
11 .\" notice appear in all copies and that both that copyright
12 .\" notice and this permission notice appear in supporting
13 .\" documentation, and that the name of M.I.T. not be used in
14 .\" advertising or publicity pertaining to distribution of the
15 .\" software without specific, written prior permission.
16 .\" M.I.T. makes no representations about the suitability of
17 .\" this software for any purpose. It is provided "as is"
18 .\" without express or implied warranty.
27 .Nm hesiod_free_list ,
30 .Nd Hesiod name server interface library
36 .Fn hesiod_init "void **context"
38 .Fn hesiod_resolve "void *context" "const char *name" "const char *type"
40 .Fn hesiod_free_list "void *context" "char **list"
42 .Fn hesiod_to_bind "void *context" "const char *name" "const char *type"
44 .Fn hesiod_end "void *context"
46 This family of functions allows you to perform lookups of Hesiod
47 information, which is stored as text records in the Domain Name
49 To perform lookups, you must first initialize a
51 an opaque object which stores information used internally by the
52 library between calls.
54 initializes a context, storing a pointer to the context in the
55 location pointed to by the
59 frees the resources used by a context.
62 is the primary interface to the library.
63 If successful, it returns a
64 list of one or more strings giving the records matching
68 The last element of the list is followed by a
72 caller's responsibility to call
74 to free the resources used by the returned list.
81 into the DNS name used by
83 It is the caller's responsibility to free the returned string using
93 and set the global variable
95 to indicate the error.
97 .Bl -tag -width HESIOD_CONFIG
99 If the environment variable
101 is set, it will override the domain in the Hesiod configuration file.
103 If the environment variable
105 is set, it specifies the location of the Hesiod configuration file.
111 .%T "Hesiod - Project Athena Technical Plan -- Name Service"
114 Hesiod calls may fail because of:
117 Insufficient memory was available to carry out the requested
121 failed because the Hesiod configuration file was invalid.
122 .It Bq Er ECONNREFUSED
124 failed because no name server could be contacted to answer the query.
129 failed because the query or response was too big to fit into the
133 failed because the name server had no text records matching
141 argument had a domain extension which could not be resolved with type
143 in the local Hesiod domain.
151 Copyright 1987, 1988, 1995, 1996 by the Massachusetts Institute of Technology.
153 The strings corresponding to the
155 values set by the Hesiod functions are not particularly indicative of
156 what went wrong, especially for