| Function report | 
| Source Code: security\keys\keyctl.c | Create Date:2022-07-28 18:19:57 | 
| Last Modify:2020-03-18 07:59:52 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:Return a description of a key to userspace
Proto:long keyctl_describe_key(key_serial_t keyid, char __user *buffer, size_t buflen)
Type:long
Parameter:
| Type | Parameter | Name | 
|---|---|---|
| key_serial_t | keyid | |
| char __user * | buffer | |
| size_t | buflen | 
| 659 | instkey = Search the current process's keyrings for the authorisation key for* instantiation of a key. | 
| 671 | Go to error | 
| 674 | okay : | 
| 675 | key = key_ref_to_ptr(key_ref) | 
| 680 | infobuf = kasprintf(GFP_KERNEL, "%s;%d;%d;%08x;", name, from_kuid_munged(current_user_ns(), uid), from_kgid_munged(current_user_ns(), gid), access permissions ) | 
| 693 | If copy_to_user(buffer, infobuf, infolen) != 0 || copy_to_user(buffer + infolen, description, desclen + 1) != 0 Then ret = -EFAULT | 
| 700 | error2 : | 
| 701 | key_ref_put(key_ref) | 
| 702 | error : | 
| 703 | Return ret | 
| Name | Describe | 
|---|---|
| SYSCALL_DEFINE5 | The key control system call | 
| COMPAT_SYSCALL_DEFINE5 | The key control system call, 32-bit compatibility version for 64-bit archs | 
| Source code conversion tool public plug-in interface | X | 
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |