|
| 1 | +# SeedShield |
| 2 | + |
| 3 | +**Cryptographic structure seed protection for Paper/Spigot servers.** |
| 4 | + |
| 5 | +SeedShield prevents seed cracking tools (chunkbase, SeedCrackerX, Structurecracker) from determining structure locations by replacing each structure type's placement salt with an irreversible SHA-256 derived value. |
| 6 | + |
| 7 | +**This is the first Paper/Spigot plugin to provide cryptographic structure seed protection.** Previously, this level of protection was only available through Fabric mods or custom server forks. |
| 8 | + |
| 9 | +## How It Works |
| 10 | + |
| 11 | +Minecraft determines structure positions using this formula: |
| 12 | + |
| 13 | +``` |
| 14 | +position = f(worldSeed, regionCoords, salt) |
| 15 | +``` |
| 16 | + |
| 17 | +The `salt` is a hardcoded integer per structure type. Tools like chunkbase know these default salts, so knowing the world seed = knowing all structure locations. |
| 18 | + |
| 19 | +SeedShield replaces each salt with: |
| 20 | + |
| 21 | +``` |
| 22 | +salt = SHA-256(secretKey + ":" + worldSeed + ":" + structureType)[0..4] |
| 23 | +``` |
| 24 | + |
| 25 | +- **Per-structure isolation**: Each structure type gets a unique cryptographic salt. Cracking one type's salt reveals nothing about others. |
| 26 | +- **Secret key protection**: Without the 256-bit key (stored in `config.yml`), salts cannot be reversed. |
| 27 | +- **Stronghold protection**: Also modifies `concentricRingsSeed` and recalculates ring positions. |
| 28 | + |
| 29 | +## Comparison with Existing Solutions |
| 30 | + |
| 31 | +| Solution | Platform | Modifies Structure Positions | Crypto Protection | Per-Structure Isolation | Stronghold Protection | |
| 32 | +|----------|----------|:---:|:---:|:---:|:---:| |
| 33 | +| **SeedShield** | **Paper/Spigot plugin** | **✅** | **✅ SHA-256** | **✅** | **✅** | |
| 34 | +| [SeedGuard](https://github.com/DrexHD/SeedGuard) | Fabric mod | ✅ | ❌ Random | ✅ | ✅ | |
| 35 | +| [SecureSeed](https://github.com/Earthcomputer/SecureSeed) | Fabric mod (1.16.5, abandoned) | ✅ | ✅ BLAKE2 | ✅ | ✅ | |
| 36 | +| [AntiSeedCracker](https://github.com/akshualy/AntiSeedCracker) | Spigot plugin | ❌ | ❌ | ❌ | ❌ | |
| 37 | +| Leaf `secure-seed` | Server fork | ✅ | ✅ 1024-bit | ✅ | ✅ | |
| 38 | +| spigot.yml seeds | Built-in | ✅ | ❌ Plain int | ❌ | ⚠️ | |
| 39 | + |
| 40 | +## Installation |
| 41 | + |
| 42 | +1. Download `SeedShield-1.0.0.jar` from [Releases](https://github.com/yunluo7/SeedShield/releases) |
| 43 | +2. Place it in your server's `plugins/` folder |
| 44 | +3. **Delete the region files** of worlds you want to protect (structures must regenerate) |
| 45 | +4. Restart the server |
| 46 | +5. Edit `plugins/SeedShield/config.yml` to configure which worlds to protect |
| 47 | + |
| 48 | +> **Important**: SeedShield only affects newly generated chunks. Existing structures in already-generated chunks will not change positions. |
| 49 | +
|
| 50 | +## Configuration |
| 51 | + |
| 52 | +```yaml |
| 53 | +# Auto-generated 256-bit secret key. DO NOT SHARE. |
| 54 | +secret-key: "a1b2c3d4..." |
| 55 | + |
| 56 | +# Worlds to protect |
| 57 | +enabled-worlds: |
| 58 | + - world |
| 59 | + - survival |
| 60 | +``` |
| 61 | +
|
| 62 | +## Requirements |
| 63 | +
|
| 64 | +- Paper 1.21+ (or forks: Leaves, Purpur, Folia, etc.) |
| 65 | +- Java 17+ |
| 66 | +
|
| 67 | +## Security Analysis |
| 68 | +
|
| 69 | +| Attack Vector | Protection Level | |
| 70 | +|---------------|:---:| |
| 71 | +| chunkbase / online seed maps | ✅ Fully defeated | |
| 72 | +| SeedCrackerX client mod | ✅ Defeated (combine with FakeSeed for hashed seed) | |
| 73 | +| Brute-force single structure salt (2³² attempts) | ⚠️ Possible per-type, but each type must be cracked independently | |
| 74 | +| Reverse secret key from salt | ✅ Infeasible (SHA-256 preimage resistance) | |
| 75 | +| Cross-structure salt derivation | ✅ Impossible without key | |
| 76 | +
|
| 77 | +## Building from Source |
| 78 | +
|
| 79 | +```bash |
| 80 | +git clone https://github.com/yunluo7/SeedShield.git |
| 81 | +cd SeedShield |
| 82 | +mvn package |
| 83 | +``` |
| 84 | + |
| 85 | +The JAR will be at `target/SeedShield-1.0.0.jar`. |
| 86 | + |
| 87 | +## License |
| 88 | + |
| 89 | +MIT License |
0 commit comments