mirror of
https://github.com/redstrate/Physis.git
synced 2025-04-24 05:27:45 +00:00
Fix Blowfish test
This commit is contained in:
parent
56a738fde7
commit
e18a242bcb
1 changed files with 2 additions and 2 deletions
|
@ -15,12 +15,12 @@ const KEYBITS: u32 = 64u32 >> 3;
|
||||||
/// ```
|
/// ```
|
||||||
/// # use physis::blowfish::Blowfish;
|
/// # use physis::blowfish::Blowfish;
|
||||||
/// let key = b"abcdefgh";
|
/// let key = b"abcdefgh";
|
||||||
/// let data = b"foobar";
|
/// let data = b"foobar ";
|
||||||
///
|
///
|
||||||
/// let fish = Blowfish::new(key);
|
/// let fish = Blowfish::new(key);
|
||||||
/// let encrypted = fish.encrypt(data).unwrap();
|
/// let encrypted = fish.encrypt(data).unwrap();
|
||||||
/// let decrypted = fish.decrypt(&encrypted).unwrap();
|
/// let decrypted = fish.decrypt(&encrypted).unwrap();
|
||||||
/// # assert!(data == decrypted)
|
/// # assert_eq!(data, &decrypted[..])
|
||||||
/// ```
|
/// ```
|
||||||
pub struct Blowfish {
|
pub struct Blowfish {
|
||||||
p: [u32; 18],
|
p: [u32; 18],
|
||||||
|
|
Loading…
Add table
Reference in a new issue