[crypto] Allow for parsing of partial ASN.1 cursors
authorMichael Brown <mcb30@ipxe.org>
Thu, 28 Jul 2016 14:02:15 +0000 (15:02 +0100)
committerMichael Brown <mcb30@ipxe.org>
Thu, 28 Jul 2016 14:02:15 +0000 (15:02 +0100)
commit296670a6481ab8b4090c3e53fa4b8dc9518e7c69
tree0512604b5923d4d32729131b16fe4870c32d7f32
parent5846ce2e9e567a216167fa389117011879fb9f8a
[crypto] Allow for parsing of partial ASN.1 cursors

Allow code to create a partial ASN.1 cursor containing only the type
and length bytes, so that asn1_start() may be used to determine the
length of a large ASN.1 blob without first allocating memory to hold
the entire blob.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/crypto/asn1.c
src/include/ipxe/asn1.h