aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/sysctl_net_ipv4.c
diff options
context:
space:
mode:
authorYuchung Cheng <ycheng@google.com>2017-10-18 11:22:51 -0700
committerDavid S. Miller <davem@davemloft.net>2017-10-20 13:21:36 +0100
commit1fba70e5b6bed53496ba1f1f16127f5be01b5fb6 (patch)
tree22b060a68ca7b36f052b8f943c91c7ba78b8ddcf /net/ipv4/sysctl_net_ipv4.c
parentMerge branch 'mlxsw-extack' (diff)
downloadlinux-dev-1fba70e5b6bed53496ba1f1f16127f5be01b5fb6.tar.xz
linux-dev-1fba70e5b6bed53496ba1f1f16127f5be01b5fb6.zip
tcp: socket option to set TCP fast open key
New socket option TCP_FASTOPEN_KEY to allow different keys per listener. The listener by default uses the global key until the socket option is set. The key is a 16 bytes long binary data. This option has no effect on regular non-listener TCP sockets. Signed-off-by: Yuchung Cheng <ycheng@google.com> Reviewed-by: Eric Dumazet <edumazet@google.com> Reviewed-by: Christoph Paasch <cpaasch@apple.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/sysctl_net_ipv4.c')
-rw-r--r--net/ipv4/sysctl_net_ipv4.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/ipv4/sysctl_net_ipv4.c b/net/ipv4/sysctl_net_ipv4.c
index cac8dd309f39..81d218346cf7 100644
--- a/net/ipv4/sysctl_net_ipv4.c
+++ b/net/ipv4/sysctl_net_ipv4.c
@@ -284,7 +284,8 @@ static int proc_tcp_fastopen_key(struct ctl_table *table, int write,
ret = -EINVAL;
goto bad_key;
}
- tcp_fastopen_reset_cipher(net, user_key, TCP_FASTOPEN_KEY_LENGTH);
+ tcp_fastopen_reset_cipher(net, NULL, user_key,
+ TCP_FASTOPEN_KEY_LENGTH);
}
bad_key: