Skip to contentSkip to conversation

Bug#881830: linux: cherry-pick "security/keys: add CONFIG_KEYS_COMPAT to Kconfig" to stretch kernel

DISCUSSION Ben Hutchings 3 participants 3 messages Nov 16, 2017 – Nov 17, 2017 3 messages not in the archive Stable branch

lore
Share & tools
lore
#3 lore raw
In reply to a message not in the archive
Quoted 7 lines · James Cowgill

Since I was a little puzzled as to why keyutils built previously on mips, I found this commit to 4.8 which caused the need for KEYS_COMPAT:

commit 20f06ed9f61a185c6dabd662c310bed6189470df

Author: David Howells <[email protected]>
Date:   Wed Jul 27 11:43:37 2016 +0100
Quoted 8 lines

KEYS: 64-bit MIPS needs to use compat_sys_keyctl for 32-bit userspace

MIPS64 needs to use compat_sys_keyctl for 32-bit userspace rather than calling sys_keyctl. The latter will work in a lot of cases, thereby hiding the issue.

Now I'm thinking maybe this can be argued as a bugfix for the above commit and put in upstream 4.9?

Greg, please queue up these two for 4.9:

5c2a625937ba arm64: support keyctl() system call in 32-bit mode 47b2c3fff493 security/keys: add CONFIG_KEYS_COMPAT to Kconfig

Ben.

Signature · 3 lines
Ben Hutchings
In a hierarchy, every employee tends to rise to his level of
incompetence.
#4 lore raw

Hi,

Quoted 14 lines · Ben Hutchings
Quoted 13 lines · James Cowgill

Since I was a little puzzled as to why keyutils built previously on mips, I found this commit to 4.8 which caused the need for KEYS_COMPAT:

commit 20f06ed9f61a185c6dabd662c310bed6189470df

Author: David Howells <[email protected]>
Date:   Wed Jul 27 11:43:37 2016 +0100

KEYS: 64-bit MIPS needs to use compat_sys_keyctl for 32-bit userspace

MIPS64 needs to use compat_sys_keyctl for 32-bit userspace rather than calling sys_keyctl. The latter will work in a lot of cases, thereby hiding the issue.

Quoted 7 lines
Quoted 2 lines

Now I'm thinking maybe this can be argued as a bugfix for the above commit and put in upstream 4.9?

Greg, please queue up these two for 4.9:

5c2a625937ba arm64: support keyctl() system call in 32-bit mode 47b2c3fff493 security/keys: add CONFIG_KEYS_COMPAT to Kconfig

Sorry, I asked for this in two places. I think it's already queued up for 4.9 now.

Thanks,
James

#5 lore raw
Quoted 20 lines · James Cowgill

Hi,

Quoted 17 lines · Ben Hutchings
Quoted 15 lines · James Cowgill

Since I was a little puzzled as to why keyutils built previously on mips, I found this commit to 4.8 which caused the need for KEYS_COMPAT:

commit 20f06ed9f61a185c6dabd662c310bed6189470df

Author: David Howells <[email protected]>
Date:   Wed Jul 27 11:43:37 2016 +0100

KEYS: 64-bit MIPS needs to use compat_sys_keyctl for 32-bit userspace

MIPS64 needs to use compat_sys_keyctl for 32-bit userspace rather than calling sys_keyctl. The latter will work in a lot of cases, thereby hiding the issue.

Now I'm thinking maybe this can be argued as a bugfix for the above commit and put in upstream 4.9?

Quoted 7 lines
Quoted 4 lines

Greg, please queue up these two for 4.9:

5c2a625937ba arm64: support keyctl() system call in 32-bit mode 47b2c3fff493 security/keys: add CONFIG_KEYS_COMPAT to Kconfig

Sorry, I asked for this in two places. I think it's already queued up for 4.9 now.

Well, close, but not quite. The second patch there reverts the first patch, and adds the "generic" work. As I already handled that in the merge of the second patch, the first one is not needed, and the end result should be the same.

So all is good. Or at least I think so, someone verifying I got this all right would be appreciated :)

thanks,

greg k-h