This project decodes Base58-encoded private and public keys used in Backpack wallets for example, ensures they are in the correct format, and serializes them into a JSON file (wallet.json
).
- Base58 decoding
- Keypair serialization as JSON
- Rust installed (https://www.rust-lang.org/tools/install)
- Dependencies: bs58 and serde_json (automatically handled via Cargo)
Make sure your repository has a clean and organized folder structure:
├── .gitignore
├── README.md
└── wallet_key_json/
├── Cargo.toml
└── src/
└── main.rs
Clone the repository:
git clone https://github.com/Skillz23/rust-wallet-key-manager-for-Eclipse-v2.git
cd rust-wallet-key-manager-for-Eclipse-v2/wallet_key_json
To run the project, use Cargo:
cargo run
In the file src/main.rs
, replace the following placeholders with your actual Base58-encoded keys:
let private_key_str = "your_base58_private_key_here";
let public_key_str = "your_base58_public_key_here";
After running the project with cargo run
, the program will create a file called wallet.json
, which will contain the serialized keypair.
You can replace the placeholders with actual keys, for example:
Private Key: 5p3fsFU7GvNJU5L47UBiqK2TUTs8nXoN2L9Qqc8vVNP3sctwUqe
Public Key: B2NpV8eA5RTSnH5F8KMNRNYvExg5PAkrtk
When you run the project, the resulting wallet.json
file will look like this:
[67, 98, 65, 213, 135, 20, ... ]
Feel free to open issues or submit pull requests if you would like to contribute to the project.
This project is licensed under the MIT License