WO2022042746A1 - Key management method and apparatus - Google Patents

Key management method and apparatus Download PDF

Info

Publication number
WO2022042746A1
WO2022042746A1 PCT/CN2021/115727 CN2021115727W WO2022042746A1 WO 2022042746 A1 WO2022042746 A1 WO 2022042746A1 CN 2021115727 W CN2021115727 W CN 2021115727W WO 2022042746 A1 WO2022042746 A1 WO 2022042746A1
Authority
WO
WIPO (PCT)
Prior art keywords
key
role
identity authentication
decryption key
authentication method
Prior art date
Application number
PCT/CN2021/115727
Other languages
French (fr)
Chinese (zh)
Inventor
王东临
Original Assignee
北京书生网络技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from CN202010897535.9A external-priority patent/CN114124395B/en
Priority claimed from CN202010897527.4A external-priority patent/CN111970126A/en
Application filed by 北京书生网络技术有限公司 filed Critical 北京书生网络技术有限公司
Publication of WO2022042746A1 publication Critical patent/WO2022042746A1/en
Priority to US18/175,872 priority Critical patent/US20230208634A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • H04L9/0866Generation of secret information including derivation or calculation of cryptographic keys or passwords involving user or device identifiers, e.g. serial number, physical or biometrical information, DNA, hand-signature or measurable physical characteristics
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0816Key establishment, i.e. cryptographic processes or cryptographic protocols whereby a shared secret becomes available to two or more parties, for subsequent use
    • H04L9/0819Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s)
    • H04L9/0822Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s) using key encryption key
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0816Key establishment, i.e. cryptographic processes or cryptographic protocols whereby a shared secret becomes available to two or more parties, for subsequent use
    • H04L9/0819Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s)
    • H04L9/0825Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s) using asymmetric-key encryption or public key infrastructure [PKI], e.g. key signature or public key certificates
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/088Usage controlling of secret information, e.g. techniques for restricting cryptographic keys to pre-authorized uses, different access levels, validity of crypto-period, different key- or password length, or different strong and weak cryptographic algorithms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0894Escrow, recovery or storing of secret information, e.g. secret key escrow or cryptographic key storage
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/14Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using a plurality of keys or algorithms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2209/00Additional information or applications relating to cryptographic mechanisms or cryptographic arrangements for secret or secure communication H04L9/00
    • H04L2209/56Financial cryptography, e.g. electronic payment or e-cash

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Storage Device Security (AREA)

Abstract

Provided are a key management method and apparatus. The key management method comprises: acquiring the authorization of a user by means of a first identity authentication mode, so as to generate a first authentication encryption key, wherein the first identity authentication mode is used for logging in with a digital identity; and encrypting at least one role decryption key by using the first authentication encryption key, so as to obtain at least one initial encrypted role decryption key corresponding to the first identity authentication mode, wherein the at least one role decryption key corresponds to at least one role of the digital identity on a one-to-one basis, and is used for decrypting at least one encrypted target key, so as to obtain at least one target key. By means of the technical solution of the present application, an identity authentication mode can be associated with a target key, thereby facilitating the process of managing and using a target key.

Description

