View previous topic :: View next topic |
Author |
Message |
g4j Apprentice

Joined: 03 Jul 2004 Posts: 174 Location: Florida
|
Posted: Mon Aug 08, 2005 5:37 pm Post subject: simple MAC spoofing? |
|
|
I have a duel-booting Dell Inspiron. I would like to spoof the MAC address on the Gentoo side so that my DHCP server will see/treat the Gentoo image as a different computer. How do I do this? |
|
Back to top |
|
 |
tomvollerthun Guru


Joined: 19 Mar 2005 Posts: 316
|
Posted: Mon Aug 08, 2005 6:00 pm Post subject: |
|
|
Since it is a potentially criminal act (or at least very closely related to such), if you try this on computers that don't belong to you, it think it is very unlikely that you'll get a hands-on-tutorial in here.
Even if you did, I would think the answer might need to be moderated down in order to keep the forum as far away from juristic trouble as possible.
So, if it is something legal you want to achieve, I'm pretty positive that you can do it another way. Just tell us what you want.
If it's not, search the web: there are many other places where you can find hacker's handbooks and stuff like that.
cu, tom _________________ Computer science is no more about computers than astronomy is about telescopes.
Dijsktra
---------------
Don't believe my "Guru" status! |
|
Back to top |
|
 |
jbc28 Apprentice


Joined: 07 Jan 2003 Posts: 205 Location: Edinburgh
|
Posted: Mon Aug 08, 2005 6:09 pm Post subject: |
|
|
How is this illegal?
J |
|
Back to top |
|
 |
g4j Apprentice

Joined: 03 Jul 2004 Posts: 174 Location: Florida
|
Posted: Mon Aug 08, 2005 6:12 pm Post subject: This is what I'm trying to accomplish |
|
|
What I want is for my DHPC server to assign a particular reserved IP address when I'm booted into Windows, and a different particular address when I'm booted into Gentoo. Since the configureation of my DHPC server looks only at the MAC address, it has no way of knowing when I'm booted into which OS, and thus would assign the same IP regardless of which OS is booted.
I normally used fixed IP addresses, which works fine for desktops that never leave my home. But the notebook is sometimes at home, and sometimes on the road. Thus it needs to have a dynamic IP for when it's on the road. I figured the best solution was to used reserved IP's, but as I said my DHPC server doesn't know when my notebook is Gentoo, and when it's Windowz, so it would get the same reserved IP regardles of what is booted. |
|
Back to top |
|
 |
g4j Apprentice

Joined: 03 Jul 2004 Posts: 174 Location: Florida
|
Posted: Mon Aug 08, 2005 6:16 pm Post subject: I might add... |
|
|
IP packets only contain MAC information while on the LAN. MAC address are dropped once the packet reaches the internet. Thus, if someone wanted to commit an internet crime, spoofing a MAC address would not be the way to do it. |
|
Back to top |
|
 |
ph03n1x l33t


Joined: 06 Feb 2003 Posts: 756
|
Posted: Mon Aug 08, 2005 6:18 pm Post subject: |
|
|
lmao
Spoofing macs is illegal since when
Doing this for years at my school. We have to fill out a form to register the mac adress or our computers to access the local net. Well i bought a new laptop and was too lazy to reregister... illegal? I don't think.
Code: | ifconfig eth0 hw ether 00:00:00:00:00:01 |
Does the trick where 00:00:00:00:00:01 is your desired mac. A quick google or man could have showed that as well... |
|
Back to top |
|
 |
jbc28 Apprentice


Joined: 07 Jan 2003 Posts: 205 Location: Edinburgh
|
Posted: Mon Aug 08, 2005 6:19 pm Post subject: |
|
|
To change your MAC address:
Code: | ifconfig eth0 hw ether 00:01:02:03:04:05 |
Doing most things on a computer you don't have permission to access is a "criminal act", I don't see that this has special status.
Hope this helps,
J |
|
Back to top |
|
 |
g4j Apprentice

Joined: 03 Jul 2004 Posts: 174 Location: Florida
|
Posted: Mon Aug 08, 2005 6:24 pm Post subject: |
|
|
Thank you.
I assume that
Code: | ifconfig eth0 hw ether 00:01:02:03:04:05 |
goes in my /etc/conf.d/net file? Does the line stand alone, or does it need to be appended to to the rest of the eth0 configureation?
Thanks again. |
|
Back to top |
|
 |
ph03n1x l33t


Joined: 06 Feb 2003 Posts: 756
|
Posted: Mon Aug 08, 2005 6:33 pm Post subject: |
|
|
Dont think u can add this to /etc/conf.d/net
But u can just type it in the console after the interface is up but preferably before dhcpcd is started. Maybe u need to make a lil script for that... |
|
Back to top |
|
 |
rwhelan n00b


Joined: 23 May 2005 Posts: 10
|
Posted: Mon Aug 08, 2005 6:44 pm Post subject: |
|
|
couldn't you just add that line to the /etc/init.d/net.ethX script? (inside the start function of course start() {) _________________ \ , , /_ { >.< } _\ , , / |
|
Back to top |
|
 |
bigfunkymo Apprentice


Joined: 23 Jan 2004 Posts: 237
|
Posted: Mon Aug 08, 2005 8:54 pm Post subject: |
|
|
It's all in how you spin it.
If you say: "I want to make this PC use a different MAC address so I can gain access to this other network," then it carries a negative tone.
if you say: "I want my gentoo machine to use the MAC address of my other computer so my cable modem will let me online," then nobody will say you're doing something illegal even though you're pretty much asking for the same advice. _________________ [No package... Grabbing a set.] |
|
Back to top |
|
 |
ph03n1x l33t


Joined: 06 Feb 2003 Posts: 756
|
Posted: Mon Aug 08, 2005 11:31 pm Post subject: |
|
|
You're right
But if the knowledge is available via google or man I don't hesitate too much giving it out.
Another point is you cannot really judge about a persons intention just because of the way they are asking. There might be the wannabe 1337 who is stupid enough to ask directly and will therefore get no answer. There might also be a really evil person just clever enough to ask in a way nobody would expect he/she would do any harm and he'll prolly get the info.
So it doesn't really matter in the end... |
|
Back to top |
|
 |
tomvollerthun Guru


Joined: 19 Mar 2005 Posts: 316
|
Posted: Tue Aug 09, 2005 9:07 am Post subject: |
|
|
Mac-spoofing is sported by many want-to-be hackers and I never found a real need to do it. Yet.
Obviously I have been a bit shortsighted/badly informed, so pardon me.
I just had a feeling when reading the OP, that it might just be yet another script kiddie looking for trouble to do. The other posts in this thread taught me that I was wrong.
But then, I didn't really put the poster off: Beside the OT-stuff, I just asked for more information, so we (read: you ;) could help better.
If I offended anyone, I want hereby to apologize: I didn't think my comments could be so "hot".
cu, tom _________________ Computer science is no more about computers than astronomy is about telescopes.
Dijsktra
---------------
Don't believe my "Guru" status! |
|
Back to top |
|
 |
g4j Apprentice

Joined: 03 Jul 2004 Posts: 174 Location: Florida
|
Posted: Tue Aug 09, 2005 10:04 am Post subject: |
|
|
Ok, I've tried
Code: | ifconfig eth0 hw ether 00:00:00:00:00:01 |
from the command prompt. No go - device is busy. I've tried it in both /etc/conf.d/net and /etc/init.d/net.eth0 . still no joy. In browsing around, I've also seen things like Code: | ifconfig_eth0=( "hw ether 00:04:E2:7D:93:C3" ) | as well as Code: | mac_eth0="00:11:22:33:44:55"
|
I've tried these from the command line, as well as incerting them in the two files mentioned above. Nothing. My searches on Google and this forum have found many references to things like "of course, you can change your MAC address with (one of the previously mentioned statements)" but no reference as to where or how to actually use the snippet of code.
Could I please have a little more guidance here? I just need Gentoo to automatically bring up eth0 with a static MAC that I assign (which would be only one bit different from the physical MAC). I'm not a programer, so if I need to script something, please be speciffic.
Thanks. |
|
Back to top |
|
 |
NeddySeagoon Administrator


Joined: 05 Jul 2003 Posts: 55441 Location: 56N 3W
|
Posted: Tue Aug 09, 2005 10:25 am Post subject: |
|
|
g4j,
In linux you can suggest an IP address to the DHCP server that you would like. It will be allocated if its free, if not, you will get another one.
I don't know if Windows supports this too.
You many not need to mess with MAC spoofing at all.
MAC spoofing will not ensure you don't get the same IP as windows unless your DHCP server reserves an IP per MAC.
Most don't, they just go round and round the pool of IPs, so you get the next free IP anyway. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
 |
ph03n1x l33t


Joined: 06 Feb 2003 Posts: 756
|
Posted: Tue Aug 09, 2005 11:54 am Post subject: |
|
|
As i tried to point out before you should do this in the following order, supposed eth0 is down:
Code: | ifconfig eth0 up
ifconfig eth0 hw ether 00:00:00:00:00:01
dhcpcd eth0 |
That way it will work if you already launched dhcpcd and device is in use you get of course an error |
|
Back to top |
|
 |
g4j Apprentice

