Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/heroesofcode/cryptotools
cryptotools is a cryptography library
https://github.com/heroesofcode/cryptotools
Last synced: 1 day ago
JSON representation
cryptotools is a cryptography library
- Host: GitHub
- URL: https://github.com/heroesofcode/cryptotools
- Owner: heroesofcode
- License: mit
- Created: 2024-04-08T01:36:25.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2024-09-27T22:46:57.000Z (about 1 month ago)
- Last Synced: 2024-10-31T11:58:54.423Z (6 days ago)
- Language: Rust
- Homepage:
- Size: 61.5 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# cryptotools
[![CI](https://github.com/heroesofcode/cryptotools/actions/workflows/CI.yml/badge.svg)](https://github.com/heroesofcode/cryptotools/actions/workflows/CI.yml)
[![Crates.io](https://img.shields.io/crates/v/cryptotools)](https://crates.io/crates/cryptotools)
![Msrv](https://img.shields.io/badge/msrv-1.56.1-blue.svg?logo=rust&logoColor=orange)
[![Downloads](https://img.shields.io/crates/d/cryptotools.svg?logo=rust&logoColor=orange)](https://crates.io/crates/cryptotools)
[![Docs](https://docs.rs/cryptotools/badge.svg)](https://docs.rs/cryptotools)
[![License](https://img.shields.io/github/license/heroesofcode/cryptotools.svg)](https://github.com/heroesofcode/cryptotools/blob/main/LICENSE)cryptotools is a cryptography library, with it you can:
- [x] Encode to base64
- [x] Decode the base64 value
- [x] Encrypt to md5## Installing
In the file `Cargo.toml`
```toml
[dependencies]
cryptotools = "0.2.0"
```## Usage
In the first example, if you want to encode and decode base64
```rust
use cryptotools::encode_base64::Base64Encode;
use cryptotools::decode_base64::Base64Decode;// Encode
let encode = Base64Encode::encode("123456789");
println!("{}", encode);// Decode
let decode = Base64Decode::decode("MTIzNDU2Nzg5");
println!("{}", decode);
```To encrypt a value to md5
```rust
use cryptotools::encrypt_md5::MD5;let md5 = MD5::encrypt("9999");
println!("{}", md5);
```## Contributing
To contribute, just fork this project and then open a pull request, feel free to contribute, bring ideas and raise any problem in the issue tab.
## License
cryptotools is released under the MIT license. See [LICENSE](https://github.com/heroesofcode/cryptotools/blob/main/LICENSE) for details.