密钥管理方法及装置Key management method and device 技术领域technical field
本申请涉及加密技术领域,具体涉及一种密钥管理方法及装置。The present application relates to the field of encryption technology, and in particular to a key management method and device.
发明背景Background of the Invention
随着区块链技术的成长,越来越多的投资者开始接触数字货币。然而,用于管理数字货币的密钥由于位数较多且毫无规律,往往非常难以记忆,成为了数字货币普及路上的门槛。为了让用户能够更加方便且更加稳妥地保管密钥,近些年市场上涌现出了一些解决方案,然而,始终没有出现一种方案能够真正地消解用户在密钥管理方面的压力。With the growth of blockchain technology, more and more investors are beginning to come into contact with digital currencies. However, the keys used to manage digital currency are often very difficult to remember due to the large number of digits and irregularities, which has become a threshold for the popularization of digital currency. In order to allow users to keep keys more conveniently and securely, some solutions have emerged in the market in recent years. However, there has never been a solution that can really relieve the pressure of users in key management.
与此同时,物联网正在高速发展,生活中越来越多的产品开始实现智能化管理。然而,各类智能产品导致用户需要管理众多的零散账户,反而让用户感到不便。如果发生管理不善的情况,甚至会给用户的资产带来安全隐患。At the same time, the Internet of Things is developing rapidly, and more and more products in life are beginning to realize intelligent management. However, all kinds of smart products cause users to manage many scattered accounts, which makes users feel inconvenient. If mismanagement occurs, it may even bring security risks to users' assets.
发明内容SUMMARY OF THE INVENTION
有鉴于此,为了解决现有技术中用户在资产管理方面所面临的上述问题,本申请的实施例提供了一种密钥管理方法及装置。In view of this, in order to solve the above-mentioned problems faced by users in asset management in the prior art, the embodiments of the present application provide a key management method and apparatus.
根据本申请实施例的第一方面,提供了一种密钥管理方法,包括:通过第一身份认证方式获取用户的授权,以生成第一认证加密密钥,其中,第一身份认证方式用于登录数字身份;利用第一认证加密密钥对至少一个角色解密密钥进行加密,得到第一身份认证方式对应的至少一个初始加密角色解密密钥,其中,至少一个角色解密密钥与数字身份的至少一个角色一一对应,用于对至少一个加密后的目标密钥进行解密,以得到至少一个目标密钥。According to a first aspect of the embodiments of the present application, a key management method is provided, including: obtaining a user's authorization through a first identity authentication method to generate a first authentication encryption key, wherein the first identity authentication method is used for Log in to the digital identity; use the first authentication encryption key to encrypt at least one role decryption key, and obtain at least one initial encrypted role decryption key corresponding to the first identity authentication method, wherein at least one role decryption key is associated with the digital identity. At least one role is in one-to-one correspondence, and is used for decrypting at least one encrypted target key to obtain at least one target key.
根据本申请实施例的第二方面,提供了一种密钥管理方法,包括:获取数字身份的第一身份认证方式对应的第一认证解密密钥;获取数字身份待添加的第二身份认证方式对应的第二认证加密密钥;利用第一认证解密密钥对第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥;利用第二认证加密密钥对第一角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第一角色解密密钥,其中,第一角色解密密钥与数字身份的至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。According to a second aspect of the embodiments of the present application, a key management method is provided, including: obtaining a first authentication and decryption key corresponding to a first identity authentication method of a digital identity; obtaining a second identity authentication method to be added to the digital identity the corresponding second authentication encryption key; use the first authentication decryption key to decrypt the initially encrypted first role decryption key corresponding to the first identity authentication method to obtain the first role decryption key; use the second authentication encryption key Encrypt the first character decryption key to obtain the initial encrypted first character decryption key corresponding to the second identity authentication method, wherein the first character decryption key corresponds to the first character in at least one character of the digital identity, and uses Decrypt the encrypted first target key to obtain the first target key.
根据本申请实施例的第三方面,提供了一种密钥管理装置,包括:第一获取模块,用于通过第一身份认证方式获取用户的授权,以生成第一认证加密密钥,其中,第一身份认证方式用于登录数字身份;第一加密模块,用于利用第一认证加密密钥对至少一个角色解密密钥进行加密,得到第一身份认证方式对应的至少一个初始加密角色解密密钥,其中,至少一个角色解密密钥与数字身份的至少一个角色一一对应,用于对至少一个加密后的目标密钥进行解密,以得到至少一个目标密钥。According to a third aspect of the embodiments of the present application, a key management device is provided, including: a first acquisition module, configured to acquire a user's authorization through a first identity authentication method to generate a first authentication encryption key, wherein, The first identity authentication method is used to log in the digital identity; the first encryption module is used to encrypt at least one character decryption key by using the first authentication encryption key, and obtain at least one initial encrypted character decryption key corresponding to the first identity authentication method. At least one character decryption key corresponds to at least one character of the digital identity one-to-one, and is used to decrypt at least one encrypted target key to obtain at least one target key.
根据本申请实施例的第四方面,提供了一种密钥管理装置,包括:第一获取模块,用于获取数字身份的第一身份认证方式对应的第一认证解密密钥;第二获取模块,用于获取数字身份待添加的第二身份认证方式对应的第二认证加密密钥;第一解密模块,用于利用第一认证解密密钥对第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥;第一加密模块,用于利用第二认证加密密钥对第一角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第一角色解密密钥,其中,第一角色解密密 钥与数字身份的至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。According to a fourth aspect of the embodiments of the present application, a key management device is provided, including: a first acquisition module for acquiring a first authentication and decryption key corresponding to a first identity authentication method of a digital identity; a second acquisition module , used to obtain the second authentication encryption key corresponding to the second identity authentication method to which the digital identity is to be added; the first decryption module is used to use the first authentication decryption key to initially encrypt the first role corresponding to the first identity authentication method The decryption key is decrypted to obtain the first character decryption key; the first encryption module is used to encrypt the first character decryption key by using the second authentication encryption key to obtain the initial encrypted first character corresponding to the second identity authentication method. A character decryption key, wherein the first character decryption key corresponds to the first character in at least one character of the digital identity, and is used to decrypt the encrypted first target key to obtain the first target key.
根据本申请实施例的第五方面,提供了一种电子设备,包括:处理器;存储器,其中,存储器用于存储处理器可执行的指令,指令在被处理器执行时,使得处理器执行上述第一方面或第二方面所提供的密钥管理方法。According to a fifth aspect of the embodiments of the present application, an electronic device is provided, including: a processor; and a memory, wherein the memory is used to store instructions executable by the processor, and when the instructions are executed by the processor, the instructions cause the processor to execute the above The key management method provided by the first aspect or the second aspect.
根据本申请实施例的第六方面,提供了一种计算机可读存储介质,包括存储在其上的计算机指令,计算机指令在被处理器执行时,使得处理器执行上述第一方面或第二方面所提供的密钥管理方法。According to a sixth aspect of the embodiments of the present application, a computer-readable storage medium is provided, including computer instructions stored thereon, and when executed by a processor, the computer instructions cause the processor to perform the above-mentioned first aspect or the second aspect The provided key management method.
本申请实施例提供了一种密钥管理方法及装置,通过生成第一身份认证方式对应的第一认证加密密钥,利用第一认证加密密钥对数字身份下的至少一个角色解密密钥进行加密,其中,至少一个角色解密密钥用于对加密后的目标密钥进行解密以得到至少一个目标密钥,从而能够将身份认证方式与目标密钥关联起来,方便目标密钥的管理和使用过程。The embodiments of the present application provide a key management method and device, by generating a first authentication encryption key corresponding to a first identity authentication method, and using the first authentication encryption key to perform at least one role decryption key under a digital identity. encryption, wherein at least one role decryption key is used to decrypt the encrypted target key to obtain at least one target key, so that the identity authentication method can be associated with the target key, which facilitates the management and use of the target key Process.
附图简要说明Brief Description of Drawings
图1是本申请一示例性实施例提供的密钥管理系统的系统架构示意图。FIG. 1 is a schematic diagram of a system architecture of a key management system provided by an exemplary embodiment of the present application.
图2是本申请一示例性实施例提供的密钥管理方法的流程示意图。FIG. 2 is a schematic flowchart of a key management method provided by an exemplary embodiment of the present application.
图3是本申请另一示例性实施例提供的密钥管理方法的流程示意图。FIG. 3 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application.
图4是本申请另一示例性实施例提供的密钥管理方法的流程示意图。FIG. 4 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application.
图5是本申请另一示例性实施例提供的密钥管理方法的流程示意图。FIG. 5 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application.
图6是本申请另一示例性实施例提供的密钥管理方法的流程示意图。FIG. 6 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application.
图7是本申请另一示例性实施例提供的密钥管理方法的流程示意图。FIG. 7 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application.
图8是本申请另一示例性实施例提供的密钥管理方法的流程示意图。FIG. 8 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application.
图9是本申请另一示例性实施例提供的密钥管理方法的流程示意图。FIG. 9 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application.
图10是本申请一示例性实施例提供的密钥管理装置的结构示意图。FIG. 10 is a schematic structural diagram of a key management apparatus provided by an exemplary embodiment of the present application.
图11是本申请另一示例性实施例提供的密钥管理装置的结构示意图。FIG. 11 is a schematic structural diagram of a key management apparatus provided by another exemplary embodiment of the present application.
图12是本申请一示例性实施例提供的用于密钥管理的电子设备的框图。FIG. 12 is a block diagram of an electronic device for key management provided by an exemplary embodiment of the present application.
实施本发明的方式MODES OF IMPLEMENTING THE INVENTION
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.
申请概述Application overview
现有技术中,密钥是一种给机器用的身份认证方法,不是给人用的。密钥可以用于管理数字货币,也可以用于执行某一智能化操作(例如智能门锁的开关等),这可以根据用户的需求设定。但是现有的密钥在使用过程中,存在各种各样的问题。例如,为了提高安全性,将密钥的长度设计的很长,这会导致用户容易忘记该密钥;对于不同的数字货币或智能化操作,可能对应多个不同的密钥,导致用户容易混淆各种密钥;密钥在使用的过程中,容易被盗取。这些问题使得密钥在使用过程中的整体安全性低、便捷性差。In the prior art, a key is an identity authentication method for machines, not for humans. The key can be used to manage digital currency, or it can be used to perform a certain intelligent operation (such as the switch of a smart door lock, etc.), which can be set according to the user's needs. However, in the process of using the existing keys, there are various problems. For example, in order to improve security, the length of the key is designed to be very long, which will cause users to easily forget the key; for different digital currencies or intelligent operations, there may be multiple different keys, causing users to be easily confused Various keys; keys are easily stolen during use. These problems make the overall security and convenience of the key in the process of use low.
示例性系统Exemplary System
图1是本申请一示例性实施例提供的密钥管理系统的系统架构示意图,其示出了一种通过电子设备进行密钥管理的应用场景。如图1所示,该密钥管理系统1包括电子设备10,服务器20。电子设备10可以通过第一身份认证方式获取用户的授权以生成第一认证加密密钥和第一认证解密密钥,基于第一认证加密密钥对角色密钥进行加密,并将加密后的角色 密钥保存至服务器20,以实现数字身份的创建过程或者是该数字身份的第一身份认证方式的添加过程。进一步地,电子设备10通过从服务器20获取加密后的角色密钥,并对其进行解密,可以实现对角色密钥的管理或使用过程。FIG. 1 is a schematic diagram of a system architecture of a key management system provided by an exemplary embodiment of the present application, which shows an application scenario of performing key management through an electronic device. As shown in FIG. 1 , the key management system 1 includes an electronic device 10 and a server 20 . The electronic device 10 can obtain the authorization of the user through the first identity authentication method to generate the first authentication encryption key and the first authentication decryption key, encrypt the character key based on the first authentication encryption key, and encrypt the encrypted character The key is stored in the server 20 to realize the process of creating the digital identity or the process of adding the first identity authentication method of the digital identity. Further, by obtaining the encrypted character key from the server 20 and decrypting it, the electronic device 10 can implement the process of managing or using the character key.
在另一实施例中,电子设备10可以通过第一身份认证方式获取用户的授权以生成第一认证加密密钥和第一认证解密密钥,基于第一认证加密密钥对角色密钥进行加密,并将加密后的角色密钥保存在电子设备10,以实现数字身份的创建过程或者是该数字身份的第一身份认证方式的添加过程。进一步地,电子设备10通过对加密后的角色密钥进行解密,可以实现对角色密钥的管理或使用过程。In another embodiment, the electronic device 10 may obtain the authorization of the user through the first identity authentication method to generate the first authentication encryption key and the first authentication decryption key, and encrypt the role key based on the first authentication encryption key , and save the encrypted character key in the electronic device 10, so as to realize the creation process of the digital identity or the adding process of the first identity authentication method of the digital identity. Further, by decrypting the encrypted character key, the electronic device 10 can implement the process of managing or using the character key.
这里,电子设备10可以是手机、游戏主机、平板电脑、照相机、摄像机、车载电脑等可移动设备;也可以是计算机,比如笔记本电脑、台式电脑等等;还可以是包含处理器及存储器的其他电子设备。当电子设备10为前述多种可能的选择时,第一身份认证方式可以是通过用户的一种现有信息对其进行身份认证的方式,该现有信息可以是用户所持有的第三方平台账户,例如可以是用户在电子设备10上安装的应用程序对应的账户等。Here, the electronic device 10 may be a mobile device, such as a mobile phone, a game console, a tablet computer, a camera, a video camera, a car computer, etc.; it may also be a computer, such as a notebook computer, a desktop computer, etc.; it may also be other devices including a processor and a memory Electronic equipment. When the electronic device 10 is selected from the aforementioned various possible options, the first identity authentication method may be a method of performing identity authentication on the user through an existing information of the user, and the existing information may be a third-party platform held by the user The account, for example, may be an account corresponding to an application program installed on the electronic device 10 by the user, or the like.
需要注意的是,上述应用场景仅是为了便于理解本申请的精神和原理而示出,本申请的实施例并不限于此。相反,本申请的实施例可以应用于可能适用的任何场景。It should be noted that the above application scenarios are only shown for the convenience of understanding the spirit and principle of the present application, and the embodiments of the present application are not limited thereto. Rather, the embodiments of the present application can be applied to any scenario that may be applicable.
示例性方法Exemplary method
图2是本申请一示例性实施例提供的密钥管理方法的流程示意图,图2的方法可以由电子设备来执行,例如手机,具体可以由电子设备上与数字身份对应的客户端执行。如图2所示,该密钥管理方法涉及数字身份的创建过程或者该数字身份的第一个身份认证方式(第一身份认证方式)的添加过程,具体包括如下内容。FIG. 2 is a schematic flowchart of a key management method provided by an exemplary embodiment of the present application. The method in FIG. 2 may be executed by an electronic device, such as a mobile phone, and may be executed by a client corresponding to a digital identity on the electronic device. As shown in FIG. 2 , the key management method involves a process of creating a digital identity or a process of adding a first identity authentication method (first identity authentication method) of the digital identity, which specifically includes the following contents.
S210:通过第一身份认证方式获取用户的授权,以生成第一认证加密密钥,其中,第一身份认证方式用于登录数字身份。S210: Obtain the authorization of the user through a first identity authentication method to generate a first authentication encryption key, wherein the first identity authentication method is used for logging in a digital identity.
用户可以通过第一身份认证方式实现数字身份的创建过程,或者数字身份是提前创建好的,用户可以为该数字身份添加第一身份认证方式。The user can realize the creation process of the digital identity through the first identity authentication method, or the digital identity is created in advance, and the user can add the first identity authentication method to the digital identity.
在一实施例中,数字身份可以是提前创建的,是一个空的数字身份。在为该数字身份添加第一身份认证方式的过程中,可以为该数字身份设置至少一个角色,每个角色对应不同的权限,用于管理或使用不同的数字货币,或执行不同的智能化操作。In one embodiment, the digital identity may be created in advance and is an empty digital identity. In the process of adding the first identity authentication method to the digital identity, at least one role can be set for the digital identity, and each role corresponds to different permissions for managing or using different digital currencies, or performing different intelligent operations .
在一实施例中,通过第一身份认证方式为数字身份创建多个角色。当该数字身份创建完成后,该用户可以通过第一身份认证方式登录该数字身份,且可以使用任一角色对应的权限以执行相应的操作。In one embodiment, multiple roles are created for the digital identity through the first identity authentication method. After the digital identity is created, the user can log in to the digital identity through the first identity authentication method, and can use the permissions corresponding to any role to perform corresponding operations.
进一步地,该用户还可以通过第一身份认证方式为数字身份添加其他的身份认证方式。任一身份认证方式均可登录该数字身份,不同的身份认证方式可以使用不同角色对应的权限。Further, the user can also add other identity authentication methods to the digital identity through the first identity authentication method. Any identity authentication method can log in to the digital identity, and different identity authentication methods can use permissions corresponding to different roles.
身份认证方式可以是通过该用户的一种现有信息对其进行身份认证的方式,在这里,用户的现有信息可以包括该用户所持有的第三方平台账户、身份认证芯片、人体生物特征、终端系统账户等。其中,第三方平台账户可以是该用户所持有的社交平台账户、购物平台账户、金融平台账户、手机号码账户、网络服务账户、智能物联平台账户等,例如:微信账户、微软账户、淘宝账户、手机银行账户等。应当理解,本申请的实施例对用户的现有信息的具体类型不进行限定。The identity authentication method can be a way of authenticating the user through an existing information of the user. Here, the existing information of the user can include the third-party platform account, identity authentication chip, and human biometrics held by the user. , terminal system accounts, etc. Among them, the third-party platform account can be the social platform account, shopping platform account, financial platform account, mobile phone number account, network service account, intelligent IoT platform account held by the user, such as: WeChat account, Microsoft account, Taobao account accounts, mobile banking accounts, etc. It should be understood that the embodiments of the present application do not limit the specific type of the user's existing information.
应当理解,本申请中所使用的“用户”一词并不仅限于自然人,还可以包括例如机器、猴子、虚拟身份、组织等,本申请对用户的真实身份不进行限定。It should be understood that the term "user" used in this application is not limited to natural persons, but may also include, for example, machines, monkeys, virtual identities, organizations, etc. This application does not limit the real identity of users.
在一实施例中,电子设备可以基于第一身份认证方式生成该第一身份认证方式对应的第一认证解密密钥和第一认证加密密钥。认证解密密钥和认证加密密钥可以用于验证身份认证方式,便于用户使用该身份认证方式对应的权限。In an embodiment, the electronic device may generate a first authentication decryption key and a first authentication encryption key corresponding to the first identity authentication method based on the first identity authentication method. The authentication decryption key and the authentication encryption key can be used to verify the identity authentication method, so that the user can use the authority corresponding to the identity authentication method.
认证解密密钥和认证加密密钥可以是对称密钥或非对称密钥。认证加密密钥可以是认证公钥,认证解密密钥可以是认证私钥。The authenticated decryption key and the authenticated encryption key can be symmetric or asymmetric. The authentication encryption key may be the authentication public key, and the authentication decryption key may be the authentication private key.
当认证解密密钥和认证加密密钥为对称密钥时,两者一样;当认证解密密钥和认证加密密钥为非对称密钥时,两者不同。When the authentication decryption key and the authentication encryption key are symmetric keys, they are the same; when the authentication decryption key and the authentication encryption key are asymmetric keys, they are different.
第一认证解密密钥可以保存在本地(电子设备)或服务器端。The first authentication and decryption key can be stored locally (electronic device) or on the server side.
S220:利用第一认证加密密钥对至少一个角色解密密钥进行加密,得到第一身份认证方式对应的至少一个初始加密角色解密密钥,其中,至少一个角色解密密钥与数字身份的至少一个角色一一对应,用于对至少一个加密后的目标密钥进行解密,以得到至少一个目标密钥。S220: Encrypt at least one character decryption key with the first authentication encryption key to obtain at least one initial encrypted character decryption key corresponding to the first identity authentication method, wherein at least one character decryption key and at least one of the digital identity The roles are in one-to-one correspondence, and are used to decrypt at least one encrypted target key to obtain at least one target key.
在一实施例中,至少一个目标密钥分别用于管理至少一个角色对应的资产。当通过第一身份认证方式为数字身份创建多个角色时,可为每个角色生成对应的角色解密密钥。每个角色解密密钥可与一个或多个目标密钥对应,用于对加密后的目标密钥进行解密,以获得相应的目标密钥。In one embodiment, at least one target key is used to manage assets corresponding to at least one role, respectively. When multiple roles are created for the digital identity through the first identity authentication method, a corresponding role decryption key can be generated for each role. Each character decryption key may correspond to one or more target keys, and is used to decrypt the encrypted target keys to obtain corresponding target keys.
具体地,角色解密密钥可以是电子设备随机生成的。这里,当通过第一身份认证方式为数字身份创建多个角色时,还可以为每个角色生成对应的角色加密密钥。与认证密钥类似,角色解密密钥和角色加密密钥可以是对称密钥或非对称密钥。Specifically, the character decryption key may be randomly generated by the electronic device. Here, when multiple roles are created for the digital identity through the first identity authentication method, a corresponding role encryption key may also be generated for each role. Similar to authentication keys, role decryption keys and role encryption keys can be symmetric or asymmetric keys.
在另一实施例中,角色解密密钥可以在服务器端生成。In another embodiment, the character decryption key may be generated on the server side.
具体地,数字身份可以拥有至少一项资产,例如,数字货币的账号、各类登录方式的账号等。其中,每项资产都具有相关的目标密钥,用于管理对应的资产。加密后的目标密钥可以保存在服务器端或者本地。Specifically, a digital identity may have at least one asset, such as an account number of digital currency, an account number of various login methods, and the like. Among them, each asset has an associated target key for managing the corresponding asset. The encrypted target key can be stored on the server or locally.
当一个数字身份只有一个角色即第一角色时,第一角色可以拥有针对该数字身份所持的全部资产的管理权限;当一个数字身份包含多个角色时,多个角色中的不同角色可以分别拥有针对该数字身份所持资产中的不同资产的管理权限。例如,一个数字身份可以包含第一角色和第二角色,其中第一角色拥有管理微信账号、微博账号以及公交乘车卡的权限,第二角色拥有管理智能门锁、数字货币账号的权限。When a digital identity has only one role, that is, the first role, the first role can have the management authority for all assets held by the digital identity; when a digital identity contains multiple roles, different roles in the multiple roles can respectively have Management rights for different assets in the assets held by the digital identity. For example, a digital identity can include a first role and a second role, where the first role has the authority to manage WeChat accounts, Weibo accounts and bus cards, and the second role has the authority to manage smart door locks and digital currency accounts.
进一步地,对一个角色赋予针对至少一项资产的管理权限时,可以用该角色对应的角色加密密钥对其管理权限内的至少一项资产对应的至少一个目标密钥分别进行加密,进而得到至少一个加密后的目标密钥,并保存到数字身份中。例如,使用第一角色加密密钥对第一角色对应资产的目标密钥进行加密,得到加密后的目标密钥。这样一来,当电子设备获得角色解密密钥后,可以使用该角色解密密钥对加密后的目标密钥进行解密,从而得到目标密钥。Further, when a role is given management authority for at least one asset, at least one target key corresponding to at least one asset within its management authority can be encrypted with the role encryption key corresponding to the role, and then obtain At least one encrypted target key and stored in the digital identity. For example, the target key of the asset corresponding to the first character is encrypted using the first character encryption key to obtain the encrypted target key. In this way, after the electronic device obtains the character decryption key, it can use the character decryption key to decrypt the encrypted target key, thereby obtaining the target key.
优选地,在另一实施例中,在得到目标密钥之后,电子设备还可以进一步根据用户的指令,利用目标密钥实现对于该目标密钥所对应的资产的管理。例如,当目标密钥为数字货币账户的密钥时,用户可以发出对该数字货币账户进行余额查看的操作指令。在接收到该操作指令后,电子设备可以找到相应的加密后的目标密钥,并使用第一角色解密密钥对其进行解密,从而得到该目标密钥,执行用户所发出的操作指令。Preferably, in another embodiment, after obtaining the target key, the electronic device may further use the target key to manage the assets corresponding to the target key according to the user's instruction. For example, when the target key is the key of a digital currency account, the user can issue an operation instruction for checking the balance of the digital currency account. After receiving the operation instruction, the electronic device can find the corresponding encrypted target key, and decrypt it using the first character decryption key to obtain the target key and execute the operation instruction issued by the user.
本申请实施例提供了一种密钥管理方法,通过生成第一身份认证方式对应的第一认证加密密钥,利用第一认证加密密钥对数字身份下的至少一个角色解密密钥进行加密,其中,至少一个角色解密密钥用于对加密后的目标密钥进行解密以得到至少一个目标密钥,从而能够将身份认证方式与目标密钥关联起来,方便目标密钥的管理和使用过程。The embodiment of the present application provides a key management method, by generating a first authentication encryption key corresponding to a first identity authentication method, and using the first authentication encryption key to encrypt at least one role decryption key under a digital identity, Wherein, at least one role decryption key is used to decrypt the encrypted target key to obtain at least one target key, so that the identity authentication method can be associated with the target key, which facilitates the management and use of the target key.
图3是本申请另一示例性实施例提供的密钥管理方法的流程示意图。在本申请图2所示实施例的基础上延伸出本申请图3所示实施例,下面着重叙述图3所示实施例与图2所示实施例的不同之处,相同之处不再赘述。FIG. 3 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application. On the basis of the embodiment shown in FIG. 2 of the present application, the embodiment shown in FIG. 3 of the present application is extended. The following focuses on the differences between the embodiment shown in FIG. 3 and the embodiment shown in FIG. 2 , and the similarities will not be repeated. .
如图3所示,在图2所示实施例的基础上,本申请实施例提供的密钥管理方法还包括以下内容。As shown in FIG. 3 , on the basis of the embodiment shown in FIG. 2 , the key management method provided by the embodiment of the present application further includes the following content.
S230:基于第一身份认证方式对应的身份认证信息生成第三存储密钥。S230: Generate a third storage key based on the identity authentication information corresponding to the first identity authentication manner.
S240:生成第一认证加密密钥对应的第一认证解密密钥。S240: Generate a first authentication decryption key corresponding to the first authentication encryption key.
S245:利用第三存储密钥对第一认证解密密钥进行加密,得到加密后的第一认证解密 密钥。S245: Encrypt the first authentication and decryption key with the third storage key to obtain the encrypted first authentication and decryption key.
在本实施例中,对第一认证解密密钥进行加密,可以保证第一认证解密密钥获取过程的安全性,进而可以提高整个目标密钥管理和使用过程的安全性。加密后的第一认证解密密钥可以保存在本地。这里,可以是利用第三存储密钥对第一认证解密密钥进行加密。第三存储密钥可以是对称密钥或非对称密钥。In this embodiment, encrypting the first authentication and decryption key can ensure the security of the process of obtaining the first authentication and decryption key, thereby improving the security of the entire target key management and use process. The encrypted first authentication and decryption key may be stored locally. Here, the third storage key may be used to encrypt the first authentication and decryption key. The third storage key may be a symmetric key or an asymmetric key.
在一实施例中,身份认证信息为非公开身份认证信息,可以基于非公开身份认证信息以及第一身份认证方式对应的用户的父母姓名生成第三存储密钥。例如,非公开身份认证信息为微信ID。腾讯核心员工可能知晓微信ID,用户的亲友可能知晓父母姓名,但二者基本上不重合,因此可以提高密钥管理的安全性,有效防止密钥被盗。In one embodiment, the identity authentication information is non-public identity authentication information, and the third storage key may be generated based on the non-public identity authentication information and the parent names of the users corresponding to the first identity authentication method. For example, the non-public identity authentication information is WeChat ID. Tencent's core employees may know WeChat ID, and users' relatives and friends may know their parents' names, but the two basically do not overlap, so the security of key management can be improved and the keys can be effectively prevented from being stolen.
在一实施例中,如图3所示,该密钥管理方法还包括如下内容。In an embodiment, as shown in FIG. 3 , the key management method further includes the following content.
S250:将加密后的第一认证解密密钥提交至服务器端。S250: Submit the encrypted first authentication and decryption key to the server.
具体地,可以将加密后的第一认证解密密钥保存在服务器端的密钥数据库中。Specifically, the encrypted first authentication and decryption key may be stored in a key database on the server side.
S255:将至少一个初始加密角色解密密钥提交至服务器端。S255: Submit at least one initial encryption role decryption key to the server.
具体地,可以将至少一个初始加密角色解密密钥保存在服务器端的用户数据库中。Specifically, at least one initial encryption role decryption key may be stored in the user database on the server side.
为了降低第三存储密钥的泄露风险,电子设备可以基于第一身份认证方式生成第三存储密钥,或者,可以将生成后的第三存储密钥与第一身份认证方式进行关联后保存,以使电子设备只有在用户通过第一身份认证方式登录数字身份的时候才能够获取第三存储密钥。例如,电子设备可以基于第一身份认证信息计算得到第三存储密钥,或者,电子设备可以随机生成第三存储密钥后将其存储于第一身份认证方式的对应云端。In order to reduce the risk of leakage of the third storage key, the electronic device may generate the third storage key based on the first identity authentication method, or may associate the generated third storage key with the first identity authentication method and save it, So that the electronic device can obtain the third storage key only when the user logs in the digital identity through the first identity authentication method. For example, the electronic device may calculate and obtain the third storage key based on the first identity authentication information, or the electronic device may randomly generate the third storage key and store it in the corresponding cloud of the first identity authentication method.
具体地,在创建第一身份认证方式时,电子设备可以向服务器端发送账号创建请求,以使服务器端创建一个用于登录密钥数据库的第一密钥数据库账户。其中,第一密钥数据库账户对应于第一身份认证方式,用于存储加密后的第一认证解密密钥。在这里,第一密钥数据库账户可以拥有一对账号和密码,即第一登录账号与第一登录密码,电子设备可以根据第一登录账号与第一登录密码登录密钥数据库并从中获取数据。应当理解,第一登录账号和第一登录密码可以由电子设备生成后发送给服务器端,也可以由服务器端直接生成,本申请的实施例对此不进行限定。Specifically, when creating the first identity authentication method, the electronic device may send an account creation request to the server, so that the server creates a first key database account for logging in to the key database. The first key database account corresponds to the first identity authentication method, and is used to store the encrypted first authentication and decryption key. Here, the first key database account may have a pair of account numbers and passwords, that is, the first login account and the first login password, and the electronic device may log in to the key database according to the first login account and the first login password and obtain data therefrom. It should be understood that the first login account and the first login password may be generated by the electronic device and then sent to the server, or may be directly generated by the server, which are not limited in the embodiments of the present application.
电子设备可以根据第一身份认证方式计算得到第一登录账号和第一登录密码,也可以通过登录第一身份认证方式的对应云端获取预先存储的第一登录账号和第一登录密码,还可以从本地直接获取与第一身份认证方式相关联的第一登录账号和第一登录密码。The electronic device can calculate and obtain the first login account and the first login password according to the first identity authentication method, and can also obtain the pre-stored first login account and first login password by logging in to the corresponding cloud of the first identity authentication method, and can also obtain the first login account and the first login password from the corresponding cloud. The first login account and the first login password associated with the first identity authentication method are directly obtained locally.
应当理解,本申请的实施例对于第一登录账号和第一登录密码的具体生成及存储方式不进行限定。It should be understood that the embodiments of the present application do not limit the specific generation and storage methods of the first login account and the first login password.
进一步地,初始加密角色解密密钥保存在服务器端的用户数据库中,用户数据库与密钥数据库之间的联系可以只有电子设备端清楚,后台服务器端并不清楚,这样在访问用户数据库获取初始加密角色解密密钥时,后台服务器端的工作人员不清楚被访问的初始加密角色解密密钥是对应哪个用户,因此可以进一步提高密钥获取过程的安全性。Further, the decryption key of the initial encryption role is stored in the user database on the server side, and the connection between the user database and the key database may be clear only on the electronic device side, but not on the backend server side. In this way, the initial encryption role is obtained when accessing the user database. When decrypting the key, the staff on the background server side does not know which user the decryption key of the initial encryption role being accessed corresponds to, so the security of the key acquisition process can be further improved.
上述步骤S255可以在步骤S220至S250之间的任一步骤执行,本申请实施例对此不做限制。The foregoing step S255 may be performed in any step between steps S220 to S250, which is not limited in this embodiment of the present application.
可选地,加密后的第一认证解密密钥和/或初始加密角色解密密钥保存在本地,可以实现半依赖或不依赖服务端的密钥管理过程。Optionally, the encrypted first authentication decryption key and/or the initial encryption role decryption key are stored locally, which can implement a key management process that is semi-dependent or independent of the server.
图4是本申请另一示例性实施例提供的密钥管理方法的流程示意图。在本申请图2所示实施例的基础上延伸出本申请图4所示实施例,下面着重叙述图4所示实施例与图2所示实施例的不同之处,相同之处不再赘述。FIG. 4 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application. On the basis of the embodiment shown in FIG. 2 of the present application, the embodiment shown in FIG. 4 of the present application is extended. The following focuses on the differences between the embodiment shown in FIG. 4 and the embodiment shown in FIG. 2 , and the similarities will not be repeated. .
如图4所示,在图2所示实施例的基础上,本申请实施例提供的密钥管理方法还包括以下内容。As shown in FIG. 4 , on the basis of the embodiment shown in FIG. 2 , the key management method provided by the embodiment of the present application further includes the following content.
S260:随机生成至少一个角色加密密钥。S260: Randomly generate at least one character encryption key.
S265:利用至少一个角色加密密钥分别对至少一个目标密钥进行加密,得到至少一个 加密后的目标密钥。S265: Encrypt at least one target key with at least one role encryption key, respectively, to obtain at least one encrypted target key.
S270:将至少一个加密后的目标密钥保存在本地。S270: Save at least one encrypted target key locally.
具体地,电子设备可以通过第一身份认证方式为该数字身份设置多个角色,并为每个角色生成对应的角色加密密钥。该角色加密密钥可以随机生成,或基于特定的信息、特定的算法生成。角色加密密钥的生成过程可以根据需要进行设定,本申请实施例对此不做限制。Specifically, the electronic device can set multiple roles for the digital identity through the first identity authentication method, and generate a corresponding role encryption key for each role. The character encryption key can be randomly generated, or generated based on specific information or a specific algorithm. The generation process of the character encryption key may be set as required, which is not limited in this embodiment of the present application.
目标密钥可以是预先设定好的,经角色加密密钥加密后的目标密钥可以保存在本地。The target key can be preset, and the target key encrypted by the role encryption key can be stored locally.
本实施例中,步骤S260可以同时生成角色加密密钥与角色解密密钥,两者可以是非对称密钥。在其他实施例中,角色加密密钥与角色解密密钥可以是由服务器端生成,加密后的目标密钥也可以保存在服务器端。In this embodiment, step S260 may generate a character encryption key and a character decryption key at the same time, and both may be asymmetric keys. In other embodiments, the character encryption key and the character decryption key may be generated by the server, and the encrypted target key may also be stored at the server.
上述步骤S260可以在步骤S220之前、之后执行,或两者同时执行,本申请实施例对此不做限制。The foregoing step S260 may be performed before or after the step S220, or both may be performed simultaneously, which is not limited in this embodiment of the present application.
根据本申请一实施例,至少一个角色包括第一角色和第二角色,数字身份包括第一权限等级和第二权限等级,第一权限等级低于第二权限等级,第一权限等级具有管理第一角色对应资产的权限,第二权限等级具有管理第一角色和第二角色对应资产的权限,第一身份认证方式对应第一权限等级,其中,利用第一认证加密密钥对至少一个角色解密密钥进行加密,得到第一身份认证方式对应的至少一个初始加密角色解密密钥(S220),包括:利用第一认证加密密钥对第一角色对应的第一角色解密密钥和第二角色对应的第二角色解密密钥进行加密,得到第一身份认证方式对应的初始加密第一角色解密密钥和初始加密第二角色解密密钥,以便通过第一身份认证方式添加具有第二权限等级的第二身份认证方式。According to an embodiment of the present application, at least one role includes a first role and a second role, the digital identity includes a first permission level and a second permission level, the first permission level is lower than the second permission level, and the first permission level has the ability to manage the first permission level. A role corresponds to the authority of the asset, the second authority level has the authority to manage the first role and the assets corresponding to the second role, and the first identity authentication method corresponds to the first authority level, wherein at least one role is decrypted by using the first authentication encryption key encrypting the key to obtain at least one initial encryption character decryption key corresponding to the first identity authentication method (S220), including: using the first authentication encryption key to decrypt the first character decryption key and the second character corresponding to the first character The corresponding second role decryption key is encrypted, and the initial encrypted first role decryption key and the initial encrypted second role decryption key corresponding to the first identity authentication method are obtained, so as to add a second authority level through the first identity authentication method. the second authentication method.
在本实施例中,第一身份认证方式是该数字身份下的第一个身份认证方式,可以通过该第一身份认证方式为该数字身份添加其他的身份认证方式。即,经过添加过程,该数字身份可以对应多个身份认证方式,该多个身份认证方式可以对应同一用户或不同用户。In this embodiment, the first identity authentication method is the first identity authentication method under the digital identity, and other identity authentication methods may be added to the digital identity through the first identity authentication method. That is, after the adding process, the digital identity can correspond to multiple identity authentication methods, and the multiple identity authentication methods can correspond to the same user or different users.
数字身份可以包含多个权限等级,多个权限等级中的每个权限等级分别具有管理多个角色中的至少一个角色所对应资产的权限。A digital identity may include multiple permission levels, and each permission level in the multiple permission levels has the permission to manage assets corresponding to at least one role among the multiple roles.
具体地,一个数字身份可以根据权限等级划分与其对应的所有身份认证方式,使每个身份认证方式都具有各自的权限等级,进而使身份认证方式拥有对应权限等级所对应的至少一个角色的资产管理权限。Specifically, a digital identity can be divided into all the corresponding identity authentication methods according to the authority level, so that each identity authentication method has its own authority level, so that the identity authentication method has the asset management of at least one role corresponding to the corresponding authority level permissions.
例如,第一身份认证方式可以对应多个权限等级中的第一权限等级,第一权限等级可以具有管理第一角色所对应资产的权限,则通过第一身份认证方式登录数字身份的用户就能够管理第一角色所对应的资产;第二身份认证方式可以对应多个权限等级中的第二权限等级,第二权限等级可以具有管理第一角色及第二角色所对应资产的权限,则通过第二身份认证方式登录数字身份的用户就能够同时管理第一角色及第二角色所对应的资产。For example, the first identity authentication method may correspond to the first authority level among the multiple authority levels, and the first authority level may have the authority to manage the assets corresponding to the first role, and users who log in to the digital identity through the first identity authentication method can Manage the assets corresponding to the first role; the second identity authentication method can correspond to the second permission level in multiple permission levels, and the second permission level can have the permission to manage the assets corresponding to the first role and the second role, then pass the first permission level. Users who log in to their digital identities by means of two-identity authentication can manage the assets corresponding to the first role and the second role at the same time.
在实际应用中,每个身份认证方式可以具有对应的认证加密密钥和认证解密密钥,例如第一身份认证方式可以对应于第一认证加密密钥和第一认证解密密钥。当对第一身份认证方式赋予第一权限等级时,可以使用第一认证加密密钥对第一权限等级所对应的第一角色解密密钥进行加密,得到初始加密第一角色解密密钥。这样一来,当用户通过第一身份认证方式登录数字身份时,电子设备可以获得第一认证解密密钥,找到初始加密第一角色解密密钥,并使用第一认证解密密钥对初始加密第一角色解密密钥进行解密,得到第一角色解密密钥。又例如,对第二身份认证方式赋予第二权限等级时,可以使用第二认证加密密钥对第二权限等级所对应的第一角色解密密钥及第二角色解密密钥分别进行加密,得到初始加密第一角色解密密钥和初始加密第二角色解密密钥。同样的,当用户通过第二身份认证方式登录数字身份时,电子设备可以获得第二认证解密密钥,根据用户的需求找到初始加密第一角色解密密钥和/或初始加密第二角色解密密钥,并使用第二认证解密密钥对初始加密第一角色解密密钥和/或初始加密第二角色解密密钥进行解密,得到第一角色解密密钥和/或第二角色解密密钥。In practical applications, each identity authentication method may have a corresponding authentication encryption key and an authentication decryption key. For example, the first identity authentication method may correspond to the first authentication encryption key and the first authentication decryption key. When the first authority level is assigned to the first identity authentication method, the first authentication encryption key may be used to encrypt the first character decryption key corresponding to the first authority level to obtain the initial encrypted first character decryption key. In this way, when the user logs in to the digital identity through the first identity authentication method, the electronic device can obtain the first authentication decryption key, find the initial encryption first character decryption key, and use the first authentication decryption key to perform the initial encryption decryption key. A character decryption key is decrypted to obtain a first character decryption key. For another example, when a second authority level is assigned to the second identity authentication method, the second authentication encryption key can be used to encrypt the first role decryption key and the second role decryption key corresponding to the second authority level, respectively, to obtain: The first character decryption key is initially encrypted and the second character decryption key is initially encrypted. Similarly, when the user logs in to the digital identity through the second identity authentication method, the electronic device can obtain the second authentication decryption key, and find the initial encrypted first character decryption key and/or the initial encrypted second character decryption key according to the user's needs. and decrypt the initially encrypted first character decryption key and/or the initially encrypted second character decryption key using the second authentication decryption key to obtain the first character decryption key and/or the second character decryption key.
应当理解,资产、角色、权限等级的具体划分及对应方式可以由本领域技术人员根据实际需求进行设定,亦可由用户在本系统中自定义设定,本申请的实施例对此不进行限定。It should be understood that the specific division and corresponding manner of assets, roles, and authority levels can be set by those skilled in the art according to actual needs, and can also be set by users in the system, which is not limited by the embodiments of the present application.
在本实施例中,由于第一身份认证方式是该数字身份下的第一个身份认证方式,后面的其他身份认证方式需要通过第一身份认证方式才能添加。具体地,当为该数字身份添加具有第二权限等级的第二身份认证方式时,为了提高密钥管理过程的安全性,需要通过第一身份认证方式登录数字身份获取第一角色解密密钥和第二角色解密密钥,并利用第二身份认证方式对应的第二认证加密密钥对第一角色解密密钥和第二角色解密密钥进行加密,以得到第二身份认证方式对应的初始加密第一角色解密密钥和初始加密第二角色解密密钥。In this embodiment, since the first identity authentication method is the first identity authentication method under the digital identity, other identity authentication methods that follow need to be added through the first identity authentication method. Specifically, when a second identity authentication method with a second authority level is added to the digital identity, in order to improve the security of the key management process, it is necessary to log in to the digital identity through the first identity authentication method to obtain the first role decryption key and The second character decryption key is used to encrypt the first character decryption key and the second character decryption key by using the second authentication encryption key corresponding to the second identity authentication method to obtain the initial encryption corresponding to the second identity authentication method. The first character decryption key and the initially encrypted second character decryption key.
在一实施例中,各个身份认证方式的权限等级可以是由用户赋予的,也可以是由该身份认证方式的本身属性决定的。例如“指纹”身份认证方式的权限等级高于“微信”身份认证方式的权限等级。In one embodiment, the authority level of each identity authentication method may be given by the user, or may be determined by the attributes of the identity authentication method. For example, the authority level of the "fingerprint" identity authentication method is higher than that of the "WeChat" identity authentication method.
在一实施例中,由于第一身份认证方式是该数字身份下的第一个身份认证方式,为了便于添加权限等级高于其的第二身份认证方式,数字身份下的第一身份认证方式可以具有最高权限等级(如,第二权限等级)。或者,数字身份下的第一身份认证方式具有低的权限等级(如,第一权限等级),但是临时具有获取所有角色解密密钥的权限,在添加具有第二权限等级的第二身份认证方式后,该第一身份认证方式恢复第一权限等级。In one embodiment, since the first identity authentication method is the first identity authentication method under the digital identity, in order to facilitate adding a second identity authentication method with a higher authority level than it, the first identity authentication method under the digital identity can be Has the highest authority level (eg, the second authority level). Or, the first identity authentication method under the digital identity has a low authority level (for example, the first authority level), but temporarily has the authority to obtain decryption keys for all roles, and the second identity authentication method with the second authority level is added. After that, the first identity authentication method restores the first authority level.
下面详细描述通过第一身份认证方式为数字身份添加第二身份认证方式的过程。The process of adding a second identity authentication method to a digital identity by using the first identity authentication method will be described in detail below.
图5是本申请另一示例性实施例提供的密钥管理方法的流程示意图,图5的方法可以由电子设备来执行,例如手机,具体可以由电子设备上与数字身份对应的客户端执行。如图5所示,该密钥管理方法涉及通过第一身份认证方式为数字身份添加第二身份认证方式的过程,具体包括如下内容。FIG. 5 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application. The method in FIG. 5 may be executed by an electronic device, such as a mobile phone, and may be executed by a client corresponding to a digital identity on the electronic device. As shown in FIG. 5 , the key management method involves a process of adding a second identity authentication method to a digital identity through a first identity authentication method, and specifically includes the following contents.
S510:获取数字身份的第一身份认证方式对应的第一认证解密密钥。S510: Obtain a first authentication and decryption key corresponding to the first identity authentication method of the digital identity.
具体地,用户可以通过第一身份认证方式登录数字身份。Specifically, the user can log in to the digital identity through the first identity authentication method.
在一实施例中,可以直接从本地或服务器端获取第一认证解密密钥;在另一实施例中,可以从本地或服务器端获取加密后的第一认证解密密钥,并利用第三存储密钥对其进行解密以获得第一认证解密密钥。In one embodiment, the first authentication and decryption key can be obtained directly from the local or the server; in another embodiment, the encrypted first authentication and decryption key can be obtained from the local or the server, and the third storage The key decrypts it to obtain the first authenticated decryption key.
S520:获取数字身份待添加的第二身份认证方式对应的第二认证加密密钥。S520: Obtain a second authentication encryption key corresponding to the second identity authentication method to be added to the digital identity.
在一实施例中,在生成第二认证加密密钥的同时还可以生成第二认证解密密钥。第二认证加密密钥和第二认证解密密钥的生成过程可以参见第一认证加密密钥和第一认证解密密钥的生成过程,即可以参见上述图2实施例的描述,为避免重复,此处不再赘述。In one embodiment, the second authentication decryption key may also be generated at the same time as the second authentication encryption key is generated. For the generation process of the second authentication encryption key and the second authentication decryption key, refer to the generation process of the first authentication encryption key and the first authentication decryption key, that is, refer to the description of the embodiment in FIG. 2 above. To avoid repetition, It will not be repeated here.
当第二身份认证方式与第一身份认证方式对应同一用户时,第二身份认证方式与第一身份认证方式可以对应同一电子设备,此时第二认证加密密钥和第二认证解密密钥的获取过程可以是在电子设备端直接生成。When the second identity authentication method and the first identity authentication method correspond to the same user, the second identity authentication method and the first identity authentication method may correspond to the same electronic device. The acquisition process can be directly generated on the electronic device side.
当第二身份认证方式与第一身份认证方式对应不同用户时,第二身份认证方式与第一身份认证方式对应不同电子设备,此时第二认证加密密钥和第二认证解密密钥的获取过程可以是,第一身份认证方式对应的电子设备接收第二身份认证方式对应的电子设备发送的第二认证加密密钥和第二认证解密密钥,该第二认证加密密钥和第二认证解密密钥是在第二身份认证方式对应的电子设备端生成的。When the second identity authentication method and the first identity authentication method correspond to different users, the second identity authentication method and the first identity authentication method correspond to different electronic devices, and the acquisition of the second authentication encryption key and the second authentication decryption key at this time The process may be that the electronic device corresponding to the first identity authentication method receives the second authentication encryption key and the second authentication decryption key sent by the electronic device corresponding to the second identity authentication method, the second authentication encryption key and the second authentication encryption key. The decryption key is generated on the side of the electronic device corresponding to the second identity authentication method.
S530:利用第一认证解密密钥对第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥。S530: Decrypt the initially encrypted first character decryption key corresponding to the first identity authentication mode by using the first authentication decryption key, to obtain the first character decryption key.
具体地,数字身份可以对应至少一个角色,每个角色对应一个角色解密密钥。根据第二身份认证方式预设的管理权限,利用第一认证解密密钥获取相应的角色解密密钥。这里预设的管理权限可以是根据用户的意愿设置的。当至少一个角色为多个角色时,用户可以预设第二身份认证方式具有管理多个角色中的任一个或几个角色对应资产的权限。Specifically, the digital identity may correspond to at least one role, and each role corresponds to a role decryption key. According to the preset management authority of the second identity authentication method, the corresponding role decryption key is obtained by using the first authentication decryption key. The preset management authority here may be set according to the user's will. When at least one role is multiple roles, the user may preset the second identity authentication method to have the authority to manage assets corresponding to any one or several roles among the multiple roles.
S540:利用第二认证加密密钥对第一角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第一角色解密密钥。S540: Encrypt the first character decryption key by using the second authentication encryption key to obtain the initially encrypted first character decryption key corresponding to the second identity authentication method.
第一角色解密密钥与数字身份的至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。The first character decryption key corresponds to the first character in at least one character of the digital identity, and is used for decrypting the encrypted first target key to obtain the first target key.
在一实施例中,第二认证解密密钥用于对第二身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥。第一目标密钥用于管理第一角色对应的资产。In one embodiment, the second authentication decryption key is used to decrypt the initially encrypted first character decryption key corresponding to the second identity authentication method to obtain the first character decryption key. The first target key is used to manage assets corresponding to the first role.
当第二身份认证方式与第一身份认证方式对应同一用户时,第二身份认证方式与第一身份认证方式可以对应同一电子设备,此时该电子设备可以将第二身份认证方式对应的初始加密第一角色解密密钥保存至第二身份认证方式对应的客户端和/或服务器端。When the second identity authentication method and the first identity authentication method correspond to the same user, the second identity authentication method and the first identity authentication method may correspond to the same electronic device, and at this time, the electronic device may encrypt the initial encryption corresponding to the second identity authentication method The first character decryption key is stored in the client and/or server corresponding to the second identity authentication method.
当第二身份认证方式与第一身份认证方式对应不同用户时,第二身份认证方式与第一身份认证方式对应不同电子设备,此时第一身份认证方式对应的电子设备可以将第二身份认证方式对应的初始加密第一角色解密密钥发送至第二身份认证方式对应的电子设备和/或服务器端。When the second identity authentication method and the first identity authentication method correspond to different users, the second identity authentication method and the first identity authentication method correspond to different electronic devices, and the electronic device corresponding to the first identity authentication method can authenticate the second identity The initial encrypted first character decryption key corresponding to the method is sent to the electronic device and/or the server corresponding to the second identity authentication method.
本申请实施例提供了一种密钥管理方法,通过第一身份认证方式为数字身份添加第二身份认证方式,可以实现密钥的分类管理,且实现密钥管理过程的多元化。The embodiment of the present application provides a key management method. By adding a second identity authentication method to a digital identity through a first identity authentication method, the classified management of keys can be realized, and the diversification of the key management process can be realized.
根据本申请一实施例,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第二身份认证方式对应多个权限等级中的第二权限等级,第一权限等级具有管理第一角色对应资产的权限,其中,在利用第一认证解密密钥对第一身份认证方式对应的初始加密第一角色解密密钥进行解密之前,该密钥管理方法还包括:确定第二身份认证方式的第二权限等级。According to an embodiment of the present application, the first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, the second identity authentication method corresponds to the second authority level among the multiple authority levels, and the first authority level has management The authority of the asset corresponding to the first role, wherein, before using the first authentication decryption key to decrypt the initially encrypted first role decryption key corresponding to the first identity authentication method, the key management method further includes: determining the second identity The second permission level of the authentication method.
具体地,在第一身份认证方式对应的电子设备添加第二身份认证方式的过程中,第二身份认证方式的第二权限等级可以是第一身份认证方式对应的用户设置的,也可以是第二身份认证方式对应的用户设置的,还可以是由第二身份认证方式的本身属性决定的。Specifically, in the process of adding the second identity authentication method to the electronic device corresponding to the first identity authentication method, the second authority level of the second identity authentication method may be set by the user corresponding to the first identity authentication method, or may be set by the user corresponding to the first identity authentication method. The setting of the user corresponding to the second identity authentication method may also be determined by the properties of the second identity authentication method.
根据本申请一实施例,第一权限等级高于第二权限等级,第一权限等级还具有管理至少一个角色中的第二角色对应资产的权限,第二权限等级具有管理第一角色对应资产的权限。According to an embodiment of the present application, the first authority level is higher than the second authority level, the first authority level also has the authority to manage assets corresponding to the second role in at least one role, and the second authority level has the authority to manage the assets corresponding to the first role. permissions.
在本实施例中,第一身份认证方式可以添加比其权限等级低的第二身份认证方式。在添加第二身份认证方式之前,第一身份认证方式可以是该数字身份下唯一的身份认证方式,也可以是该数字身份下多个身份认证方式中的一个身份认证方式。In this embodiment, a second identity authentication method with a lower authority level than the first identity authentication method may be added. Before adding the second identity authentication method, the first identity authentication method may be the only identity authentication method under the digital identity, or may be one identity authentication method among multiple identity authentication methods under the digital identity.
图6是本申请另一示例性实施例提供的密钥管理方法的流程示意图。在本申请图5所示实施例的基础上延伸出本申请图6所示实施例,下面着重叙述图6所示实施例与图5所示实施例的不同之处,相同之处不再赘述。FIG. 6 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application. On the basis of the embodiment shown in FIG. 5 of the present application, the embodiment shown in FIG. 6 of the present application is extended. The following focuses on the differences between the embodiment shown in FIG. 6 and the embodiment shown in FIG. 5 , and the similarities will not be repeated. .
在本实施例中,第一权限等级等于第二权限等级,第一权限等级还具有管理至少一个角色中的第二角色对应资产的权限,其中,如图6所示,该密钥管理方法还包括如下内容。In this embodiment, the first authority level is equal to the second authority level, and the first authority level also has the authority to manage the assets corresponding to the second role in the at least one role, wherein, as shown in FIG. 6 , the key management method further Include the following.
S561:利用第一认证解密密钥对第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥。S561: Decrypt the initially encrypted second role decryption key corresponding to the first identity authentication mode by using the first authentication decryption key to obtain the second role decryption key.
S562:利用第二认证加密密钥对第二角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第二角色解密密钥。S562: Encrypt the second character decryption key with the second authentication encryption key to obtain the initially encrypted second character decryption key corresponding to the second identity authentication method.
第二认证解密密钥还用于对第二身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥,第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第二目标密钥用于管理第二角色对应的资产。The second authentication decryption key is also used to decrypt the initially encrypted second role decryption key corresponding to the second identity authentication method to obtain the second role decryption key, and the second role decryption key corresponds to the second role and is used for Decrypt the encrypted second target key to obtain the second target key, and the second target key is used to manage the assets corresponding to the second role.
这里,步骤S561可以与步骤S530同时进行,步骤S562可以与步骤S540同时进行。Here, step S561 may be performed simultaneously with step S530, and step S562 may be performed simultaneously with step S540.
在本实施例中,第一身份认证方式可以添加与其权限等级相等的第二身份认证方式。In this embodiment, the first identity authentication method may be added with a second identity authentication method equal to its authority level.
图7是本申请另一示例性实施例提供的密钥管理方法的流程示意图。在本申请图5所示实施例的基础上延伸出本申请图7所示实施例,下面着重叙述图7所示实施例与图5所示实施例的不同之处,相同之处不再赘述。FIG. 7 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application. On the basis of the embodiment shown in FIG. 5 of the present application, the embodiment shown in FIG. 7 of the present application is extended. The following focuses on the differences between the embodiment shown in FIG. 7 and the embodiment shown in FIG. 5 , and the similarities will not be repeated. .
在本实施例中,在添加第二身份认证方式前,第一身份认证方式为数字身份下唯一的认证方式,第一权限等级低于第二权限等级,第二权限等级具有管理第一角色和至少一个角色 中的第二角色对应资产的权限,具有第一权限等级的第一身份认证方式具有管理第一角色对应资产的权限,其中,如图7所示,该密钥管理方法还包括如下内容。In this embodiment, before adding the second identity authentication method, the first identity authentication method is the only authentication method under the digital identity, the first authority level is lower than the second authority level, and the second authority level has the management first role and The authority of the assets corresponding to the second role in the at least one role, and the first identity authentication method with the first authority level has the authority to manage the assets corresponding to the first role, wherein, as shown in FIG. 7 , the key management method also includes the following content.
S571:生成第二角色解密密钥。S571: Generate a second character decryption key.
具体地,第二角色解密密钥可以由电子设备生成,例如数字身份对应的客户端生成;或由服务器端生成发送至电子设备。Specifically, the second character decryption key may be generated by the electronic device, for example, generated by the client corresponding to the digital identity; or generated by the server and sent to the electronic device.
S572:利用第二认证加密密钥对第二角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第二角色解密密钥。S572: Encrypt the second character decryption key by using the second authentication encryption key to obtain the initially encrypted second character decryption key corresponding to the second identity authentication method.
第二认证解密密钥还用于对第二身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥,第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第二目标密钥用于管理第二角色对应的资产。The second authentication decryption key is also used to decrypt the initially encrypted second role decryption key corresponding to the second identity authentication method to obtain the second role decryption key, and the second role decryption key corresponds to the second role and is used for Decrypt the encrypted second target key to obtain the second target key, and the second target key is used to manage the assets corresponding to the second role.
具体地,在某些实施例中,步骤S571与步骤S572的执行主体可以是第一身份认证方式对应的电子设备。第二角色解密密钥可以由第一身份认证方式对应的电子设备生成;或者第二角色解密密钥可以由服务器端生成,第一身份认证方式对应的电子设备从服务器端获取第二角色解密密钥;或者,第二角色解密密钥可以由第二身份认证方式对应的电子设备生成,第一身份认证方式对应的电子设备从第二身份认证方式对应的电子设备获取第二角色解密密钥。第二身份认证方式对应的初始加密第二角色解密密钥可以保存在第二身份认证方式对应的电子设备或服务器端。Specifically, in some embodiments, the execution subject of step S571 and step S572 may be an electronic device corresponding to the first identity authentication method. The second role decryption key may be generated by the electronic device corresponding to the first identity authentication method; or the second role decryption key may be generated by the server, and the electronic device corresponding to the first identity authentication method obtains the second role decryption key from the server. Alternatively, the second role decryption key may be generated by an electronic device corresponding to the second identity authentication method, and the electronic device corresponding to the first identity authentication method obtains the second role decryption key from the electronic device corresponding to the second identity authentication method. The initially encrypted second role decryption key corresponding to the second identity authentication method may be stored in the electronic device or server side corresponding to the second identity authentication method.
在其他实施例中,步骤S571与步骤S572中的至少一个的执行主体可以是第二身份认证方式对应的电子设备或服务器端。第二身份认证方式对应的初始加密第二角色解密密钥可以保存在第二身份认证方式对应的电子设备或服务器端。In other embodiments, the execution subject of at least one of steps S571 and S572 may be an electronic device or a server side corresponding to the second identity authentication method. The initially encrypted second role decryption key corresponding to the second identity authentication method may be stored in the electronic device or server side corresponding to the second identity authentication method.
在一实施例中,当数字身份对应多个身份认证方式时,多个身份认证方式中的低权限等级的身份认证方式无法添加比其权限等级高的身份认证方式,需要通过多个身份认证方式中的高权限等级添加低于或等于该高权限等级的身份认证方式。在本实施例中,由于第一身份认证方式是唯一的身份认证方式,在添加比其权限等级高的身份认证方式,可以通过第一身份认证方式获取第一角色解密密钥,进而赋予该权限等级高的身份认证方式获取第一角色解密密钥的权限,同时可以通过生成第二角色解密密钥,进而赋予该权限等级高的身份认证方式获取第二角色解密密钥的权限。In one embodiment, when a digital identity corresponds to multiple identity authentication methods, an identity authentication method with a lower authority level among the multiple identity authentication methods cannot be added to an identity authentication method with a higher authority level, and multiple identity authentication methods are required. Add the authentication methods that are lower than or equal to the high-privilege level in the high-privilege level. In this embodiment, since the first identity authentication method is the only identity authentication method, when an identity authentication method with a higher authority level is added, the first role decryption key can be obtained through the first identity authentication method, and then the authority can be given The high-level identity authentication method obtains the authority of the decryption key of the first role, and at the same time, the authorization of obtaining the decryption key of the second role can be given to the identity authentication method with a high authority level by generating the second role's decryption key.
本申请一示例性实施例提供一种密钥管理方法,该方法可以由电子设备来执行,例如手机,具体可以由电子设备上与数字身份对应的客户端执行。该密钥管理方法涉及通过第一身份认证方式改变第三身份认证方式的权限等级的过程,具体包括:删除第三身份认证方式对应的初始加密第二角色解密密钥,以降低第三身份认证方式的权限等级。An exemplary embodiment of the present application provides a key management method, which can be executed by an electronic device, such as a mobile phone, and specifically can be executed by a client corresponding to a digital identity on the electronic device. The key management method involves the process of changing the authority level of the third identity authentication method through the first identity authentication method, and specifically includes: deleting the initially encrypted second role decryption key corresponding to the third identity authentication method, so as to reduce the third identity authentication method. the permission level of the method.
该数字身份至少包括第一身份认证方式和第三身份认证方式,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第三身份认证方式对应多个权限等级中的第三权限等级,第三权限等级等于或低于第一权限等级,第三权限等级具有管理第一角色和至少一个角色中的第二角色对应资产的权限。The digital identity includes at least a first identity authentication method and a third identity authentication method. The first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, and the third identity authentication method corresponds to the first authority level among the multiple authority levels. Three permission levels, the third permission level is equal to or lower than the first permission level, and the third permission level has the permission to manage the assets corresponding to the first role and the second role of the at least one role.
若第三身份认证方式与第一身份认证方式对应同一用户的同一电子设备,第三身份认证方式对应的初始加密第二角色解密密钥保存在该电子设备上,可以通过该电子设备直接对其进行删除。若第三身份认证方式与第一身份认证方式对应不同用户,第三身份认证方式对应的初始加密第二角色解密密钥保存在第三身份认证方式对应的电子设备上,可以通过第一身份认证方式对应的电子设备向第三身份认证方式对应的电子设备发送指令从而对其进行删除。若第三身份认证方式对应的初始加密第二角色解密密钥保存在本地,则电子设备直接对其进行删除。若第三身份认证方式对应的初始加密第二角色解密密钥保存在服务器端,则该第一身份认证方式对应的电子设备通过向服务器端发送指令从而对其进行删除。If the third identity authentication method and the first identity authentication method correspond to the same electronic device of the same user, the initial encrypted second character decryption key corresponding to the third identity authentication method is stored on the electronic device, and the electronic device can directly access the same electronic device through the electronic device. to delete. If the third identity authentication method and the first identity authentication method correspond to different users, the initial encrypted second role decryption key corresponding to the third identity authentication method is stored on the electronic device corresponding to the third identity authentication method, and the first identity authentication method can pass the first identity authentication. The electronic device corresponding to the method sends an instruction to the electronic device corresponding to the third identity authentication method to delete it. If the initially encrypted second role decryption key corresponding to the third identity authentication method is stored locally, the electronic device directly deletes it. If the initially encrypted second role decryption key corresponding to the third identity authentication method is stored on the server side, the electronic device corresponding to the first identity authentication method deletes it by sending an instruction to the server side.
在本实施例中,通过删除第三身份认证方式对应的初始加密第二角色解密密钥,以降低第三身份认证方式的权限等级,可以只涉及第三身份认证方式对应的密钥,而对其他身份认 证方式对应的密钥无影响。该方法可以更好地适用于数字身份对应的身份认证方式较多的情况,可以快速实现对第三身份认证方式权限等级的降低。In this embodiment, by deleting the initially encrypted second role decryption key corresponding to the third identity authentication method to reduce the authority level of the third identity authentication method, only the key corresponding to the third identity authentication method can be involved, and the Keys corresponding to other authentication methods are not affected. The method can be better applied to the situation where there are many identity authentication methods corresponding to digital identities, and can quickly reduce the authority level of the third identity authentication method.
在另一实施例中,还可以通过进一步删除第三身份认证方式对应的初始加密第一角色解密密钥,以将第三身份认证方式从数字身份中删除。In another embodiment, the third identity authentication method may be deleted from the digital identity by further deleting the initially encrypted first character decryption key corresponding to the third identity authentication method.
第三身份认证方式对应的初始加密第一角色解密密钥的删除过程与上述的第三身份认证方式对应的初始加密第二角色解密密钥的删除过程类似。The deletion process of the initially encrypted first role decryption key corresponding to the third identity authentication method is similar to the deletion process of the initially encrypted second role decryption key corresponding to the third identity authentication method described above.
图8是本申请另一示例性实施例提供的密钥管理方法的流程示意图,图8的方法可以由电子设备来执行,例如手机,具体可以由电子设备上与数字身份对应的客户端执行。如图8所示,该密钥管理方法涉及通过第一身份认证方式改变第三身份认证方式的权限等级的过程,具体包括如下内容。FIG. 8 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application. The method in FIG. 8 may be executed by an electronic device, such as a mobile phone, and may be executed by a client corresponding to a digital identity on the electronic device. As shown in FIG. 8 , the key management method involves the process of changing the authority level of the third identity authentication method through the first identity authentication method, and specifically includes the following contents.
S810:生成新的第二角色解密密钥。S810: Generate a new second character decryption key.
S820:利用第一认证解密密钥对应的第一认证加密密钥对新的第二角色解密密钥进行加密,得到第一身份认证方式对应的新的初始加密第二角色解密密钥,以降低第三身份认证方式的权限等级。S820: Encrypt the new second role decryption key by using the first authentication encryption key corresponding to the first authentication decryption key to obtain a new initially encrypted second role decryption key corresponding to the first identity authentication method, so as to reduce the The authority level of the third identity authentication method.
该数字身份至少包括第一身份认证方式和第三身份认证方式,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第三身份认证方式对应多个权限等级中的第三权限等级,第三权限等级等于或低于第一权限等级,第三权限等级具有管理第一角色和至少一个角色中的第二角色对应资产的权限。The digital identity includes at least a first identity authentication method and a third identity authentication method. The first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, and the third identity authentication method corresponds to the first authority level among the multiple authority levels. Three permission levels, the third permission level is equal to or lower than the first permission level, and the third permission level has the permission to manage the assets corresponding to the first role and the second role of the at least one role.
第一认证解密密钥用于对第一身份认证方式对应的新的初始加密第二角色解密密钥进行解密,得到新的第二角色解密密钥,新的第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第二目标密钥用于管理第二角色对应的资产。The first authentication decryption key is used to decrypt the new initially encrypted second role decryption key corresponding to the first identity authentication method, to obtain a new second role decryption key, and the new second role decryption key is the same as the second role decryption key. Corresponding roles, used to decrypt the encrypted second target key to obtain the second target key, and the second target key is used to manage the assets corresponding to the second role.
在本实施例中,通过生成新的角色解密密钥来降低第三身份认证方式的权限等级,可以不涉及第三身份认证方式对应的密钥。该方法可以更好地适用于数字身份对应的身份认证方式较少的情况,可以避免两个身份认证方式之间的交互,从而可以快速实现对第三身份认证方式权限等级的降低。In this embodiment, by generating a new role decryption key to reduce the authority level of the third identity authentication method, the key corresponding to the third identity authentication method may not be involved. The method can be better applied to the situation where there are few identity authentication methods corresponding to digital identities, can avoid interaction between the two identity authentication methods, and can quickly reduce the authority level of the third identity authentication method.
在一实施例中,在生成新的第二角色解密密钥的同时还可以生成新的第二角色加密密钥。In one embodiment, a new second character encryption key may be generated at the same time as the new second character decryption key.
在一实施例中,还可以通过生成新的第一角色解密密钥,并利用第一认证解密密钥对应的第一认证加密密钥对新的第一角色解密密钥进行加密,得到第一身份认证方式对应的新的初始加密第一角色解密密钥,以将第三身份认证方式从数字身份中删除。In one embodiment, a new first character decryption key can also be generated by using the first authentication encryption key corresponding to the first authentication decryption key to encrypt the new first character decryption key to obtain the first character decryption key. The new initial encrypted first role decryption key corresponding to the identity authentication method is used to delete the third identity authentication method from the digital identity.
图9是本申请另一示例性实施例提供的密钥管理方法的流程示意图,图9的方法可以由电子设备来执行,例如手机,具体可以由电子设备上与数字身份对应的客户端执行。如图9所示,该密钥管理方法涉及通过第一身份认证方式改变第三身份认证方式的权限等级的过程,具体包括如下内容。FIG. 9 is a schematic flowchart of a key management method provided by another exemplary embodiment of the present application. The method in FIG. 9 may be executed by an electronic device, such as a mobile phone, and may be executed by a client corresponding to a digital identity on the electronic device. As shown in FIG. 9 , the key management method involves the process of changing the authority level of the third identity authentication method through the first identity authentication method, and specifically includes the following contents.
S910:获取第三身份认证方式对应的第三认证加密密钥。S910: Obtain a third authentication encryption key corresponding to the third identity authentication method.
第三认证加密密钥的生成和获取过程,可以参见上述图5实施例中第二认证加密密钥的生成和获取过程,为避免重复,此处不再赘述。For the generation and acquisition process of the third authentication encryption key, reference may be made to the generation and acquisition process of the second authentication encryption key in the embodiment of FIG. 5 . To avoid repetition, details are not described here.
S920:利用第一认证解密密钥对第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥。S920: Decrypt the initially encrypted second role decryption key corresponding to the first identity authentication mode by using the first authentication decryption key to obtain the second role decryption key.
S930:利用第三认证加密密钥对第二角色解密密钥进行加密,得到第三身份认证方式对应的初始加密第二角色解密密钥,以提升第三身份认证方式的权限等级。S930: Encrypt the second role decryption key with the third authentication encryption key to obtain the initially encrypted second role decryption key corresponding to the third identity authentication method, so as to increase the authority level of the third identity authentication method.
该数字身份至少包括第一身份认证方式和第三身份认证方式,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第三身份认证方式对应多个权限等级中的第三权限等级,第三权限等级低于第一权限等级,第一权限等级具有管理第一角色和至少一个角色中的第二角色对应资产的权限,第三权限等级具有管理第一角色对应资产的权限。The digital identity includes at least a first identity authentication method and a third identity authentication method. The first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, and the third identity authentication method corresponds to the first authority level among the multiple authority levels. Three permission levels, the third permission level is lower than the first permission level, the first permission level has the permission to manage the assets corresponding to the first role and the second role in at least one role, and the third permission level has the permission to manage the assets corresponding to the first role. permissions.
第三认证解密密钥与第三认证加密密钥对应,用于对第三身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥,第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第二目标密钥用于管理第二角色对应的资产。The third authentication decryption key corresponds to the third authentication encryption key, and is used to decrypt the initially encrypted second role decryption key corresponding to the third identity authentication method to obtain the second role decryption key, the second role decryption key Corresponding to the second role, it is used to decrypt the encrypted second target key to obtain the second target key, and the second target key is used to manage the assets corresponding to the second role.
在本实施例中,通过第一身份认证方式实现对第三身份认证方式权限等级的提升,可以使得各个身份认证方式对数字身份下所有资产的管理更具有灵活性。In this embodiment, the authority level of the third identity authentication method is improved through the first identity authentication method, which can make the management of all assets under the digital identity more flexible in each identity authentication method.
示例性装置Exemplary device
图10所示为本申请一示例性实施例提供的密钥管理装置1000的结构示意图。如图10所示,装置1000包括:第一获取模块1010以及第一加密模块1020。FIG. 10 is a schematic structural diagram of a key management apparatus 1000 according to an exemplary embodiment of the present application. As shown in FIG. 10 , the apparatus 1000 includes: a first acquisition module 1010 and a first encryption module 1020 .
第一获取模块1010用于通过第一身份认证方式获取用户的授权,以生成第一认证加密密钥,其中,第一身份认证方式用于登录数字身份。第一加密模块1020用于利用第一认证加密密钥对至少一个角色解密密钥进行加密,得到第一身份认证方式对应的至少一个初始加密角色解密密钥,其中,至少一个角色解密密钥与数字身份的至少一个角色一一对应,用于对至少一个加密后的目标密钥进行解密,以得到至少一个目标密钥。The first obtaining module 1010 is configured to obtain the authorization of the user through a first identity authentication method to generate a first authentication encryption key, wherein the first identity authentication method is used to log in a digital identity. The first encryption module 1020 is configured to encrypt at least one character decryption key by using the first authentication encryption key to obtain at least one initial encrypted character decryption key corresponding to the first identity authentication method, wherein the at least one character decryption key is the same as the At least one role of the digital identity is in one-to-one correspondence, and is used for decrypting at least one encrypted target key to obtain at least one target key.
本申请实施例提供了一种密钥管理装置,通过生成第一身份认证方式对应的第一认证加密密钥,利用第一认证加密密钥对数字身份下的至少一个角色解密密钥进行加密,其中,至少一个角色解密密钥用于对加密后的目标密钥进行解密以得到至少一个目标密钥,从而能够将身份认证方式与目标密钥关联起来,方便目标密钥的管理和使用过程。An embodiment of the present application provides a key management device, which generates a first authentication encryption key corresponding to a first identity authentication method, and uses the first authentication encryption key to encrypt at least one character decryption key under a digital identity, Wherein, at least one role decryption key is used to decrypt the encrypted target key to obtain at least one target key, so that the identity authentication method can be associated with the target key, which facilitates the management and use of the target key.
根据本发明一实施例,装置1000还包括:第一生成模块1030,用于基于第一身份认证方式对应的身份认证信息生成第三存储密钥,并生成第一认证加密密钥对应的第一认证解密密钥;第二加密模块1040,用于利用第三存储密钥对第一认证解密密钥进行加密,得到加密后的第一认证解密密钥。According to an embodiment of the present invention, the apparatus 1000 further includes: a first generation module 1030, configured to generate a third storage key based on the identity authentication information corresponding to the first identity authentication method, and generate a first authentication encryption key corresponding to the first authentication encryption key. authentication and decryption key; the second encryption module 1040 is configured to encrypt the first authentication and decryption key by using the third storage key to obtain the encrypted first authentication and decryption key.
根据本发明一实施例,身份认证信息为非公开身份认证信息,其中,第一生成模块1030,用于基于非公开身份认证信息以及第一身份认证方式对应的用户的父母姓名生成第三存储密钥。According to an embodiment of the present invention, the identity authentication information is non-public identity authentication information, wherein the first generation module 1030 is configured to generate a third storage password based on the non-public identity authentication information and the parent name of the user corresponding to the first identity authentication method key.
根据本发明一实施例,装置1000还包括:发送模块1050,用于将加密后的第一认证解密密钥提交至服务器端,并将至少一个初始加密角色解密密钥提交至服务器端。According to an embodiment of the present invention, the apparatus 1000 further includes: a sending module 1050, configured to submit the encrypted first authentication decryption key to the server, and submit at least one initial encryption role decryption key to the server.
根据本发明一实施例,装置1000还包括:第三加密模块1060,用于利用至少一个角色加密密钥分别对至少一个目标密钥进行加密,得到至少一个加密后的目标密钥。According to an embodiment of the present invention, the apparatus 1000 further includes: a third encryption module 1060, configured to encrypt at least one target key by using at least one role encryption key to obtain at least one encrypted target key.
根据本发明一实施例,装置1000还包括:存储模块1070,用于将至少一个加密后的目标密钥保存在本地。According to an embodiment of the present invention, the apparatus 1000 further includes: a storage module 1070, configured to store at least one encrypted target key locally.
根据本发明一实施例,装置1000还包括:第二生成模块1080,用于随机生成至少一个角色解密密钥。According to an embodiment of the present invention, the apparatus 1000 further includes: a second generation module 1080, configured to randomly generate at least one character decryption key.
应当理解,上述实施例中的第一获取模块1010、第一加密模块1020、第一生成模块1030、第二加密模块1040、发送模块1050、第三加密模块1060、存储模块1070以及第二生成模块1080的操作和功能可以参考上述图2至图4实施例中提供的密钥管理方法中的描述,为了避免重复,在此不再赘述。It should be understood that the first acquisition module 1010 , the first encryption module 1020 , the first generation module 1030 , the second encryption module 1040 , the sending module 1050 , the third encryption module 1060 , the storage module 1070 and the second generation module in the above embodiment For the operations and functions of 1080, reference may be made to the descriptions in the key management methods provided in the embodiments of FIG. 2 to FIG. 4, which are not repeated here to avoid repetition.
图11所示为本申请另一示例性实施例提供的密钥管理装置1100的结构示意图。如图11所示,装置1100包括:第一获取模块1110、第二获取模块1120、第一解密模块1130以及第一加密模块1140。FIG. 11 is a schematic structural diagram of a key management apparatus 1100 provided by another exemplary embodiment of the present application. As shown in FIG. 11 , the apparatus 1100 includes: a first acquisition module 1110 , a second acquisition module 1120 , a first decryption module 1130 and a first encryption module 1140 .
第一获取模块1110用于获取数字身份的第一身份认证方式对应的第一认证解密密钥。第二获取模块1120用于获取数字身份待添加的第二身份认证方式对应的第二认证加密密钥。第一解密模块1130用于利用第一认证解密密钥对第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥。第一加密模块1140用于利用第二认证加密密钥对第一角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第一角色解密密钥,其 中,第一角色解密密钥与数字身份的至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。The first obtaining module 1110 is configured to obtain the first authentication and decryption key corresponding to the first identity authentication method of the digital identity. The second obtaining module 1120 is configured to obtain the second authentication encryption key corresponding to the second identity authentication method to be added to the digital identity. The first decryption module 1130 is configured to decrypt the initially encrypted first character decryption key corresponding to the first identity authentication method by using the first authentication decryption key to obtain the first character decryption key. The first encryption module 1140 is configured to encrypt the first character decryption key by using the second authentication encryption key to obtain the initial encrypted first character decryption key corresponding to the second identity authentication method, wherein the first character decryption key is the same as the first character decryption key. The first role in the at least one role of the digital identity corresponds to the first role, and is used for decrypting the encrypted first target key to obtain the first target key.
本申请实施例提供了一种密钥管理装置,通过第一身份认证方式为数字身份添加第二身份认证方式,可以实现密钥的分类管理,且实现密钥管理过程的多元化。The embodiment of the present application provides a key management device, which can implement classified management of keys and diversify the key management process by adding a second identity authentication method to a digital identity through a first identity authentication method.
根据本发明一实施例,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第二身份认证方式对应多个权限等级中的第二权限等级,第一权限等级具有管理第一角色对应资产的权限,其中,装置1100还包括:第一确定模块1150,用于在第一解密模块1130利用第一认证解密密钥对第一身份认证方式对应的初始加密第一角色解密密钥进行解密之前,确定第二身份认证方式的第二权限等级。According to an embodiment of the present invention, the first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, the second identity authentication method corresponds to the second authority level among the multiple authority levels, and the first authority level has management The authority of the asset corresponding to the first role, wherein the apparatus 1100 further includes: a first determination module 1150 for decrypting the initially encrypted first role corresponding to the first identity authentication method by using the first authentication decryption key in the first decryption module 1130 Before the key is decrypted, the second authority level of the second identity authentication method is determined.
根据本发明一实施例,第一权限等级高于第二权限等级,第一权限等级还具有管理至少一个角色中的第二角色对应资产的权限,第二权限等级具有管理第一角色对应资产的权限。According to an embodiment of the present invention, the first authority level is higher than the second authority level, the first authority level also has the authority to manage assets corresponding to the second role in at least one role, and the second authority level has the authority to manage the assets corresponding to the first role. permissions.
根据本发明一实施例,第一权限等级等于第二权限等级,第一权限等级还具有管理至少一个角色中的第二角色对应资产的权限,其中,第一解密模块1130还用于利用第一认证解密密钥对第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥;第一加密模块1140还用于利用第二认证加密密钥对第二角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第二角色解密密钥,其中,第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第一目标密钥用于管理第一角色对应的资产,第二目标密钥用于管理第二角色对应的资产。According to an embodiment of the present invention, the first permission level is equal to the second permission level, and the first permission level also has the permission to manage assets corresponding to the second role in at least one role, wherein the first decryption module 1130 is further configured to utilize the first The authentication decryption key decrypts the initially encrypted second character decryption key corresponding to the first identity authentication method to obtain the second character decryption key; the first encryption module 1140 is further configured to use the second authentication encryption key to decrypt the second character The decryption key is encrypted to obtain the initial encrypted second role decryption key corresponding to the second identity authentication method, wherein the second role decryption key corresponds to the second role and is used to decrypt the encrypted second target key , to obtain the second target key, the first target key is used to manage the assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
根据本发明一实施例,第一权限等级低于第二权限等级,第二权限等级具有管理第一角色和至少一个角色中的第二角色对应资产的权限,其中,装置1100还包括:第一生成模块1160,用于生成第二角色解密密钥;第二加密模块1170,用于利用第二认证加密密钥对第二角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第二角色解密密钥,其中,第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第一目标密钥用于管理第一角色对应的资产,第二目标密钥用于管理第二角色对应的资产。According to an embodiment of the present invention, the first permission level is lower than the second permission level, and the second permission level has the permission to manage the assets corresponding to the first role and the second role in the at least one role, wherein the apparatus 1100 further includes: a first The generation module 1160 is used to generate the second character decryption key; the second encryption module 1170 is used to encrypt the second character decryption key by using the second authentication encryption key to obtain the initial encryption first corresponding to the second identity authentication method. Two-role decryption key, wherein the second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to obtain the second target key, and the first target key is used for management Assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
根据本发明一实施例,装置1100还包括:第一存储模块1180,用于将第二身份认证方式对应的初始加密第一角色解密密钥保存至服务器端或第二身份认证方式对应的客户端。According to an embodiment of the present invention, the apparatus 1100 further includes: a first storage module 1180, configured to save the decryption key of the initial encrypted first role corresponding to the second identity authentication method to the server or the client corresponding to the second identity authentication method .
根据本发明一实施例,数字身份还包括第三身份认证方式,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第三身份认证方式对应多个权限等级中的第三权限等级,第三权限等级等于或低于第一权限等级,第三权限等级具有管理第一角色和至少一个角色中的第二角色对应资产的权限,其中,装置1100还包括:第一删除模块1181,用于删除第三身份认证方式对应的初始加密第二角色解密密钥,以降低第三身份认证方式的权限等级。According to an embodiment of the present invention, the digital identity further includes a third identity authentication method. The first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, and the third identity authentication method corresponds to the first authority level among the multiple authority levels. Three permission levels, the third permission level is equal to or lower than the first permission level, and the third permission level has the permission to manage the assets corresponding to the first role and the second role in the at least one role, wherein the apparatus 1100 further includes: a first deletion The module 1181 is configured to delete the initially encrypted second role decryption key corresponding to the third identity authentication method, so as to reduce the authority level of the third identity authentication method.
根据本发明一实施例,第一删除模块1181还用于删除第三身份认证方式对应的初始加密第一角色解密密钥,以将第三身份认证方式从数字身份中删除。According to an embodiment of the present invention, the first deletion module 1181 is further configured to delete the initially encrypted first character decryption key corresponding to the third identity authentication method, so as to delete the third identity authentication method from the digital identity.
根据本发明一实施例,数字身份还包括第三身份认证方式,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第三身份认证方式对应多个权限等级中的第三权限等级,第三权限等级等于或低于第一权限等级,第三权限等级具有管理第一角色和至少一个角色中的第二角色对应资产的权限,其中,装置1100还包括:第二生成模块1182,用于生成新的第二角色解密密钥;第三加密模块1183,用于利用第一认证解密密钥对应的第一认证加密密钥对新的第二角色解密密钥进行加密,得到第一身份认证方式对应的新的初始加密第二角色解密密钥,以降低第三身份认证方式的权限等级,其中,新的第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第一目标密钥用于管理第一角色对应的资产,第二目标密钥用于管理第二角色对应的资产。According to an embodiment of the present invention, the digital identity further includes a third identity authentication method. The first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, and the third identity authentication method corresponds to the first authority level among the multiple authority levels. Three permission levels, the third permission level is equal to or lower than the first permission level, and the third permission level has the permission to manage the assets corresponding to the first role and the second role in the at least one role, wherein the apparatus 1100 further includes: a second generation The module 1182 is used to generate a new second character decryption key; the third encryption module 1183 is used to encrypt the new second character decryption key using the first authentication encryption key corresponding to the first authentication decryption key, Obtain a new initial encrypted second role decryption key corresponding to the first identity authentication method to reduce the authority level of the third identity authentication method, wherein the new second role decryption key corresponds to the second role and is used to encrypt The second target key is decrypted to obtain the second target key, the first target key is used to manage the assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
根据本发明一实施例,第二生成模块1182还用于生成新的第一角色解密密钥;第三加密模块1183还用于利用第一认证解密密钥对应的第一认证加密密钥对新的第一角色解密密钥进行加密,得到第一身份认证方式对应的新的初始加密第一角色解密密钥,以将第三身份认证方式从数字身份中删除。According to an embodiment of the present invention, the second generation module 1182 is further configured to generate a new first character decryption key; the third encryption module 1183 is further configured to use the first authentication encryption key corresponding to the first authentication decryption key to pair the new Encrypt the first character decryption key of the first identity authentication method to obtain a new initial encrypted first character decryption key corresponding to the first identity authentication method, so as to delete the third identity authentication method from the digital identity.
根据本发明一实施例,数字身份还包括第三身份认证方式,第一身份认证方式对应数字身份的多个权限等级中的第一权限等级,第三身份认证方式对应多个权限等级中的第三权限等级,第三权限等级低于第一权限等级,第一权限等级具有管理第一角色和至少一个角色中的第二角色对应资产的权限,第三权限等级具有管理第一角色对应资产的权限,其中,装置1100还包括:第三获取模块1184,用于获取第三身份认证方式对应的第三认证加密密钥,其中,第一解密模块1130还用于利用第一认证解密密钥对第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥;第四加密模块1185,用于利用第三认证加密密钥对第二角色解密密钥进行加密,得到第三身份认证方式对应的初始加密第二角色解密密钥,以提升第三身份认证方式的权限等级,其中,第二角色解密密钥与第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,第一目标密钥用于管理第一角色对应的资产,第二目标密钥用于管理第二角色对应的资产。According to an embodiment of the present invention, the digital identity further includes a third identity authentication method. The first identity authentication method corresponds to the first authority level among the multiple authority levels of the digital identity, and the third identity authentication method corresponds to the first authority level among the multiple authority levels. Three permission levels, the third permission level is lower than the first permission level, the first permission level has the permission to manage the assets corresponding to the first role and the second role in at least one role, and the third permission level has the permission to manage the assets corresponding to the first role. The device 1100 further includes: a third obtaining module 1184, configured to obtain a third authentication encryption key corresponding to the third identity authentication method, wherein the first decryption module 1130 is further configured to use the first authentication decryption key pair Decrypt the initially encrypted second role decryption key corresponding to the first identity authentication method to obtain the second role decryption key; the fourth encryption module 1185 is used to encrypt the second role decryption key with the third authentication encryption key , and obtain the initial encrypted second role decryption key corresponding to the third identity authentication method, so as to improve the authority level of the third identity authentication method, wherein the second role decryption key corresponds to the second role, and is used for encrypting the encrypted first The second target key is decrypted to obtain the second target key, the first target key is used to manage the assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
应当理解,上述实施例中的第一获取模块1110、第二获取模块1120、第一解密模块1130、第一加密模块1140、第一确定模块1150、第一生成模块1160、第二加密模块1170、第一存储模块1180、第一删除模块1181、第二生成模块1182、第三加密模块1183、第三获取模块1184以及第四加密模块1185的操作和功能可以参考上述图5至图9实施例中提供的密钥管理方法中的描述,为了避免重复,在此不再赘述。It should be understood that the first obtaining module 1110, the second obtaining module 1120, the first decryption module 1130, the first encryption module 1140, the first determination module 1150, the first generation module 1160, the second encryption module 1170, The operations and functions of the first storage module 1180 , the first deletion module 1181 , the second generation module 1182 , the third encryption module 1183 , the third acquisition module 1184 and the fourth encryption module 1185 may refer to the above-mentioned embodiments in FIGS. 5 to 9 . The description in the provided key management method is not repeated here in order to avoid repetition.
图12是本申请一示例性实施例提供的用于密钥管理的电子设备1200的框图。FIG. 12 is a block diagram of an electronic device 1200 for key management provided by an exemplary embodiment of the present application.
参照图12,电子设备1200包括处理器1210,以及由存储器1220所代表的存储器资源,用于存储可由处理器1210的执行的指令,例如应用程序。存储器1220中存储的应用程序可以包括一个或一个以上的每一个对应于一组指令的模块。此外,处理器1210被配置为执行指令,以执行上述密钥管理方法。12, an electronic device 1200 includes a processor 1210, and a memory resource represented by a memory 1220 for storing instructions executable by the processor 1210, such as an application program. An application program stored in memory 1220 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processor 1210 is configured to execute instructions to perform the above-described key management method.
电子设备1200还可以包括一个电源组件被配置为执行电子设备1200的电源管理,一个有线或无线网络接口被配置为将电子设备1200连接到网络,和一个输入输出(I/O)接口。可以基于存储在存储器1220的操作系统操作电子设备1200,例如Windows Server TM,Mac OS X TM,Unix TM,Linux TM,FreeBSD TM或类似。 The electronic device 1200 may also include a power supply assembly configured to perform power management of the electronic device 1200, a wired or wireless network interface configured to connect the electronic device 1200 to a network, and an input output (I/O) interface. Electronic device 1200 may be operated based on an operating system stored in memory 1220, such as Windows Server , Mac OS X , Unix , Linux , FreeBSD or the like.
一种非临时性计算机可读存储介质,当存储介质中的指令由上述电子设备1200的处理器执行时,使得上述电子设备1200能够执行一种密钥管理方法。该密钥管理方法包括:通过第一身份认证方式获取用户的授权,以生成第一认证加密密钥,其中,第一身份认证方式用于登录数字身份;利用第一认证加密密钥对至少一个角色解密密钥进行加密,得到第一身份认证方式对应的至少一个初始加密角色解密密钥,其中,至少一个角色解密密钥与数字身份的至少一个角色一一对应,用于对至少一个加密后的目标密钥进行解密,以得到至少一个目标密钥。或者,该密钥管理方法包括:获取数字身份的第一身份认证方式对应的第一认证解密密钥;获取数字身份待添加的第二身份认证方式对应的第二认证加密密钥;利用第一认证解密密钥对第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥;利用第二认证加密密钥对第一角色解密密钥进行加密,得到第二身份认证方式对应的初始加密第一角色解密密钥,其中,第一角色解密密钥与数字身份的至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。A non-transitory computer-readable storage medium, when the instructions in the storage medium are executed by the processor of the electronic device 1200, the electronic device 1200 can execute a key management method. The key management method includes: obtaining a user's authorization through a first identity authentication method to generate a first authentication encryption key, wherein the first identity authentication method is used to log in a digital identity; using the first authentication encryption key to pair at least one The character decryption key is encrypted to obtain at least one initial encrypted character decryption key corresponding to the first identity authentication method, wherein the at least one character decryption key is in one-to-one correspondence with at least one character of the digital identity, and is used to encrypt the at least one encrypted character. The target key is decrypted to obtain at least one target key. Alternatively, the key management method includes: obtaining a first authentication and decryption key corresponding to a first identity authentication method of a digital identity; obtaining a second authentication and encryption key corresponding to a second identity authentication method to be added to the digital identity; The authentication decryption key decrypts the initially encrypted first role decryption key corresponding to the first identity authentication method to obtain the first role decryption key; the second authentication encryption key is used to encrypt the first role decryption key to obtain the first role decryption key. The initial encrypted first character decryption key corresponding to the two-identity authentication method, wherein the first character decryption key corresponds to the first character in at least one character of the digital identity, and is used to decrypt the encrypted first target key , to get the first target key.
上述所有可选技术方案,可采用任意结合形成本发明的可选实施例,在此不再一一赘述。All the above-mentioned optional technical solutions can be combined arbitrarily to form optional embodiments of the present invention, which will not be repeated here.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每 个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Skilled artisans may use different methods of implementing the described functionality for each particular application, but such implementations should not be considered beyond the scope of the present invention.
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统、装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the system, device and unit described above may refer to the corresponding process in the foregoing method embodiments, which will not be repeated here.
在本申请所提供的几个实施例中,应该理解到,所揭露的系统、装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the apparatus embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components may be combined or Can be integrated into another system, or some features can be ignored, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
所述功能如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序校验码的介质。The functions, if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention can be embodied in the form of a software product in essence, or the part that contributes to the prior art or the part of the technical solution. The computer software product is stored in a storage medium, including Several instructions are used to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage media include: U disk, mobile hard disk, Read-Only Memory (ROM, Read-Only Memory), Random Access Memory (RAM, Random Access Memory), magnetic disk or CD, etc. that can store program check codes medium.
需要说明的是,在本发明的描述中,术语“第一”、“第二”、“第三”等仅用于描述目的,而不能理解为指示或暗示相对重要性。此外,在本发明的描述中,除非另有说明,“多个”的含义是两个或两个以上。It should be noted that, in the description of the present invention, the terms "first", "second", "third", etc. are only used for the purpose of description, and should not be construed as indicating or implying relative importance. Also, in the description of the present invention, unless otherwise specified, "plurality" means two or more.
以上所述仅为本发明的较佳实施例而已,并不用以限制本发明,凡在本发明的精神和原则之内,所作的任何修改、等同替换等,均应包含在本发明的保护范围之内。The above descriptions are only preferred embodiments of the present invention, and are not intended to limit the present invention. Any modifications, equivalent replacements, etc. made within the spirit and principles of the present invention shall be included in the protection scope of the present invention. within.

