Skip to contentSkip to conversation

pull request (net-next): ipsec-next 2020-12-12

PATCH Applied Steffen Klassert 2 participants 4 messages Dec 12, 2020

Subsystems (4)
lore
Share & tools
lore

Steffen Klassert

author maintainer
#0 lore raw

Just one patch this time:

1) Redact the SA keys with kernel lockdown confidentiality. If enabled, no secret keys are sent to uuserspace. From Antony Antony.

Please pull or let me know if there are problems.

Thanks!

The following changes since commit 8be33ecfc1ffd2da20cc29e957e4cb6eb99310cb:

net: skb_vlan_untag(): don't reset transport offset if set by GRO layer (2020-11-09 20:03:55 -0800)

are available in the Git repository at:

git://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec-next.git master

for you to fetch changes up to c7a5899eb26e2a4d516d53f65b6dd67be2228041:

xfrm: redact SA secret with lockdown confidentiality (2020-11-27 11:03:06 +0100)

----------------------------------------------------------------
Antony Antony (1):
xfrm: redact SA secret with lockdown confidentiality

 include/linux/security.h |  1 +
 net/xfrm/xfrm_user.c     | 74 +++++++++++++++++++++++++++++++++++++++++++-----
 security/security.c      |  1 +
 3 files changed, 69 insertions(+), 7 deletions(-)
author maintainer
#1 lore raw

PATCH 1/1 xfrm: redact SA secret with lockdown confidentiality

From: Antony Antony <[email protected]>

redact XFRM SA secret in the netlink response to xfrm_get_sa() or dumpall sa.
Enable lockdown, confidentiality mode, at boot or at run time.

e.g. when enabled:
cat /sys/kernel/security/lockdown
none integrity [confidentiality]

ip xfrm state
src 172.16.1.200 dst 172.16.1.100

	proto esp spi 0x00000002 reqid 2 mode tunnel
	replay-window 0
	aead rfc4106(gcm(aes)) 0x0000000000000000000000000000000000000000 96

note: the aead secret is redacted. Redacting secret is also a FIPS 140-2 requirement.

v1->v2
- add size checks before memset calls
v2->v3
- replace spaces with tabs for consistency
v3->v4
- use kernel lockdown instead of a /proc setting
v4->v5
- remove kconfig option

---
 include/linux/security.h |  1 +
 net/xfrm/xfrm_user.c     | 74 ++++++++++++++++++++++++++++++++++++----
 security/security.c      |  1 +
 3 files changed, 69 insertions(+), 7 deletions(-)
include/linux/security.h +1 -0
index bc2725491560..1112a79a7dba 100644
@@ -127,6 +127,7 @@ enum lockdown_reason {
 	LOCKDOWN_PERF,
 	LOCKDOWN_TRACEFS,
 	LOCKDOWN_XMON_RW,
+	LOCKDOWN_XFRM_SECRET,
 	LOCKDOWN_CONFIDENTIALITY_MAX,
 };
 
net/xfrm/xfrm_user.c +67 -7

108 lines not on this page · raw message

security/security.c +1 -0
index a28045dc9e7f..abff77c1c8a7 100644
@@ -65,6 +65,7 @@ const char *const lockdown_reasons[LOCKDOWN_CONFIDENTIALITY_MAX+1] = {
 	[LOCKDOWN_PERF] = "unsafe use of perf",
 	[LOCKDOWN_TRACEFS] = "use of tracefs",
 	[LOCKDOWN_XMON_RW] = "xmon read and write access",
+	[LOCKDOWN_XFRM_SECRET] = "xfrm SA secret",
 	[LOCKDOWN_CONFIDENTIALITY_MAX] = "confidentiality",
 };
 
Signature · 1 line
2.25.1
#2 lore raw

Re: [PATCH] xfrm: redact SA secret with lockdown confidentiality

This patch was applied to netdev/net-next.git (refs/heads/master):

Hello:

This patch was applied to netdev/net-next.git (refs/heads/master):

Quoted 11 lines · On Sat, 12 Dec 2020 09:57:37 +0100 you wrote:

From: Antony Antony <[email protected]>

redact XFRM SA secret in the netlink response to xfrm_get_sa() or dumpall sa.
Enable lockdown, confidentiality mode, at boot or at run time.

e.g. when enabled:
cat /sys/kernel/security/lockdown
none integrity [confidentiality]

[...]

Here is the summary with links:
- xfrm: redact SA secret with lockdown confidentiality

    https://git.kernel.org/netdev/net-next/c/c7a5899eb26e

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html

#3 lore raw
In reply to Steffen Klassert
This pull request was applied to netdev/net-next.git (refs/heads/master):

Hello:

This pull request was applied to netdev/net-next.git (refs/heads/master):

Quoted 9 lines · On Sat, 12 Dec 2020 09:57:36 +0100 you wrote:

Just one patch this time:

1) Redact the SA keys with kernel lockdown confidentiality. If enabled, no secret keys are sent to uuserspace. From Antony Antony.

Please pull or let me know if there are problems.

[...]

Here is the summary with links:
- pull request (net-next): ipsec-next 2020-12-12

    https://git.kernel.org/netdev/net-next/c/e2437ac2f59d

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html