*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->FreeBSD man pages -> hesiod (3)              
Title
Content
Arch
Section
 

HESIOD(3)

Contents


NAME    [Toc]    [Back]

     hesiod, hesiod_init, hesiod_resolve, hesiod_free_list, hesiod_to_bind,
     hesiod_end -- Hesiod name server interface library

LIBRARY    [Toc]    [Back]

     Standard C Library (libc, -lc)

SYNOPSIS    [Toc]    [Back]

     #include <hesiod.h>

     int
     hesiod_init(void **context);

     char **
     hesiod_resolve(void *context, const char *name, const char *type);

     void
     hesiod_free_list(void *context, char **list);

     char *
     hesiod_to_bind(void *context, const char *name, const char *type);

     void
     hesiod_end(void *context);

DESCRIPTION    [Toc]    [Back]

     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 context, an opaque object
     which stores information used internally by the library between calls.
     The hesiod_init() function initializes a context, storing a pointer to
     the context in the location pointed to by the context argument.  The
     hesiod_end() function frees the resources used by a context.

     The hesiod_resolve() function is the primary interface to the library.
     If successful, it returns a list of one or more strings giving the
     records matching name and type.  The last element of the list is followed
     by a NULL pointer.  It is the caller's responsibility to call
     hesiod_free_list() to free the resources used by the returned list.

     The hesiod_to_bind() function converts name and type into the DNS name
     used by hesiod_resolve().	It is the caller's responsibility to free the
     returned string using free().

RETURN VALUES    [Toc]    [Back]

     The hesiod_init() function returns the value 0 if successful; otherwise
     the value -1 is returned and the global variable errno is set to indicate
     the error.  On failure, hesiod_resolve() and hesiod_to_bind() return NULL
     and set the global variable errno to indicate the error.

ENVIRONMENT    [Toc]    [Back]

     HES_DOMAIN     If the environment variable HES_DOMAIN is set, it will
		    override the domain in the Hesiod configuration file.

     HESIOD_CONFIG  If the environment variable HESIOD_CONFIG is set, it specifies
 the location of the Hesiod configuration file.

SEE ALSO    [Toc]    [Back]

      
      
     hesiod.conf(5), named(8)

     Hesiod - Project Athena Technical Plan -- Name Service.

ERRORS    [Toc]    [Back]

     Hesiod calls may fail because of:

     [ENOMEM]		Insufficient memory was available to carry out the
			requested operation.

     [ENOEXEC]		The hesiod_init() function failed because the Hesiod
			configuration file was invalid.

     [ECONNREFUSED]	The hesiod_resolve() function failed because no name
			server could be contacted to answer the query.

     [EMSGSIZE] 	The hesiod_resolve() or hesiod_to_bind() function
			failed because the query or response was too big to
			fit into the packet buffers.

     [ENOENT]		The hesiod_resolve() function failed because the name
			server had no text records matching name and type, or
			hesiod_to_bind() failed because the name argument had
			a domain extension which could not be resolved with
			type ``rhs-extension'' in the local Hesiod domain.

AUTHORS    [Toc]    [Back]

     Steve Dyer, IBM/Project Athena
     Greg Hudson, MIT Team Athena

     Copyright 1987, 1988, 1995, 1996 by the Massachusetts Institute of Technology.

BUGS    [Toc]    [Back]

     The strings corresponding to the errno values set by the Hesiod functions
     are not particularly indicative of what went wrong, especially for
     ENOEXEC and ENOENT.


FreeBSD 5.2.1		       November 30, 1996		 FreeBSD 5.2.1
[ Back ]
 Similar pages
Name OS Title
hesiod.conf FreeBSD configuration file for the Hesiod library
tclObjSrv IRIX Tcl-library interface to the object server
hesinfo FreeBSD find out what is stored in the Hesiod database
CGI::Push IRIX Simple Interface to Server Push
cdsclerk HP-UX Manages the interface between clients and the CDS server
apachectl OpenBSD Apache HTTP server control interface
ProclaimServerMgr IRIX graphical interface for proclaim server configuration
xjoin Tru64 Graphical user interface program to configure DHCP server
dgld IRIX Graphics Library server
rpccp_unexport HP-UX Removes binding information, interface identifiers, and object UUIDs from a server entry
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service