aboutsummaryrefslogtreecommitdiff
path: root/networking/udhcp/options.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* udhcp: move options.c to common.c; disable unused bool and s16 option codeDenys Vlasenko2010-03-261-262/+0
| | | | | | | | | | | | | | | | | function old new delta udhcp_add_binary_option - 94 +94 udhcp_str2nip - 42 +42 len_of_option_as_string 12 10 -2 dhcp_option_lengths 12 10 -2 udhcpc_main 2859 2851 -8 read_nip 42 - -42 xmalloc_optname_optval 590 536 -54 udhcp_str2optset 443 366 -77 udhcp_add_option_string 86 - -86 ------------------------------------------------------------------------------ (add/remove: 2/2 grow/shrink: 0/5 up/down: 136/-271) Total: -135 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcpc: add -x OPT:VAL optionDenys Vlasenko2010-03-251-4/+6
| | | | | | | | | | | | | | | | | function old new delta udhcp_str2optset - 443 +443 add_client_options - 160 +160 udhcpc_main 2753 2857 +104 packed_usage 26670 26689 +19 attach_option 380 385 +5 udhcpd_main 1964 1965 +1 udhcp_add_option_string 94 86 -8 add_param_req_option 128 - -128 read_opt 443 - -443 ------------------------------------------------------------------------------ (add/remove: 2/2 grow/shrink: 4/1 up/down: 732/-579) Total: 153 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcp: merge options.h into common.h, script.c into dhcpc.cDenys Vlasenko2010-03-221-14/+7
| | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcpd: untangle incredibly messy handling of DHCPREQUESTDenys Vlasenko2010-03-211-1/+1
| | | | | | | | | | | | | | Also fixes attacks possible via DHCPDECLINE / DHCPRELEASE function old new delta udhcpd_main 1846 1949 +103 send_renew 105 142 +37 send_NAK 61 - -61 send_ACK 180 - -180 ------------------------------------------------------------------------------ (add/remove: 0/2 grow/shrink: 2/0 up/down: 140/-241) Total: -101 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcp: code shrink; disable time and log server optionsDenys Vlasenko2010-03-211-32/+32
| | | | | | | | | | | | | | | | | | | function old new delta add_server_options - 100 +100 udhcp_add_simple_option 92 90 -2 nobody_responds_to_arp 88 85 -3 dhcp_options 66 62 -4 udhcp_add_option_string 104 94 -10 udhcp_run_script 665 654 -11 dhcp_option_strings 203 188 -15 static.blank_chaddr 16 - -16 send_ACK 211 180 -31 add_bootp_options 61 - -61 udhcpd_main 1925 1846 -79 ------------------------------------------------------------------------------ (add/remove: 1/2 grow/shrink: 0/8 up/down: 100/-232) Total: -132 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcpc: make it possible to disable vendor id; improve help textDenys Vlasenko2010-03-201-0/+1
| | | | | | | | | | | | function old new delta init_packet 135 139 +4 packed_usage 26789 26786 -3 alloc_dhcp_option 67 63 -4 udhcpc_main 2467 2447 -20 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/3 up/down: 4/-27) Total: -23 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcpd: remove five more options which do not make sense or not supportedDenys Vlasenko2010-03-201-14/+20
| | | | | | | | | | | | | | | | requestip, vendorclass, clientid are client-side variables, they do not make sense as udhcpd opts dhcptype is the packet type (not interesting, it's always 5) userclass needs parser support in order to work function old new delta dhcp_options 68 66 -2 read_opt 865 859 -6 dhcp_option_strings 253 203 -50 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 0/3 up/down: 0/-58) Total: -58 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcp: remove support for some really old and odd optionsDenys Vlasenko2010-03-191-6/+6
| | | | | | | | function old new delta dhcp_options 72 68 -4 dhcp_option_strings 271 253 -18 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* *: use "can't" instead of "cannot"Denys Vlasenko2009-11-131-1/+1
| | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* more C standard compat fixes from Dan FandrichDenys Vlasenko2009-09-061-1/+1
| | | | | | | function old new delta docolon 207 204 -3 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcpc: support option 0x79 (static routes) (part of bug 341)Denys Vlasenko2009-07-031-0/+4
| | | | | | | | | | | | | | function old new delta xmalloc_optname_optval - 583 +583 dhcp_option_strings 258 266 +8 dhcp_options 70 72 +2 len_of_option_as_string 11 12 +1 dhcp_option_lengths 11 12 +1 udhcp_run_script 1187 669 -518 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 4/1 up/down: 595/-518) Total: 77 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcp: dname_dec may return NULL, account for that caseDenys Vlasenko2009-07-031-1/+1
| | | | | | Other random cleanips included... Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcp: logging improvements, field and variable renamesDenys Vlasenko2009-06-171-6/+16
| | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcp: shorten mac len from 16 to 6 in lease fileDenys Vlasenko2009-06-171-3/+12
| | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* udhcp: change UDHCP_DEBUG into int, make verbosity selectable with -vDenys Vlasenko2009-06-171-1/+1
| | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* dhcpd: remember and record hostnames; optimize get_optionDenis Vlasenko2009-04-011-47/+49
| | | | | | | | | | | | | | | | | dumpleases: show hostnames function old new delta add_lease 230 292 +62 send_offer 403 421 +18 send_ACK 232 249 +17 read_leases 249 258 +9 dumpleases_main 604 609 +5 nobody_responds_to_arp 84 86 +2 udhcp_end_option 32 30 -2 udhcp_get_option 222 171 -51 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 6/2 up/down: 113/-53) Total: 60 bytes
* optimize 16- and 32-bit movesDenis Vlasenko2008-12-081-3/+2
| | | | | | | | | | | | | | | | function old new delta udhcpd_main 1239 1257 +18 udhcp_add_simple_option 93 92 -1 buffer_read_le_u32 19 18 -1 unpack_gz_stream_with_info 526 520 -6 dnsd_main 1470 1463 -7 udhcp_run_script 1208 1186 -22 send_ACK 255 229 -26 arping_main 1661 1623 -38 send_offer 470 428 -42 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/8 up/down: 18/-143) Total: -125 bytes
* Fix forgotten license commentsDenis Vlasenko2008-12-071-0/+2
|
* build system: tidying up CONFIG_xxx names (suggested by Rob)Denis Vlasenko2008-11-061-3/+3
|
* dhcp: add FAST_FUNC as appropriate. -160 bytes.Denis Vlasenko2008-09-261-4/+4
|
* udhcpc: support for -O <option>.Denis Vlasenko2007-12-101-49/+49
| | | | | | | | | | | | | | | | Two important notes: * nissrv and nisdomain are not requested by default anymore! * inconsistency between "XXXsvr" and "XXsrv" in option names resolved, all are "XXXsrv" now. function old new delta udhcpc_main 2494 2600 +106 packed_usage 23023 23067 +44 add_requests 91 119 +28 static.udhcpc_longopts 209 226 +17 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 4/0 up/down: 195/0) Total: 195 bytes
* dhcp: heed TODO item - divorced options from their string descriptionsDenis Vlasenko2007-11-291-46/+92
| | | | | | | | | | | | | | | | | | | | | code shrink while at it. function old new delta dhcp_option_strings - 258 +258 udhcp_run_script 1135 1174 +39 dhcp_option_lengths - 11 +11 udhcp_add_simple_option 93 92 -1 packet_num 4 - -4 read_opt 746 739 -7 udhcp_option_lengths 11 - -11 udhcpc_main 2590 2494 -96 dhcp_options 490 70 -420 ------------------------------------------------------------------------------ (add/remove: 2/2 grow/shrink: 1/4 up/down: 308/-539) Total: -231 bytes text data bss dec hex filename 775309 929 9100 785338 bfbba busybox_old 775098 929 9084 785111 bfad7 busybox_unstripped
* dhcpc: let server know we don't like oversized packets.Denis Vlasenko2007-11-281-31/+37
| | | | | add TODO comment
* dhcpc: cope with buggy DHCP servers which send oversized packetsDenis Vlasenko2007-11-251-1/+1
| | | | | (Cristian Ionescu-Idbohrn <cristian.ionescu-idbohrn@axis.com>)
* dhcp: stop using magic constants; use (htonl(CONST) != a) - it's smallerDenis Vlasenko2007-11-231-8/+10
| | | | | | | function old new delta udhcp_get_packet 146 134 -12 get_raw_packet 368 353 -15
* trylink: produce even more info about final link stageDenis Vlasenko2007-08-121-1/+1
| | | | | | | | | trylink: explain how to modify link and drastically decrease amount of padding (unfortunately, needs hand editing ATM). *: add ALIGN1 / ALIGN2 to global strings and arrays of bytes and shorts size saving: 0.5k
* udhcp: optionally support RFC3397 (by Gabriel L. Somlo <somlo@cmu.edu>)Denis Vlasenko2007-02-271-1/+7
|
* udhcpd: allow "domain" to be a list of DNS servers, not just oneDenis Vlasenko2007-02-021-1/+1
|
* add "wpad" DHCP option. Spotted some optimization opportunities: -80 bytesDenis Vlasenko2006-11-231-43/+45
|
* udhcp: fix indentation and style.Denis Vlasenko2006-11-181-4/+0
| | | | | Eliminate (group) a lot of smallish *.h files Remove lots of unneeded #includes
* message string changes, mostly for consistency, also -32 bytes in .rodataDenis Vlasenko2006-10-201-4/+4
|
* add open_read_close() and similar stuffDenis Vlasenko2006-10-141-1/+1
|
* several fixes from openWRT projectDenis Vlasenko2006-09-261-0/+3
|
* Implement optional syslog logging using ordinaryDenis Vlasenko2006-09-061-6/+7
| | | | | | bb_xx_msg calls, and convert networking/* to it. The rest of bbox will be converted gradually.
* Standardize on the vi editing directives being on the first line."Robert P. J. Day"2006-07-021-0/+1
|
* Use BB endianness macro.Rob Landley2006-05-311-2/+1
|
* add back in udhcp supportMike Frysinger2006-05-081-0/+172
|
* remove in place of external linkMike Frysinger2006-03-231-172/+0
|
* sync busybox and udhcp treesMike Frysinger2006-03-231-1/+0
|
* just whitespaceTim Riker2006-01-251-2/+2
|
* more make safe the exported namespace for udhcp. Move to bb-specific file ↵"Vladimir N. Oleynik"2005-09-231-1/+1
| | | | for reduce change into udhcp-CVS
* move a couple of functions from common code (options.c) to udhcpd privatePaul Fox2005-09-221-47/+1
| | | | code (files.c) to make udhcpc a little smaller.
* Fix the warning by rewriting the function to be smaller and simpler.Rob Landley2005-09-081-28/+17
| | | | | I'd appreciate somebody on a __BIG_ENDIAN platform testing this out; I haven't got the hardware...
* merge from udhcp moduleMike Frysinger2004-12-061-1/+3
|
* Remove trailing whitespace. Update copyright to include 2004.Eric Andersen2004-03-151-15/+15
|
* Use standard C99 typesEric Andersen2004-01-301-12/+12
|
* options is a pretty common symbol, bad idea to use as a global in udhcp when ↵Russ Dill2003-12-151-4/+4
| | | | compiling into busybox
* Vodz, last_patch_88Glenn L McGrath2003-06-101-3/+1
|
* sorry about all the noise, should be all synced up nowRuss Dill2002-12-111-2/+2
|
* resync with udhcp cvsRuss Dill2002-12-111-6/+1
|