Skip to content

Commit 957dba9

Browse files
authored
aes: fix min version of zeroize and build warnings on AArch64 (#562)
1 parent c69a235 commit 957dba9

4 files changed

Lines changed: 22 additions & 15 deletions

File tree

Cargo.lock

Lines changed: 12 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

aes/CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,13 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## 0.9.1 (UNRELEASED)
9+
### Fixed
10+
- Minimal version of `zeroize` dependency ([#562])
11+
- Build warnings on AArch64 targets ([#562])
12+
13+
[#562]: https://github.com/RustCrypto/block-ciphers/pull/562
14+
815
## 0.9.0 (2026-04-10)
916
### Changed
1017
- Bump `cipher` dependency to v0.5

aes/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ categories = ["cryptography", "no-std"]
1515
[dependencies]
1616
cipher = "0.5"
1717
cpubits = "0.1"
18-
zeroize = { version = "1.5.6", optional = true, default-features = false, features = ["aarch64"] }
18+
zeroize = { version = "1.8", optional = true, default-features = false, features = ["aarch64"] }
1919

2020
[target.'cfg(any(target_arch = "aarch64", target_arch = "x86_64", target_arch = "x86"))'.dependencies]
2121
cpufeatures = "0.3"

aes/src/armv8/encdec.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ pub(super) unsafe fn encrypt_par<const KEYS: usize, ParBlocks: ArraySize>(
6868
keys: &[uint8x16_t; KEYS],
6969
blocks: InOut<'_, '_, Array<Block, ParBlocks>>,
7070
) {
71-
#[inline(always)]
71+
#[target_feature(enable = "aes")]
7272
unsafe fn par_round<ParBlocks: ArraySize>(
7373
key: uint8x16_t,
7474
blocks: &mut Array<uint8x16_t, ParBlocks>,
@@ -126,7 +126,7 @@ pub(super) unsafe fn decrypt_par<const KEYS: usize, ParBlocks: ArraySize>(
126126
keys: &[uint8x16_t; KEYS],
127127
blocks: InOut<'_, '_, Array<Block, ParBlocks>>,
128128
) {
129-
#[inline(always)]
129+
#[target_feature(enable = "aes")]
130130
unsafe fn par_round<ParBlocks: ArraySize>(
131131
key: uint8x16_t,
132132
blocks: &mut Array<uint8x16_t, ParBlocks>,

0 commit comments

Comments
 (0)