Skip to content

Fix wrong assert if padding is disabled#21

Open
simc wants to merge 25 commits into
cloudflare:masterfrom
isar:master
Open

Fix wrong assert if padding is disabled#21
simc wants to merge 25 commits into
cloudflare:masterfrom
isar:master

Conversation

@simc

@simc simc commented Mar 19, 2021

Copy link
Copy Markdown

No description provided.

@inikulin inikulin requested review from vkrasnov and wbl March 26, 2021 13:50
@inikulin

Copy link
Copy Markdown
Collaborator

@leisim Could you give more context for the issue that this one fixes, please? Regression test would be useful too

@simc

simc commented Mar 26, 2021

Copy link
Copy Markdown
Author

@inikulin
This assert assert!(output.len() >= input.len() + block_size); requires the output size to be greater than the input size to make sure there is enough space for padding.
If no padding is used (not necessary if the input size is a multiple of the cipher block size) the output of the encryption has the exact same size as the input.

I'll add a regression test 👍

@inikulin

inikulin commented Jun 1, 2021

Copy link
Copy Markdown
Collaborator

@leisim seems like needs a rebase and a regression test

nox pushed a commit to nox/boring that referenced this pull request Jul 28, 2023
…atest tags

Merge in OXY/boring-rpk from scrat/update-images-5cb0d33b14bb9ed955c8df0a25455c1f10646182 to master

* commit 'a55301dc68dcdc5e35808597c921804cbd40b915':
  SEC-3915 - Upgrade Docker base images to get the latest security updates
@nox

nox commented Oct 9, 2023

Copy link
Copy Markdown
Contributor

@simc Ping?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants