How cnlnn/ja3-server works
Project type and purpose
• This is a lightweight Python microservice whose sole responsibility is to listen for incoming TLS connections, extract the JA3 fingerprint from each client’s TLS ClientHello, and (optionally) log it.
• There is no frontend, no database, and no persistent storage beyond console or file‐based logs. It’s effectively a single‐component, single‐responsibility network service.
File structure
• Top-level files only:
• README.md – usage instructions and description
• ja3-server.py – the whole server implementation
• server.crt & server.key – TLS certificate and private key
• No additional modules, libraries or subdirectories. The script probably uses Python’s built‐in libraries (socket, ssl, argparse).
README for additional insights
• Default behavior: listen on 127.0.0.1:443, no logs
• Flags: “-l” to set bind address and port, “-v” to turn on verbose logging
• Example screenshot shows JA3 hash output via curl test
Main components
a. External Client(s) (e.g., curl, browsers, custom TLS client)
b. Network and TLS handshake layer
c. Python ja3-server.py service
– CLI/argparse component (parsing “-l” and “-v”)
– SSLContext/ssl.wrap_socket for server.crt & server.key
– JA3 fingerprint extraction logic
– Logging mechanism (console or file, verbose vs. silent)
d. (Optional) Log sink (stdout, file, syslog)
Architectural patterns & design principles
• Single‐responsibility, microservice‐style design
• CLI flag‐driven configuration
• Use of standard library modules only (socket, ssl, argparse)
• Event‐driven (accept → handle → loop)