Browse Source

Fix CVE-2019-8912 : net: crypto set sk to NULL when af_alg_release. : 9060cb719e61b685ec0102574e10337fa5f445ea

RISCi_ATOM 3 weeks ago
parent
commit
3a3cd11885
1 changed files with 14 additions and 0 deletions
  1. 14 0
      target/linux/generic/patches-4.4/999-fix_cve-2019-8912.patch

+ 14 - 0
target/linux/generic/patches-4.4/999-fix_cve-2019-8912.patch

@@ -0,0 +1,14 @@
+--- a/crypto/af_alg.c
++++ b/crypto/af_alg.c
+@@ -121,8 +121,10 @@ static void alg_do_release(const struct
+ 
+ int af_alg_release(struct socket *sock)
+ {
+-	if (sock->sk)
++	if (sock->sk) {
+ 		sock_put(sock->sk);
++		sock->sk = NULL;
++	}
+ 	return 0;
+ }
+ EXPORT_SYMBOL_GPL(af_alg_release);