Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 758032

Summary: net-analyzer/macchanger-1.7.0_{p5,p4} exit status regression on same MAC
Product: Gentoo Linux Reporter: Jaak Ristioja <jaak>
Component: Current packagesAssignee: Robin Johnson <robbat2>
Status: UNCONFIRMED ---    
Severity: normal CC: jstein, netmon
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Jaak Ristioja 2020-12-02 10:02:36 UTC
Something changed in the behavior of net-analyzer/macchanger when upgrading from 1.7.0 to 1.7.0_p5_p4, breaking my networking scripts which basically did things  like

    macchanger -m <some MAC> eth0 && dhclient eth0

because I need a different MAC for some networks, and the currently permament mac for others.

I tracked this down to the following regression:

With 1.7.0_p5_p4 when I try to change the MAC address to what it was earlier, it fails with exit status 1:

    # macchanger -m 98:fa:1b:5a:8e:4f eth0
    Current MAC:   98:fa:1b:5a:8e:4f (unknown)
    Permanent MAC: 98:fa:1b:5a:8e:4f (unknown)
    New MAC:       98:fa:1b:5a:8e:4f (unknown)
    It's the same MAC!!
    # echo $?
    1

Whereas with 1.7.0, it resulted in the exact same output, but an error status of 0:

    # macchanger -m 98:fa:1b:5a:8e:4f eth0
    Current MAC:   98:fa:1b:5a:8e:4f (unknown)
    Permanent MAC: 98:fa:1b:5a:8e:4f (unknown)
    New MAC:       98:fa:1b:5a:8e:4f (unknown)
    It's the same MAC!!
    # echo $?
    0

Using macchanger --permanent also seems to have the same issue.

Downgrading back to 1.7.0 fixes this.

I think this may be caused by "${WORKDIR}"/debian/patches/verify-changed-MAC.patch
Comment 1 Jaak Ristioja 2020-12-02 10:07:14 UTC
Sorry, I meant "${WORKDIR}"/debian/patches/check-random-device-read-errors.patch