• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-12-stable/contrib/ntp/ntpd/

Lines Matching refs:interface

148  * an indication of the source host and the interface it was received
164 volatile u_long packets_ignored; /* packets received on wild card interface */
176 endpt * any_interface; /* wildcard ipv4 interface */
177 endpt * any6_interface; /* wildcard ipv6 interface */
178 endpt * loopback_interface; /* loopback ipv4 interface */
283 static isc_boolean_t socket_broadcast_enable (struct interface *, SOCKET, sockaddr_u *);
289 static isc_boolean_t socket_broadcast_disable (struct interface *, sockaddr_u *);
340 static inline int read_network_packet (SOCKET, struct interface *, l_fp);
417 * to bind to to the interface address on NTP_PORT so that
421 * the interface in order to quickly re-assign the peers to
422 * new interface in case an interface is deleted (=> gone from system or
428 * - facilitate updating the internal interface list with respect to
433 * - mapping of multicast addresses to the interface affected is not always
435 * the code here currently allocates a separate interface entry for those
438 * in case of failure the multicast address is bound to an existing interface.
456 /* update interface every 5 minutes as default */
517 * function to dump the contents of the interface structure
527 printf("Dumping interface: %p\n", itf);
728 * interface list enumerator - visitor pattern
744 * do standard initialization of interface structure
759 * create new interface structure initialize from
763 static struct interface *
765 struct interface *interface
768 struct interface * iface;
772 if (NULL == interface)
775 memcpy(iface, interface, sizeof(*iface));
777 /* count every new instance of an interface in the system */
783 msyslog(LOG_EMERG, "cannot register interface with IO engine -- will exit now");
792 * return interface storage into free memory pool
807 * link interface into list of known interfaces
864 * interface, and some are link- or site-local, do not multicast
870 * prefix on the same network interface, multicast from one,
979 * remove interface from known interface list and clean up
1010 "Deleting interface #%d %s, %s#%d, interface stats: received=%ld, sent=%ld, dropped=%ld, active_time=%ld secs",
1028 "stop listening for broadcasts to %s on interface #%d %s",
1043 /* remove restrict interface entry */
1076 struct interface * wildif;
1089 * create pseudo-interface with wildcard IPv6 address
1100 /* check for interface/nic rules affecting the wildcard */
1135 * create pseudo-interface with wildcard IPv4 address
1144 /* check for interface/nic rules affecting the wildcard */
1193 const char * if_name, /* interface name or numeric address */
1267 DPRINTF(4, ("interface_action: interface %s ",
1274 * Find any matching NIC rule from --interface / -I or ntp.conf
1275 * interface/nic rules.
1340 DPRINTF(4, ("interface name match - %s\n",
1370 * Check for "virtual IP" (colon in the interface name) after
1371 * the rules so that "ntpd --interface eth0:1 -novirtualips"
1382 * If there are no --interface/-I command-line options and no
1383 * interface/nic rules in ntp.conf, the default action is to
1386 * every default with no interface listen configuration, and
1483 struct interface * interface
1487 if (interface->fd != INVALID_SOCKET) {
1488 int bcast = (interface->flags & INT_BCASTXMIT) != 0;
1492 socket_broadcast_disable(interface, &interface->sin);
1494 close_and_delete_fd_from_list(interface->fd);
1498 interface->fd = open_socket(&interface->sin,
1499 bcast, 0, interface);
1504 interface->last_ttl = 0;
1505 return (interface->fd != INVALID_SOCKET);
1509 return (interface->fd != INVALID_SOCKET);
1534 msyslog(LOG_DEBUG, "new interface(s) found: waking up resolver");
1594 struct interface *any;
1731 * attempt to create a new interface entry
1735 * if interface does not match configuration phase (not seen in phase 1):
1736 * remove interface from known interface list
1737 * forall peers associated with this interface
1738 * disconnect peer from this interface
1779 * Toggle system interface scan phase to find untouched
1810 * Check if and how we are going to use the interface.
1816 DPRINTF(4, ("ignoring interface %s (%s) - by nic rules\n",
1821 DPRINTF(4, ("listen interface %s (%s) - by nic rules\n",
1827 DPRINTF(4, ("drop on interface %s (%s) - by nic rules\n",
1835 DPRINTF(4, ("skipping interface %s (%s) - DOWN\n",
1861 * (interface name, ip-address).
1867 * found existing and up to date interface -
1873 * the interface name shows up again if
1884 /* name collision - rename interface */
1896 * for the interface address. This is
1898 * for an interface that shares its
1907 * filtering via interface name is
1912 * interface address where the conflict
1932 * our interface list. If refreshing failed we
1933 * will delete the interface structure in phase
1934 * 2 as the interface was not marked current.
1956 "failed to init interface for address %s",
1973 * if phase does not match sys_phase this interface was
1974 * not enumerated during the last interface scan - so it
1976 * originate from interface enumeration (INT_WILDCARD,
1998 * a loopback interface
2028 /* Find remote address that was linked to this interface */
2050 * create_sockets - create a socket for each interface plus a default
2084 * create_interface - create a new interface for a given prototype
2087 static struct interface *
2090 struct interface * protot
2102 /* build an interface */
2138 * loopback interface of the appropriate class
2145 * put into our interface list
2266 struct interface * iface,
2283 struct interface * iface,
2292 /* if this interface can support broadcast, set SO_BROADCAST */
2317 struct interface * iface,
2378 * Multicast servers need to set the appropriate Multicast interface
2379 * socket option in order for it to know which interface to use for
2384 struct interface * iface,
2489 * interface index from the scope id. Don't do this
2501 "setsockopt IPV6_JOIN_GROUP failed: %m on socket %d, addr %s for interface %u (%s)",
2506 DPRINTF(4, ("Added IPv6 multicast group on socket %d, addr %s for interface %u (%s)\n",
2529 struct interface * iface,
2568 * interface index from the scope id. Don't do this
2629 /* Need a broadcast-capable interface */
2654 * broadcast on the interface address
2660 "Listen for broadcasts to %s on interface #%d %s",
2684 "failed to listen for broadcasts to %s on interface #%d %s",
2727 "stop listening for broadcasts to %s on interface #%d %s",
2791 /* bind failed, re-use wildcard interface */
2806 "multicast address %s using wildcard interface #%d %s",
2942 * number on each interface according to turn_off_reuse.
3135 struct interface * ep,
3162 DPRINTF(2, ("%ssendpkt(dst=%s, ttl=%d, len=%d): no interface - IGNORED\n",
3279 * Routine to read the refclock packets for a specific interface
3474 * Routine to read the network NTP packets for a specific interface
3481 struct interface * itf,
3570 msyslog(LOG_ERR, "recvfrom(%s) fd=%d: refclock srcadr on a network interface!",
3922 * find an interface suitable for the src address
3938 * Initialize the peer structure and dance the interface jig.
3940 * squaredance around the interface list looking for a buddy. If
3941 * the dance peters out, there is always the wildcard interface.
3951 DPRINTF(4, ("Found *-cast interface %s for address %s\n",
3963 * it. For unicast, we get to find the interface when dstadr is
3986 * findinterface - find local interface corresponding to address
3998 DPRINTF(4, ("Found no interface for address %s - returning wildcard\n",
4003 DPRINTF(4, ("Found interface #%d %s for address %s\n",
4010 * findlocalinterface - find local interface corresponding to addr,
4038 DPRINTF(4, ("Finding interface for addr %s in list of addresses\n",
4057 * If we are looking for broadcast interface we need to set this
4100 /* Don't use an interface which will ignore replies */
4111 * If there are -I/--interface or -L/novirtualips command-line options,
4112 * or "nic" or "interface" rules in ntp.conf, findlocalinterface() may
4255 * fetch an interface structure the matches the
4276 * findbcastinter - find broadcast interface corresponding to address
4287 DPRINTF(4, ("Finding broadcast/multicast interface for addr %s in list of addresses\n",
4293 DPRINTF(4, ("Easily found bcast-/mcast- interface index #%d %s\n",
4322 * this interface is one...
4329 * an interface to use for link-local multicast
4366 DPRINTF(4, ("No bcast interface found for %s\n",
4370 DPRINTF(4, ("Found bcast-/mcast- interface index #%d %s\n",
4631 DPRINTF(4, ("Deleted addr %s for interface #%d %s from list of addresses\n",
4639 static struct interface *
4813 * if an interface goes up and down or routing
4816 DPRINTF(3, ("routing message op = %d: scheduling interface update\n",
4851 "unable to open routing socket (%m) - using polled interface update");
4865 "bind failed on routing socket (%m) - using polled interface update");
4881 "Listening on routing socket on fd #%d for interface updates",