1#
2# Makefile for asymmetric cryptographic keys
3#
4
5obj-$(CONFIG_ASYMMETRIC_KEY_TYPE) += asymmetric_keys.o
6
7asymmetric_keys-y := asymmetric_type.o signature.o
8
9obj-$(CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE) += public_key.o
10obj-$(CONFIG_PUBLIC_KEY_ALGO_RSA) += rsa.o
11
12#
13# X.509 Certificate handling
14#
15obj-$(CONFIG_X509_CERTIFICATE_PARSER) += x509_key_parser.o
16x509_key_parser-y := \
17	x509-asn1.o \
18	x509_akid-asn1.o \
19	x509_rsakey-asn1.o \
20	x509_cert_parser.o \
21	x509_public_key.o
22
23$(obj)/x509_cert_parser.o: \
24	$(obj)/x509-asn1.h \
25	$(obj)/x509_akid-asn1.h \
26	$(obj)/x509_rsakey-asn1.h
27$(obj)/x509-asn1.o: $(obj)/x509-asn1.c $(obj)/x509-asn1.h
28$(obj)/x509_akid-asn1.o: $(obj)/x509_akid-asn1.c $(obj)/x509_akid-asn1.h
29$(obj)/x509_rsakey-asn1.o: $(obj)/x509_rsakey-asn1.c $(obj)/x509_rsakey-asn1.h
30
31clean-files	+= x509-asn1.c x509-asn1.h
32clean-files	+= x509_akid-asn1.c x509_akid-asn1.h
33clean-files	+= x509_rsakey-asn1.c x509_rsakey-asn1.h
34
35#
36# PKCS#7 message handling
37#
38obj-$(CONFIG_PKCS7_MESSAGE_PARSER) += pkcs7_message.o
39pkcs7_message-y := \
40	pkcs7-asn1.o \
41	pkcs7_parser.o \
42	pkcs7_trust.o \
43	pkcs7_verify.o
44
45$(obj)/pkcs7_parser.o: $(obj)/pkcs7-asn1.h
46$(obj)/pkcs7-asn1.o: $(obj)/pkcs7-asn1.c $(obj)/pkcs7-asn1.h
47
48clean-files	+= pkcs7-asn1.c pkcs7-asn1.h
49
50#
51# PKCS#7 parser testing key
52#
53obj-$(CONFIG_PKCS7_TEST_KEY) += pkcs7_test_key.o
54pkcs7_test_key-y := \
55	pkcs7_key_type.o
56
57#
58# Signed PE binary-wrapped key handling
59#
60obj-$(CONFIG_SIGNED_PE_FILE_VERIFICATION) += verify_signed_pefile.o
61
62verify_signed_pefile-y := \
63	verify_pefile.o \
64	mscode_parser.o \
65	mscode-asn1.o
66
67$(obj)/mscode_parser.o: $(obj)/mscode-asn1.h $(obj)/mscode-asn1.h
68$(obj)/mscode-asn1.o: $(obj)/mscode-asn1.c $(obj)/mscode-asn1.h
69
70clean-files	+= mscode-asn1.c mscode-asn1.h
71