Problem with MAC spoofing

LoZiOcErCa

New Member
Joined
Dec 9, 2018
Messages
1
Reaction score
0
Credits
0
Hi everyone, I'm writing because I'm a rookie with GNU Linux and I got this problem:

If i write this commands:

sudo ifconfig <interface> down
sudo macchanger -r <interface>
sudo ifconfig <interface> up

then, I can't surf the net... If anyone could help me with this problem, I'd be very thankful. I'm using a virtual machine (VirtualBox) on Windows 10.
I'm using Linux Mint.

Sorry for the mistakes, but english is not my first language.
 


Hi and wellcome to Linux.org :)
Is your problem to surve in the web or to surve in the web when you tipped this commands?
udo ifconfig <interface> down
sudo macchanger -r <interface>
sudo ifconfig <interface> up
type
Code:
sudo apt update
sudo apt-get dist-upgrade
and give us the out put.
 
Hi everyone, I'm writing because I'm a rookie with GNU Linux and I got this problem:

If i write this commands:

sudo ifconfig <interface> down
sudo macchanger -r <interface>
sudo ifconfig <interface> up

then, I can't surf the net... If anyone could help me with this problem, I'd be very thankful. I'm using a virtual machine (VirtualBox) on Windows 10.
I'm using Linux Mint.

Sorry for the mistakes, but english is not my first language.

0) You should be more specific when writing questions. Please consider this good read first:
https://stackoverflow.com/help/how-to-ask

1) Check the network settings in the virtual machine. I would recommend enabling the network adapter setting and selecting bridged adapter option.

2) How do you connect to the internet? Wired connection or wireless?

In every case, the operating system needs to have an IP address to communicate with other devices.
It is possible that after changing the MAC address your system doesn't have an IP address assigned to it or it has an assigned IP address and routing information that are not correct.

Also, if you try to establish a wireless connection, you need to remember that configuration with DHCP is not enough -- the system has to run a WPA client.

Issue the following in your terminal to get information on how to use the DHCP and WPA client programs:
Code:
man dhclient wpa_supplicant

Important note: in order for everything to work properly, your machine needs to run only one instance of DHCP and WPA. Multiple instances can (and quite likely will) cause problems with connectivity. What I would recommend is killing the old running instances and launching them manually.

Have a look at these two scripts:

start_wpa_and_dhcp_clients.sh
Code:
#!/bin/sh

IFACE="wlo1"

ip link set $IFACE down
macchanger -A $IFACE || exit 1
ip link set $IFACE up

wpa_supplicant -B -c/etc/wpa_supplicant.conf -i$IFACE -s
dhclient -v -4 $IFACE

kill_dhcp_and_wpa_clients.sh
Code:
#!/bin/sh

IFACE="wlo1"

dhclient -v -r $IFACE

DHCP_PIDS=$( pidof dhclient )
if [ ! -z "${DHCP_PIDS}" ]
then
    echo "Killing DHCP clients: $DHCP_PIDS"
    kill $DHCP_PIDS
fi
unset DHCP_PIDS

WPA_PIDS=$( pidof wpa_supplicant )
if [ ! -z "${WPA_PIDS}" ]
then
    echo "Killing WPA clients: $WPA_PIDS"
    kill $WPA_PIDS
fi
unset WPA_PIDS
 
  • Like
Reactions: Rob

Members online


Latest posts

Top