1

I'm using a v2ray server I want each client user can have ability to access the internet just with one device and he can't use multiple devices to use the connection that I provide for him please let me know if you have solution

I have tested several x-ui forks that claims their x-ui can provide me that ability but none of them work for me

2 Answers2

1

This Script can help you. Of course, if you create multiple users with different UIDs.

Mehrdad
  • 19
  • 3
  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Jan 01 '23 at 03:05
0

In 6 steps:

  1. apt install python3
  2. pip3 install requests
  3. pip3 install schedule
  4. apt install net-tools
  5. copy main.py file to your server
  6. nohup python3 main.py & Maybe you need run these commands with sudo keyword
morteza khadem
  • 346
  • 3
  • 8
  • Thanks for this answer, but seems like no matter what i do, the column $3 is always 0 for all records so the return value is null. – Burzum Jun 04 '23 at 16:25
  • The server is up and the specific port is working well. the $3 column is in this line of code: netstate_data = os.popen("netstat -np 2>/dev/null | grep :"+str(user_port)+" | awk '{if($3!=0) print $5;}' | cut -d: -f1 | sort | uniq -c | sort -nr | head").read(); – Burzum Jun 04 '23 at 16:27