00001 /* @file dhcp6_nic.c 00002 * 00003 * Network Interface Configurator for the DHCPv6 IPv6 DHCP client library. 00004 * 00005 */ 00006 /* 00007 * Copyright (C) 2006 Red Hat, Inc. All rights reserved. 00008 * 00009 * This copyrighted material is made available to anyone wishing to use, 00010 * modify, copy, or redistribute it subject to the terms and conditions of 00011 * the GNU General Public License v.2. This program is distributed in the 00012 * hope that it will be useful, but WITHOUT ANY WARRANTY expressed or 00013 * implied, including the implied warranties of MERCHANTABILITY or FITNESS 00014 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more 00015 * details. You should have received a copy of the GNU General Public 00016 * License along with this program; if not, write to the Free Software 00017 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, 00018 * USA. Any Red Hat trademarks that are incorporated in the source code or 00019 * documentation are not subject to the GNU General Public License and may 00020 * only be used or replicated with the express permission of Red Hat, Inc. 00021 * 00022 * Red Hat Author(s): Jason Vas Dias 00023 * David Cantrell 00024 */ 00025 #include <libdhcp.h> 00026 #include <dhcp6_lease.h> 00027 #include <nic.h> 00028 #include <stdarg.h> 00029 00030 /** 00031 * @addtogroup DHCPv6 00032 * @{ 00033 */ 00034 typedef 00035 struct dhcp6_nic_s 00036 { 00037 NLH_t nh; 00038 NIC_t nic; 00039 IPaddr_list_t address_list; 00040 IProute_list_t route_list; 00041 IPaddr_list_t dns_list; 00042 char *search_list; 00043 char *host_name; 00044 DHCPv6_lease *lease; 00045 char *name; 00046 } DHCPv6_nic; 00047 00048 extern 00049 DHCPv6_nic *do_dhcpv6( LIBDHCP_Control *, NLH_t nh, char *if_name ); 00050 00051 extern 00052 DHCPv6_nic *dhcp6_nic_from_lease( LIBDHCP_Control *ctl, NLH_t nh, DHCPv6_lease *lease, NIC_t nic); 00053 00054 extern 00055 int dhcp6_process_lease( LIBDHCP_Control *ctl, DHCPv6_nic *nic ); 00056 00057 extern 00058 NIC_Res_t dhcpv6_nic( DHCPv6_nic* ); 00059 00060 extern 00061 int dhcp6_nic_callback 00062 ( LIBDHCP_Control *control, 00063 DHCP_State state, 00064 void *arg 00065 ); 00066 00067 void dhcpv6_nic_free( DHCPv6_nic* ); 00068 00069 /**@}*/