Claims (25)

  1. 一种密钥管理方法,其特征在于,包括:A key management method, comprising:
    通过第一身份认证方式获取用户的授权,以生成第一认证加密密钥,其中,所述第一身份认证方式用于登录数字身份;Obtain the user's authorization through a first identity authentication method to generate a first authentication encryption key, wherein the first identity authentication method is used to log in to a digital identity;
    利用所述第一认证加密密钥对至少一个角色解密密钥进行加密,得到所述第一身份认证方式对应的至少一个初始加密角色解密密钥,其中,Encrypt at least one character decryption key by using the first authentication encryption key to obtain at least one initial encrypted character decryption key corresponding to the first identity authentication method, wherein,
    所述至少一个角色解密密钥与所述数字身份的至少一个角色一一对应,用于对至少一个加密后的目标密钥进行解密,以得到至少一个目标密钥。The at least one character decryption key is in one-to-one correspondence with at least one character of the digital identity, and is used to decrypt at least one encrypted target key to obtain at least one target key.
  2. 根据权利要求1所述的密钥管理方法,其特征在于,还包括:The key management method according to claim 1, further comprising:
    基于所述第一身份认证方式对应的身份认证信息生成第三存储密钥;generating a third storage key based on the identity authentication information corresponding to the first identity authentication method;
    生成所述第一认证加密密钥对应的第一认证解密密钥;generating a first authentication decryption key corresponding to the first authentication encryption key;
    利用所述第三存储密钥对所述第一认证解密密钥进行加密,得到加密后的第一认证解密密钥。The first authentication and decryption key is encrypted by using the third storage key to obtain an encrypted first authentication and decryption key.
  3. 根据权利要求2所述的密钥管理方法,其特征在于,所述身份认证信息为非公开身份认证信息,其中,所述基于所述第一身份认证方式对应的身份认证信息生成第三存储密钥,包括:The key management method according to claim 2, wherein the identity authentication information is non-public identity authentication information, wherein the third storage key is generated based on the identity authentication information corresponding to the first identity authentication method. keys, including:
    基于所述非公开身份认证信息以及所述第一身份认证方式对应的用户的父母姓名生成所述第三存储密钥。The third storage key is generated based on the non-public identity authentication information and the parent name of the user corresponding to the first identity authentication method.
  4. 根据权利要求2所述的密钥管理方法,其特征在于,还包括:The key management method according to claim 2, further comprising:
    将所述加密后的第一认证解密密钥提交至服务器端;Submitting the encrypted first authentication decryption key to the server;
    将所述至少一个初始加密角色解密密钥提交至所述服务器端。Submitting the at least one initial encryption role decryption key to the server.
  5. 根据权利要求2所述的密钥管理方法,其特征在于,还包括:The key management method according to claim 2, further comprising:
    利用至少一个角色加密密钥分别对所述至少一个目标密钥进行加密,得到所述至少一个加密后的目标密钥。The at least one target key is encrypted by using at least one role encryption key, respectively, to obtain the at least one encrypted target key.
  6. 根据权利要求5所述的密钥管理方法,其特征在于,还包括:The key management method according to claim 5, further comprising:
    将所述至少一个加密后的目标密钥保存在本地。The at least one encrypted target key is stored locally.
  7. 根据权利要求1至6中任一项所述的密钥管理方法,其特征在于,还包括:The key management method according to any one of claims 1 to 6, further comprising:
    随机生成所述至少一个角色解密密钥。The at least one character decryption key is randomly generated.
  8. 根据权利要求1至7中任一项所述的密钥管理方法,其特征在于,还包括:The key management method according to any one of claims 1 to 7, further comprising:
    获取所述数字身份的所述第一身份认证方式对应的第一认证解密密钥;obtaining a first authentication decryption key corresponding to the first identity authentication method of the digital identity;
    获取所述数字身份待添加的第二身份认证方式对应的第二认证加密密钥;obtaining the second authentication encryption key corresponding to the second identity authentication method to be added to the digital identity;
    利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥;Use the first authentication decryption key to decrypt the initially encrypted first character decryption key corresponding to the first identity authentication mode to obtain the first character decryption key;
    利用所述第二认证加密密钥对所述第一角色解密密钥进行加密,得到所述第二身份认证方式对应的初始加密第一角色解密密钥,其中,The first character decryption key is encrypted by using the second authentication encryption key to obtain the initially encrypted first character decryption key corresponding to the second identity authentication method, wherein,
    所述第一角色解密密钥与所述数字身份的所述至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。The first character decryption key corresponds to the first character in the at least one character of the digital identity, and is used to decrypt the encrypted first target key to obtain the first target key.
  9. 根据权利要求8所述的密钥管理方法,其特征在于,所述第一身份认证方式对应所述数字身份的多个权限等级中的第一权限等级,所述第二身份认证方式对应所述多个权限等级中的第二权限等级,所述第一权限等级具有管理所述第一角色对应资产的权限,其中,The key management method according to claim 8, wherein the first identity authentication method corresponds to a first authority level among multiple authority levels of the digital identity, and the second identity authentication method corresponds to the The second authority level among the plurality of authority levels, the first authority level has the authority to manage the assets corresponding to the first role, wherein,
    在所述利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第一角色解密密钥进行解密之前,所述密钥管理方法还包括:Before using the first authentication decryption key to decrypt the initially encrypted first character decryption key corresponding to the first identity authentication method, the key management method further includes:
    确定所述第二身份认证方式的第二权限等级。A second authority level of the second identity authentication method is determined.
  10. 根据权利要求9所述的密钥管理方法,其特征在于,所述第一权限等级高于所述第二权限等级,所述第一权限等级还具有管理所述至少一个角色中的第二角色对应资产的权限,所述第二权限等级具有管理所述第一角色对应资产的权限。The key management method according to claim 9, wherein the first permission level is higher than the second permission level, and the first permission level further has a second role in managing the at least one role The authority corresponding to the asset, and the second authority level has the authority to manage the asset corresponding to the first role.
  11. 根据权利要求9所述的密钥管理方法,其特征在于,所述第一权限等级等于所述第二权限等级,所述第一权限等级还具有管理所述至少一个角色中的第二角色对应资产的权限,其中,所述密钥管理方法还包括:The key management method according to claim 9, wherein the first permission level is equal to the second permission level, and the first permission level further has a corresponding second role in managing the at least one role Asset rights, wherein the key management method further includes:
    利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥;Use the first authentication decryption key to decrypt the initially encrypted second role decryption key corresponding to the first identity authentication mode to obtain the second role decryption key;
    利用所述第二认证加密密钥对所述第二角色解密密钥进行加密,得到所述第二身份认证方式对应的初始加密第二角色解密密钥,其中,Encrypt the second character decryption key by using the second authentication encryption key to obtain the initially encrypted second character decryption key corresponding to the second identity authentication method, wherein,
    所述第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。The second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to obtain a second target key, and the first target key is used to manage the Assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
  12. 根据权利要求9所述的密钥管理方法,其特征在于,所述第一权限等级低于所述第二权限等级,所述第二权限等级具有管理所述第一角色和所述至少一个角色中的第二角色对应资产的权限,其中,所述密钥管理方法还包括:The key management method according to claim 9, wherein the first permission level is lower than the second permission level, and the second permission level has the ability to manage the first role and the at least one role The second role in the corresponding asset authority, wherein, the key management method further includes:
    生成第二角色解密密钥;Generate the second character decryption key;
    利用所述第二认证加密密钥对所述第二角色解密密钥进行加密,得到所述第二身份认证方式对应的初始加密第二角色解密密钥,其中,Encrypt the second character decryption key by using the second authentication encryption key to obtain the initially encrypted second character decryption key corresponding to the second identity authentication method, wherein,
    所述第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。The second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to obtain a second target key, and the first target key is used to manage the Assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
  13. 根据权利要求8所述的密钥管理方法,其特征在于,所述数字身份还包括第三身份认证方式,所述第一身份认证方式对应所述数字身份的多个权限等级中的第一权限等级,所述第三身份认证方式对应所述多个权限等级中的第三权限等级,所述第三权限等级等于或低于所述第一权限等级,所述第三权限等级具有管理所述第一角色和所述至少一个角色中的第二角色对应资产的权限,其中,The key management method according to claim 8, wherein the digital identity further comprises a third identity authentication method, and the first identity authentication method corresponds to a first authority among multiple authority levels of the digital identity level, the third identity authentication method corresponds to a third authority level among the plurality of authority levels, the third authority level is equal to or lower than the first authority level, and the third authority level has the ability to manage the The permissions of the assets corresponding to the first role and the second role in the at least one role, wherein,
    所述密钥管理方法还包括:The key management method further includes:
    删除所述第三身份认证方式对应的初始加密第二角色解密密钥,以降低所述第三身份认证方式的权限等级,Deleting the initially encrypted second role decryption key corresponding to the third identity authentication method to reduce the authority level of the third identity authentication method,
    或者,所述密钥管理方法还包括:Alternatively, the key management method further includes:
    生成新的第二角色解密密钥;Generate a new second character decryption key;
    利用所述第一认证解密密钥对应的所述第一认证加密密钥对所述新的第二角色解密密钥进行加密,得到所述第一身份认证方式对应的新的初始加密第二角色解密密钥,以降低所述第三身份认证方式的权限等级,其中,所述新的第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。Encrypt the new second role decryption key by using the first authentication encryption key corresponding to the first authentication decryption key to obtain a new initial encrypted second role corresponding to the first identity authentication method A decryption key to lower the authority level of the third identity authentication method, wherein the new second role decryption key corresponds to the second role and is used to decrypt the encrypted second target key to obtain a second target key, where the first target key is used to manage the assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
  14. 根据权利要求8所述的密钥管理方法,其特征在于,所述数字身份还包括第三身份认证方式,所述第一身份认证方式对应所述数字身份的多个权限等级中的第一权限等级,所述 第三身份认证方式对应所述多个权限等级中的第三权限等级,所述第三权限等级低于所述第一权限等级,所述第一权限等级具有管理所述第一角色和所述至少一个角色中的第二角色对应资产的权限,所述第三权限等级具有管理所述第一角色对应资产的权限,其中,所述密钥管理方法还包括:The key management method according to claim 8, wherein the digital identity further comprises a third identity authentication method, and the first identity authentication method corresponds to a first authority among multiple authority levels of the digital identity level, the third identity authentication method corresponds to a third authority level among the plurality of authority levels, the third authority level is lower than the first authority level, and the first authority level has the ability to manage the first authority level. The role and the permission of the asset corresponding to the second role in the at least one role, the third permission level has the permission to manage the asset corresponding to the first role, wherein the key management method further includes:
    获取所述第三身份认证方式对应的第三认证加密密钥;obtaining a third authentication encryption key corresponding to the third identity authentication method;
    利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥;Use the first authentication decryption key to decrypt the initially encrypted second role decryption key corresponding to the first identity authentication mode to obtain the second role decryption key;
    利用所述第三认证加密密钥对所述第二角色解密密钥进行加密,得到所述第三身份认证方式对应的初始加密第二角色解密密钥,以提升所述第三身份认证方式的权限等级,其中,The second role decryption key is encrypted by using the third authentication encryption key to obtain the initially encrypted second role decryption key corresponding to the third identity authentication method, so as to improve the performance of the third identity authentication method. permission level, where,
    所述第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。The second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to obtain a second target key, and the first target key is used to manage the Assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
  15. 一种密钥管理方法,其特征在于,包括:A key management method, comprising:
    获取数字身份的第一身份认证方式对应的第一认证解密密钥;Obtain the first authentication decryption key corresponding to the first identity authentication method of the digital identity;
    获取所述数字身份待添加的第二身份认证方式对应的第二认证加密密钥;obtaining the second authentication encryption key corresponding to the second identity authentication method to be added to the digital identity;
    利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥;Use the first authentication decryption key to decrypt the initially encrypted first character decryption key corresponding to the first identity authentication mode to obtain the first character decryption key;
    利用所述第二认证加密密钥对所述第一角色解密密钥进行加密,得到所述第二身份认证方式对应的初始加密第一角色解密密钥,其中,The first character decryption key is encrypted by using the second authentication encryption key to obtain the initially encrypted first character decryption key corresponding to the second identity authentication method, wherein,
    所述第一角色解密密钥与所述数字身份的至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。The first character decryption key corresponds to the first character in at least one character of the digital identity, and is used to decrypt the encrypted first target key to obtain the first target key.
  16. 根据权利要求15所述的密钥管理方法,其特征在于,所述第一身份认证方式对应所述数字身份的多个权限等级中的第一权限等级,所述第二身份认证方式对应所述多个权限等级中的第二权限等级,所述第一权限等级具有管理所述第一角色对应资产的权限,其中,The key management method according to claim 15, wherein the first identity authentication method corresponds to a first authority level among multiple authority levels of the digital identity, and the second identity authentication method corresponds to the The second authority level among the plurality of authority levels, the first authority level has the authority to manage the assets corresponding to the first role, wherein,
    在所述利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第一角色解密密钥进行解密之前,所述密钥管理方法还包括:Before using the first authentication decryption key to decrypt the initially encrypted first character decryption key corresponding to the first identity authentication method, the key management method further includes:
    确定所述第二身份认证方式的第二权限等级。A second authority level of the second identity authentication method is determined.
  17. 根据权利要求16所述的密钥管理方法,其特征在于,所述第一权限等级高于所述第二权限等级,所述第一权限等级还具有管理所述至少一个角色中的第二角色对应资产的权限,所述第二权限等级具有管理所述第一角色对应资产的权限。The key management method according to claim 16, wherein the first permission level is higher than the second permission level, and the first permission level further has a second role in managing the at least one role The authority corresponding to the asset, and the second authority level has the authority to manage the asset corresponding to the first role.
  18. 根据权利要求16所述的密钥管理方法,其特征在于,所述第一权限等级等于所述第二权限等级,所述第一权限等级还具有管理所述至少一个角色中的第二角色对应资产的权限,其中,所述密钥管理方法还包括:The key management method according to claim 16, wherein the first permission level is equal to the second permission level, and the first permission level further has a second role corresponding to the management of the at least one role. Asset rights, wherein the key management method further includes:
    利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥;Use the first authentication decryption key to decrypt the initially encrypted second role decryption key corresponding to the first identity authentication mode to obtain the second role decryption key;
    利用所述第二认证加密密钥对所述第二角色解密密钥进行加密,得到所述第二身份认证方式对应的初始加密第二角色解密密钥,其中,Encrypt the second character decryption key by using the second authentication encryption key to obtain the initially encrypted second character decryption key corresponding to the second identity authentication method, wherein,
    所述第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。The second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to obtain a second target key, and the first target key is used to manage the Assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
  19. 根据权利要求16所述的密钥管理方法,其特征在于,所述第一权限等级低于所述第二权限等级,所述第二权限等级具有管理所述第一角色和所述至少一个角色中的第二角色对应资产的权限,其中,所述密钥管理方法还包括:The key management method according to claim 16, wherein the first permission level is lower than the second permission level, and the second permission level has the ability to manage the first role and the at least one role The second role in the corresponding asset authority, wherein, the key management method further includes:
    生成第二角色解密密钥;Generate the second character decryption key;
    利用所述第二认证加密密钥对所述第二角色解密密钥进行加密,得到所述第二身份认证方式对应的初始加密第二角色解密密钥,其中,Encrypt the second character decryption key by using the second authentication encryption key to obtain the initially encrypted second character decryption key corresponding to the second identity authentication method, wherein,
    所述第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。The second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to obtain a second target key, and the first target key is used to manage the Assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
  20. 根据权利要求15所述的密钥管理方法,其特征在于,所述数字身份还包括第三身份认证方式,所述第一身份认证方式对应所述数字身份的多个权限等级中的第一权限等级,所述第三身份认证方式对应所述多个权限等级中的第三权限等级,所述第三权限等级等于或低于所述第一权限等级,所述第三权限等级具有管理所述第一角色和所述至少一个角色中的第二角色对应资产的权限,其中,The key management method according to claim 15, wherein the digital identity further comprises a third identity authentication method, and the first identity authentication method corresponds to a first authority among multiple authority levels of the digital identity level, the third identity authentication method corresponds to a third authority level among the plurality of authority levels, the third authority level is equal to or lower than the first authority level, and the third authority level has the ability to manage the the permissions of the assets corresponding to the first role and the second role in the at least one role, wherein,
    所述密钥管理方法还包括:The key management method further includes:
    删除所述第三身份认证方式对应的初始加密第二角色解密密钥,以降低所述第三身份认证方式的权限等级,Deleting the initially encrypted second role decryption key corresponding to the third identity authentication method to reduce the authority level of the third identity authentication method,
    或者,所述密钥管理方法还包括:Alternatively, the key management method further includes:
    生成新的第二角色解密密钥;Generate a new second character decryption key;
    利用所述第一认证解密密钥对应的第一认证加密密钥对所述新的第二角色解密密钥进行加密,得到所述第一身份认证方式对应的新的初始加密第二角色解密密钥,以降低所述第三身份认证方式的权限等级,其中,所述新的第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。Encrypt the new second character decryption key by using the first authentication encryption key corresponding to the first authentication decryption key to obtain a new initial encrypted second character decryption key corresponding to the first identity authentication method key to reduce the authority level of the third identity authentication method, wherein the new second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to A second target key is obtained, where the first target key is used to manage the asset corresponding to the first role, and the second target key is used to manage the asset corresponding to the second role.
  21. 根据权利要求15所述的密钥管理方法,其特征在于,所述数字身份还包括第三身份认证方式,所述第一身份认证方式对应所述数字身份的多个权限等级中的第一权限等级,所述第三身份认证方式对应所述多个权限等级中的第三权限等级,所述第三权限等级低于所述第一权限等级,所述第一权限等级具有管理所述第一角色和所述至少一个角色中的第二角色对应资产的权限,所述第三权限等级具有管理所述第一角色对应资产的权限,其中,所述密钥管理方法还包括:The key management method according to claim 15, wherein the digital identity further comprises a third identity authentication method, and the first identity authentication method corresponds to a first authority among multiple authority levels of the digital identity level, the third identity authentication method corresponds to a third authority level among the plurality of authority levels, the third authority level is lower than the first authority level, and the first authority level has the ability to manage the first authority level. The role and the permission of the asset corresponding to the second role in the at least one role, the third permission level has the permission to manage the asset corresponding to the first role, wherein the key management method further includes:
    获取所述第三身份认证方式对应的第三认证加密密钥;obtaining a third authentication encryption key corresponding to the third identity authentication method;
    利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第二角色解密密钥进行解密,得到第二角色解密密钥;Use the first authentication decryption key to decrypt the initially encrypted second role decryption key corresponding to the first identity authentication method to obtain the second role decryption key;
    利用所述第三认证加密密钥对所述第二角色解密密钥进行加密,得到所述第三身份认证方式对应的初始加密第二角色解密密钥,以提升所述第三身份认证方式的权限等级,其中,The second role decryption key is encrypted by using the third authentication encryption key to obtain the initially encrypted second role decryption key corresponding to the third identity authentication method, so as to improve the performance of the third identity authentication method. permission level, where,
    所述第二角色解密密钥与所述第二角色对应,用于对加密后的第二目标密钥进行解密,以得到第二目标密钥,所述第一目标密钥用于管理所述第一角色对应的资产,所述第二目标密钥用于管理所述第二角色对应的资产。The second role decryption key corresponds to the second role, and is used to decrypt the encrypted second target key to obtain a second target key, and the first target key is used to manage the Assets corresponding to the first role, and the second target key is used to manage the assets corresponding to the second role.
  22. 一种密钥管理装置,其特征在于,包括:A key management device, comprising:
    第一获取模块,用于通过第一身份认证方式获取用户的授权,以生成第一认证加密密钥,其中,所述第一身份认证方式用于登录数字身份;a first obtaining module, configured to obtain a user's authorization through a first identity authentication method to generate a first authentication encryption key, wherein the first identity authentication method is used to log in to a digital identity;
    第一加密模块,用于利用所述第一认证加密密钥对至少一个角色解密密钥进行加密,得到所述第一身份认证方式对应的至少一个初始加密角色解密密钥,其中,a first encryption module, configured to encrypt at least one character decryption key by using the first authentication encryption key to obtain at least one initial encrypted character decryption key corresponding to the first identity authentication method, wherein,
    所述至少一个角色解密密钥与所述数字身份的至少一个角色一一对应,用于对至少一个加密后的目标密钥进行解密,以得到至少一个目标密钥。The at least one character decryption key is in one-to-one correspondence with at least one character of the digital identity, and is used for decrypting at least one encrypted target key to obtain at least one target key.
  23. 一种密钥管理装置,其特征在于,包括:A key management device, comprising:
    第一获取模块,用于获取数字身份的第一身份认证方式对应的第一认证解密密钥;a first obtaining module, configured to obtain a first authentication decryption key corresponding to a first identity authentication method of the digital identity;
    第二获取模块,用于获取所述数字身份待添加的第二身份认证方式对应的第二认证加密密钥;a second obtaining module, configured to obtain a second authentication encryption key corresponding to the second identity authentication method to be added to the digital identity;
    第一解密模块,用于利用所述第一认证解密密钥对所述第一身份认证方式对应的初始加密第一角色解密密钥进行解密,得到第一角色解密密钥;a first decryption module, configured to decrypt the initially encrypted first character decryption key corresponding to the first identity authentication mode by using the first authentication decryption key to obtain the first character decryption key;
    第一加密模块,用于利用所述第二认证加密密钥对所述第一角色解密密钥进行加密,得到所述第二身份认证方式对应的初始加密第一角色解密密钥,其中,a first encryption module, configured to encrypt the first character decryption key by using the second authentication encryption key to obtain an initially encrypted first character decryption key corresponding to the second identity authentication method, wherein,
    所述第一角色解密密钥与所述数字身份的至少一个角色中的第一角色对应,用于对加密后的第一目标密钥进行解密,以得到第一目标密钥。The first character decryption key corresponds to the first character in at least one character of the digital identity, and is used for decrypting the encrypted first target key to obtain the first target key.
  24. 一种电子设备,包括:An electronic device comprising:
    处理器;processor;
    存储器,其中,所述存储器用于存储所述处理器可执行的指令,所述指令在被所述处理器执行时,使得所述处理器执行权利要求1至21中任一项所述的密钥管理方法。A memory, wherein the memory is used to store instructions executable by the processor which, when executed by the processor, cause the processor to perform the encryption of any one of claims 1 to 21 key management method.
  25. 一种计算机可读存储介质,包括存储在其上的计算机指令,所述计算机指令在被处理器执行时,使得所述处理器执行权利要求1至21中任一项所述的密钥管理方法。A computer-readable storage medium comprising computer instructions stored thereon, the computer instructions, when executed by a processor, cause the processor to perform the key management method of any one of claims 1 to 21 .
