1.\" Copyright (c) 2001 Kungliga Tekniska H�gskolan
| 1.\" Copyright (c) 2001 Kungliga Tekniska H�gskolan
|
2.\" $Id: krb5_get_krbhst.3,v 1.4 2002/08/28 15:30:53 joda Exp $
| 2.\" (Royal Institute of Technology, Stockholm, Sweden). 3.\" All rights reserved. 4.\" 5.\" Redistribution and use in source and binary forms, with or without 6.\" modification, are permitted provided that the following conditions 7.\" are met: 8.\" 9.\" 1. Redistributions of source code must retain the above copyright 10.\" notice, this list of conditions and the following disclaimer. 11.\" 12.\" 2. Redistributions in binary form must reproduce the above copyright 13.\" notice, this list of conditions and the following disclaimer in the 14.\" documentation and/or other materials provided with the distribution. 15.\" 16.\" 3. Neither the name of the Institute nor the names of its contributors 17.\" may be used to endorse or promote products derived from this software 18.\" without specific prior written permission. 19.\" 20.\" THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND 21.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 22.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 23.\" ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE 24.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30.\" SUCH DAMAGE. 31.\" 32.\" $Id: krb5_get_krbhst.3,v 1.6 2003/04/16 13:58:16 lha Exp $ 33.\"
|
3.Dd June 17, 2001 4.Dt KRB5_GET_KRBHST 3 5.Os HEIMDAL 6.Sh NAME 7.Nm krb5_get_krbhst 8.Nm krb5_get_krb_admin_hst 9.Nm krb5_get_krb_changepw_hst 10.Nm krb5_get_krb524hst 11.Nm krb5_free_krbhst 12.Nd lookup Kerberos KDC hosts 13.Sh LIBRARY 14Kerberos 5 Library (libkrb5, -lkrb5) 15.Sh SYNOPSIS
| 34.Dd June 17, 2001 35.Dt KRB5_GET_KRBHST 3 36.Os HEIMDAL 37.Sh NAME 38.Nm krb5_get_krbhst 39.Nm krb5_get_krb_admin_hst 40.Nm krb5_get_krb_changepw_hst 41.Nm krb5_get_krb524hst 42.Nm krb5_free_krbhst 43.Nd lookup Kerberos KDC hosts 44.Sh LIBRARY 45Kerberos 5 Library (libkrb5, -lkrb5) 46.Sh SYNOPSIS
|
16.Fd #include <krb5.h>
| 47.In krb5.h
|
17.Ft krb5_error_code 18.Fn krb5_get_krbhst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 19.Ft krb5_error_code 20.Fn krb5_get_krb_admin_hst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 21.Ft krb5_error_code 22.Fn krb5_get_krb_changepw_hst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 23.Ft krb5_error_code 24.Fn krb5_get_krb524hst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 25.Ft krb5_error_code 26.Fn krb5_free_krbhst "krb5_context context" "char **hostlist" 27.Sh DESCRIPTION 28These functions implement the old API to get a list of Kerberos hosts, 29and are thus similar to the 30.Fn krb5_krbhst_init 31functions. However, since these functions returns 32.Em all 33hosts in one go, they potentially have to do more lookups than 34necessary. These functions remain for compatibility reasons. 35.Pp 36After a call to one of these functions, 37.Fa hostlist 38is a 39.Dv NULL 40terminated list of strings, pointing to the requested Kerberos hosts. These should be freed with 41.Fn krb5_free_krbhst 42when done with. 43.Sh EXAMPLE 44The following code will print the KDCs of the realm 45.Dq MY.REALM . 46.Bd -literal -offset indent 47char **hosts, **p; 48krb5_get_krbhst(context, "MY.REALM", &hosts); 49for(p = hosts; *p; p++) 50 printf("%s\\n", *p); 51krb5_free_krbhst(context, hosts); 52.Ed 53.\" .Sh BUGS 54.Sh SEE ALSO 55.Xr krb5_krbhst_init 3
| 48.Ft krb5_error_code 49.Fn krb5_get_krbhst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 50.Ft krb5_error_code 51.Fn krb5_get_krb_admin_hst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 52.Ft krb5_error_code 53.Fn krb5_get_krb_changepw_hst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 54.Ft krb5_error_code 55.Fn krb5_get_krb524hst "krb5_context context" "const krb5_realm *realm" "char ***hostlist" 56.Ft krb5_error_code 57.Fn krb5_free_krbhst "krb5_context context" "char **hostlist" 58.Sh DESCRIPTION 59These functions implement the old API to get a list of Kerberos hosts, 60and are thus similar to the 61.Fn krb5_krbhst_init 62functions. However, since these functions returns 63.Em all 64hosts in one go, they potentially have to do more lookups than 65necessary. These functions remain for compatibility reasons. 66.Pp 67After a call to one of these functions, 68.Fa hostlist 69is a 70.Dv NULL 71terminated list of strings, pointing to the requested Kerberos hosts. These should be freed with 72.Fn krb5_free_krbhst 73when done with. 74.Sh EXAMPLE 75The following code will print the KDCs of the realm 76.Dq MY.REALM . 77.Bd -literal -offset indent 78char **hosts, **p; 79krb5_get_krbhst(context, "MY.REALM", &hosts); 80for(p = hosts; *p; p++) 81 printf("%s\\n", *p); 82krb5_free_krbhst(context, hosts); 83.Ed 84.\" .Sh BUGS 85.Sh SEE ALSO 86.Xr krb5_krbhst_init 3
|