函数逻辑报告 |
Source Code:security\keys\request_key.c |
Create Date:2022-07-27 19:58:05 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| 首页 | 函数Tree |
| 注解内核,赢得工具 | 下载SCCT | English |
函数名称:Allocate a new key in under-construction state and attempt to link it in to* the requested keyring.* May return a key that's already under construction instead if there was a* race between two thread calling request_key().
函数原型:static int construct_alloc_key(struct keyring_search_context *ctx, struct key *dest_keyring, unsigned long flags, struct key_user *user, struct key **_key)
返回类型:int
参数:
| 类型 | 参数 | 名称 |
|---|---|---|
| struct keyring_search_context * | ctx | |
| struct key * | dest_keyring | |
| unsigned long | flags | |
| struct key_user * | user | |
| struct key ** | _key |
| 372 | struct assoc_array_edit * edit = NULL |
| 378 | kenter("%s,%s,,,", name, description) |
| 381 | * _key = NULL |
| 382 | mutex_lock( & construction initiation lock ) |
| 384 | perm等于possessor can view a key's attributes 按位或possessor can find a key in search / search a keyring 按位或possessor can create a link to a key/keyring 按位或possessor can set key attributes |
| 385 | perm或等于user permissions... |
| 395 | 如果是错误则转到:alloc_failed |
| 398 | 设置内存位 |
| 400 | 如果dest_keyring则 |
| 402 | 如果ret小于0则转到:link_lock_failed |
| 405 | 如果ret小于0则转到:link_prealloc_failed |
| 417 | 如果非是错误则转到:key_already_present |
| 424 | 如果dest_keyring则Finish linking a key into to a keyring.* Must be called with __key_link_begin() having being called. |
| 428 | kleave(" = 0 [%d]", key_serial(key)) |
| 429 | 返回:0 |
| 433 | key_already_present : |
| 436 | key等于key_ref_to_ptr(key_ref) |
| 437 | 如果dest_keyring则 |
| 441 | Finish linking a key into to a keyring.* Must be called with __key_link_begin() having being called. |
| 442 | 如果ret小于0则转到:link_check_failed |
| 447 | kleave(" = -EINPROGRESS [%d]", key_serial(key)) |
| 448 | 返回:负EINPROGRESS |
| 450 | link_check_failed : |
| 454 | 返回:ret |
| 456 | link_prealloc_failed : |
| 457 | Finish linking a key into to a keyring.* Must be called with __key_link_begin() having being called. |
| 458 | link_lock_failed : |
| 462 | 返回:ret |
| 464 | alloc_failed : |
| 467 | 返回:错误 |
| 名称 | 描述 |
|---|---|
| construct_key_and_link | Commence key construction. |
| 源代码转换工具 开放的插件接口 | X |
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |