itytophile/hash-slaveThe slave which cracks the hashes.itytophile/hash-serverThe server which shares equally the ranges to each slave to crack a hash. It offers an UI at http://localhost:3000itytophile/monitorThe monitor which observes the server's request queue. It asks docker to scale the slave service replicas.
glibc is harder to deal with when we do static linking however it is much faster than musl (the binary is bigger though).
src/main.rsThe server.src/server/to_dude.rsThe task that manages dudes.src/server/to_slave.rsThe task that manages slaves.src/slave.rsThe slave.src/monitor.rsThe monitor.src/alphabet.rsFunctions that help us to generate words to crack hashes.
cargo run
# or cargo run -- --help--release is good but not necessary.
cargo run --release --bin slave
# or cargo run --release --bin slave -- --helpWe add the --release to make the slave fast.
Before building:
cargo vendorThen:
docker build -f docker/Dockerfile.slave -t itytophile/hash-slave .docker build -f docker/Dockerfile.server -t itytophile/hash-server .Because using cargo vendor within a runner is not easy. The CI has to update crates.io index for each build.
Initialize the swarm:
docker swarm init
After creating the swarm:
docker stack deploy --compose-file docker-compose.yml stackhashTo delete the stack:
docker stack rm stackhash