#!/usr/bin/env python3

# Usage: gen-auth-cookie > static_extended_orport_auth_cookie
#
# Generates a pluggable transport Extended ORPort (ExtORPort) authentication
# cookie file, containing a random cookie.

import os
import sys

sys.stdout.buffer.write(
    b"! Extended ORPort Auth Cookie !\n" +
    bytes.hex(os.urandom(16)).encode()[:31] + b"\n"
)
