Skip to contentSkip to conversation

Patch "crypto: asymmetric_keys - remove always false comparison" has been added to the 4.3-stable tree

PATCH [email protected] 1 participant 1 message Dec 10, 2015

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

crypto: asymmetric_keys - remove always false comparison

to the 4.3-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
crypto-asymmetric_keys-remove-always-false-comparison.patch
and it can be found in the queue-4.3 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From 4dd17c9c8a30c8d8cd1c9d4b94f08aca4b038d3e Mon Sep 17 00:00:00 2001

From: sudip <[email protected]>
Date: Thu, 17 Sep 2015 13:12:51 +0530
Subject: crypto: asymmetric_keys - remove always false comparison

From: sudip <[email protected]>

commit 4dd17c9c8a30c8d8cd1c9d4b94f08aca4b038d3e upstream.

hour, min and sec are unsigned int and they can never be less than zero.

---
 crypto/asymmetric_keys/x509_cert_parser.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
crypto/asymmetric_keys/x509_cert_parser.c +3 -3
@@ -546,9 +546,9 @@ int x509_decode_time(time64_t *_t,  size
 	if (year < 1970 ||
 	    mon < 1 || mon > 12 ||
 	    day < 1 || day > mon_len ||
-	    hour < 0 || hour > 23 ||
-	    min < 0 || min > 59 ||
-	    sec < 0 || sec > 59)
+	    hour > 23 ||
+	    min > 59 ||
+	    sec > 59)
 		goto invalid_time;
 	
 	*_t = mktime64(year, mon, day, hour, min, sec);

Patches currently in stable-queue which might be from [email protected] are

queue-4.3/crypto-asymmetric_keys-remove-always-false-comparison.patch