PCT/CN2021/115727 2020-08-31 2021-08-31 Key management method and apparatus WO2022042746A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US18/175,872 US20230208634A1 (en) 2020-08-31 2023-02-28 Key management method and apparatus

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN202010897527.4 2020-08-31
CN202010897535.9A CN114124395B (en) 2020-08-31 2020-08-31 Key management method and device
CN202010897527.4A CN111970126A (en) 2020-08-31 2020-08-31 Key management method and device
CN202010897535.9 2020-08-31

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/175,872 Continuation US20230208634A1 (en) 2020-08-31 2023-02-28 Key management method and apparatus

Publications (1)

Publication Number Publication Date
WO2022042746A1 true WO2022042746A1 (en) 2022-03-03

Family

ID=80354709

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/115727 WO2022042746A1 (en) 2020-08-31 2021-08-31 Key management method and apparatus

Country Status (2)

Country Link
US (1) US20230208634A1 (en)
WO (1) WO2022042746A1 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101510238A (en) * 2008-02-15 2009-08-19 北京书生国际信息技术有限公司 Document database safety access method and system
CN104468074A (en) * 2013-09-18 2015-03-25 北京三星通信技术研究有限公司 Method and equipment for authentication between applications
CN104780175A (en) * 2015-04-24 2015-07-15 广东电网有限责任公司信息中心 Hierarchical classification access authorization management method based on roles
CN111970126A (en) * 2020-08-31 2020-11-20 北京书生网络技术有限公司 Key management method and device
CN112039665A (en) * 2020-08-31 2020-12-04 北京书生网络技术有限公司 Key management method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101510238A (en) * 2008-02-15 2009-08-19 北京书生国际信息技术有限公司 Document database safety access method and system
CN104468074A (en) * 2013-09-18 2015-03-25 北京三星通信技术研究有限公司 Method and equipment for authentication between applications
CN104780175A (en) * 2015-04-24 2015-07-15 广东电网有限责任公司信息中心 Hierarchical classification access authorization management method based on roles
CN111970126A (en) * 2020-08-31 2020-11-20 北京书生网络技术有限公司 Key management method and device
CN112039665A (en) * 2020-08-31 2020-12-04 北京书生网络技术有限公司 Key management method and device

