| Crates.io | yellowstone-shield-cli |
| lib.rs | yellowstone-shield-cli |
| version | 0.6.0 |
| created_at | 2025-06-19 12:20:47.657075+00 |
| updated_at | 2025-07-16 16:25:02.105101+00 |
| description | Yellowstone Shield CLI |
| homepage | |
| repository | https://github.com/rpcpool/yellowstone-shield |
| max_upload_size | |
| id | 1718292 |
| size | 240,275 |
The Yellowstone Shield CLI is a command-line tool for managing access policies for Solana identities, such as validators, wallets, or programs. It allows users to create and manage policies, add, update and remove identites, and configure various settings related to the policy.
To install the CLI, ensure you have Rust and Cargo installed on your system. Then, clone the repository and build the project:
git clone https://github.com/rpcpool/yellowstone-shield
cd yellowstone-shield
cargo build --release --bin yellowstone-shield-cli
The binary should be located at ./target/release/yellowstone-shield-cli.
The CLI provides several commands to interact with the shield policies and identities. Below are the available commands and their options:
-r, --rpc <URL>: RPC endpoint url to override using the Solana config.-T, --timeout <SECONDS>: Set the timeout duration (default is 90 seconds).-l, --log-level <LEVEL>: Set the log level (default is "off").-k, --keypair <FILE>: Path to the local owner keypair file -- not a hardware wallet.Before creating a new Policy, plan ahead by creating a URI-addressable JSON file containing the metadata for your Policy. The Policy metadata should use the format shown in this example (https://gateway.irys.xyz/CdxWAuxk483JsqJdbE8cSKkZEMTJ1EKpDsUWmqGTaFu8):
{
"name": "Top 25 Validators by Stake",
"symbol": "TV25",
"description": "A Yellowstone Shield policy of the top 25 validators by stake.",
"image": "https://gateway.irys.xyz/Hhdy76nXVpNBCg1pVLtpctaZXbpnSufWggbyiMFUoCTh",
"external_url": "https://triton.one",
"attributes": []
}
After uploading your metadata to a publicly accessible URI, you will use the URI with the --uri parameter when creating the Policy.
Create a Policy
yellowstone-shield-cli policy create [OPTIONS] --strategy <STRATEGY> --name <NAME> --symbol <SYMBOL> --uri <URI>
-r, --rpc <RPC>: RPC endpoint URL to override using the Solana config.--strategy <STRATEGY>: The strategy to use for the policy. Valid options are 'allow' or 'deny'.-l, --log-level <LOG_LEVEL>: Log level (default is "off").--name <NAME>: The name of the policy.-k, --keypair <KEYPAIR>: Path to the local owner keypair file -- not a hardware wallet.--symbol <SYMBOL>: The symbol of the policy.--uri <URI>: The URI of the policy.-h, --help: Print help.After creating a new Policy, you will receive CLI output including the Mint address required in the following steps.
Add Identities
yellowstone-shield-cli identities add --mint <MINT> --identities-path <IDENTITIES>
--mint <MINT>: The mint address linked to the shield policy.--identities-path <IDENTITIES>: File path to a list of public keys, each on a new line, to be added.Update Identities
yellowstone-shield-cli identities update --mint <MINT> --identities-path <IDENTITIES>
--mint <MINT>: The mint address linked to the shield policy.--identities-path <IDENTITIES>: File path to a list of public keys, each on a new line, to be updated/replaced.Remove Identities
yellowstone-shield-cli identities remove --mint <MINT> --identities-path <IDENTITIES>
--mint <MINT>: The mint address linked to the shield policy.--identities-path <IDENTITIES>: File path to a list of public keys, each on a new line, to be removed.The CLI uses the Solana CLI configuration file to manage RPC endpoints and keypair paths. You can override these settings using the command-line options provided.
Contributions are welcome! Please fork the repository and submit a pull request with your changes.
This project is licensed under the MIT License. See the LICENSE file for details.
For questions or support, please open an issue on github.