Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

All over the internet I see example of how to set up dhcpd with WAPD proxy auto configuration using DHCP.

In the /etc/dhcpd.conf file
There are statements like this.

option wpad code 252;
option wpad code 252 = text;

What is code 252, where is it defined and what does it mean. Why is it a number 252 and not a useful statement like wpad-proxy-url; Why use 252 and not some other number (0, 5000). I get that it works, it just does not make any sense to a human (me). Googling for what is option 252 has been fruitless.

share|improve this question
up vote 5 down vote accepted

Option 252 provides a DHCP client a URL to use to configure its proxy settings. It's defined in draft-ietf-wrec-wpad-01.

If it was a statement like "wpad-proxy-url" then only systems that understood it could use it (they'd have to recognize that string and know how to handle it). Since it's a number, an arbitrary tag, it can be processed even by servers that don't understand it.

For example, if I say "What's on Jessica's head?" you have to know who Jessica is to answer me. But if I say "What's on the head of the third person in line?" you don't have to know that her name is Jessica.

It's 252 because that was the number assigned to the protocol by the IETF DHC working group. See RFC 2132.

share|improve this answer

Here is a nice link that lists what many of the code ### number mean and how they are used.

252 is part a private usage reserved section. Basically for other people to use in there servers as they feel necessary.

Microsoft, decided to use 252 for their dhcp server, and then wrote into their browsers the ability to speak to the dhcp server and ask for code 252 to get information about proxy setup on the network form the url listed by the option.

Firefox, and chrome still require the dns setup to server the .pac file for proxy configuration. They currently don't work with the dhcp option.

share|improve this answer
Microsoft didn't pull 252 out of a hat. The request was made by representatives of Microsoft, Inktomi, RealNetworks and Sun Microsytems, and it was approved by the IETF DHC working group. (I admit, this makes it particularly baffling that a number from the block reserved for private use was chosen.) – David Schwartz Jan 31 '12 at 11:01
@David, How come it is not listed in… ? – nhed Aug 14 '12 at 20:45

More lightweight option is to publish PAC file using DNS

namely a browser will fetch without needing raw network access.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.