Also Published As

Publication number Publication date
US20230208634A1 (en) 2023-06-29

Similar Documents

Publication Publication Date Title
US11336634B2 (en) Identity management via a centralized identity management server device
CN106537403B (en) System for accessing data from multiple devices
US11764966B2 (en) Systems and methods for single-step out-of-band authentication
JP6335280B2 (en) User and device authentication in enterprise systems
CN111147255B (en) Data security service system, method and computer readable storage medium
WO2017000829A1 (en) Method for checking security based on biological features, client and server
US7987357B2 (en) Disabling remote logins without passwords
WO2021184755A1 (en) Application access method and apparatus, and electronic device and storage medium
EP3997606A1 (en) Cryptoasset custodial system with custom logic
CA3122376A1 (en) Systems and methods for securing login access
US20230208637A1 (en) Key management method and apparatus
CN112039665A (en) Key management method and device
CA3149910A1 (en) Advanced security control implementation of proxied cryptographic keys
US20140250499A1 (en) Password based security method, systems and devices
WO2022042746A1 (en) Key management method and apparatus
CN111970126A (en) Key management method and device
KR101221728B1 (en) The certification process server and the method for graphic OTP certification
US10756899B2 (en) Access to software applications
CN114124395B (en) Key management method and device
CN108668260B (en) SIM card data self-destruction method, SIM card, device and server
TWM599939U (en) System for identity verification
Raji et al. Enhancing Public Cloud Security by Developing a Model For User Authentication and Data Integrity Checking
KR102542840B1 (en) Method and system for providing finance authentication service based on open api
CN114124422B (en) Key management method and device
EP4047871A1 (en) Advanced security control implementation of proxied cryptographic keys

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21860578

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 21.06.2023)

122 Ep: pct application non-entry in european phase

Ref document number: 21860578

Country of ref document: EP

Kind code of ref document: A1