Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 1 | # |
| 2 | # For a description of the syntax of this configuration file, |
Kartik Agaram | 43b17b1 | 2018-05-31 22:15:55 -0700 | [diff] [blame] | 3 | # see docs/Kconfig-language.txt. |
Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 4 | # |
| 5 | |
Denys Vlasenko | 4662de0 | 2009-12-11 02:21:10 +0100 | [diff] [blame] | 6 | config UDHCPD |
Denys Vlasenko | 83e7e13 | 2018-12-28 13:03:48 +0100 | [diff] [blame] | 7 | bool "udhcpd (21 kb)" |
Denys Vlasenko | 2f32bf8 | 2010-06-06 04:14:28 +0200 | [diff] [blame] | 8 | default y |
Samuel Thibault | 77216c3 | 2022-10-16 02:04:59 +0200 | [diff] [blame^] | 9 | select PLATFORM_LINUX |
Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 10 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 11 | udhcpd is a DHCP server geared primarily toward embedded systems, |
| 12 | while striving to be fully functional and RFC compliant. |
Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 13 | |
Vladislav Grishenko | 5827167 | 2011-02-16 13:31:30 +0100 | [diff] [blame] | 14 | config FEATURE_UDHCPD_BASE_IP_ON_MAC |
| 15 | bool "Select IP address based on client MAC" |
| 16 | default n |
| 17 | depends on UDHCPD |
| 18 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 19 | If selected, udhcpd will base its selection of IP address to offer |
| 20 | on the client's hardware address. Otherwise udhcpd uses the next |
| 21 | consecutive free address. |
Vladislav Grishenko | 5827167 | 2011-02-16 13:31:30 +0100 | [diff] [blame] | 22 | |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 23 | This reduces the frequency of IP address changes for clients |
| 24 | which let their lease expire, and makes consecutive DHCPOFFERS |
| 25 | for the same client to (almost always) contain the same |
| 26 | IP address. |
Denis Vlasenko | c82b510 | 2007-07-01 17:05:57 +0000 | [diff] [blame] | 27 | |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 28 | config FEATURE_UDHCPD_WRITE_LEASES_EARLY |
| 29 | bool "Rewrite lease file at every new acknowledge" |
| 30 | default y |
| 31 | depends on UDHCPD |
| 32 | help |
| 33 | If selected, udhcpd will write a new file with leases every |
| 34 | time a new lease has been accepted, thus eliminating the need |
| 35 | to send SIGUSR1 for the initial writing or updating. Any timed |
| 36 | rewriting remains undisturbed. |
| 37 | |
Denis Vlasenko | 84da0bf | 2008-02-20 22:29:52 +0000 | [diff] [blame] | 38 | config DHCPD_LEASES_FILE |
| 39 | string "Absolute path to lease file" |
| 40 | default "/var/lib/misc/udhcpd.leases" |
Denys Vlasenko | 4662de0 | 2009-12-11 02:21:10 +0100 | [diff] [blame] | 41 | depends on UDHCPD |
Denis Vlasenko | 84da0bf | 2008-02-20 22:29:52 +0000 | [diff] [blame] | 42 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 43 | udhcpd stores addresses in a lease file. This is the absolute path |
| 44 | of the file. Normally it is safe to leave it untouched. |
Denis Vlasenko | 84da0bf | 2008-02-20 22:29:52 +0000 | [diff] [blame] | 45 | |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 46 | config DUMPLEASES |
Denys Vlasenko | 83e7e13 | 2018-12-28 13:03:48 +0100 | [diff] [blame] | 47 | bool "dumpleases (5.1 kb)" |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 48 | default y |
| 49 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 50 | dumpleases displays the leases written out by the udhcpd. |
| 51 | Lease times are stored in the file by time remaining in lease, or |
| 52 | by the absolute time that it expires in seconds from epoch. |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 53 | |
| 54 | config DHCPRELAY |
Denys Vlasenko | 83e7e13 | 2018-12-28 13:03:48 +0100 | [diff] [blame] | 55 | bool "dhcprelay (5.2 kb)" |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 56 | default y |
Samuel Thibault | 77216c3 | 2022-10-16 02:04:59 +0200 | [diff] [blame^] | 57 | select PLATFORM_LINUX |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 58 | help |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 59 | dhcprelay listens for DHCP requests on one or more interfaces |
| 60 | and forwards these requests to a different interface or DHCP |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 61 | server. |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 62 | |
Denys Vlasenko | 4662de0 | 2009-12-11 02:21:10 +0100 | [diff] [blame] | 63 | config UDHCPC |
Denys Vlasenko | df1ff10 | 2018-12-28 13:37:44 +0100 | [diff] [blame] | 64 | bool "udhcpc (24 kb)" |
Denys Vlasenko | 2f32bf8 | 2010-06-06 04:14:28 +0200 | [diff] [blame] | 65 | default y |
Samuel Thibault | 77216c3 | 2022-10-16 02:04:59 +0200 | [diff] [blame^] | 66 | select PLATFORM_LINUX |
Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 67 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 68 | udhcpc is a DHCP client geared primarily toward embedded systems, |
| 69 | while striving to be fully functional and RFC compliant. |
Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 70 | |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 71 | The udhcp client negotiates a lease with the DHCP server and |
| 72 | runs a script when a lease is obtained or lost. |
Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 73 | |
Denis Vlasenko | 223bc97 | 2007-11-22 00:58:49 +0000 | [diff] [blame] | 74 | config FEATURE_UDHCPC_ARPING |
Denis Vlasenko | a4a93fd | 2008-04-21 20:27:29 +0000 | [diff] [blame] | 75 | bool "Verify that the offered address is free, using ARP ping" |
Denis Vlasenko | 223bc97 | 2007-11-22 00:58:49 +0000 | [diff] [blame] | 76 | default y |
Denys Vlasenko | 4662de0 | 2009-12-11 02:21:10 +0100 | [diff] [blame] | 77 | depends on UDHCPC |
Denis Vlasenko | 223bc97 | 2007-11-22 00:58:49 +0000 | [diff] [blame] | 78 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 79 | If selected, udhcpc will send ARP probes and make sure |
| 80 | the offered address is really not in use by anyone. The client |
| 81 | will DHCPDECLINE the offer if the address is in use, |
| 82 | and restart the discover process. |
Denis Vlasenko | 223bc97 | 2007-11-22 00:58:49 +0000 | [diff] [blame] | 83 | |
Denys Vlasenko | 85090c1 | 2014-06-16 00:17:00 +0200 | [diff] [blame] | 84 | config FEATURE_UDHCPC_SANITIZEOPT |
| 85 | bool "Do not pass malformed host and domain names" |
| 86 | default y |
| 87 | depends on UDHCPC |
| 88 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 89 | If selected, udhcpc will check some options (such as option 12 - |
| 90 | hostname) and if they don't look like valid hostnames |
| 91 | (for example, if they start with dash or contain spaces), |
| 92 | they will be replaced with string "bad" when exporting |
| 93 | to the environment. |
Denys Vlasenko | 85090c1 | 2014-06-16 00:17:00 +0200 | [diff] [blame] | 94 | |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 95 | config UDHCPC_DEFAULT_SCRIPT |
| 96 | string "Absolute path to config script" |
| 97 | default "/usr/share/udhcpc/default.script" |
Denys Vlasenko | 64211ce | 2018-01-16 22:23:38 +0100 | [diff] [blame] | 98 | depends on UDHCPC || UDHCPC6 |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 99 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 100 | This script is called after udhcpc receives an answer. See |
| 101 | examples/udhcp for a working example. Normally it is safe |
| 102 | to leave this untouched. |
Denys Vlasenko | c6137ba | 2017-01-04 12:13:38 +0100 | [diff] [blame] | 103 | |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 104 | # udhcpc6 config is inserted here: |
| 105 | INSERT |
| 106 | |
| 107 | comment "Common options for DHCP applets" |
| 108 | depends on UDHCPD || UDHCPC || UDHCPC6 || DHCPRELAY |
| 109 | |
Andre Kalb | 5f2e00f | 2020-05-05 18:24:25 +0200 | [diff] [blame] | 110 | config UDHCPC_DEFAULT_INTERFACE |
| 111 | string "Default interface name" |
| 112 | default "eth0" |
| 113 | depends on UDHCPC || UDHCPC6 |
| 114 | help |
| 115 | The interface that will be used if no other interface is |
| 116 | specified on the commandline. |
| 117 | |
Denis Vlasenko | d55fe3e | 2008-02-04 13:12:16 +0000 | [diff] [blame] | 118 | config FEATURE_UDHCP_PORT |
| 119 | bool "Enable '-P port' option for udhcpd and udhcpc" |
Vladislav Grishenko | 5827167 | 2011-02-16 13:31:30 +0100 | [diff] [blame] | 120 | default n |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 121 | depends on UDHCPD || UDHCPC || UDHCPC6 |
Denis Vlasenko | d55fe3e | 2008-02-04 13:12:16 +0000 | [diff] [blame] | 122 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 123 | At the cost of ~300 bytes, enables -P port option. |
| 124 | This feature is typically not needed. |
Denis Vlasenko | 223bc97 | 2007-11-22 00:58:49 +0000 | [diff] [blame] | 125 | |
Denis Vlasenko | 35a064b | 2008-11-06 00:49:59 +0000 | [diff] [blame] | 126 | config UDHCP_DEBUG |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 127 | int "Maximum verbosity level (0..9)" |
Denys Vlasenko | 6eb6e6a | 2019-05-31 23:51:07 +0200 | [diff] [blame] | 128 | default 2 |
Denys Vlasenko | 7a76eba | 2009-06-19 13:51:29 +0200 | [diff] [blame] | 129 | range 0 9 |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 130 | depends on UDHCPD || UDHCPC || UDHCPC6 || DHCPRELAY |
Mike Frysinger | 7031f62 | 2006-05-08 03:20:50 +0000 | [diff] [blame] | 131 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 132 | Verbosity can be increased with multiple -v options. |
| 133 | This option controls how high it can be cranked up. |
Denys Vlasenko | ac906fa | 2009-06-17 11:54:52 +0200 | [diff] [blame] | 134 | |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 135 | Bigger values result in bigger code. Levels above 1 |
| 136 | are very verbose and useful for debugging only. |
Denis Vlasenko | 5066473 | 2007-02-27 21:15:08 +0000 | [diff] [blame] | 137 | |
Denis Vlasenko | 72e7604 | 2007-11-25 03:15:24 +0000 | [diff] [blame] | 138 | config UDHCPC_SLACK_FOR_BUGGY_SERVERS |
| 139 | int "DHCP options slack buffer size" |
| 140 | default 80 |
| 141 | range 0 924 |
Denys Vlasenko | 4662de0 | 2009-12-11 02:21:10 +0100 | [diff] [blame] | 142 | depends on UDHCPD || UDHCPC |
Denis Vlasenko | 72e7604 | 2007-11-25 03:15:24 +0000 | [diff] [blame] | 143 | help |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 144 | Some buggy DHCP servers send DHCP offer packets with option |
| 145 | field larger than we expect (which might also be considered a |
| 146 | buffer overflow attempt). These packets are normally discarded. |
| 147 | If circumstances beyond your control force you to support such |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 148 | servers, this may help. The upper limit (924) makes udhcpc accept |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 149 | even 1500 byte packets (maximum-sized ethernet packets). |
Denis Vlasenko | 72e7604 | 2007-11-25 03:15:24 +0000 | [diff] [blame] | 150 | |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 151 | This option does not make udhcp[cd] emit non-standard |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 152 | sized packets. |
Denis Vlasenko | 72e7604 | 2007-11-25 03:15:24 +0000 | [diff] [blame] | 153 | |
Denys Vlasenko | 72089cf | 2017-07-21 09:50:55 +0200 | [diff] [blame] | 154 | Known buggy DHCP servers: |
| 155 | 3Com OfficeConnect Remote 812 ADSL Router: |
| 156 | seems to confuse maximum allowed UDP packet size with |
| 157 | maximum size of entire IP packet, and sends packets |
| 158 | which are 28 bytes too large. |
| 159 | Seednet (ISP) VDSL: sends packets 2 bytes too large. |
Denys Vlasenko | 68b653b | 2017-07-27 10:53:09 +0200 | [diff] [blame] | 160 | |
| 161 | config FEATURE_UDHCP_RFC3397 |
| 162 | bool "Support RFC 3397 domain search options" |
| 163 | default y |
| 164 | depends on UDHCPD || UDHCPC |
| 165 | help |
| 166 | If selected, both client and server will support passing of domain |
| 167 | search lists via option 119, specified in RFC 3397, |
| 168 | and SIP servers option 120, specified in RFC 3361. |
| 169 | |
| 170 | config FEATURE_UDHCP_8021Q |
| 171 | bool "Support 802.1Q VLAN parameters options" |
| 172 | default y |
| 173 | depends on UDHCPD || UDHCPC |
| 174 | help |
| 175 | If selected, both client and server will support passing of VLAN |
| 176 | ID and priority via options 132 and 133 as per 802.1Q. |