FW: [ISC-Bugs #37715] AutoReply: dhcp-4.3.1 and initial versions. - dhcp user class option 77 encoding is not encoding as per the RFC.

Venkatesh Siddappa Venkatesh.Siddappa at oneaccess-net.com
Wed Nov 26 13:41:36 UTC 2014


Hi Glenn,

Thanks I will try and let u know.


Thanks,
Venkatesh.


-----Original Message-----
From: dhcp-users-bounces at lists.isc.org [mailto:dhcp-users-bounces at lists.isc.org] On Behalf Of Glenn Satchell
Sent: Wednesday, November 26, 2014 7:07 PM
To: Users of ISC DHCP
Subject: RE: FW: [ISC-Bugs #37715] AutoReply: dhcp-4.3.1 and initial versions. - dhcp user class option 77 encoding is not encoding as per the RFC.

Maybe carefully padding the text with a 1 byte length as the first character will work?

eg if the user-class option you want is "foo" then use "\003foo" to set the first byte to the length. You can use \nnn where nnn is an octal code.

regards,
-glenn

On Thu, November 27, 2014 12:27 am, Venkatesh Siddappa wrote:
> Hi Glenn,
>
> Thanks for the Reply and info provided.
>
>
> As am now using as a string ,
> I will investigate further on this issue by looking through the code, 
> as our server is not responding. (as we are using proprietery server 
> it is not giving the response).
> I will let you know if the solution is generic.
>
> Thanks,
> Venkatesh.
>
>
>
>
> -----Original Message-----
> From: dhcp-users-bounces at lists.isc.org 
> [mailto:dhcp-users-bounces at lists.isc.org] On Behalf Of Glenn Satchell
> Sent: Wednesday, November 26, 2014 6:39 PM
> To: Users of ISC DHCP
> Subject: Re: FW: [ISC-Bugs #37715] AutoReply: dhcp-4.3.1 and initial 
> versions. - dhcp user class option 77 encoding is not encoding as per 
> the RFC.
>
> Seems dhclient is not the only one getting this wrong:
>
> https://ask.wireshark.org/questions/35332/dhcp-option-77-malformed-opt
> ion
>
> Microsoft doesn't seem to think it needs the sub item lengths:
>
> http://technet.microsoft.com/en-us/library/dd145324%28v=ws.10%29.aspx
>
> iPXE also uses it in the same way:
>
> http://forum.ipxe.org/showthread.php?tid=7530
>
> So maybe, the defacto use case is to non-compliant and treat the 
> option as a single string, rather than the array of strings?
>
> regards,
> -glenn
>
> On Wed, November 26, 2014 3:21 am, Venkatesh Siddappa wrote:
>> Hi,
>>
>> Please let me know if anyone faced following issue.
>>
>> Thanks,
>> Venkatesh.
>>
>>
>> -----Original Message-----
>> From: DHCP Bugs via RT [mailto:dhcp-bugs at isc.org]
>> Sent: Tuesday, November 04, 2014 7:00 PM
>> To: Venkatesh Siddappa
>> Subject: [ISC-Bugs #37715] AutoReply: dhcp-4.3.1 and initial versions.
>> - dhcp user class option 77 encoding is not encoding as per the RFC.
>>
>>
>> Greetings,
>>
>> This message has been automatically generated in response to the 
>> creation of a trouble ticket regarding:
>> 	"dhcp-4.3.1 and initial versions. - dhcp user  class  option 77 
>> encoding is not encoding as per the RFC.", a summary of which appears 
>> below.
>>
>> There is no need to reply to this message right now.  Your ticket has 
>> been assigned an ID of [ISC-Bugs #37715].
>>
>> Please include the string:
>>
>>          [ISC-Bugs #37715]
>>
>> in the subject line of all future correspondence about this issue. To 
>> do so, you may reply to this message.
>>
>>                         Thank you,
>>                         dhcp-bugs at isc.org
>>
>> ---------------------------------------------------------------------
>> -
>> ---
>> Bug Report from www.isc.org:
>>
>>   * Name: venkatesh
>>
>>   * Email: venkatesh.siddappa at oneaccess-net.com
>>
>>   * Software Version: dhcp-4.3.1 and initial versions.
>>
>>   * OS: Linux
>>
>>   * Subject:dhcp user class option 77 encoding is not encoding as per 
>> the RFC.
>>
>> Bug Detail
>>
>> The format of this option is as follows:
>>
>> Code Len Value
>> +—–+—–+————â
>> +€”——
>> . . . –+
>> | 77 | N | User Class Data ('Len' octets) |
>> +—–+—–+————â
>> +€”——
>> . . . –+
>>
>> UC_Len_i User_Class_Data_i
>> +——–+—————ââ
>> +‚¬â€Ã¢â‚¬â€Ã¢â‚¬â€
>> . . . –+
>> | L_i | Opaque-Data ('UC_Len_i' octets) |
>> +——–+—————ââ
>> +‚¬â€Ã¢â‚¬â€Ã¢â‚¬â€
>> . . . –+
>>
>> Each User Class value (User_Class_Data_i) is indicated as an opaque 
>> field.
>> The value in UC_Len_i does not include the length field itself and 
>> MUST be non-zero. Let m be the number of User Classes carried in the 
>> option. The length of the option as specified in Len must be the sum 
>> of the lengths of each of the class names plus m:
>> Len= UC_Len_1 + UC_Len_2 + … + UC_Len_m + m. If any instances 
>> of User Class Data are present, the minimum value of Len is two (Len 
>> =
>> UC_Len_1 + 1 = 1 + 1 = 2)
>>
>> ===
>> config:
>>
>> debian73-32bit:/home/oauser/opensource/dhcp-4.3.1/client# cat 
>> /etc/dhcp/dhclient.conf # Configuration file for /sbin/dhclient, 
>> which is included in Debian's # dhcp3-client package.
>> #
>> # This is a sample configuration file for dhclient. See 
>> dhclient.conf's # man page for more information about the syntax of 
>> this file # and a more comprehensive list of the parameters 
>> understood by # dhclient.
>> #
>> # Normally, if the DHCP server provides reasonable information and 
>> does # not leave anything out (like the domain name, for example), 
>> then # few changes must be made to this file, if any.
>> #
>>
>> option rfc3442-classless-static-routes code 121 = array of unsigned 
>> integer 8;
>>
>> #send host-name "andare.fugue.com";
>> #send host-name = gethostname();
>> #send dhcp-client-identifier 1:0:a0:24:ab:fb:9c; #send 
>> dhcp-client-identifier eth0; #send dhcp-lease-time 3600; #send 
>> dhcp-lease-time 36; send user-class "MC76"; #send 
>> vendor-class-identifier "1:0:a0:24:ab:fb:9c"; #supersede domain-name 
>> "fugue.com home.vix.com"; #prepend domain-name-servers 127.0.0.1; 
>> #omapi port 7911; request subnet-mask, broadcast-address, 
>> time-offset, routers, domain-name, domain-name-servers, 
>> domain-search, host-name, dhcp6.name-servers, dhcp6.domain-search, 
>> netbios-name-servers, netbios-scope, interface-mtu, 
>> rfc3442-classless-static-routes, ntp-servers, static-routes, 
>> extensions-path; #require subnet-mask, domain-name-servers; #timeout 
>> 60; #retry 60; #reboot 10; #select-timeout 5; #initial-interval 2; 
>> #script "/etc/dhcp3/dhclient-script"; #media "-link0 -link1 -link2", 
>> "link0 link1"; #reject 192.33.137.209;
>>
>> #alias {
>> # interface "eth0";
>> # fixed-address 192.5.5.213;
>> # option subnet-mask 255.255.255.255; #}
>>
>> #lease {
>> # interface "eth0";
>> # fixed-address 192.33.137.200;
>> # medium "link0 link1";
>> # option host-name "andare.swiftmedia.com"; # option subnet-mask 
>> 255.255.255.0; # option broadcast-address 192.33.137.255; # option 
>> routers 192.33.137.250; # option domain-name-servers 127.0.0.1; # 
>> renew 2
>> 2000/1/12 00:00:01; # rebind 2 2000/1/12 00:00:01; 
>> =============================== comand executed:
>> debian73-32bit:/home/oauser/opensource/dhcp-4.3.1/client# ./dhclient
>> -4 -d -cf /etc/dhcp/dhclient.conf eth1
>>
>> ====
>>
>> If i see in the wireshark "user-class "MC76";", is encoding as -> 4d
>> 04 4d
>> 43
>> 37 36
>> But ideally it should have been in the form -> 4d 05 04 4d 43 37 36
>>
>> DHCP servers not able to give offers because of user-class not matched.
>>
>> Please let me know whether "user class option " not handled in isc 
>> dhcp cleint.
>>
>> Thanks,
>> venkatesh.
>>
>> ---
>>
>> This email was received through isc.org Bug Submission Form
>>
>> All information within this email is considered confidential and for 
>> internal use only.
>>
>> _______________________________________________
>> dhcp-users mailing list
>> dhcp-users at lists.isc.org
>> https://lists.isc.org/mailman/listinfo/dhcp-users
>>
>>
>
>
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at lists.isc.org
> https://lists.isc.org/mailman/listinfo/dhcp-users
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at lists.isc.org
> https://lists.isc.org/mailman/listinfo/dhcp-users
>
>


_______________________________________________
dhcp-users mailing list
dhcp-users at lists.isc.org
https://lists.isc.org/mailman/listinfo/dhcp-users


More information about the dhcp-users mailing list