Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:Assume (or clear) the authority to instantiate the specified key

Proto:long keyctl_assume_authority(key_serial_t id)

Type:long

Parameter:

TypeParameterName
key_serial_tid
1447  ret = -EINVAL
1448  If id < 0 Then Go to error
1452  If id == 0 Then
1453  ret = Change the request_key authorisation key on the current process.
1454  Go to error
1462  authkey = Search the current process's keyrings for the authorisation key for* instantiation of a key.
1463  If IS_ERR(authkey) Then
1464  ret = PTR_ERR(authkey)
1465  Go to error
1468  ret = Change the request_key authorisation key on the current process.
1469  If ret == 0 Then ret = key serial number
1471  key_put - Discard a reference to a key.*@key: The key to discard a reference from.* Discard a reference to a key, and when all the references are gone, we* schedule the cleanup task to come and pull it out of the tree in process
1472  error :
1473  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