Skip to content

Commit

Permalink
Bump hybrid-array to v0.2.0-pre.7
Browse files Browse the repository at this point in the history
  • Loading branch information
tarcieri committed Dec 31, 2023
1 parent acd0dbc commit b891a6c
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 19 deletions.
14 changes: 7 additions & 7 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion aes/src/soft.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ macro_rules! define_aes_impl {
#[inline]
fn new(key: &Key<Self>) -> Self {
Self {
keys: $fixslice_key_schedule(key.as_ref()),
keys: $fixslice_key_schedule(key.into()),
}
}
}
Expand Down
12 changes: 6 additions & 6 deletions aria/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ fn test_rfc5794_a1() {

let mut buf = Array::from(pt);
c.encrypt_block(&mut buf);
assert_eq!(buf.as_ref(), &ct);
assert_eq!(&buf, &ct);
c.decrypt_block(&mut buf);
assert_eq!(buf.as_ref(), &pt);
assert_eq!(&buf, &pt);
}

/// Test vector from RFC 5794, Appendix A.2
Expand All @@ -29,9 +29,9 @@ fn test_rfc5794_a2() {

let mut buf = Array::from(pt);
c.encrypt_block(&mut buf);
assert_eq!(buf.as_ref(), &ct);
assert_eq!(&buf, &ct);
c.decrypt_block(&mut buf);
assert_eq!(buf.as_ref(), &pt);
assert_eq!(&buf, &pt);
}

/// Test vector from RFC 5794, Appendix A.3
Expand All @@ -45,7 +45,7 @@ fn test_rfc5794_a3() {

let mut buf = Array::from(pt);
c.encrypt_block(&mut buf);
assert_eq!(buf.as_ref(), &ct);
assert_eq!(&buf, &ct);
c.decrypt_block(&mut buf);
assert_eq!(buf.as_ref(), &pt);
assert_eq!(&buf, &pt);
}
4 changes: 2 additions & 2 deletions belt-block/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ fn belt_block() {
let cipher = BeltBlock::new(&key.into());
let mut block = pt.into();
cipher.encrypt_block(&mut block);
assert_eq!(block, ct.into());
assert_eq!(block, ct);
cipher.decrypt_block(&mut block);
assert_eq!(block, pt.into());
assert_eq!(block, pt);
}
}
}
Expand Down
6 changes: 3 additions & 3 deletions cast6/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ fn rfc2144_a() {
let key128 = hex!("2342bb9efa38542c0af75647f29f615d");
let key192 = hex!("2342bb9efa38542cbed0ac83940ac298bac77a7717942863");
let key256 = hex!("2342bb9efa38542cbed0ac83940ac2988d7c47ce264908461cc1b5137ae6b604");
let ct128 = hex!("c842a08972b43d20836c91d1b7530f6b").into();
let ct192 = hex!("1b386c0210dcadcbdd0e41aa08a7a7e8").into();
let ct256 = hex!("4f6a2038286897b9c9870136553317fa").into();
let ct128 = hex!("c842a08972b43d20836c91d1b7530f6b");
let ct192 = hex!("1b386c0210dcadcbdd0e41aa08a7a7e8");
let ct256 = hex!("4f6a2038286897b9c9870136553317fa");
let pt = Block::<Cast6>::default();

let mut buf = pt;
Expand Down

0 comments on commit b891a6c

Please sign in to comment.