[Israel.pm] MAC Address

Gaal Yahas gaal at forum2.org
Tue Mar 16 12:04:03 PST 2004

On Tue, Mar 16, 2004 at 09:46:22PM +0200, Georges EL OJAIMI wrote:
> It is the same as: http://www.nthelp.com/NT6/change_mac_w2k.htm
> I also tried: http://amac.paqtool.com/ similar to SMAC
> In both cases, you need to reboot the machine!
> I thought PERL can overcome this problem :(

Perl certainly can't help you there. The best it may be able to do is
provide you with a programmatic interface to an existing service, but
the service has to exist already. In this case you want to tell your
NIC something; I believe the underlying problem is that in Windows you
can't do that as directly as you would in many unices.

> I am not a geek in Network Programming but can I access it directly via the
> TCP/IP protocol stack? If so, will it broadcast directly the new MAC to the
> network or keep using the old one?

Supposing you could update the NIC with the new MAC, you'd also have to
chase down all the references to the old MAC address (e.g., in the
registry) to prevent spurious changes back. But modulo that, yes; on
most NICs the change is instantaneous. One note, though: neither the NIC
nor the TCP/IP stack announce the new MAC by themselves. Rather, the
broadcast occurs the first time someone sends an ARP WHO-IS query. But
there's no need to worry about that for, er, most applications, because
that'll all happen automatically once you attempt to contact another
machine on the network.

Gaal Yahas <gaal at forum2.org>

More information about the Perl mailing list