krb5_free_addresses

Langue: en

Version: 267273 (debian - 07/07/09)

Section: 3 (Bibliothèques de fonctions)


BSD mandoc
HEIMDAL

NAME

krb5_address krb5_addresses krb5_sockaddr2address krb5_sockaddr2port krb5_addr2sockaddr krb5_max_sockaddr_size krb5_sockaddr_uninteresting krb5_h_addr2sockaddr krb5_h_addr2addr krb5_anyaddr krb5_print_address krb5_parse_address krb5_address_order krb5_address_compare krb5_address_search krb5_free_address krb5_free_addresses krb5_copy_address krb5_copy_addresses krb5_append_addresses krb5_make_addrport - mange addresses in Kerberos

LIBRARY

Kerberos 5 Library (libkrb5, -lkrb5)

SYNOPSIS

In krb5.h

Ft krb5_error_code Fo krb5_sockaddr2address Fa krb5_context context Fa const struct sockaddr *sa Fa krb5_address *addr Fc Ft krb5_error_code Fo krb5_sockaddr2port Fa krb5_context context Fa const struct sockaddr *sa Fa int16_t *port Fc Ft krb5_error_code Fo krb5_addr2sockaddr Fa krb5_context context Fa const krb5_address *addr Fa struct sockaddr *sa Fa krb5_socklen_t *sa_size Fa int port Fc Ft size_t Fo krb5_max_sockaddr_size Fa void Fc Ft krb5_boolean Fo krb5_sockaddr_uninteresting Fa const struct sockaddr *sa Fc Ft krb5_error_code Fo krb5_h_addr2sockaddr Fa krb5_context context Fa int af Fa const char *addr Fa struct sockaddr *sa Fa krb5_socklen_t *sa_size Fa int port Fc Ft krb5_error_code Fo krb5_h_addr2addr Fa krb5_context context Fa int af Fa const char *haddr Fa krb5_address *addr Fc Ft krb5_error_code Fo krb5_anyaddr Fa krb5_context context Fa int af Fa struct sockaddr *sa Fa krb5_socklen_t *sa_size Fa int port Fc Ft krb5_error_code Fo krb5_print_address Fa const krb5_address *addr Fa char *str Fa size_t len Fa size_t *ret_len Fc Ft krb5_error_code Fo krb5_parse_address Fa krb5_context context Fa const char *string Fa krb5_addresses *addresses Fc Ft int Fo krb5_address_order Fa krb5_context context Fa const krb5_address *addr1 Fa const krb5_address *addr2 Fc Ft krb5_boolean Fo krb5_address_compare Fa krb5_context context Fa const krb5_address *addr1 Fa const krb5_address *addr2 Fc Ft krb5_boolean Fo krb5_address_search Fa krb5_context context Fa const krb5_address *addr Fa const krb5_addresses *addrlist Fc Ft krb5_error_code Fo krb5_free_address Fa krb5_context context Fa krb5_address *address Fc Ft krb5_error_code Fo krb5_free_addresses Fa krb5_context context Fa krb5_addresses *addresses Fc Ft krb5_error_code Fo krb5_copy_address Fa krb5_context context Fa const krb5_address *inaddr Fa krb5_address *outaddr Fc Ft krb5_error_code Fo krb5_copy_addresses Fa krb5_context context Fa const krb5_addresses *inaddr Fa krb5_addresses *outaddr Fc Ft krb5_error_code Fo krb5_append_addresses Fa krb5_context context Fa krb5_addresses *dest Fa const krb5_addresses *source Fc Ft krb5_error_code Fo krb5_make_addrport Fa krb5_context context Fa krb5_address **res Fa const krb5_address *addr Fa int16_t port Fc  

DESCRIPTION

The krb5_address structure holds a address that can be used in Kerberos API calls. There are help functions to set and extract address information of the address.

The krb5_addresses structure holds a set of krb5_address:es.

Fn krb5_sockaddr2address stores a address a struct sockaddr Fa sa in the krb5_address Fa addr .

Fn krb5_sockaddr2port extracts a Fa port (if possible) from a struct sockaddr Fa sa .

Fn krb5_addr2sockaddr sets the struct sockaddr Fa sockaddr from Fa addr and Fa port . The argument Fa sa_size should initially contain the size of the Fa sa , and after the call, it will contain the actual length of the address.

Fn krb5_max_sockaddr_size returns the max size of the struct sockaddr that the Kerberos library will return.

Fn krb5_sockaddr_uninteresting returns TRUE for all Fa sa that the kerberos library thinks are uninteresting. One example are link local addresses.

Fn krb5_h_addr2sockaddr initializes a struct sockaddr Fa sa from Fa af and the struct hostent (see gethostbyname(3)) Fa h_addr_list component. The argument Fa sa_size should initially contain the size of the Fa sa , and after the call, it will contain the actual length of the address.

Fn krb5_h_addr2addr works like Fn krb5_h_addr2sockaddr with the exception that it operates on a krb5_address instead of a struct sockaddr

Fn krb5_anyaddr fills in a struct sockaddr Fa sa that can be used to bind(2) to. The argument Fa sa_size should initially contain the size of the Fa sa , and after the call, it will contain the actual length of the address.

Fn krb5_print_address prints the address in Fa addr to the string Fa string that have the length Fa len . If Fa ret_len is not NULL it will be filled with the length of the string if size were unlimited (not including the final `\0' ) .

Fn krb5_parse_address Returns the resolved hostname in Fa string to the krb5_addresses Fa addresses .

Fn krb5_address_order compares the addresses Fa addr1 and Fa addr2 so that it can be used for sorting addresses. If the addresses are the same address Fa krb5_address_order will return 0.

Fn krb5_address_compare compares the addresses Fa addr1 and Fa addr2 . Returns TRUE if the two addresses are the same.

Fn krb5_address_search checks if the address Fa addr is a member of the address set list Fa addrlist .

Fn krb5_free_address frees the data stored in the Fa address that is alloced with any of the krb5_address functions.

Fn krb5_free_addresses frees the data stored in the Fa addresses that is alloced with any of the krb5_address functions.

Fn krb5_copy_address copies the content of address Fa inaddr to Fa outaddr .

Fn krb5_copy_addresses copies the content of the address list Fa inaddr to Fa outaddr .

Fn krb5_append_addresses adds the set of addresses in Fa source to Fa dest . While copying the addresses, duplicates are also sorted out.

Fn krb5_make_addrport allocates and creates an krb5_address in Fa res of type KRB5_ADDRESS_ADDRPORT from Fa ( addr , port ) .

SEE ALSO

krb5(3), krb5.conf5, kerberos(8)