rand_tool
A formidable random number generator capable of producing passwords, service ports, and UUIDs, alongside the ability to encode and decode Base64.
Installation
Features
- Password Generation: Create strong, random passwords with configurable length and character sets
- Port Generation: Generate random port numbers within specified ranges
- UUID Generation: Generate Version 4 UUIDs
- Base64 Operations: Encode and decode Base64 strings
Usage
Password Generation
Generate random passwords with customizable options:
# Generate 5 passwords (18 chars, numbers + uppercase + lowercase, default)
# Generate 10 passwords with 24 characters
# Generate password with special symbols
# Generate password without numbers
# Generate password with only lowercase letters
Options:
-c, --count <COUNT>: Number of passwords to generate (default: 5)-c --length <LENGTH>: Password length (default: 18)-n --numbers: Exclude digits 0-9-u --uppercase: Exclude uppercase letters A-Z-l --lowercase: Exclude lowercase letters a-z-s, --symbols: Include special characters
Port Generation
Generate random port numbers within a specified range:
# Generate 5 random ports (default range: 1024-49151)
# Generate 10 ports in custom range
# Generate ports in specific range
# Generate unique ports without duplicates
Options:
-c, --count <COUNT>: Number of ports to generate (default: 5)-r, --range <RANGE>: Port range in format "min-max" (default: 1024-49151)--unique: Generate unique ports without duplicates
UUID Generation
Generate Version 4 UUIDs:
# Generate 5 UUIDs (default)
# Generate 20 UUIDs
Base64 Operations
Encode and decode Base64 strings:
# Encode string to Base64
# Decode Base64 string
Options:
-e, --encode <STRING>: Encode UTF-8 string to Base64-d, --decode <STRING>: Decode Base64 string to UTF-8
Exactly one of --encode or --decode is required.
Global Options
-c, --count <COUNT>: Default quantity of items to generate (default: 5)-h, --help: Print help information-V, --version: Print version information
Examples
# Generate 3 strong passwords with symbols
# Generate 100 ports for testing
# Generate single UUID
# Encode sensitive data