The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: Don57 on January 24, 2012, 05:23:44 PM

Title: Locally Administrated MAC address
Post by: Don57 on January 24, 2012, 05:23:44 PM
I'm trying to write a program that will automatically allocated a new MAC address on my WiFi card, rather than do it manually. But I can't seem to find the appropriate API calls.
I'm just getting tired of doing it manually.
Title: Re: Locally Administrated MAC address
Post by: Vortex on January 24, 2012, 06:30:16 PM
Did you try to trace the modifications in the registry after setting a new MAC address?
Title: Re: Locally Administrated MAC address
Post by: Don57 on January 24, 2012, 06:35:48 PM
No but I will. The closest call that I can find is GetAdapterInfo. I was going to disassemble the relative DLL and see where that leads me.
Title: Re: Locally Administrated MAC address
Post by: Don57 on January 24, 2012, 06:53:02 PM
I found the registry entry at  HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-08002BE10318}\0008  NetworkAddress.

Can I use a write a program so that I can edit it, and have update on the fly, without having to reboot the computer.
Title: Re: Locally Administrated MAC address
Post by: ragdog on January 24, 2012, 07:18:13 PM
A MAC address can be changed? :eek
Title: Re: Locally Administrated MAC address
Post by: dedndave on January 24, 2012, 07:18:53 PM
i doubt it will be that simple
the information is likely stored elsewhere - places that also need to be refreshed after the update
not saying it isn't do-able, but i think it will involve more than simply changing a registry value
Title: Re: Locally Administrated MAC address
Post by: Vortex on January 24, 2012, 07:23:40 PM
Quote from: ragdog on January 24, 2012, 07:18:13 PM
A MAC address can be changed? :eek

Yes, it can be changed easily.
Title: Re: Locally Administrated MAC address
Post by: BogdanOntanu on January 24, 2012, 10:30:39 PM
Question is: WHY do you want to do this, esp on a WiFi network card :D ? eh?

The only reason I can find is not legit.