C Library Functions HESIOD(3) NAME hesiod, hesiod_init, hesiod_resolve, hesiod_free_list, hes- iod_to_bind, hesiod_end - Hesiod name server interface library SYNOPSIS #include int hesiod_init(void **_______) char **hesiod_resolve(void *_______, const char *____, const char *____) void hesiod_free_list(void *_______, char **____); char *hesiod_to_bind(void *_______, const char *____, const char *____) void hesiod_end(void *_______) DESCRIPTION This family of functions allows you to perform lookups of Hesiod information, which is stored as text records in the Domain Name Service. To perform lookups, you must first initialize a _______, an opaque object which stores informa- tion used internally by the library between calls. ____ ________ initializes a context, storing a pointer to the context in the location pointed to by the _______ argument. __________ frees the resources used by a context. ______________ is the primary interface to the library. If successful, it returns a list of one or more strings giving the records matching ____ and ____. The last element of the list is followed by a NULL pointer. It is the caller's responsibility to call ________________ to free the resources used by the returned list. ______________ converts ____ and ____ into the DNS name used by ______________. It is the caller's responsibility to free the returned string using ____. RETURN VALUES If successful, ___________ returns 0; otherwise it returns -1 and sets _____ to indicate the error. On failure, ____ ___________ and ______________ return NULL and set the global variable _____ to indicate the error. ENVIRONMENT If the environment variable HES_DOMAIN is set, it will over- ride the domain in the Hesiod configuration file. If the environment variable HESIOD_CONFIG is set, it specifies the location of the Hesiod configuration file. SEE ALSO `Hesiod - Project Athena Technical Plan -- Name Service', named(8), hesiod.conf(5) SunOS 5.6 Last change: 30 November 1996 1 C Library Functions HESIOD(3) ERRORS Hesiod calls may fail because of: ENOMEM Insufficient memory was available to carry out the requested operation. ENOEXEC ___________ failed because the Hesiod configuration file was invalid. ECONNREFUSED ______________ failed because no name server could be contacted to answer the query. EMSGSIZE ______________ failed because the query or response was too big to fit into the packet buffers. ENOENT ______________ failed because the name server had no text records matching ____ and ____, or ______________ failed because the ____ argument had a domain extension which could not be resolved with type ``rhs-extension'' in the local Hesiod domain. AUTHOR Steve Dyer, IBM/Project Athena Greg Hudson, MIT Team Athena Copyright 1987, 1988, 1995, 1996 by the Massachusetts Insti- tute of Technology. BUGS The strings corresponding to the _____ values set by the Hesiod functions are not particularly indicative of what went wrong, especially for _______ and ______. SunOS 5.6 Last change: 30 November 1996 2