Update README.md
This commit is contained in:
parent
89b5fb9cf1
commit
dfbf23a27c
57
README.md
57
README.md
|
|
@ -11,6 +11,7 @@ The Hash of Wisdom server requires clients to solve computational puzzles (proof
|
||||||
### Prerequisites
|
### Prerequisites
|
||||||
- Go 1.24.3+
|
- Go 1.24.3+
|
||||||
- Docker (optional)
|
- Docker (optional)
|
||||||
|
- [Task](https://taskfile.dev/) (optional, but recommended)
|
||||||
|
|
||||||
### Building
|
### Building
|
||||||
```bash
|
```bash
|
||||||
|
|
@ -22,6 +23,29 @@ go build -o client ./cmd/client
|
||||||
```
|
```
|
||||||
|
|
||||||
### Running
|
### Running
|
||||||
|
|
||||||
|
#### Using Task (Recommended)
|
||||||
|
```bash
|
||||||
|
# Most useful command - run all checks
|
||||||
|
task check
|
||||||
|
|
||||||
|
# Start server
|
||||||
|
task server -- -config config.yaml
|
||||||
|
|
||||||
|
# Connect client
|
||||||
|
task client -- --addr=localhost:8080
|
||||||
|
|
||||||
|
# Run tests
|
||||||
|
task test
|
||||||
|
|
||||||
|
# See coverage
|
||||||
|
task test-coverage
|
||||||
|
|
||||||
|
# See all available commands
|
||||||
|
task --list
|
||||||
|
```
|
||||||
|
|
||||||
|
#### Manual Commands
|
||||||
```bash
|
```bash
|
||||||
# Start server (uses config.yaml by default)
|
# Start server (uses config.yaml by default)
|
||||||
./hash-of-wisdom
|
./hash-of-wisdom
|
||||||
|
|
@ -31,6 +55,9 @@ go build -o client ./cmd/client
|
||||||
|
|
||||||
# Connect with client
|
# Connect with client
|
||||||
./client -addr localhost:8080
|
./client -addr localhost:8080
|
||||||
|
|
||||||
|
# Run tests
|
||||||
|
go test ./...
|
||||||
```
|
```
|
||||||
|
|
||||||
### Using Docker
|
### Using Docker
|
||||||
|
|
@ -50,38 +77,10 @@ docker run -p 8080:8080 -p 8081:8081 hash-of-wisdom
|
||||||
|
|
||||||
### Protocol & Implementation
|
### Protocol & Implementation
|
||||||
- [Protocol Specification](docs/PROTOCOL.md) - Binary protocol definition
|
- [Protocol Specification](docs/PROTOCOL.md) - Binary protocol definition
|
||||||
|
- [PoW Algorithm Analysis](docs/POW_ANALYSIS.md) - Algorithm selection rationale and comparison
|
||||||
- [Implementation Plan](docs/IMPLEMENTATION.md) - Development phases and progress
|
- [Implementation Plan](docs/IMPLEMENTATION.md) - Development phases and progress
|
||||||
- [Package Structure](docs/PACKAGES.md) - Code organization and package responsibilities
|
- [Package Structure](docs/PACKAGES.md) - Code organization and package responsibilities
|
||||||
- [Architecture Choices](docs/ARCHITECTURE.md) - Design decisions and patterns
|
- [Architecture Choices](docs/ARCHITECTURE.md) - Design decisions and patterns
|
||||||
|
|
||||||
### Production Readiness
|
### Production Readiness
|
||||||
- [Production Readiness Guide](docs/PRODUCTION_READINESS.md) - Requirements for production deployment
|
- [Production Readiness Guide](docs/PRODUCTION_READINESS.md) - Requirements for production deployment
|
||||||
|
|
||||||
## Algorithm Choice
|
|
||||||
|
|
||||||
The server uses **SHA-256 based proof-of-work** with leading zero bits difficulty:
|
|
||||||
- **Why SHA-256**: Cryptographically secure, well-tested, hardware-optimized
|
|
||||||
- **Leading Zero Bits**: Simple difficulty scaling, easy verification
|
|
||||||
- **HMAC Authentication**: Prevents challenge tampering and replay attacks
|
|
||||||
- **Configurable Difficulty**: Adaptive to different threat levels (4-30 bits)
|
|
||||||
|
|
||||||
This approach provides strong DDoS protection while remaining computationally reasonable for legitimate clients.
|
|
||||||
|
|
||||||
## Current Status
|
|
||||||
|
|
||||||
✅ **Complete**: Core functionality, TCP server, client, metrics, containerization
|
|
||||||
🔄 **In Progress**: Documentation (Phase 9)
|
|
||||||
📋 **Planned**: See [Production Readiness Guide](docs/PRODUCTION_READINESS.md) for production deployment requirements
|
|
||||||
|
|
||||||
## Testing
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Run all tests
|
|
||||||
go test ./...
|
|
||||||
|
|
||||||
# Run integration tests
|
|
||||||
go test ./test/integration/...
|
|
||||||
|
|
||||||
# Benchmarks
|
|
||||||
go test -bench=. ./internal/pow/...
|
|
||||||
```
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue