CN111930881B - 基于国密算法的连接关键词认证可搜索加密方法 - Google Patents
基于国密算法的连接关键词认证可搜索加密方法 Download PDFInfo
- Publication number
- CN111930881B CN111930881B CN202011075188.8A CN202011075188A CN111930881B CN 111930881 B CN111930881 B CN 111930881B CN 202011075188 A CN202011075188 A CN 202011075188A CN 111930881 B CN111930881 B CN 111930881B
- Authority
- CN
- China
- Prior art keywords
- keyword
- key
- data
- algorithm
- search
- Prior art date
- Legal status (The legal status 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 status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/30—Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
- G06F16/31—Indexing; Data structures therefor; Storage structures
- G06F16/316—Indexing structures
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/953—Querying, e.g. by the use of web search engines
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/602—Providing cryptographic facilities or services
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/04—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
- H04L63/0428—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
- H04L63/0435—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload wherein the sending and receiving network entities apply symmetric encryption, i.e. same key used for encryption and decryption
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/08—Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
- H04L9/0816—Key establishment, i.e. cryptographic processes or cryptographic protocols whereby a shared secret becomes available to two or more parties, for subsequent use
- H04L9/0819—Key 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)
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/08—Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
- H04L9/0816—Key establishment, i.e. cryptographic processes or cryptographic protocols whereby a shared secret becomes available to two or more parties, for subsequent use
- H04L9/0838—Key agreement, i.e. key establishment technique in which a shared key is derived by parties as a function of information contributed by, or associated with, each of these
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/08—Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
- H04L9/0861—Generation of secret information including derivation or calculation of cryptographic keys or passwords
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/30—Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy
- H04L9/3066—Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy involving algebraic varieties, e.g. elliptic or hyper-elliptic curves
- H04L9/3073—Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy involving algebraic varieties, e.g. elliptic or hyper-elliptic curves involving pairings, e.g. identity based encryption [IBE], bilinear mappings or bilinear pairings, e.g. Weil or Tate pairing
Abstract
本发明涉及一种基于国密算法的连接关键词认证可搜索加密方法,包括以下步骤:(1)初始化算法,(2)生成公私钥对,(3)密钥协商产生加密密钥,(4)加密文档,(5)生成安全索引,(6)安全列表发送给云服务器,(7)生成搜索令牌,(8)搜索结果,(9)比较结果,(10)循环,(11)搜索结果反馈,(12)得到明文结果。本发明支持连接关键词搜索,确保了安全索引只能由数据发送方生成,抵抗了云服务器的关键词猜测攻击;确保了令牌只匹配数据发送方发送的安全索引,获得数据发送方的密文,且方法在生成关键词索引没有涉及到计算开销较大的双线性对运算,生成搜索令牌时只需要一次双线性对运算。
Description
技术领域
本发明涉及一种基于国密算法的连接关键词认证可搜索加密方法,属于国产密码关键词加密方法技术领域。
背景技术
2020年以来,新型冠状病毒肺炎使得越来越多企业的工作方式向远程工作转移。远程工作要求企业员工之间可以共享文件并协作编辑文档,这一功能可以由支持在线文档编辑的云存储服务提供商(例如Dropbox,腾讯云,Google云等等)实现。有了云存储,开发者和企业就可以通过互联网享受全球高度持久的存储服务和灵活的访问机制。任一用户都可以将自己的工作文档上传到企业的公共云端,而其他团队成员就可以访问云盘查看并编辑文档。虽然云存储为疫情下的远程办公提供了解决办法,但是上传到云端共享的文档往往包含一些隐私信息,一旦发生信息的泄漏,公司的业务往往会造成损失,因此人们对云存储的安全问题的担忧与日俱增。
为了减少潜在的数据安全泄漏,加密数据后再上传至云端服务器是一个直接的解决方法。同时,为了使得加密数据在云端可被直接检索,公钥可搜索加密方案支持数据发送方和接收方为不同的用户的想法被提出。为了满足连接关键词搜索的需求,支持连接关键词搜索的公钥可搜索加密方案也由此诞生。但是公钥可搜索加密方案由于其生成安全索引时无需私钥的特点,使得关键词猜测攻击对系统安全造成很大的影响。另外,现有的能够抵抗关键词猜测攻击的方案很少能够高效地支持连接关键词搜索,往往在关键词索引生成阶段引入了大量的双线性对运算,大大降低了搜索效率。
近年来,国家密码科技发展迅速,密码管理部门公开发布了具有自主知识产权和高安全强度的多项密码相关标准,基本建成了密码基础设施并提供服务,国产密码产品在众多领域中得到了广泛应用,信息系统领域使用国产密码的条件已基本具备。因此,在设计密码方案时应用国密算法,对我国网络与信息安全体系建设具有重要战略意义。
发明内容
为了解决上述技术问题,本发明提供一种基于国密算法的支持连接关键词搜索的认证可搜索加密方法,其具体技术方案如下:
一种基于国密算法的连接关键词认证可搜索加密方法,包括以下步骤:
步骤一:初始化算法:授权中心输入安全参数,运行初始化算法,输出公共参数并预定义关键词域,将该公共参数及关键词域发送给云服务器、数据发送方和数据接收方;
步骤二:生成公私钥对:所述授权中心通过密钥生成算法生成公钥和私钥的公-私钥对,并分发公私钥对给数据发送方与数据接收方;
步骤五:生成安全索引:数据发送方根据步骤一预定义的关键词域对步骤四中文
档进行关键词集提取,得到关键词集;利用步骤一中接收的公共参数和步骤二中数据发送
方接收的私钥以及数据接收方的公钥,运行关键词集索引生成算法,加密关键词集,生成关
键词集索引,即安全索引;
步骤七:生成搜索令牌:数据接收方用步骤一中接收的公共参数和步骤二中生成的数据发送方的公钥及数据接收方的私钥,对所需查询的关键词集运行搜索令牌生成算法进行加密生成搜索令牌,同时记录该关键词集中每个关键词在步骤一中的关键词域中的位置,记作位置集合,并将该搜索令牌及所述位置集合一起发送给云服务器;
步骤八:搜索结果:当云服务器收到步骤七中来自数据接收方的搜索令牌及位置集合后,遍历步骤六中接收的安全列表,先根据位置集合按照顺序将对应位置的安全索引挑选出来,然后以挑选出来的安全索引与搜索令牌为输入执行测试算法,比较用户搜索令牌中包含的关键词集与云服务器中的安全索引对应的关键词集是否一致,从而得到测试结果;
步骤十:依次循环步骤八,直到最后的测试结果若仍不一致,则测试失败终止流程;
步骤十一:搜索结果反馈:云服务器将步骤八、步骤九和步骤十中得到的搜索结果集R返回给数据接收方;
进一步的,步骤一具体过程为:
进一步的,步骤二中密钥生成算法随机选择数据发送方的私钥,数据
发送方的公钥计算公式为;并随机选择数据接收方的私钥,接收方的
公钥计算公式为;私钥、分别通过安全信道发送到数据发送方和数据接
收方,将公钥、公开。
进一步的,步骤八中具体过程为:
步骤8.4:以中间量和接收方公钥为输入,计算索引中间量
本发明的有益效果是:数据发送方在生成安全索引时采取了认证加密的技术,即使用了自己的私钥以及数据接收方的公钥,确保了安全索引只能由数据发送方生成,从而抵抗了来自内部敌手,即云服务器的关键词猜测攻击;数据接收方在生成搜索令牌时使用了自己的私钥以及数据发送方的公钥,确保了令牌只匹配数据发送方发送的安全索引,从而获得数据发送方的密文;且方法在生成关键词索引没有涉及到计算开销较大的双线性对运算,生成搜索令牌时只需要一次双线性对运算;根据预定义的关键词域,数据发送方在生成安全索引时为每个文档提取具有关键词集,同时数据接收方在生成搜索令牌时发送想要搜索的关键词集中每个关键词在关键词域中的位置集合,使得本方法支持连接关键词搜索。
附图说明
图1是本发明的方法流程图,
图2是本发明的方法原理图。
具体实施方式
现在结合附图对本发明作进一步详细的说明。
为了简明表示本发明中的文档-关键词集-安全索引的关系,现将三者关系列如下表1所示。
表1
本发明的具体步骤为:
步骤二:生成公私钥对:所述授权中心通过密钥生成算法随机选择数据发送方的
私钥,数据发送方的公钥计算公式为;并随机选择数据接收方的私
钥,接收方的公钥计算公式为;私钥、分别通过安全信
道发送到数据发送方和数据接收方,将公钥、公开。
步骤五:生成安全索引:数据发送方根据步骤一预定义的关键词域对步骤四中文
档进行关键词集提取,得到关键词集;利用步骤一中接收的公共参数和步骤二
中数据发送方接收的私钥以及数据接收方的公钥,运行关键词集索引生成算法,随机选择,安全索引公式为,
其中,为关键词索引的最后一部分。
步骤七:生成搜索令牌:数据接收方用步骤一中接收的公共参数和步骤二中生成
的数据发送方的公钥及数据接收方的私钥,对所需查询的关键词集为运行搜索
令牌生成算法进行加密生成搜索令牌,计算搜索令牌为,同时记
录该关键词集中每个关键词在步骤一中的关键词域中的位置,记作位置集合为,
其中t为搜索的关键词数量。并将该搜索令牌及所述位置集合一起发送给云服务器。
步骤八:搜索结果:当云服务器收到步骤七中来自数据接收方的搜索令牌及位置
集合后,遍历步骤六中接收的安全列表,先根据位置集合按照顺序将对应位置的安全索引
挑选出来,挑选中对应的安全索引集合,然后以挑选出来的安全索引与搜索令牌为输入执行
测试算法,计算中间量;以公共参数中的g和关键词数
量t为输入,计算关键词数中间量;以搜索令牌和步骤8.2
的关键词数中间量为输入,计算搜索令牌中间量;
步骤十:依次循环步骤八,直到最后的测试结果若仍不一致,则测试失败终止流程;
步骤十一:搜索结果反馈:云服务器将步骤八、步骤九和步骤十中得到的搜索结果集R返回给数据接收方;
步骤十二:得到明文数据:数据接收方以接收到的所述搜索结果集R的密文和步骤三中生成的加密密钥k为输入,运行SM4解密算法进行解密,得到最终的明文结果集。
以上述依据本发明的理想实施例为启示,通过上述的说明内容,相关工作人员完全可以在不偏离本项发明技术思想的范围内,进行多样的变更以及修改。本项发明的技术性范围并不局限于说明书上的内容,必须要根据权利要求范围来确定其技术性范围。
Claims (7)
1.一种基于国密算法的连接关键词认证可搜索加密方法,其特征在于:包括以下步骤:
步骤一:初始化算法:授权中心输入安全参数,运行初始化算法,输出公共参数并预定义关键词域,将该公共参数及关键词域发送给云服务器、数据发送方和数据接收方;
步骤二:生成公私钥对:所述授权中心通过密钥生成算法生成公钥和私钥的公-私钥对,并分发公私钥对给数据发送方与数据接收方;
步骤五:生成安全索引:数据发送方根据步骤一预定义的关键词域对步骤四中文档进
行关键词集提取,得到关键词集;利用步骤一中接收的公共参数和步骤二中数据发送方接
收的私钥以及数据接收方的公钥,运行关键词集索引生成算法,加密关键词集,生成关键词
集索引,即安全索引;
步骤七:生成搜索令牌:数据接收方用步骤一中接收的公共参数和步骤二中生成的数据发送方的公钥及数据接收方的私钥,对所需查询的关键词集运行搜索令牌生成算法进行加密生成搜索令牌,同时记录该关键词集中每个关键词在步骤一中的关键词域中的位置,记作位置集合,并将该搜索令牌及所述位置集合一起发送给云服务器;
步骤八:搜索结果:当云服务器收到步骤七中来自数据接收方的搜索令牌及位置集合后,遍历步骤六中接收的安全列表,先根据位置集合按照顺序将对应位置的安全索引挑选出来,然后以挑选出来的安全索引与搜索令牌为输入执行测试算法,比较用户搜索令牌中包含的关键词集与云服务器中的安全索引对应的关键词集是否一致,从而得到测试结果;
步骤十:依次循环步骤八,直到最后的测试结果若仍不一致,则测试失败终止流程;
步骤十一:搜索结果反馈:云服务器将步骤八、步骤九和步骤十中得到的搜索结果集R返回给数据接收方;
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011075188.8A CN111930881B (zh) | 2020-10-10 | 2020-10-10 | 基于国密算法的连接关键词认证可搜索加密方法 |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011075188.8A CN111930881B (zh) | 2020-10-10 | 2020-10-10 | 基于国密算法的连接关键词认证可搜索加密方法 |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111930881A CN111930881A (zh) | 2020-11-13 |
CN111930881B true CN111930881B (zh) | 2021-01-26 |
Family
ID=73334977
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011075188.8A Active CN111930881B (zh) | 2020-10-10 | 2020-10-10 | 基于国密算法的连接关键词认证可搜索加密方法 |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111930881B (zh) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113343000A (zh) * | 2021-05-17 | 2021-09-03 | 杭州未名信科科技有限公司 | 基于国密算法的图像加密方法、装置、电子设备及介质 |
CN113810416B (zh) * | 2021-09-17 | 2023-07-04 | 福建师范大学 | 基于sm2公钥加密算法的公钥可搜索加密方法 |
CN114142996B (zh) * | 2021-11-18 | 2023-09-05 | 贵州大学 | 一种基于sm9密码算法的可搜索加密方法 |
CN114666050B (zh) * | 2022-03-30 | 2024-03-12 | 浙江科技学院 | 一种抵抗在线和离线关键字猜测攻击的数据传输方法 |
CN115333811B (zh) * | 2022-08-01 | 2024-03-12 | 华南农业大学 | 一种多关键词搜索功能的安全无信道公钥认证可搜索加密方法及相关装置 |
CN117375801B (zh) * | 2023-12-08 | 2024-03-26 | 贵州大学 | 基于sm9的指定服务器可搜索加密方法 |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
FR3059445A1 (fr) * | 2016-11-28 | 2018-06-01 | Orange | Procede de chiffrement cherchable |
CN111106936B (zh) * | 2019-11-27 | 2023-04-21 | 国家电网有限公司 | 一种基于sm9的属性加密方法与系统 |
CN111625856B (zh) * | 2020-02-27 | 2022-10-25 | 南京理工大学 | 基于国密算法的溯源和前向安全的可搜索密文病历系统 |
-
2020
- 2020-10-10 CN CN202011075188.8A patent/CN111930881B/zh active Active
Also Published As
Publication number | Publication date |
---|---|
CN111930881A (zh) | 2020-11-13 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111930881B (zh) | 基于国密算法的连接关键词认证可搜索加密方法 | |
Wang et al. | A blockchain-based framework for data sharing with fine-grained access control in decentralized storage systems | |
Li et al. | Full verifiability for outsourced decryption in attribute based encryption | |
Chen et al. | BL-MLE: Block-level message-locked encryption for secure large file deduplication | |
TWI725124B (zh) | 決定用於資訊的安全交換的共同私密,及階層化的決定性加密金鑰 | |
JP6180177B2 (ja) | プライバシーを保護することができる暗号化データの問い合わせ方法及びシステム | |
Yang et al. | Achieving efficient and privacy-preserving cross-domain big data deduplication in cloud | |
CN108632032A (zh) | 无密钥托管的安全多关键词排序检索系统 | |
Wang et al. | Verifiable and multi-keyword searchable attribute-based encryption scheme for cloud storage | |
Li et al. | Privacy-preserving data utilization in hybrid clouds | |
CN109361644B (zh) | 一种支持快速搜索和解密的模糊属性基加密方法 | |
Sun et al. | Research on logistics information blockchain data query algorithm based on searchable encryption | |
CN114244498A (zh) | 一种具有前向安全的动态可搜索公钥加密方法 | |
Tian et al. | Privacy preserving query processing on secret share based data storage | |
Li et al. | Efficient data retrieval over encrypted attribute-value type databases in cloud-assisted ehealth systems | |
Falk et al. | Durasift: A robust, decentralized, encrypted database supporting private searches with complex policy controls | |
CN115694974A (zh) | 一种基于协同可搜索的密文数据共享方法及系统 | |
Yang et al. | Keyword searchable encryption scheme based on blockchain in cloud environment | |
Hong et al. | Constructing conditional PKEET with verification mechanism for data privacy protection in intelligent systems | |
Zhang et al. | Multi-user and keyword-based searchable encryption scheme | |
Wang et al. | An effective verifiable symmetric searchable encryption scheme in cloud computing | |
Sun et al. | Research of data security model in cloud computing platform for SMEs | |
Yao et al. | Online/offline attribute-based boolean keyword search for internet of things | |
Hou et al. | Public-key searchable encryption from lattices | |
Bhavya et al. | EFUMS: Efficient File Upload and Mutli-Keyword Search over Encrypted Cloud Data |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |