Solutions to the Protohackers server programming challenges:
- Smoke Test - Echo service from RFC 862 (TCP).
- Prime Time - Primality testing service using a JSON-based response-request protocol (TCP).
- Means to an End - Asset price tracking service using a binary message format (TCP).
- Budget Chat - Simple chat room (TCP).
- Unusual Database Program - Key-value store (UDP).
- Mob in the Middle - Man-in-the-middle attack on Budget Chat (TCP).
$ mkdir -p bin
$ go build -o bin ./...
The server is deployed/hosted on AWS: see the
CloudFormation template.
Additionally, a useful collection of tiny Bash scripts
is defined in internal/deploy
.
I typically use direnv to automatically set
project-relevant environment variables and add helper utilities to PATH.
My .envrc
looks something like:
export AWS_ACCESS_KEY_ID=
export AWS_SECRET_ACCESS_KEY=
export AWS_DEFAULT_REGION=
export EC2_KEYNAME=
export CHECKER_ADDR=
PATH_add internal/deploy
PATH_add bin