summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Pismenny <borisp@mellanox.com>2018-02-14 11:46:08 +0300
committerDavid S. Miller <davem@davemloft.net>2018-02-14 23:05:19 +0300
commitc410c1966fe6fcfb23bcac0924aaa6a6e7449829 (patch)
tree9fdb29c51b80329dba0745103efdf9a840fffec4
parent257082e6ae23e92898440f6bcb2857555bf7957c (diff)
downloadlinux-c410c1966fe6fcfb23bcac0924aaa6a6e7449829.tar.xz
tls: getsockopt return record sequence number
Return the TLS record sequence number in getsockopt. Signed-off-by: Boris Pismenny <borisp@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/tls/tls_main.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/net/tls/tls_main.c b/net/tls/tls_main.c
index c105f86a7ea6..e9b4b53ab53e 100644
--- a/net/tls/tls_main.c
+++ b/net/tls/tls_main.c
@@ -311,6 +311,8 @@ static int do_tls_getsockopt_tx(struct sock *sk, char __user *optval,
memcpy(crypto_info_aes_gcm_128->iv,
ctx->iv + TLS_CIPHER_AES_GCM_128_SALT_SIZE,
TLS_CIPHER_AES_GCM_128_IV_SIZE);
+ memcpy(crypto_info_aes_gcm_128->rec_seq, ctx->rec_seq,
+ TLS_CIPHER_AES_GCM_128_REC_SEQ_SIZE);
release_sock(sk);
if (copy_to_user(optval,
crypto_info_aes_gcm_128,