aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kernel/module_signing.c14
-rw-r--r--lib/asn1_decoder.c2
2 files changed, 8 insertions, 8 deletions
diff --git a/kernel/module_signing.c b/kernel/module_signing.c
index ea1b1df5dbb0..f2970bddc5ea 100644
--- a/kernel/module_signing.c
+++ b/kernel/module_signing.c
@@ -27,13 +27,13 @@
27 * - Information block 27 * - Information block
28 */ 28 */
29struct module_signature { 29struct module_signature {
30 enum pkey_algo algo : 8; /* Public-key crypto algorithm */ 30 u8 algo; /* Public-key crypto algorithm [enum pkey_algo] */
31 enum pkey_hash_algo hash : 8; /* Digest algorithm */ 31 u8 hash; /* Digest algorithm [enum pkey_hash_algo] */
32 enum pkey_id_type id_type : 8; /* Key identifier type */ 32 u8 id_type; /* Key identifier type [enum pkey_id_type] */
33 u8 signer_len; /* Length of signer's name */ 33 u8 signer_len; /* Length of signer's name */
34 u8 key_id_len; /* Length of key identifier */ 34 u8 key_id_len; /* Length of key identifier */
35 u8 __pad[3]; 35 u8 __pad[3];
36 __be32 sig_len; /* Length of signature data */ 36 __be32 sig_len; /* Length of signature data */
37}; 37};
38 38
39/* 39/*
diff --git a/lib/asn1_decoder.c b/lib/asn1_decoder.c
index de2c8b5a715b..5293d2433029 100644
--- a/lib/asn1_decoder.c
+++ b/lib/asn1_decoder.c
@@ -91,7 +91,7 @@ next_tag:
91 91
92 /* Extract the length */ 92 /* Extract the length */
93 len = data[dp++]; 93 len = data[dp++];
94 if (len < 0x7f) { 94 if (len <= 0x7f) {
95 dp += len; 95 dp += len;
96 goto next_tag; 96 goto next_tag;
97 } 97 }