[crypto] Expose pem_asn1() for use with non-image data

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2017-05-29 17:29:20 +01:00
parent b506528c1e
commit 14e3b4b29a
2 changed files with 81 additions and 42 deletions

View File

@@ -3,12 +3,15 @@
/** @file
*
* PEM image format
* PEM-encoded ASN.1 data
*
*/
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
#include <stdint.h>
#include <ipxe/uaccess.h>
#include <ipxe/asn1.h>
#include <ipxe/image.h>
/** Pre-encapsulation boundary marker */
@@ -17,6 +20,9 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
/** Post-encapsulation boundary marker */
#define PEM_END "-----END"
extern int pem_asn1 ( userptr_t data, size_t len, size_t offset,
struct asn1_cursor **cursor );
extern struct image_type pem_image_type __image_type ( PROBE_NORMAL );
#endif /* _IPXE_PEM_H */