GitHub - calpa/urusai: Go implementation of noisy HTTP/DNS traffic generator (original) (raw)

๐Ÿ”Š Urusai

ใ†ใ‚‹ใ•ใ„ - Your Privacy Shield in the Digital Noise

Go Report Card License: MIT GitHub stars GitHub last commit

A Go implementation of noisy - Making your web traffic less valuable, one request at a time ๐Ÿ›ก๏ธ

๐ŸŒŸ What is Urusai?

Urusai (Japanese for 'noisy') is your digital privacy companion that generates random HTTP/DNS traffic noise in the background while you browse the web. By creating this digital smokescreen, it helps make your actual web traffic data less valuable for tracking and selling.

โœจ Features

๐Ÿ“ฅ Installation

Arch Linux (AUR)

Void Linux

sudo xbps-install -S urusai

๐Ÿ“ฆ Using Pre-built Binaries

The easiest way to get started is to download a pre-built binary from the releases page ๐Ÿš€

  1. Download the appropriate binary for your platform:
    • ๐ŸŽ urusai-macos-amd64 - for macOS Intel systems
    • ๐Ÿ urusai-macos-arm64 - for macOS Apple Silicon systems
    • ๐Ÿง urusai-linux-amd64 - for Linux x86_64 systems
    • ๐ŸชŸ urusai-windows-amd64.exe - for Windows x86_64 systems
  2. Make the binary executable (Unix-based systems only):
  3. ๐Ÿš€ Run the binary:

๐ŸŽ On macOS (Intel)

./urusai-macos-amd64

๐Ÿ On macOS (Apple Silicon)

./urusai-macos-arm64

๐Ÿง On Linux

./urusai-linux-amd64

๐ŸชŸ On Windows (using Command Prompt)

urusai-windows-amd64.exe

๐Ÿ› ๏ธ Building from Source

๐Ÿ’ป Clone the repository

git clone https://github.com/calpa/urusai.git

๐Ÿ“ Navigate to the project directory

cd urusai

๐Ÿ’ฟ Build the project

go build -o urusai

๐Ÿณ Using Docker

๐ŸŒŒ Pull from Docker Hub

๐Ÿ“ฅ Pull the latest image

docker pull calpa/urusai:latest

๐Ÿš€ Run the container with default configuration

docker run calpa/urusai

โš™๏ธ Run with custom configuration (mount your config file)

docker run -v $(pwd)/config.json:/app/config.json calpa/urusai --config config.json

The Docker image is available for multiple platforms:

๐Ÿ’ป Build Locally

๐Ÿ—๏ธ Build the Docker image

docker build -t urusai .

๐Ÿš€ Run your locally built container

docker run urusai

Usage

Run with built-in default configuration

./urusai

Run with custom configuration file

./urusai --config config.json

Show help

./urusai --help

Command Line Arguments

โš™๏ธ Configuration

Urusai comes with a built-in default configuration, but you can also provide your own custom configuration file. The configuration is in JSON format with the following structure:

๐Ÿ‘จโ€๐Ÿ’ป For Developers

๐Ÿ› ๏ธ Development

Urusai is developed using standard Go practices. Here are some commands that will help you during development:

๐Ÿ’ป Run the project directly without building

go run main.go

๐Ÿ“ Run with a specific log level

go run main.go --log debug

โš™๏ธ Run with a custom configuration file

go run main.go --config config.json

โฐ Run with a timeout (in seconds)

go run main.go --timeout 300

๐Ÿงช Testing

Urusai includes comprehensive test coverage for all packages. The tests verify configuration loading, command-line flag parsing, and crawler functionality.

๐ŸŽฃ Run all tests

go test ./...

๐Ÿ“˜ Run tests with verbose output

go test -v ./...

๐Ÿ“ˆ Run tests with coverage

go test -cover ./...

๐Ÿ“‹ Generate a coverage report

go test -coverprofile=coverage.out ./... go tool cover -html=coverage.out

Test files include:

๐Ÿ—๏ธ Building

๐Ÿ› ๏ธ Build for the current platform

go build -o urusai

๐Ÿ’ป Build for a specific platform (e.g., Linux)

GOOS=linux GOARCH=amd64 go build -o urusai-linux-amd64

๐ŸŒ Build for multiple platforms

GOOS=darwin GOARCH=amd64 go build -o urusai-macos-amd64 GOOS=windows GOARCH=amd64 go build -o urusai-windows-amd64.exe

โญ Star History

Star History Chart

๐Ÿš€ Releases

Urusai uses GitHub Actions for automated releases. When a new tag with format v* (e.g., v1.0.0) is pushed to the repository, GitHub Actions will automatically:

  1. ๐Ÿงช Run tests to ensure code quality
  2. ๐Ÿ”จ Build binaries for all supported platforms (macOS Intel/ARM, Linux, Windows)
  3. ๐Ÿ“ฆ Create compressed archives of the binaries
  4. ๐ŸŽ‰ Create a new GitHub release with the binaries attached

To create a new release:

๐Ÿท๏ธ Tag the commit

git tag v1.0.0

๐Ÿš€ Push the tag to GitHub

git push origin v1.0.0

The GitHub Actions workflow will handle the rest automatically.

๐Ÿ’Ž Code Quality

๐ŸŽจ Format code

go fmt ./...

๐Ÿ” Vet code for potential issues

go vet ./...

โœจ Run linter (requires golint)

go install golang.org/x/lint/golint@latest golint ./...

๐Ÿ”ฌ Run static analysis (requires staticcheck)

go install honnef.co/go/tools/cmd/staticcheck@latest staticcheck ./...

๐Ÿ“œ License

This project is licensed under the MIT License - see the LICENSE file for details. โš–๏ธ