mirror of
https://github.com/bol-van/zapret.git
synced 2025-05-24 22:32:58 +03:00
blockcheck: port and ip block tests
This commit is contained in:
@@ -293,7 +293,7 @@ random()
|
||||
rs="$RANDOM$RANDOM$(date)"
|
||||
fi
|
||||
# shells use signed int64
|
||||
r=1$(echo $rs | $MD5 | sed 's/[^0-9]//g' | head -c 17)
|
||||
r=1$(echo $rs | $MD5 | sed 's/[^0-9]//g' | cut -c 1-17)
|
||||
echo $(( ($r % ($2-$1+1)) + $1 ))
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user