fix: randomize VIO seq/ack and correct SOCKS5 display for panel users
Randomize TCP seq/ack numbers in VIO packets on both client and server to reduce packet fingerprinting. Fix misleading SOCKS5 port display when panel is detected but SOCKS5 auto-add didn't complete — previously showed the panel port (e.g. 443) labeled as SOCKS5. Ref #27, Fixes #35
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
from scapy.all import AsyncSniffer,IP,TCP,Raw,conf,Ether,get_if_hwaddr
|
||||
import asyncio
|
||||
import random
|
||||
import parameters
|
||||
import logging
|
||||
import os
|
||||
@@ -84,6 +85,8 @@ else:
|
||||
|
||||
def send_to_violated_TCP(binary_data):
|
||||
new_pkt = basepkt.copy()
|
||||
new_pkt[TCP].seq = random.randint(1024,1048576)
|
||||
new_pkt[TCP].ack = random.randint(1024,1048576)
|
||||
new_pkt[TCP].load = binary_data
|
||||
skt.send(new_pkt)
|
||||
|
||||
|
||||
@@ -99,8 +99,8 @@ def send_to_violated_TCP(binary_data,client_ip,client_port):
|
||||
new_pkt = basepkt.copy()
|
||||
new_pkt[IP].dst = client_ip
|
||||
new_pkt[TCP].dport = client_port
|
||||
# new_pkt[TCP].seq = random.randint(1024,1048576)
|
||||
# new_pkt[TCP].ack = random.randint(1024,1048576)
|
||||
new_pkt[TCP].seq = random.randint(1024,1048576)
|
||||
new_pkt[TCP].ack = random.randint(1024,1048576)
|
||||
new_pkt[TCP].load = binary_data
|
||||
skt.send(new_pkt)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user