Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\keys\keyctl.c Create Date:2022-07-28 18:19:32
Last Modify:2020-03-18 07:59:52 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Join a (named) session keyring.* Create and join an anonymous session keyring or join a named session* keyring, creating it if necessary. A named session keyring must have Search* permission for it to be joined. Session keyrings without this permit will

Proto:long keyctl_join_session_keyring(const char __user *_name)

Type:long

Parameter:

TypeParameterName
const char __user *_name
295  name = NULL
296  If _name Then
297  name = strndup_user - duplicate an existing string from user space*@s: The string to duplicate*@n: Maximum number of bytes to copy, including the trailing NUL.* Return: newly allocated copy of @s or an ERR_PTR() in case of error
298  If IS_ERR(name) Then
299  ret = PTR_ERR(name)
300  Go to error
303  ret = -EPERM
304  If name[0] == '.' Then Go to error_name
309  ret = Join the named keyring as the session keyring if possible else attempt to* create a new one of that name and join that
310  error_name :
311  kfree(name)
312  error :
313  Return ret
Caller
NameDescribe
SYSCALL_DEFINE5The key control system call
COMPAT_SYSCALL_DEFINE5The key control system call, 32-bit compatibility version for 64-bit archs