-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
error.c does not include asn1.h #3328
Comments
Hi @davidhuziji. For questions like this it's best to use the Mbed TLS mailing list: https://lists.trustedfirmware.org/mailman/listinfo/mbed-tls. This issue tracker is mainly for reporting bugs and possible enhancements. Regards, Dan. |
Thx a lot, Dan! Thx for saving this orphan thread. :) |
That's actually a bug. ASN.1 doesn't depend on anything, so it should be possible to build the library with it and nothing else. We won't fix it in Mbed Crypto, which is no longer maintained, but it's a bug in Mbed TLS as well. We probably never noticed before because if you include ASN.1, you probably include something else that uses it and that will pull in If you write your own |
Thx @gilles-peskine-arm. I'm building up a minimal set of configurations to support TLS with ECDHE_ECDSA and therefore ASN.1 is selected. It seems that Mbed Crypto is running in secure world in my use case. I'd prefer to put Crypto stuff as little as possible to optimize the secure binary size. If a feature belongs to common protocol level, I'd enable it in mbedTLS in non-secure world. But due to my limited knowledge of TLS, I'm not sure whether the 3 configs (PKCS#5, PKCS#12, OID) should be enabled by default in Mbed Crypto if ECDHE_ECDSA is selected for TLS. Or should I rely on those 3 configs to get include of |
You probably don't need PKCS#5 or PKCS#12, those are for loading encrypted key files. You do need OID for X.509, but that would be in the normal world for you. You do need |
I think the fix is to delete the line |
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Thx! @gilles-peskine-arm |
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
Hi all,
I'm redirected from Mbed Crypto repo as it suggests to bring up new issues here. Please gently kick me out if I misunderstood something.
I'm working on a use case in which the memory footprint is very sensitive. Therefore I only uncomment essential options (I thought) in mbed-crypto configuration file.
However, ASN.1 related definitions cannot be found during mbed-crypto build. The error log looks like the code block below.
It seems that
asn1.h
is not directly included inerror.c
. But it is included in other modules whose header files are included inerror.c
. It looks likeasn1.h
include depends on other modules.So I guess another module is expected to be enabled by default when ASN.1 is selected. Right? May I know which modules should be enabled together with ASN.1, by default?
Thanks a lot.
The text was updated successfully, but these errors were encountered: