CN111835517A - 一种双域椭圆曲线点乘硬件加速器 - Google Patents

一种双域椭圆曲线点乘硬件加速器 Download PDF

Info

Publication number
CN111835517A
CN111835517A CN202010605159.1A CN202010605159A CN111835517A CN 111835517 A CN111835517 A CN 111835517A CN 202010605159 A CN202010605159 A CN 202010605159A CN 111835517 A CN111835517 A CN 111835517A
Authority
CN
China
Prior art keywords
domain
modular
point
hardware accelerator
multiplication
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
CN202010605159.1A
Other languages
English (en)
Other versions
CN111835517B (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.)
Yizhao Micro Electronics Hangzhou Co Ltd
Original Assignee
Yizhao Micro Electronics Hangzhou Co Ltd
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 Yizhao Micro Electronics Hangzhou Co Ltd filed Critical Yizhao Micro Electronics Hangzhou Co Ltd
Priority to CN202010605159.1A priority Critical patent/CN111835517B/zh
Publication of CN111835517A publication Critical patent/CN111835517A/zh
Application granted granted Critical
Publication of CN111835517B publication Critical patent/CN111835517B/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/30Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy
    • H04L9/3066Public 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
    • 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/30Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy
    • H04L9/3006Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy underlying computational problems or public-key parameters
    • H04L9/302Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy underlying computational problems or public-key parameters involving the integer factorization problem, e.g. RSA or quadratic sieve [QS] schemes
    • 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/12Details relating to cryptographic hardware or logic circuitry
    • 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/12Details relating to cryptographic hardware or logic circuitry
    • H04L2209/122Hardware reduction or efficient architectures

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computing Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Algebra (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Mathematical Physics (AREA)
  • Pure & Applied Mathematics (AREA)
  • Advance Control (AREA)
  • Complex Calculations (AREA)

Abstract

一种双域椭圆曲线点乘硬件加速器,该硬件加速器分为模运算层和点运算层,其中该模运算层包括素数域和二进制域模约减、模乘、模逆模块;点运算层包括素数域NAF点乘运算模块,倍点和点加以及二进制域点乘模块。其中,所述硬件加速器是作为从设备挂载在设备总线上并且连接到处理器,处理器通过配置该硬件加速器中的功能寄存器来实现不同的加速运算模式。

Description

一种双域椭圆曲线点乘硬件加速器
[技术领域]
本发明涉及安全芯片中椭圆曲线密码点乘的超大规模集成电路(VLSI)的实现方法。
[背景技术]
公钥密码系统相对于对称密码系统来说因其较高的安全性被广泛用于数字签名、认证、密钥分发等高安全性应用场景中。在安全芯片领域,广泛使用的公钥密码体制是RSA加密算法,由硬件电路实现大素数模乘、模幂和模逆运算。现有技术的安全芯片实现方案普遍将素数域椭圆曲线密码(ECC)的底层大素数模运算和RSA电路复用以节省电路面积。
现有方案的缺陷是为了和RSA复用一套电路,只实现了素数域椭圆曲线密码方案,并没有实现二进制域椭圆曲线密码方案。为了节省面积,椭圆曲线密码倍点、点加和点乘运算是通过软件调用底层模运算加速器实现,导致ECC密码体制的运算速度缓慢。
[发明内容]
为克服上述现有方案的不足,本发明提供一种同时支持素数域和二进制域椭圆曲线点乘的硬件加速器设计。实现上述目的所采用的解决方案是:
一种双域椭圆曲线点乘硬件加速器,该硬件加速器分为模运算层和点运算层,其中该模运算层包括素数域和二进制域模约减、模乘、模逆模块;点运算层包括素数域NAF点乘运算模块,倍点和点加以及二进制域点乘模块。
其中,所述硬件加速器是作为从设备挂载在设备总线上并且连接到处理器,处理器通过配置该硬件加速器中的功能寄存器来实现不同的加速运算模式。
在一个改进中,二进制域模运算复用大部分的素数域模运算逻辑资源;采用基32蒙哥马利模乘;素数域NAF采用基2窗,对存储空间要求降到最低;素数域倍点在jacobian投影坐标下进行运算,素数域点加在jacobian投影和仿射混合坐标下进行运算;二进制域点乘在LD投影坐标下进行运算。
与现有技术相比,本发明有以下显著效果:采用基32蒙哥马利模乘相比基64模乘灵活度更高,能适应更多的椭圆曲线;通过硬件定制,椭圆曲线密码系统核心运算点乘的效率得到提升;复用大部分电路资源,实现二进制域和素数域椭圆曲线点乘。
[附图说明]
图1是本发明双域椭圆曲线点乘加速器结构的功能原理框图;
图2是本发明双域椭圆曲线点乘加速器的实现结构框图;
图3是宽度为2的规则窗口NAF素数域点乘状态机的原理实现框图。
[具体实施方式]
下面结合附图对本发明的实施步骤做详细说明。椭圆曲线点乘加速器结构图如附图1到3所示,模运算包括模约减,模乘,模逆三种基本的双域模运算,素数域点运算层包括倍点和点加,通过状态机调用不同的模运算完成,素数域点乘通过调用倍点和点加的状态机完成,二进制域点乘通过状态机调用不同的模运算完成。
其中,所有的点运算和模运算都由硬件实现以提高ECC运算速度。
在一个例子中,本发明蒙哥马利模乘采用基32方式,同时为了支持最高二进制域521bit椭圆曲线,在实现上采用了12块32x32 RAM来暂存曲线参数,预计算点以及所有中间运算结果。素数域点乘采用NAF基2窗,这样只需要预计算-3P,3P,-P和P四个椭圆曲线点的值,这样能在满足安全性的前提下预存储点最少,最大限度的减少存储资源。
素域倍点采用jacobian射影坐标系,为了灵活调度内部存储空间,需要将基点的仿射X坐标值存入memory al中,将基点的仿射Y坐标值存入memory bl中,参数a存入memoryal起始地址0x18的缓存空间中,标准投影Z坐标初始值为1,存入memory al起始地址0x10缓存空间中;运算完成的结果仿射X坐标存在memory al中,仿射Y坐标存在memory bl中。
作为一种改进,素域点加运算采用混合坐标系,为了灵活调度内部存储空间,需要将投影X坐标值存入memory al中,将投影Y坐标值存入memory bl中,投影Z坐标存入memoryal起始地址0x10缓存空间中,将仿射X坐标值存入memory x中,将基点的仿射Y坐标值存入memory y中;运算完成的结果仿射X坐标存在memory al中,仿射Y坐标存在memory bl中。
素域点乘采用宽度为2的规则窗口NAF表示法,大数K存入memory bh中,预计算的点1P X坐标存入memory x起始地址0x10缓存空间中,预计算的点3P X坐标存入memory x起始地址0x18缓存空间中,预计算的点1P Y坐标存入memory y起始地址0x10缓存空间中,预计算的点3P Y坐标存入memory y起始地址0x18缓存空间中,预计算的点-1P X坐标存入memory v起始地址0x10缓存空间中,预计算的点-3P X坐标存入memory v起始地址0x18缓存空间中;运算完成的结果仿射X坐标存在memory al中,仿射Y坐标存在memory bl中。
为了方便求逆之后恢复模数P方便,将模数P同时存入memory pl和ph中。标量大数K预先存入memory bh起始地址0x10缓存空间中,参数b预先存入memory v中。
二进制域点乘采用标准射影坐标下mentgomery点乘算法,标量大数K预先存入memory bh起始地址0x10缓存空间中,参数b预先存入memory v中;射坐标系基点坐标x预先存入memory x起始地址0x10缓存空间中,标x预先存入memory y起始地址0x10缓存空间中;运算完成的结果仿射X坐标存在memory al中,仿射Y坐标存在memory bl中。
在本发明实施例中,蒙哥马利模乘采用基32方式实现双域运算,可以更灵活的实现不同的曲线。素数域点乘采用宽度为2的规则窗口NAF表示法,减少预计算数据量。另外,本地多寄存器缓存方式用于提高速度减少功耗。模运算层采用双域实现,可以同时满足双域椭圆曲线密码系统要求。

Claims (2)

1.一种双域椭圆曲线点乘硬件加速器,其特征是该硬件加速器分为模运算层和点运算层,其中该模运算层包括素数域和二进制域模约减、模乘、模逆模块;点运算层包括素数域NAF点乘运算模块,倍点和点加以及二进制域点乘模块,其中,所述硬件加速器是作为从设备挂载在设备总线上并且连接到处理器,处理器通过配置该硬件加速器中的功能寄存器来实现不同的加速运算模式。
2.根据权利要求1所述的一种双域椭圆曲线点乘硬件加速器,其特征是,二进制域模运算复用大部分的素数域模运算逻辑资源;采用基32蒙哥马利模乘;素数域NAF采用基2窗,对存储空间要求降到最低;素数域倍点在jacobian投影坐标下进行运算,素数域点加在jacobian投影和仿射混合坐标下进行运算;二进制域点乘在LD投影坐标下进行运算。
CN202010605159.1A 2020-06-29 2020-06-29 一种双域椭圆曲线点乘硬件加速器 Active CN111835517B (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010605159.1A CN111835517B (zh) 2020-06-29 2020-06-29 一种双域椭圆曲线点乘硬件加速器

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010605159.1A CN111835517B (zh) 2020-06-29 2020-06-29 一种双域椭圆曲线点乘硬件加速器

Publications (2)

Publication Number Publication Date
CN111835517A true CN111835517A (zh) 2020-10-27
CN111835517B CN111835517B (zh) 2023-12-22

Family

ID=72898317

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010605159.1A Active CN111835517B (zh) 2020-06-29 2020-06-29 一种双域椭圆曲线点乘硬件加速器

Country Status (1)

Country Link
CN (1) CN111835517B (zh)

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030206629A1 (en) * 2002-05-01 2003-11-06 Sun Microsystems, Inc. Hardware accelerator for elliptic curve cryptography
CN1831754A (zh) * 2005-11-04 2006-09-13 北京浦奥得数码技术有限公司 一种椭圆曲线密码系统及实现方法
US7240204B1 (en) * 2000-03-31 2007-07-03 State Of Oregon Acting By And Through The State Board Of Higher Education On Behalf Of Oregon State University Scalable and unified multiplication methods and apparatus
US20090319804A1 (en) * 2007-07-05 2009-12-24 Broadcom Corporation Scalable and Extensible Architecture for Asymmetrical Cryptographic Acceleration
CN101826142A (zh) * 2010-04-19 2010-09-08 中国人民解放军信息工程大学 一种可重构椭圆曲线密码处理器
DE102010043993A1 (de) * 2010-11-16 2012-05-16 Ihp Gmbh - Innovations For High Performance Microelectronics / Leibniz-Institut Für Innovative Mikroelektronik Unifizierter Multiplizierer für die Galois-Körper GF(2n) und GF(p), sowie Kryptographie-Verfahren und Kryptographie-Vorrichtung
CN103078732A (zh) * 2013-01-08 2013-05-01 武汉大学 一种素域椭圆曲线加密的点乘加速电路
CN103793199A (zh) * 2014-01-24 2014-05-14 天津大学 一种支持双域的快速rsa密码协处理器
CN104184578A (zh) * 2014-07-30 2014-12-03 山东大学 一种基于fpga的椭圆曲线标量乘法加速电路及其算法
CN104579656A (zh) * 2014-12-31 2015-04-29 北京时代民芯科技有限公司 一种椭圆曲线公钥密码sm2算法的硬件加速协处理器
CN105790939A (zh) * 2016-03-01 2016-07-20 全球能源互联网研究院 一种vlsi实现加速器的素数域椭圆曲线密码系统
CN106549769A (zh) * 2016-12-08 2017-03-29 广东工业大学 一种素域Fp下SM2椭圆曲线签名系统
CN107463354A (zh) * 2017-07-12 2017-12-12 东南大学 一种面向ECC的双域并行度可变的Montgomery模乘电路

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7240204B1 (en) * 2000-03-31 2007-07-03 State Of Oregon Acting By And Through The State Board Of Higher Education On Behalf Of Oregon State University Scalable and unified multiplication methods and apparatus
US20030206629A1 (en) * 2002-05-01 2003-11-06 Sun Microsystems, Inc. Hardware accelerator for elliptic curve cryptography
US20030212729A1 (en) * 2002-05-01 2003-11-13 Sun Microsystems, Inc. Modular multiplier
CN1831754A (zh) * 2005-11-04 2006-09-13 北京浦奥得数码技术有限公司 一种椭圆曲线密码系统及实现方法
US20090319804A1 (en) * 2007-07-05 2009-12-24 Broadcom Corporation Scalable and Extensible Architecture for Asymmetrical Cryptographic Acceleration
CN101826142A (zh) * 2010-04-19 2010-09-08 中国人民解放军信息工程大学 一种可重构椭圆曲线密码处理器
DE102010043993A1 (de) * 2010-11-16 2012-05-16 Ihp Gmbh - Innovations For High Performance Microelectronics / Leibniz-Institut Für Innovative Mikroelektronik Unifizierter Multiplizierer für die Galois-Körper GF(2n) und GF(p), sowie Kryptographie-Verfahren und Kryptographie-Vorrichtung
CN103078732A (zh) * 2013-01-08 2013-05-01 武汉大学 一种素域椭圆曲线加密的点乘加速电路
CN103793199A (zh) * 2014-01-24 2014-05-14 天津大学 一种支持双域的快速rsa密码协处理器
CN104184578A (zh) * 2014-07-30 2014-12-03 山东大学 一种基于fpga的椭圆曲线标量乘法加速电路及其算法
CN104579656A (zh) * 2014-12-31 2015-04-29 北京时代民芯科技有限公司 一种椭圆曲线公钥密码sm2算法的硬件加速协处理器
CN105790939A (zh) * 2016-03-01 2016-07-20 全球能源互联网研究院 一种vlsi实现加速器的素数域椭圆曲线密码系统
CN106549769A (zh) * 2016-12-08 2017-03-29 广东工业大学 一种素域Fp下SM2椭圆曲线签名系统
CN107463354A (zh) * 2017-07-12 2017-12-12 东南大学 一种面向ECC的双域并行度可变的Montgomery模乘电路

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
杨先文;杨洋;李峥;: "GF(2~m)域上ECC通用加速器设计与实现", 计算机工程与设计 *
范云海: "椭圆曲线密码ECC二进制域的算法改进与硬件实现", 上海交通大学硕士学位论文 *
范云海;: "集成加密方案ECIES的设计与验证", 信息技术 *

Also Published As

Publication number Publication date
CN111835517B (zh) 2023-12-22

Similar Documents

Publication Publication Date Title
CN101170406B (zh) 双核公钥密码算法运算协处理器的一种实现方法
Knežević et al. Low-latency ECDSA signature verification—A road toward safer traffic
CN101547089B (zh) 集成电路中素数域椭圆曲线密码算法的实现方法
CN112988237B (zh) 一种Paillier解密系统、芯片和方法
US11032074B2 (en) Cryptosystem and method using isogeny-based computations to reduce a memory footprint
JP2002297033A (ja) 情報処理装置の演算方法および耐タンパー演算撹乱実装方式
CN101834723A (zh) 一种rsa算法及其ip核
CN101562522A (zh) 抗侧信道攻击的椭圆曲线密码系统实现方法
CN103942031B (zh) 椭圆域曲线运算方法
CN100579006C (zh) 一种实现快速大素数生成的rsa加密方法
Kocabaş et al. Implementation of binary Edwards curves for very-constrained devices
CN105790939A (zh) 一种vlsi实现加速器的素数域椭圆曲线密码系统
CN104536913A (zh) 一种基于多块ram的大数运算电路及数据转移方法
CN112883408B (zh) 用于隐私计算的加解密系统和芯片
KR20070085129A (ko) 인크립션 프로세싱 방법 및 인크립션 프로세싱 장치
Guneysu et al. Dynamic intellectual property protection for reconfigurable devices
CN105871552A (zh) 双核并行rsa密码处理方法及协处理器
CN114021734A (zh) 用于联邦学习和隐私计算的参数计算装置、系统及方法
CN111835517B (zh) 一种双域椭圆曲线点乘硬件加速器
CN103246494A (zh) 一种抵抗能量分析和错误攻击的安全模幂计算方法
CN103023659B (zh) 一种参数位宽可扩展的ecc加密硬件装置
CN101819519B (zh) 多功能数字签名电路
CN105094746A (zh) 一种椭圆曲线密码的点加/点倍的实现方法
CN108322308B (zh) 一种用于身份认证的数字签名算法的硬件实现系统
CN109284082A (zh) 一种ecc和sm2通用的点运算方法及装置

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