You are not logged in.

#1 2023-06-15 09:11:49

qqwerasd
Member
Registered: 2023-06-15
Posts: 1

[SOLVED]ax88179a can't get ipv4 address normally

ax88179a can't get ipv4 address normally after changing mac address
Hello!

I have an Ax88179a NIC and I want to change its mac address for better authentication on the campus network, but after I make the change, it appears that dhcd cannot get the ipv4 address, but can get the ipv6 address, and when the mac address is not changed, it can get the ipv4 and ipv6 addresses normally, so I want to use wireshark to capture the packets to see what is happening, but after using wireshark to turn on the capture, it can get the ipv4 address and communicate normally.

The result of using the command "ip a" when no mac address change has been made

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: enp0s13f0u1u4c2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 08:26:ae:3b:5f:dd brd ff:ff:ff:ff:ff:ff
    inet 172.20.129.240/17 brd 172.20.255.255 scope global dynamic noprefixroute enp0s13f0u1u4c2
       valid_lft 172555sec preferred_lft 172555sec
    inet6 2001:da8:402e:111:e7e0:f25:84e1:1e2f/64 scope global dynamic noprefixroute
       valid_lft 2591958sec preferred_lft 604758sec
    inet6 fe80::1ed6:488:4902:7eef/64 scope link noprefixroute
       valid_lft forever preferred_lft forever
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 72:ee:2e:a6:b6:fd brd ff:ff:ff:ff:ff:ff permaddr 00:93:37:5e:57:59
    inet 172.19.8.37/16 brd 172.19.255.255 scope global dynamic noprefixroute wlan0
       valid_lft 7153sec preferred_lft 7153sec
    inet6 fe80::ae06:bab6:b040:7ede/64 scope link noprefixroute
       valid_lft forever preferred_lft forever

I used the following command to make the mac address change

sudo ip link set dev enp0s13f0u1u4c2 down

sudo ip link set dev enp0s13f0u1u4c2 address c2:f4:a8:e9:2d:85

sudo ip link set dev enp0s13f0u1u4c2 up

sudo systemctl restart NetworkManager

Here are the results after the changes

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: enp0s13f0u1u4c2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether c2:f4:a8:e9:2d:85 brd ff:ff:ff:ff:ff:ff permaddr 08:26:ae:3b:5f:dd
    inet6 2001:da8:402e:111:e7e0:f25:84e1:1e2f/64 scope global dynamic noprefixroute
       valid_lft 2591999sec preferred_lft 604799sec
    inet6 fe80::1ed6:488:4902:7eef/64 scope link noprefixroute
       valid_lft forever preferred_lft forever
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 72:ee:2e:a6:b6:fd brd ff:ff:ff:ff:ff:ff permaddr 00:93:37:5e:57:59
    inet 172.19.8.37/16 brd 172.19.255.255 scope global dynamic noprefixroute wlan0
       valid_lft 7083sec preferred_lft 7083sec
    inet6 fe80::ae06:bab6:b040:7ede/64 scope link noprefixroute
       valid_lft forever preferred_lft forever

This is the result of re-dhcp after grabbing the packets with this command "dumpcap -i 1 -b filesize:100000 -b files:20 -w mycapture.pcapng"

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: enp0s13f0u1u4c2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether c2:f4:a8:e9:2d:85 brd ff:ff:ff:ff:ff:ff permaddr 08:26:ae:3b:5f:dd
    inet 172.20.128.105/17 brd 172.20.255.255 scope global dynamic noprefixroute enp0s13f0u1u4c2
       valid_lft 172672sec preferred_lft 172672sec
    inet6 2001:da8:402e:111:e7e0:f25:84e1:1e2f/64 scope global dynamic noprefixroute
       valid_lft 2591811sec preferred_lft 604611sec
    inet6 fe80::1ed6:488:4902:7eef/64 scope link noprefixroute
       valid_lft forever preferred_lft forever
3: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 72:ee:2e:a6:b6:fd brd ff:ff:ff:ff:ff:ff permaddr 00:93:37:5e:57:59
    inet 172.19.8.37/16 brd 172.19.255.255 scope global dynamic noprefixroute wlan0
       valid_lft 7199sec preferred_lft 7199sec
    inet6 fe80::ae06:bab6:b040:7ede/64 scope link noprefixroute
       valid_lft forever preferred_lft forever


----------------------------------------------------------------------------------------------------

Solutions:

Well, this is a problem caused by the ax88179a driver, at first I got the driver model wrong, it should be ax88179a and not ax88179, I have corrected it, so I downloaded the ax88179a driver in asix, but the current driver is not supported by kernel 6.x, so there will be errors when compiling, here are the errors I encountered Corresponding solution, you need to change netif_napi_add(netdev, &axdev->napi, ax_poll, info->napi_weight) function to netif_napi_add_weight(netdev, &axdev->napi, ax_poll. info->napi_weight), and another is to change the netif_set_gso_max_size(netdev, axdev->gso_max_size) function to netif_set_tso_max_size(netdev, axdev->gso_max_size) , this is the problem I encountered, I'm not sure if it works for you, please solve it according to your situation。Thanks!

Last edited by qqwerasd (2023-06-16 09:21:27)

Offline

Board footer

Powered by FluxBB