Re: Documentation clarification about unsigned/signed integer options

Simon Hobson <[email protected]> Wed, 13 Apr 2022 22:04:48 +0100
Newsgroups gmane.network.dhcp.isc.dhcp-server
Message-ID <51891D41-84E9-4B7B-9DF4-833AA8ACF23D__35884.5496129774$1649883911$gmane$org@thehobsons.co.uk>
On 6 April 2022 14:05:03 BST, Alex Duzsardi <[email protected]> wrote:
>Hi,
>I'm using PXE for some testing and i configured option 93 on my isc dhcp
>server to capture the architecture of the clients, like
>
>option arch code 93 = unsigned integer 16;
>
>
>now i saw a lot of ways to match the architecture on the interwebs and this
>is confusing for me because i can't find any documentation about cases
>where you would use
>
>if option arch = 00:00
>
>or
>
>if option arch = 0x0000
>
>or
>
>if option arch = 0
>
>Can somebody please clarify this for me?
>
>Thank you!

The server really doesn't care - those examples are equivalent. It really comes down to what makes the most sense to the humans involved.

For something that's "just a number" then the decimal version makes sense. If it's something more readable in hex then use one of the hex formats.

You could also use a string. E.g. "AA" is (if I remember my codes after a long day) the same as 0x4141, or 41:41, or 16705.

Simon
-- 
ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information.

dhcp-users mailing list
[email protected]
https://lists.isc.org/mailman/listinfo/dhcp-users