Joined: 03 Jul 2004 Posts: 174 Location: Florida
|
Posted: Tue Aug 09, 2005 12:54 pm Post subject: |
|
|
Thanks ph03n1x,
If I want the code you suggested to run at boot time, where would I put it? Is there a way to insert it into one of the config files so I don't have to call a seperate script? I've tried putting the ifconfig line in the start section of /etc/init.d/net.eth0, but that hasn't worked.
NeddySeagoon, thanks for your input. My dhcp server can be (and is) configured to reserve IP addresses per MAC. I thought that was a common feature? If I wanted Gentoo to *request* an IP (as opposed to assigning a fixed IP which would fail when I am connected to a network outside of my home) how would I do that? I assume that if I configure it to request a 192.168.... IP (which would be right for home), this request would be ignored when I bootup at work where the network is 10.....?
My desired end result is to have one known IP for Gentoo, and a different known IP for Windows - both for sake of my home network - but both must be assigned by a DHHCP server as not to cause problems when I'm connected to any network other than home. However I achieve this end result is fine.
Thanks for any input. |
|
Back to top |
|
 |
rwhelan n00b


Joined: 23 May 2005 Posts: 10
|
Posted: Wed Aug 10, 2005 8:08 pm Post subject: |
|
|
g4j wrote: | Ok, I've tried
Code: | ifconfig eth0 hw ether 00:00:00:00:00:01 |
from the command prompt. No go - device is busy. I've tried it in both /etc/conf.d/net and /etc/init.d/net.eth0 . still no joy. In browsing around, I've also seen things like Code: | ifconfig_eth0=( "hw ether 00:04:E2:7D:93:C3" ) | as well as Code: | mac_eth0="00:11:22:33:44:55"
|
I've tried these from the command line, as well as incerting them in the two files mentioned above. Nothing. My searches on Google and this forum have found many references to things like "of course, you can change your MAC address with (one of the previously mentioned statements)" but no reference as to where or how to actually use the snippet of code.
Could I please have a little more guidance here? I just need Gentoo to automatically bring up eth0 with a static MAC that I assign (which would be only one bit different from the physical MAC). I'm not a programer, so if I need to script something, please be speciffic.
Thanks. |
seems to me if you edited the file /etc/init.d/net.eth0 (assuming you were talking about your first eth card) with the ifconfig command (full path - so /sbin/ifconfig) there is a line in the iface_start() function ebegin "Bringing ${IFACE} up via DHCP" Put the command on the next line down from there.
so from this http://www.burningpc.com/before.JPG
to this http://www.burningpc.com/after.JPG
(i know i got the command typed wrong, it is just an example.)
If you are nervous about editing the file, make a copy of it first, just incase. Let me know if this works. i would be interested to know.  _________________ \ , , /_ { >.< } _\ , , / |
|
Back to top |
|
 |
g4j Apprentice

Joined: 03 Jul 2004 Posts: 174 Location: Florida
|
Posted: Mon Aug 15, 2005 11:41 pm Post subject: |
|
|
Thanks rwhelan, but I couldn't get it to work. My net.eth0 file doesn't have the ebegin "Bringing ${IFACE} up via DHCP" line that you mentioned, so just stuck ifconfig in the start section.
I saw in a forum somewhere that it's not possible to spoof the mac on some of the newer hardware, but I don't know if that's true.
I'm starting to think that maybe quickswitch might be a better answer than trying to spoof the MAC. With quichswitch I could default to a static IP for my home network, then use QS to change to a dynamic setup for when I'm someplace other than home.
Thanks for your suggestion. |
|
Back to top |
|
 |
wjholden l33t

Joined: 01 Mar 2004 Posts: 826 Location: Augusta, GA
|
Posted: Tue Aug 16, 2005 12:48 am Post subject: |
|
|
Umm, I just want to mention that there are a ton of great reasons to spoof a MAC address. Somebody asking about how to spoof a MAC might be trying to register an Xbox to an authenticate DHCP server or something. At the university I work we use Cisco's Perfigo software and, until a programmer here built a manual registration form about the only way to register a device without a webbrowser was to spoof the MAC.
MAC spoofing is only a problem on really poorly set up networks. |
|
Back to top |
|
 |
slycordinator Advocate


Joined: 31 Jan 2004 Posts: 3065 Location: Korea
|
Posted: Fri Nov 18, 2005 10:50 pm Post subject: |
|
|
Another great reason to spoof your IP is:
Lots of ISPs assign your IP based on your device's specific MAC address. So if you were to put your computer(s) behind a router you may find that you no longer have connection. Or if you had a router you were replacing you might have to spoof the old router's MAC. |
|
Back to top |
|
 |
|