1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
|
NAME(3) BSD Library Functions Manual NAME(3)
NNAAMMEE
kkrrbb55__ggeettppoorrttbbyynnaammee -- get port number by name
LLIIBBRRAARRYY
Kerberos 5 Library (libkrb5, -lkrb5)
SSYYNNOOPPSSIISS
##iinncclluuddee <<kkrrbb55..hh>>
_i_n_t
kkrrbb55__ggeettppoorrttbbyynnaammee(_k_r_b_5___c_o_n_t_e_x_t _c_o_n_t_e_x_t, _c_o_n_s_t _c_h_a_r _*_s_e_r_v_i_c_e,
_c_o_n_s_t _c_h_a_r _*_p_r_o_t_o, _i_n_t _d_e_f_a_u_l_t___p_o_r_t);
DDEESSCCRRIIPPTTIIOONN
kkrrbb55__ggeettppoorrttbbyynnaammee() gets the port number for _s_e_r_v_i_c_e _/ _p_r_o_t_o pair from
the global service table for and returns it in network order. If it
isn't found in the global table, the _d_e_f_a_u_l_t___p_o_r_t (given in host order)
is returned.
EEXXAAMMPPLLEE
int port = krb5_getportbyname(context, "kerberos", "tcp", 88);
SSEEEE AALLSSOO
krb5(3)
HEIMDAL August 15, 2004 HEIMDAL
|