rc_get_srcaddr(3) Radius client library rc_get_srcaddr(3)

rc_get_srcaddr - Find outbound interface address for a given destination.

#include <radcli/>

int rc_get_srcaddr(
    struct sockaddr        *lia,
    const struct sockaddr  *ria
);

Given remote address find local address which the system will use as a source address for sending datagrams to that remote address.

local address.
the remote address.

OK_RC on success. NETUNREACH_RC if network is unreachable (i.e. no route to destination). ERROR_RC for all other failures. Address is filled into the first argument.

rc_getport(3), rc_openlog(3), rc_own_hostname(3), rc_setdebug(3)

2026-08-19 radcli