CN113132100A - 一种基于滑窗QC-LDPC码的McEliece体制加解密方法 - Google Patents

一种基于滑窗QC-LDPC码的McEliece体制加解密方法 Download PDF

Info

Publication number
CN113132100A
CN113132100A CN202110395007.8A CN202110395007A CN113132100A CN 113132100 A CN113132100 A CN 113132100A CN 202110395007 A CN202110395007 A CN 202110395007A CN 113132100 A CN113132100 A CN 113132100A
Authority
CN
China
Prior art keywords
sliding window
message
encryption
bits
ldpc code
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.)
Granted
Application number
CN202110395007.8A
Other languages
English (en)
Other versions
CN113132100B (zh
Inventor
王明阳
史治平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
University of Electronic Science and Technology of China
Original Assignee
University of Electronic Science and Technology of China
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
Application filed by University of Electronic Science and Technology of China filed Critical University of Electronic Science and Technology of China
Priority to CN202110395007.8A priority Critical patent/CN113132100B/zh
Publication of CN113132100A publication Critical patent/CN113132100A/zh
Application granted granted Critical
Publication of CN113132100B publication Critical patent/CN113132100B/zh
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/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
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0056Systems characterized by the type of code used
    • H04L1/0061Error detection codes
    • H04L1/0063Single parity check
    • 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/002Countermeasures against attacks on cryptographic mechanisms
    • 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
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Landscapes

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

Abstract

本发明属于基于纠错编码的密码学领域,具体涉及一种基于滑窗QC‑LDPC码的McEliece体制加解密方法。在纠错编码领域,矩阵分解问题目前无法被量子计算机攻破。然而,基于QC‑LDPC码的McEliece体制在错误向量权重较高时,译码成功率和抗信息集译码攻击能力较低。在基于滑窗QC‑LDPC码的McEliece体制加解密方法中,加入了滑窗技术,以加解密效率降低为代价换取了更高的解密成功率和抗信息集译码攻击能力,一定程度上提高了算法的安全性。

Description

一种基于滑窗QC-LDPC码的McEliece体制加解密方法
技术领域
本发明属于基于纠错编码的密码学领域,具体涉及一种基于滑窗QC-LDPC码的McEliece体制加解密方法。
背景技术
当今量子计算技术发展迅猛,基于大整数分解和离散对数困难问题的密码体制将不再安全。基于纠错编码的公钥密码体制目前具有抵抗量子攻击的特性,许多学者开始研究基于纠错编码的密码学理论。在加密算法领域,学者Goppa首先提出了基于Goppa码的McEliece体制,但是Goppa的校验矩阵的尺寸太大,难以实用,后来,Baldi等学者提出了基于QC-LDPC(准循环低密度奇偶校验)码的McEliece体制,减少了公钥的存储空间,但是,这种体制采用的是BF(比特翻转)译码器,由于其概率译码特性,译码成功率较低。
发明内容
本发明的目的在于,针对上述问题,为了提高传统的基于QC-LDPC码的McEliece体制的解密成功率和体制的安全性,提出了基于滑窗QC-LDPC码的McEliece体制加解密方法。本发明的方法中,在加解密时引入了滑窗技术,相比于原始McEliece体制其译码性能有所提高,在相同译码成功率的情况下,本发明提出的改进算法能在译码成功率相同的情况下纠正更多的错误,因而在加解密成功率相同的情况下有着更高的安全性。
本发明的技术方案如下:
(1)Bob生成一对密钥。
算法使用QC-LDPC码的校验矩阵H作为密码算法的部分私钥:
Figure BDA0003018191350000011
H由
Figure BDA0003018191350000012
共n0个循环矩阵块Hn(0≤n≤n0-1)组成,其中,Hn的阶数为p,Hn的行重为dv。因此H为一个p行,p*n0列,行重为n0*dv的矩阵。假定其纠错能力为d。
公钥G'如下所示:
G'=S-1GQ-1
其中,Q为n阶准循环可逆矩阵,行重为m,S为k阶准循环可逆矩阵,G为校验矩阵H所对应的生成矩阵。
Bob的私钥是:H、Q、S
(2)Alice使用Bob的公钥进行加密。
加密过程如下所示:
xi=ui·G'+ei
其中,xi为加密后的n比特信息,ui为k比特待加密消息,ei为随机生成的0,1错误向量,其权重为t。如图1所示,Alice将明文消息分为n个k比特长的消息ui,设计一个k比特长的滑窗,第一个k比特原始消息u1直接使用xi=ui·G'+ei进行加密,然后滑窗开始滑动,每次滑动四分之三k比特,这样i的取值范围为1~[(4n-1)/3],依次对滑窗所选部分进行加密。最后将(4n-1)/3个比特加密后的信息发给Bob。由说明书附图中图1可知,除了第一个消息和最后一个消息,其余原始消息ui相当于都被分为了三个部分,其中只有b部分是只经过了一次加密的。
加密完成后,Alice直接将xi通过信道发送给Bob。
(3)Bob使用私钥进行解密过程。
A.计算xi'=xi·Q=ui·S-1·G·Q-1·Q+eiQ=ui·S-1·G+ei·Q
B.计算H(x'i)T=H(eiQ)T=si,根据si和私钥H,译码得到eiQ。(此处使用的译码算法为BF译码算法),判断并记录si是否为0。
C.计算ui·S-1·G=xi'+eiQ,得到ui·S-1
D.最后将u·S-1右乘S,得到消息ui,若si为0说明译码成功,则进行步骤E;若si不为0说明译码失败,则进行步骤F。
E.将译码得到的明文ui全部保存下来,与前面译码得到的明文消息重复的部分直接覆盖。
F.只保存明文ui的中间b部分,a和c两个部分则分别用前后两个消息与该消息重复的部分代替。
Bob在收到密文后,按上述加密算法逐个解密后,由说明书中图2所示方法进行明文的恢复。
本发明的有益效果为,本发明提出的基于滑窗QC-LDPC码的McEliece体制加解密方法具有抵抗当今量子计算机攻击的能力,其安全性基于大矩阵分解问题,量子计算难以有效破解它,能保证传输信息的保密性。并且由于引入了滑窗技术,改进算法的解密准确率更高,且在相同解密准确率的情况下,改进算法有着更高的安全级别。
附图说明
图1为本发明的基于滑窗QC-LDPC码的McEliece体制加解密方法加密过程;
图2为本发明的基于滑窗QC-LDPC码的McEliece体制加解密方法的解密过程;
图3为H为512行,1024列的矩阵,行重为6时,基于滑窗QC-LDPC码的McEliece体制加解密方法和原M体制错误向量权重和译码成功率的关系;
图4为H为512行,1024列的矩阵,行重为10时,基于滑窗QC-LDPC码的McEliece体制加解密方法和原M体制错误向量权重和译码成功率的关系。
具体实施方式
下面结合实施例和附图,详细说明本发明的技术方案。
在下文的实施例中,通过仿真得到了,在码长相同和校验矩阵H相同的条件下,基于滑窗QC-LDPC码的McEliece体制加解密方法与原M体制的解密性能对比。发现了基于滑窗的改进算法在这种条件下,解密的准确率更高。
实施例以校验矩阵H行重不同的QC-LDPC码为例。首先,仿真参数是码长n=1024,p=512,n0=2,仿真的原始信息大小为512000比特。在H的行重为6和行重为10的情况下分别得到仿真曲线如图3和图4所示。
由图3和图4的两组仿真对比图可知,
在译码成功率方面:在校验矩阵参数相同的情况下,基于QC-LDPC码的M体制和基于滑窗QC-LDPC码的McEliece体制加解密方法的译码成功率都会随着错误向量权重的增加而降低,但改进算法的译码成功率在错误向量权重相同的情况下一直高于原始算法。
在安全性方面:改进算法和原始M体制算法都可能受到信息集译码攻击。信息集译码攻击的思想是从密文中分析出明文。由于密文需要通过信道传输,因此攻击者实施信息集译码攻击是可行的。
对于这两种算法而言,加密方式都为:x=u·G'+e。其中,x是n比特向量,u是k比特向量,e是随机产生的具有固定权重t的向量。假设攻击者收集到了其中的一个密文x,他从x中任意选出k个比特组成向量xk。从理论上分析,xk满足:
xk=u·G'K+ek
其中,G'K和ek分别是根据x中选出k比特的位置随之选出的k列矩阵和k比特向量。由此可得:
u=(xk+ek)·(G'K)-1
由于x和G'都是攻击者可以得到的,因此,攻击者能否获得明文消息的关键在于ek。破译者每一次从x向量中选择k位,执行u=xk·(G'K)-1,如果破解出来的u是有意义的,则说明选择的ek恰好为全零向量,如果u没有意义,则继续选择另外一组k比特向量。攻击者破译成功的概率为:
Figure BDA0003018191350000041
由该式可得,错误向量权重越大,攻击者破译成功的概率越小。然而,随着错误向量权重t的增大,使用基于QC-LDPC码的M体制密码算法解密成功的概率也逐渐降低,本文使用的改进方法能够改善这个问题。
在加解密效率方面:由于加入的滑窗每次只滑动每个待加密消息的3/4,因此如果明文长度总共为n比特的话,经过滑窗会产生[(4n-1)/3]-n比特的冗余。所以改进算法的加解密效率比基于QC-LDPC的M体制算法低。
由上述三项性能对比可知,本发明所述的基于滑窗QC-LDPC码的McEliece体制加解密方法是以加解密效率降低为代价换取的更高的译码成功率和抗信息集译码攻击能力。

Claims (1)

1.一种基于滑窗QC-LDPC码的McEliece体制加解密方法,其特征在于,包括以下步骤:
S1、Bob生成一队密钥,包括公钥G'和私钥H、Q、S:
G'=S-1GQ-1
其中,Q为n阶准循环可逆矩阵,行重为m,S为k阶准循环可逆矩阵,G为QC-LDPC码的校验矩阵H所对应的生成矩阵,
Figure FDA0003018191340000011
H由
Figure FDA0003018191340000012
共n0个循环矩阵块Hn组成,0≤n≤n0-1,其中,Hn的阶数为p,Hn的行重为dv,即H为一个p行,p*n0列,行重为n0*dv的矩阵;
S2、Alice使用Bob的公钥进行加密,加密过程为:
xi=ui·G'+ei
其中,xi为加密后的n比特信息,ui为k比特待加密消息,ei为随机生成的0、1错误向量,其权重为t;
Alice将明文消息分为n个k比特长的消息ui,定义一个k比特长的滑窗,第一个k比特原始消息u1直接使用xi=ui·G'+ei进行加密,然后滑窗开始滑动,每次滑动四分之三k比特,从而i的取值范围为1~[(4n-1)/3],依次对滑窗所选部分进行加密,最后将(4n-1)/3个比特加密后的信息发给Bob;在对滑窗所选部分进行加密的过程中,除第一个消息和最后一个消息,其余原始消息ui被分为了三个部分,将只经过了一次加密的部分定义为b部分,其余两部分定义为a部分和c部分;
S3、Bob在收到密文后,使用私钥进行解密,进行明文的恢复;Bob使用私钥进行解密过程具体为:
a)计算xi'=xi·Q=ui·S-1·G·Q-1·Q+eiQ=ui·S-1·G+ei·Q;
b)计算H(x'i)T=H(eiQ)T=si,根据si和私钥H,译码得到eiQ,判断并记录si是否为0;
c)计算ui·S-1·G=xi'+eiQ,得到ui·S-1
d)将u·S-1右乘S,得到消息ui,若si为0说明译码成功,则进入步骤e;否则进入步骤f;
e)将译码得到的明文ui全部保存下来,与前面译码得到的明文消息重复的部分直接覆盖;
f)只保存明文ui的中间b部分,a和c这两部分则分别用前后两个消息与该消息重复的部分代替。
CN202110395007.8A 2021-04-13 2021-04-13 一种基于滑窗QC-LDPC码的McEliece体制加解密方法 Active CN113132100B (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110395007.8A CN113132100B (zh) 2021-04-13 2021-04-13 一种基于滑窗QC-LDPC码的McEliece体制加解密方法

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110395007.8A CN113132100B (zh) 2021-04-13 2021-04-13 一种基于滑窗QC-LDPC码的McEliece体制加解密方法

Publications (2)

Publication Number Publication Date
CN113132100A true CN113132100A (zh) 2021-07-16
CN113132100B CN113132100B (zh) 2022-09-09

Family

ID=76776043

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110395007.8A Active CN113132100B (zh) 2021-04-13 2021-04-13 一种基于滑窗QC-LDPC码的McEliece体制加解密方法

Country Status (1)

Country Link
CN (1) CN113132100B (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115242475A (zh) * 2022-07-14 2022-10-25 南京化科天创科技有限公司 一种大数据安全传输方法及系统

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130117575A1 (en) * 2011-11-04 2013-05-09 Fujitsu Limited Encryption apparatus, encryption method, decryption apparatus, decryption method and system
CN103457718A (zh) * 2013-05-28 2013-12-18 香港应用科技研究院有限公司 使用可变长度分段和固定分组加密的部分密文更新
US20150052358A1 (en) * 2013-08-16 2015-02-19 Netflix, Inc. Key generation and broadcasting
CN104468125A (zh) * 2014-12-24 2015-03-25 江西倍康信息技术有限公司 基于国密算法的移动互联网信息通信加密方法
WO2019094917A1 (en) * 2017-11-13 2019-05-16 Alibaba Group Holding Limited Device and method for increasing the security of a database
CN110299992A (zh) * 2019-05-27 2019-10-01 广东技术师范大学 基于滑动窗口的多变量二次方程的乱序加密方法及装置
CN110784230A (zh) * 2018-07-31 2020-02-11 西安电子科技大学 一种基于bp-led的多元sc-ldpc码滑窗译码方法
CN111756727A (zh) * 2020-06-23 2020-10-09 电子科技大学 基于QC-LDPC码的McEliece体制加解密方法

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130117575A1 (en) * 2011-11-04 2013-05-09 Fujitsu Limited Encryption apparatus, encryption method, decryption apparatus, decryption method and system
CN103457718A (zh) * 2013-05-28 2013-12-18 香港应用科技研究院有限公司 使用可变长度分段和固定分组加密的部分密文更新
US20150052358A1 (en) * 2013-08-16 2015-02-19 Netflix, Inc. Key generation and broadcasting
CN104468125A (zh) * 2014-12-24 2015-03-25 江西倍康信息技术有限公司 基于国密算法的移动互联网信息通信加密方法
WO2019094917A1 (en) * 2017-11-13 2019-05-16 Alibaba Group Holding Limited Device and method for increasing the security of a database
CN110019994A (zh) * 2017-11-13 2019-07-16 阿里巴巴集团控股有限公司 数据加密、解密及查询方法、数据加密解密及查询装置
CN110784230A (zh) * 2018-07-31 2020-02-11 西安电子科技大学 一种基于bp-led的多元sc-ldpc码滑窗译码方法
CN110299992A (zh) * 2019-05-27 2019-10-01 广东技术师范大学 基于滑动窗口的多变量二次方程的乱序加密方法及装置
CN111756727A (zh) * 2020-06-23 2020-10-09 电子科技大学 基于QC-LDPC码的McEliece体制加解密方法

Non-Patent Citations (5)

* Cited by examiner, † Cited by third party
Title
KUN ZHANG ET AL.: ""High Efficiency Continuous-Variable Quantum Key Distribution Based on Quasi-Cyclic LDPC Codes"", 《2020 5TH INTERNATIONAL CONFERENCE ON COMMUNICATION,IMAGE AND SIGNAL PROCESSING(CCISP)》 *
SEYED HESAM ODIN HASHEMI ET AL.: ""A Modified McEliece Public-Key Cryptosystem Based On Irregular Codes Of QC-LDPC And QC-MDPC"", 《27TH IRANIAN CONFERENCE ON ELECTRICAL ENGINEERING (ICEE2019)》 *
张娅妹 等: ""窗口可变的空间耦合LDPC码滑窗译码算法"", 《西安电子科技大学学报》 *
赖凤麟 等: ""一种OFDM系统信道密钥生成方法"", 《电讯技术》 *
陶忠君 等: ""基于QC-LDPC码的M公钥密码体制及其性能研究"", 《通信技术》 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115242475A (zh) * 2022-07-14 2022-10-25 南京化科天创科技有限公司 一种大数据安全传输方法及系统

Also Published As

Publication number Publication date
CN113132100B (zh) 2022-09-09

Similar Documents

Publication Publication Date Title
EP3583739B1 (en) Key exchange devices and method
EP3402118A1 (en) Key agreement devices and method
US20100281336A1 (en) Method and entity for probabilistic symmetrical encryption
CN108712256B (zh) 一种基于椭圆曲线子域子码的加密解密算法
CN110138752B (zh) 一种基于格的公钥加密方法
Hooshmand et al. Reducing the key length of McEliece cryptosystem using polar codes
CN110138549B (zh) 一种基于格的数字签名方法
Agrawal et al. Elliptic curve cryptography with hill cipher generation for secure text cryptosystem
CN107786327B (zh) 一种基于ldpc码的安全可靠传输方法
Vambol et al. McEliece and Niederreiter Cryptosystems Analysis in the Context of Post-Quantum Network Security
CN113132100B (zh) 一种基于滑窗QC-LDPC码的McEliece体制加解密方法
Mohan et al. Improved ElGamal cryptosystem for secure data transfer in IoT networks
CN117527223A (zh) 一种基于格的抗量子密码的分布式解密方法及系统
Liu et al. A secure and efficient code-based signature scheme
EP4170959B1 (en) A method of constructing a semi-public key system in qap-based homomorphic encryption
Bhatia et al. Post-Quantum Cryptography
EP4186204A1 (en) Methods and systems for the implementation of ntru-like cryptosystem relying on optical fourier transforms
Sahu et al. A code-based digital signature scheme using modified quasi-cyclic low-density parity-check codes (QC-LDPC)
Pham et al. Security of the Cryptosystem GPT Based on Rank Codes and Term-rank Codes
Isakov et al. McEliece cryptosystem based on quaternary hamming codes
CN111314051A (zh) 一种加解密方法和装置
EP4170964B1 (en) A method of constructing a public-key system in qap-based homomorphic encryption
Xu et al. Attacking the Niederreiter-type cryptosystem based on rank metric
US11502818B2 (en) System to secure encoding and mapping on elliptic curve cryptography (ECC)
Yang et al. Quantum McEliece public-key encryption scheme

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