mirror of
https://github.com/AuxXxilium/arc.git
synced 2024-11-24 00:09:53 +07:00
arc-functions: make hwid unique
Signed-off-by: AuxXxilium <info@auxxxilium.tech>
This commit is contained in:
parent
1d04d3f59f
commit
24d9ed7bb3
@ -2198,7 +2198,7 @@ function getpatfiles() {
|
|||||||
# Generate HardwareID
|
# Generate HardwareID
|
||||||
function genHardwareID() {
|
function genHardwareID() {
|
||||||
while true; do
|
while true; do
|
||||||
HWID="$(echo $(ifconfig | grep eth0 | awk '{print $NF}' | sed 's/://g') | sha256sum | awk '{print $1}' | cut -c1-16)" 2>/dev/null
|
HWID="$(echo $(ifconfig | grep eth0 | awk '{print $NF}' | sed 's/://g') $(cat /proc/cpuinfo | grep "model name" | cut -d':' -f2 | head -1) | sha256sum | awk '{print $1}' | cut -c1-16)" 2>/dev/null
|
||||||
if [ -n "${HWID}" ]; then
|
if [ -n "${HWID}" ]; then
|
||||||
USERID="$(curl -skL "https://arc.auxxxilium.tech?hwid=${HWID}")"
|
USERID="$(curl -skL "https://arc.auxxxilium.tech?hwid=${HWID}")"
|
||||||
if echo "${USERID}" | grep -vq "Hardware ID"; then
|
if echo "${USERID}" | grep -vq "Hardware ID"; then
|
||||||
@ -2228,7 +2228,7 @@ function genHardwareID() {
|
|||||||
###############################################################################
|
###############################################################################
|
||||||
# Check HardwareID
|
# Check HardwareID
|
||||||
function checkHardwareID() {
|
function checkHardwareID() {
|
||||||
HWID="$(echo $(ifconfig | grep eth0 | awk '{print $NF}' | sed 's/://g') | sha256sum | awk '{print $1}' | cut -c1-16)" 2>/dev/null
|
HWID="$(echo $(ifconfig | grep eth0 | awk '{print $NF}' | sed 's/://g') $(cat /proc/cpuinfo | grep "model name" | cut -d':' -f2 | head -1) | sha256sum | awk '{print $1}' | cut -c1-16)" 2>/dev/null
|
||||||
USERID="$(curl -skL "https://arc.auxxxilium.tech?hwid=${HWID}")"
|
USERID="$(curl -skL "https://arc.auxxxilium.tech?hwid=${HWID}")"
|
||||||
if echo "${USERID}" | grep -vq "Hardware ID"; then
|
if echo "${USERID}" | grep -vq "Hardware ID"; then
|
||||||
writeConfigKey "arc.hwid" "${HWID}" "${USER_CONFIG_FILE}"
|
writeConfigKey "arc.hwid" "${HWID}" "${USER_CONFIG_FILE}"
|
||||||
|
Loading…
Reference in New Issue
Block a user