]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 May 2018 10:30:08 +0000 (12:30 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 May 2018 10:30:08 +0000 (12:30 +0200)
added patches:
xfrm-fix-xfrm_do_migrate-with-aead-e.g-aes-gcm.patch

queue-4.14/series
queue-4.14/xfrm-fix-xfrm_do_migrate-with-aead-e.g-aes-gcm.patch [new file with mode: 0644]

index dfd51be8bca834a5732bc36c856b7170686471ee..be4905605376a76f7119a7748ee468c668e1fce0 100644 (file)
@@ -40,3 +40,4 @@ udp-fix-so_bindtodevice.patch
 scsi-aacraid-correct-hba_send-to-include-iu_type.patch
 xfrm-use-__skb_queue_tail-in-xfrm_trans_queue.patch
 btrfs-take-trans-lock-before-access-running-trans-in-check_delayed_ref.patch
+xfrm-fix-xfrm_do_migrate-with-aead-e.g-aes-gcm.patch
diff --git a/queue-4.14/xfrm-fix-xfrm_do_migrate-with-aead-e.g-aes-gcm.patch b/queue-4.14/xfrm-fix-xfrm_do_migrate-with-aead-e.g-aes-gcm.patch
new file mode 100644 (file)
index 0000000..d6f19d1
--- /dev/null
@@ -0,0 +1,42 @@
+From 75bf50f4aaa1c78d769d854ab3d975884909e4fb Mon Sep 17 00:00:00 2001
+From: Antony Antony <antony@phenome.org>
+Date: Thu, 7 Dec 2017 21:54:27 +0100
+Subject: xfrm: fix xfrm_do_migrate() with AEAD e.g(AES-GCM)
+
+From: Antony Antony <antony@phenome.org>
+
+commit 75bf50f4aaa1c78d769d854ab3d975884909e4fb upstream.
+
+copy geniv when cloning the xfrm state.
+
+x->geniv was not copied to the new state and migration would fail.
+
+xfrm_do_migrate
+  ..
+  xfrm_state_clone()
+   ..
+   ..
+   esp_init_aead()
+   crypto_alloc_aead()
+    crypto_alloc_tfm()
+     crypto_find_alg() return EAGAIN and failed
+
+Signed-off-by: Antony Antony <antony@phenome.org>
+Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
+Cc: Ben Hutchings <ben.hutchings@codethink.co.uk>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ net/xfrm/xfrm_state.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/net/xfrm/xfrm_state.c
++++ b/net/xfrm/xfrm_state.c
+@@ -1345,6 +1345,7 @@ static struct xfrm_state *xfrm_state_clo
+       if (orig->aead) {
+               x->aead = xfrm_algo_aead_clone(orig->aead);
++              x->geniv = orig->geniv;
+               if (!x->aead)
+                       goto error;
+       }