forked from RustCrypto/block-ciphers
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[pull] master from RustCrypto:master #2
Open
pull
wants to merge
377
commits into
mesalock-linux:master
Choose a base branch
from
RustCrypto:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This commit cuts releases of the following crates: - `blowfish` v0.5.0 - `cast5` v0.7.0 - `des` v0.4.0 - `idea` v0.1.0 - `rc2` v0.4.0 - `serpent` v0.1.0 - `sm4` v0.1.0 - `twofish` v0.3.0 - `threefish` v0.3.0 It also adds CHANGELOG.md details to `kuznyechik` and `magma` but does not release those yet as they had endianness issues we should double check are corrected before cutting a release.
* Use repeat expression * Use ref in iterator * Use u64::from()
"enviromental variable" -> "environment variable"
- Fix broken Unicode - Link to https://github.com/RustCrypto/meta/blob/master/HAZMAT.md
Includes the v0.0.1 release
- add `lints.rust.unexpected_cfgs` to Cargo.toml - threefish: fix typo in `cfg(feature = "cipher")`
Cuts a new release of every crate which previously received a pre.0 prerelease, i.e. is used as a (dev-)dependency in downstream projects that need to be upgraded. This includes the following: - `aes` v0.9.0-pre.1 - `belt-block` v0.2.0-pre.1 - `des` v0.9.0-pre.1 - `kuznyechik` v0.9.0-pre.1 - `magma` v0.10.0-pre.1
This pull request contains a constant-time software fixslicing implementation of the [GIFT](https://eprint.iacr.org/2017/622.pdf) block cipher, based on the C implementation of the original authors found [here](https://github.com/aadomn/gift/tree/master/crypto_bc/gift128/opt32). Gift is a PRESENT based block cipher with focus on energy efficiency and a small memory footprint making it ideal for usage in resource constrained environments. It gained some popularity as part of GIFT-COFB, which is a finalist in the current [NIST lightweight cryptography competition](https://csrc.nist.gov/Projects/lightweight-cryptography) as well as SUNDAE-GIFT. This pull request comes with an implementation of GIFT-128, meaning Gift operating on 128-bit blocks, though I am planning on implementing GIFT-64 in the future. It passes all test vectors and performs at ~44.5 cpb on an Intel Core i7 8700k with 3.7GHz core clock, while the C version "only" performs at ~47.1 cpb on the same machine.
This PR implements XTEA as described by various sources, including https://en.wikipedia.org/wiki/XTEA, XTEA is a historical cipher, which is no longer commonly used today, but some legacy software still uses it to this day. I tested that the cipher methods get properly unrolled, which boosts a 3x speed increase, and is one of the faster ciphers in this collection. (Hopefully there will be an unroll pragma sometime in the future) Partially solves #1 I decided against pre-computing keys as the computation is trivial, and doesn't have a noticeable impact on speed, probably because of memory accesses and that 256 byte don't fit easily in a cache line anyway.
- Updates `cipher` to v0.5.0-pre.6 - Sets both crates' versions to 0.0.0 - Renames gift to `gift-cipher` which is presently unregistered
Criterion is a relatively big dependency which unnecessarily gets pulled during testing. Additionally, it results in the [security warnings](https://github.com/RustCrypto/block-ciphers/security/dependabot/1). In addition to the benchmark changes, this PR also slightly tweaks module structure of the crate.
The new software backend implements the same approach as in the SSE2 backend, but uses `u128` instead of `__m128i`. The resulting performance is slightly worse compared to SSE2, but the code is cross-platform and should be much faster than the old "compact" software backend.
CI did not catch this issue because the job config was broken in the same PR which has introduced the bad code.
This PR unifies code between AES-NI and ARM backends and prepares ground for future removal of duplicated definitions of AES types in `autodetect`, `soft`, `ni`, and `armv8` modules. Additionally, it allows to quickly change number of blocks processed in parallel by different intrinsics-based backends instead of hardcoding it to 8 blocks.
This PR significantly reduces size of the crate. But now clean build of the crate takes 7-12 seconds, which is not great, but tolerable enough. Hopefully, performance of const eval will be improved in future. We could improve build times by using a build script and `include_bytes!`, but it would result in a somewhat less clear code and it would mean introduction of the first algorithmic crate which uses build script. Additionally, this PR adds a chain encryption test for a more thorough testing. Closes #448
New Ubuntu images are being deployed, which is causing the cached binaries not to work due to a GLIBC upgrade: https://github.blog/changelog/2024-09-25-actions-new-images-and-ubuntu-latest-changes/ To ensure we're caching consistently on the new image, switches from using `ubuntu-latest` to `ubuntu-24.04`. We can revert this change after October 30th, when the blog post says the deployment is complete.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by pull[bot]
Can you help keep this open source service alive? 💖 Please sponsor : )