Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Find Discord Voice Server IPs in Python
- # Based on the simple fact of:
- ### Discord RTC Session Auth packets have a TTL of 51 (Meaning when you join the call the packets TTL is 51)
- ### Discord RTC Alive (ACK) packets have a length of 305 (Blank Audio, Keeping alive conection between Client and Server)
- from scapy.all import *
- def sniffPackets(packet):
- if packet.haslayer(IP):
- pckt_src=packet[IP].src
- pckt_port=packet[UDP].sport
- pckt_ttl=packet[IP].ttl
- pckt_len=packet[UDP].len
- if pckt_ttl == 51:
- print 'Discord Server IP %s : Port %s' % (pckt_src,pckt_port)
- exit()
- if pckt_len == 305:
- print 'Discord Server IP %s : Port %s' % (pckt_src,pckt_port)
- exit()
- def main():
- print 'Sniffing for Discord Voice IP'
- sniff(filter="udp",prn=sniffPackets)
- main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement