/usr/share/cagefs-skeleton/usr/include/bind9/isc
/* * Copyright (C) Internet Systems Consortium, Inc. ("ISC") * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, you can obtain one at https://mozilla.org/MPL/2.0/. * * See the COPYRIGHT file distributed with this work for additional * information regarding copyright ownership. */ #ifndef ISC_INTERFACEITER_H #define ISC_INTERFACEITER_H 1 /***** ***** Module Info *****/ /*! \file isc/interfaceiter.h * \brief Iterates over the list of network interfaces. * * Interfaces whose address family is not supported are ignored and never * returned by the iterator. Interfaces whose netmask, interface flags, * or similar cannot be obtained are also ignored, and the failure is logged. * * Standards: * The API for scanning varies greatly among operating systems. * This module attempts to hide the differences. */ /*** *** Imports ***/ #include <inttypes.h> #include <isc/lang.h> #include <isc/netaddr.h> #include <isc/types.h> /*! * \brief Public structure describing a network interface. */ struct isc_interface { char name[32]; /*%< Interface name, null-terminated. */ unsigned int af; /*%< Address family. */ isc_netaddr_t address; /*%< Local address. */ isc_netaddr_t netmask; /*%< Network mask. */ isc_netaddr_t dstaddress; /*%< Destination address * (point-to-point * only). */ uint32_t flags; /*%< Flags; see INTERFACE flags. */ }; /*@{*/ /*! Interface flags. */ #define INTERFACE_F_UP 0x00000001U #define INTERFACE_F_POINTTOPOINT 0x00000002U #define INTERFACE_F_LOOPBACK 0x00000004U /*@}*/ /*** *** Functions ***/ ISC_LANG_BEGINDECLS isc_result_t isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp); /*!< * \brief Create an iterator for traversing the operating system's list * of network interfaces. * * Returns: *\li #ISC_R_SUCCESS * \li #ISC_R_NOMEMORY *\li Various network-related errors */ isc_result_t isc_interfaceiter_first(isc_interfaceiter_t *iter); /*!< * \brief Position the iterator on the first interface. * * Returns: *\li #ISC_R_SUCCESS Success. *\li #ISC_R_NOMORE There are no interfaces. */ isc_result_t isc_interfaceiter_current(isc_interfaceiter_t *iter, isc_interface_t *ifdata); /*!< * \brief Get information about the interface the iterator is currently * positioned at and store it at *ifdata. * * Requires: *\li The iterator has been successfully positioned using * isc_interface_iter_first() / isc_interface_iter_next(). * * Returns: *\li #ISC_R_SUCCESS Success. */ isc_result_t isc_interfaceiter_next(isc_interfaceiter_t *iter); /*!< * \brief Position the iterator on the next interface. * * Requires: * \li The iterator has been successfully positioned using * isc_interface_iter_first() / isc_interface_iter_next(). * * Returns: *\li #ISC_R_SUCCESS Success. *\li #ISC_R_NOMORE There are no more interfaces. */ void isc_interfaceiter_destroy(isc_interfaceiter_t **iterp); /*!< * \brief Destroy the iterator. */ ISC_LANG_ENDDECLS #endif /* ISC_INTERFACEITER_H */
.
Edit
..
Edit
aes.h
Edit
align.h
Edit
app.h
Edit
assertions.h
Edit
astack.h
Edit
atomic.h
Edit
backtrace.h
Edit
barrier.h
Edit
base32.h
Edit
base64.h
Edit
bind9.h
Edit
buffer.h
Edit
bufferlist.h
Edit
cmocka.h
Edit
commandline.h
Edit
condition.h
Edit
counter.h
Edit
crc64.h
Edit
deprecated.h
Edit
dir.h
Edit
endian.h
Edit
errno.h
Edit
errno2result.h
Edit
error.h
Edit
event.h
Edit
eventclass.h
Edit
file.h
Edit
formatcheck.h
Edit
fsaccess.h
Edit
fuzz.h
Edit
hash.h
Edit
heap.h
Edit
hex.h
Edit
hmac.h
Edit
hp.h
Edit
ht.h
Edit
httpd.h
Edit
interfaceiter.h
Edit
iterated_hash.h
Edit
lang.h
Edit
lex.h
Edit
lfsr.h
Edit
lib.h
Edit
likely.h
Edit
list.h
Edit
log.h
Edit
magic.h
Edit
managers.h
Edit
md.h
Edit
mem.h
Edit
meminfo.h
Edit
mutex.h
Edit
mutexatomic.h
Edit
mutexblock.h
Edit
net.h
Edit
netaddr.h
Edit
netdb.h
Edit
netmgr.h
Edit
netscope.h
Edit
nonce.h
Edit
offset.h
Edit
once.h
Edit
os.h
Edit
parseint.h
Edit
platform.h
Edit
pool.h
Edit
portset.h
Edit
print.h
Edit
queue.h
Edit
quota.h
Edit
radix.h
Edit
random.h
Edit
ratelimiter.h
Edit
refcount.h
Edit
regex.h
Edit
region.h
Edit
resource.h
Edit
result.h
Edit
resultclass.h
Edit
rwlock.h
Edit
safe.h
Edit
serial.h
Edit
siphash.h
Edit
sockaddr.h
Edit
socket.h
Edit
stat.h
Edit
stats.h
Edit
stdatomic.h
Edit
stdio.h
Edit
stdtime.h
Edit
strerr.h
Edit
string.h
Edit
symtab.h
Edit
syslog.h
Edit
task.h
Edit
taskpool.h
Edit
thread.h
Edit
time.h
Edit
timer.h
Edit
tm.h
Edit
types.h
Edit
url.h
Edit
utf8.h
Edit
util.h
Edit
version.h
Edit