krb5_getportbyname(3)

krb5_getportbyname3

Get port number by name

Usage

#include <krb5.h>

int

krb5_getportbyname(krb5_context context, const char *service, const char *proto, int default_port);

Library

Kerberos 5 Library (libkrb5, -lkrb5)

Overview

krb5_getportbyname() gets the port number for service, / proto pair from the global service table for and returns it in network order. If it isn't found in the global table, the default_port (given in host order) is returned.

Examples

int port = krb5_getportbyname(context, "kerberos", "tcp", 88);

Releases

10 releases since Debian 4.0 (Etch); the text changed 2 times.

  1. 4.0
  2. 5.0
  3. 6.0–13

From heimdal-dev 7.8.git20221117.28daf24+dfsg-9+deb13u1 in Debian 13 (Trixie). Parsed by carta from the page's mdoc source.