Skip to content

Instantly share code, notes, and snippets.

View cxzlw's full-sized avatar
🏳️‍⚧️
Proudly Transitioning

Thomas Wang cxzlw

🏳️‍⚧️
Proudly Transitioning
  • Shenzhen College of International Education
  • 09:24 (UTC +08:00)
View GitHub Profile
from os import urandom
from socket import create_connection
from cryptography.hazmat.primitives.asymmetric import padding
from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes
from cryptography.hazmat.primitives.serialization import load_der_public_key
def read(sock, length):
result = b''