Skip to content

test_suite_asn1parse: improve testing of trailing garbage in parse_prefixes #350

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

Conversation

gilles-peskine-arm
Copy link
Collaborator

Do it in a way that's more systematic and clear. Add comments to document what's going on.

Before, the string to parse may contain trailing garbage (there was
never more than one byte), and there was a separate argument
indicating the length of the content. Now, the string to parse is the
exact content, and the test code runs an extra test step with a
trailing byte added.
@gilles-peskine-arm gilles-peskine-arm added enhancement New feature or request needs: review The pull request is ready for review. This generally means that it has no known issues. labels Jan 21, 2020
Copy link
Contributor

@mpg mpg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Collaborator

@yanesca yanesca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@yanesca yanesca removed the needs: review The pull request is ready for review. This generally means that it has no known issues. label Feb 5, 2020
@yanesca
Copy link
Collaborator

yanesca commented Feb 5, 2020

The CI failures are due to a known issue that is unrelated to this PR.

@yanesca yanesca merged commit f317dc4 into ARMmbed:development Feb 5, 2020
gilles-peskine-arm added a commit to gilles-peskine-arm/mbed-crypto that referenced this pull request Mar 23, 2020
* ARMmbed#352: Parse RSA parameters DP, DQ and QP from PKCS1 private keys
* ARMmbed#263: Introduce ASN.1 SEQUENCE traversal API
* ARMmbed#345: Fix possible error code mangling in psa_mac_verify_finish
* ARMmbed#357: Update Mbed Crypto with latest Mbed TLS changes as of 2020-02-03
* ARMmbed#350: test_suite_asn1parse: improve testing of trailing garbage in parse_prefixes
* ARMmbed#346: Improve robustness and testing of mbedtls_mpi_copy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants