Skip to contentSkip to conversation

syscalls/request_key04: new test for request_key() permission check bug

PATCH Richard Palethorpe 3 participants 3 messages Jan 10, 2018 – Jan 19, 2018 Keys/keyrings

lore
Share & tools
lore
#0 lore raw

Hello Eric,

Quoted 9 lines · Eric Biggers

From: Eric Biggers <[email protected]>

Add a test for a bug that allowed the request_key() system call to be used to add a key to a keyring using only Search permission. This bug was assigned CVE-2017-17807.

---

Quoted 8 lines

No changes since v1, just added a patch preceding this one.

 include/lapi/keyctl.h                              |  4 +
 runtest/cve                                        |  1 +
 runtest/syscalls                                   |  1 +
 .../kernel/syscalls/request_key/request_key04.c    | 87 ++++++++++++++++++++++
 4 files changed, 93 insertions(+)
 create mode 100644 testcases/kernel/syscalls/request_key/request_key04.c

Only issue is that you are missing .gitignore entry. Otherwise LGTM.

Signature · 2 lines
Thank you,
Richard.
#1 lore raw
Quoted 8 lines

From: Eric Biggers <[email protected]>

Add a test for a bug that allowed the request_key() system call to be used to add a key to a keyring using only Search permission. This bug was assigned CVE-2017-17807.

---

LGTM both commits.
BTW it might be worth to define SAFE_KEYCTL().

Kind regards,
Petr