Skip to content
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

Report correct unencrypted length #126

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nevelis
Copy link

@nevelis nevelis commented May 3, 2021

COSE_Encrypt_GetContent() returns a valid pointer to the content, but the length parameter is set to 0.

The reason for this is because cbOut is set to the correct value, but is then used as the remaining bytes in the EVP functions and gets set to 0.

This PR sets the output parameter to the correct value, so we can use the payload safely.

@coveralls
Copy link

coveralls commented May 3, 2021

Coverage Status

Coverage decreased (-0.4%) to 89.348% when pulling 08b55fa on selfienetworks:fix-decrypt-length into 97d1805 on cose-wg:master.

COSE_Encrypt_GetContent() returns a valid pointer to the content, but
the length parameter is set to 0.

The reason for this is because cbOut is set to the correct value, but is
then used as the remaining bytes in the EVP functions and gets set to 0.

This commit sets the output parameter to the correct value, so we can
use the payload safely.
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.

2 participants