Skip to content

Instantly share code, notes, and snippets.

View kotovalexarian's full-sized avatar
🏴
Rust, Ruby, OSDev, decentralized networks

Alex Kotov kotovalexarian

🏴
Rust, Ruby, OSDev, decentralized networks
View GitHub Profile
@kotovalexarian
kotovalexarian / README.md
Last active July 21, 2021 18:35
Linux network namespaces

Abbreviations

  • mc - just prefix for every object in this example
  • br - bridge
  • rtr - router
  • srv - server (is not different from client)
  • cli - client (is not different from server)
@kotovalexarian
kotovalexarian / ipv4-udp-client.py
Last active July 21, 2021 06:14
IPv4 and IPv6 multicast
#!/usr/bin/env python3
import socket
GROUP = '224.1.1.1'
HOST = '0.0.0.0'
PORT = 5000
def main():
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM, socket.IPPROTO_UDP)