#!/system/bin/sh if [[ -f /system/.no_macaddres_in_eeprom ]] then macaddress=$(cat /data/.macaddress) if [[ -z $macaddress ]] then MAC_ADDRESS_OUIID="2c:f0:5d" macaddress=$(hexdump -n3 -e"/3 \"$MAC_ADDRESS_OUIID\" 3/1 \":%02x\"" /dev/random) echo $macaddress > /data/.macaddress fi ip link set eth0 down ip link set dev eth0 addr $macaddress ip link set eth0 up restart netd fi