WO2023201962A1 - 一种基于区块链的匿名可信投票方法、装置及相关设备 - Google Patents

一种基于区块链的匿名可信投票方法、装置及相关设备 Download PDF

Info

Publication number
WO2023201962A1
WO2023201962A1 PCT/CN2022/116770 CN2022116770W WO2023201962A1 WO 2023201962 A1 WO2023201962 A1 WO 2023201962A1 CN 2022116770 W CN2022116770 W CN 2022116770W WO 2023201962 A1 WO2023201962 A1 WO 2023201962A1
Authority
WO
WIPO (PCT)
Prior art keywords
tuple
voting
signature
promise
value
Prior art date
Application number
PCT/CN2022/116770
Other languages
English (en)
French (fr)
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
Application filed by 南方电网科学研究院有限责任公司, 贵州电网有限责任公司 filed Critical 南方电网科学研究院有限责任公司
Publication of WO2023201962A1 publication Critical patent/WO2023201962A1/zh

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/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3247Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving digital signatures
    • H04L9/3252Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving digital signatures using DSA or related signature schemes, e.g. elliptic based signatures, ElGamal or Schnorr schemes
    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C13/00Voting apparatus
    • 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/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3236Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions
    • 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/42Anonymization, e.g. involving pseudonyms
    • 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/46Secure multiparty computation, e.g. millionaire problem
    • H04L2209/463Electronic voting

Definitions

  • This application relates to the field of blockchain technology, and in particular to an anonymous and trusted voting method, device and related equipment based on blockchain.
  • IoE Internet of Energy
  • IoE Internet of Energy
  • voting is one of the most common activities in IoE. For example, we can choose a suitable energy broker through electronic voting. Although there are many electronic voting schemes, the schemes in IoE have more stringent requirements.
  • this application provides an anonymous and trusted voting method, device and related equipment based on blockchain to achieve decentralized anonymous voting.
  • the first aspect of this application provides an anonymous and trusted voting method based on blockchain, including:
  • the original vote content is hashed to obtain a hash output that includes the commitment value
  • the commitment value Perform blinding processing to obtain the commitment value tuple and
  • the signature tuple Sign tuples for each other voter pair Verified and generated after verification is passed; promise value tuple Used to decrypt the voting tuple.
  • the original voting content is hashed to obtain the commitment value
  • the process includes:
  • o is a randomly generated string.
  • the commitment value is determined by combining the information of other voters Perform blinding processing to obtain the commitment value tuple and
  • the process includes:
  • the commitment value tuple is processed through the ESDSA algorithm Sign and get the signature tuple
  • Sign includes:
  • pair tuple Perform a hash operation to get the signature tuple
  • ID i and addr i are the identity identification and address information of the target voter, is a tuple of promise values corresponds to the commitment value of voter n v .
  • said hash output also includes a commitment value
  • the method also includes:
  • voting tuple Used as voting content to open the voting stage.
  • the blockchain-based anonymous and trusted voting method also includes:
  • the signature tuple Signature elements that exceed the preset proportion in If the verification is passed, the promise tuple is obtained through the preset algorithm. and to verify the original voting content.
  • the promise tuple is obtained through a preset algorithm and
  • the process of verifying the original voting content includes:
  • the input original vote content m and the string serialized promise tuple Perform a hash operation to get the hash value
  • the second aspect of this application provides an anonymous and trusted voting device based on blockchain, including:
  • the commitment unit is used to perform a hash operation on the original voting content to obtain a hash output, and the hash output includes the commitment value
  • the blinding unit is used to combine the information of other voters to determine the commitment value. Perform blinding processing to obtain the commitment value tuple and
  • Signature unit used to sign the commitment value tuple through the ESDSA algorithm Sign and get the signature tuple
  • Voting unit for tuples based on promise values Signature tuple and the signature tuples of each other voter Construct voting tuple and will vote the tuple and a tuple of promise values On-chain, the voting tuple Used as voting content for the voting stage;
  • the signature tuple Sign tuples for each other voter pair Verified and generated after verification is passed; promise value tuple Used to decrypt the voting tuple.
  • the third aspect of this application provides an anonymous and trusted voting device based on blockchain, including: a memory and a processor;
  • the memory is used to store programs
  • the processor is used to execute the program and implement each step of the above-mentioned anonymous and trusted voting method based on the blockchain.
  • the fourth aspect of this application provides a storage medium on which a computer program is stored.
  • the computer program is executed by a processor, each step of the above-mentioned anonymous trusted voting method based on the blockchain is implemented.
  • this application first performs a hash operation on the original voting content to obtain a hash output, and the hash output includes the commitment value.
  • the hash operation enables the original voting content to be better hidden.
  • the commitment value Perform blinding processing to obtain the commitment value tuple and After blinding, the identity of the voter can be better hidden.
  • the commitment value tuple is processed through the ESDSA algorithm Sign and get the signature tuple By signing the commitment value tuple by the voter himself, the voting content can be authenticated by the target voter himself and prevent others from forging the voting content.
  • Figure 1 is a schematic diagram of the overall design of the anonymous and trusted voting method based on blockchain disclosed in the embodiment of this application;
  • Figure 2 is a flow diagram of the anonymous and trusted voting method based on the blockchain disclosed in the embodiment of this application;
  • Figure 3 is a schematic diagram of an anonymous and trusted voting device based on blockchain disclosed in the embodiment of this application;
  • Figure 4 is another schematic diagram of the anonymous and trusted voting device based on blockchain disclosed in the embodiment of this application.
  • Figure 5 is another schematic diagram of the anonymous and trusted voting device based on the blockchain disclosed in the embodiment of the present application.
  • Figure 6 is a schematic diagram of an anonymous and trusted voting device based on blockchain disclosed in the embodiment of this application.
  • the main idea of this technical solution is that when a user wants to vote for a ballot, the user first commits to the voting message (to achieve credibility), blinds (to achieve anonymity) and signs (to achieve verifiability). Cryptographic operations are used to obtain an anonymous and trusted voting result for the original voting content; then a blind signature algorithm is used to blindly sign (verifiable) the anonymous and trusted voting result, and finally the voting information for a ballot information (triple ). The user will then upload their voting information for the ballot in the blockchain, where the blind signature results are uploaded directly to the blockchain, and the committed, blinded ballot message will be opened by the user using an open voting stage.
  • the commitment is processed and uploaded to the blockchain. Finally, the voter's voting content (quadruple) on the ballot will be recorded in the blockchain. Finally, users can verify whether the vote is valid in the blockchain. If valid, the vote counting operation is performed and the voting results are tallied.
  • the anonymous trusted voting method based on the blockchain provided by the embodiment of this application may include the following steps:
  • Step S101 Perform a hash operation on the original voting content to obtain a hash output.
  • the hash operation can transform the input of any length (also called pre-mapping pre-image) into a fixed-length hash output through the hash algorithm.
  • the hash output includes the commitment value
  • This transformation is a compressed mapping, that is, the space of the hash output is usually much smaller than the space of the input. Different inputs may hash to the same hash output, so it is impossible to determine the unique input from the hash output. value.
  • the original vote content m is hashed to a promised value This allows the voting content to be well hidden, and no other voters will be able to know the specific voting content before the vote is unlocked.
  • Step S102 combine the information of other voters to determine the commitment value Perform blinding processing to obtain the commitment value tuple and
  • the blinding process can be completed through the preset blind commitment algorithm.
  • the information of other voters can be embedded into the commitment value. , thereby hiding the identity information of the target voter and achieving the purpose of anonymous voting.
  • Step S103 Use the ESDSA algorithm to calculate the commitment value tuple Sign and get the signature tuple
  • the commitment value tuple is Signatures are performed so that the voting content can be authenticated by the target voter and prevent others from forging the voting content.
  • Step S104 based on the commitment value tuple Signature tuple and the signature tuples of each other voter Construct voting tuple and will vote the tuple and a tuple of promise values Wind up.
  • the signature tuple Sign tuples for each other voter pair Verified and generated after verification is passed; promise value tuple Used to decrypt the voting tuple, which Used as voting content for the voting phase.
  • the embodiment of this application first performs a hash operation on the original voting content to obtain a hash output, which includes the commitment value. This hash operation allows the original voting content to be better hidden. Then, combined with the information of other voters, the commitment value Perform blinding processing to obtain the commitment value tuple and After blinding, the identity of the voter can be better hidden. Next, the commitment value tuple is processed through the ESDSA algorithm Sign and get the signature tuple By signing the commitment value tuple by the voter himself, the voting content can be authenticated by the target voter himself and prevent others from forging the voting content.
  • the above step S101 performs a hash operation on the original voting content to obtain the commitment value
  • the process may include:
  • o is a randomly generated string.
  • algorithm C the above hashing operation can be implemented through algorithm C, that is Among them, the specific content of algorithm C is as follows:
  • algorithm C first generates a 32-byte random string as the open string o in the commitment, and then the commitment string c is the hash value of the original votes m and o after running the SHA256 collision-resistant hashing algorithm, where the algorithm serialize() in C means string serialization of o.
  • the above step S102 combines the information of other voters to determine the commitment value.
  • Perform blinding processing to obtain the commitment value tuple and The process may include:
  • the above blinding process can be performed through the algorithm BlindX, that is, through for a different voter other than Generate blinded promise value tuples and (Note that in this specification, the case where the lowercase letter is superscripted with ⁇ indicates that it is a string vector, the number of strings is n v , and the case where the lowercase letter is superscripted with ⁇ indicates that it is a string).
  • the specific content of the algorithm BlindX is as follows:
  • the algorithm BlindX first randomly generates two 32-byte random strings ⁇ and ⁇ , which are used to perform the dot multiplication operation of elliptic curve ECC on the input public key information (the fourth line). Subsequently, the X-axis coordinate data of the point of the elliptic curve is taken as a factor for blinding (fifth line), where the getXpointFromPubkey function is a function in the elliptic curve ECC that takes the X-axis coordinate value of a certain point. Next, the original commitment Perform blinding to obtain a new commitment value (lines 6 and 7). In addition, the blinded commitment needs to be signed for subsequent authenticity verification. Specifically, a signature algorithm Sign of the ECDSA algorithm is called, and the private key sk i of the voter vi is used to sign. Finally, the algorithm returns As a result of blinding.
  • a signature algorithm Sign of the ECDSA algorithm is called, and the private key sk i of the voter vi is used to sign.
  • a blockchain smart contract algorithm setAnmVote needs to be called. Its function is to upload the voter's address information, blinded string commitment information and signature information to the chain through smart contract transactions.
  • a data structure is needed to record information bound to voters.
  • the structure in Table 1 can be used as the data structure (voters) of the records stored in the blockchain.
  • address, PK, PKs, and ID are basic public information, and the other three mapping data correspond to the voter’s voting tuple for the ballot.
  • Its data type is a mapping vector, which is characterized by using the address data type of the blockchain to represent the index of the vector.
  • the algorithm setAnmVote is an on-chain operation, which has no output.
  • its specific content is as follows:
  • iV and iS represent the voter address and potential signer address respectively in the Ethereum blockchain.
  • iS i and iC i are data generated in the BlindX algorithm.
  • Voters are the array corresponding to the data structure in Table 1.
  • the first line msg.sender refers to the transaction sender address in the blockchain that calls the smart contract algorithm. This requirement ensures that only the voter himself can set the data (valid when it calls the smart contract).
  • the algorithm will put iS i and iC i on the chain, the data will be recorded in the blockchain, and no one can reset it, including the voters themselves.
  • the above step S103 uses the ESDSA algorithm to calculate the commitment value tuple. Sign and get the signature tuple
  • the process may include:
  • pair tuple Perform a hash operation to get the signature tuple
  • ID i and addr i are the identity identification and address information of the target voter, is a tuple of promise values corresponds to the commitment value of voter n v .
  • the information is recorded into the blockchain through smart contracts, using a smart contract algorithm setAnmVote.
  • a smart contract algorithm setAnmVote it should be noted that At this stage it is kept secret by the voter v i himself.
  • the signature tuples of each other voter It can be calculated by the preset algorithm BlindS.
  • every other voter verifies the validity of the signature through the ECDSA verification algorithm.
  • a smart contract algorithm getAnmVote needs to be used to query the signature in the blockchain. If the verification is valid, then every other voter generates a blind signature in the blind signature protocol through the blind signature algorithm BlindS i.e. pass and uses a smart contract algorithm signAnmVote to Upload to the blockchain. Finally, let for different voters blind signed tuple.
  • algorithm BlindS For example, the specific content of algorithm BlindS is as follows:
  • the blind signature also needs to be uploaded to the chain, and a smart contract algorithm signAnmVote for the chain operation is called.
  • the requirement in line 2 ensures that only the signer himself can set the corresponding data. Once a signature is recorded, no one can reset it, including the signer himself.
  • the algorithm BlindS returns the generated blind signature
  • iV and iS respectively represent the voter address and the potential signer address in the Ethereum blockchain.
  • the output is an address V, and the voter's address recorded in the current blockchain block.
  • the signature is i and the commitment ic i .
  • the algorithm After the algorithm starts, it directly returns the voters in the voters data structure with the current address of iV, the iV position of si and the iV position field of ci.
  • the algorithm signAnmVote is an on-chain operation, and it has no output. Its function is to upload the blind signature generated by the algorithm BlindS to the chain.
  • the specific content of the algorithm signAnmVote is as follows:
  • the algorithm signAnmVote has two input parameters iV and idsig, which respectively represent the voter's address and a blind signature implemented by the corresponding address in the blockchain.
  • the first line msg.sender refers to the transaction sender address in the blockchain that calls the smart contract algorithm (the signer address of the blind signature). This requirement ensures that only the signer himself can upload data to the chain.
  • the hash output mentioned in the above step S101 also includes a commitment value
  • This blockchain-based anonymous and trusted voting method can also include:
  • Step S105 obtain the signature tuple from the blockchain and promise value tuple and based on signed tuple Calculate the signature tuples of other voters
  • Step S106 based on commitment value and promise value tuple Use the preset algorithm VerifyS to verify signature elements Verify the validity and obtain each signature element that passes the verification
  • the target voter v i can pass an algorithm verify The effectiveness of , where, It is also a commitment value stored in the blockchain. is a signed tuple corresponds to the commitment value of voter n v
  • the signature element of , the target voter v i can be calculated by get ⁇ is a random key.
  • Step S107 obtain each signature element corresponding to the verification passed promise string and based on each signature element that passes verification Build a new signed tuple Based on each promise string Construct a new promise tuple
  • Step S108 use a random address to convert the voting tuple Wind up.
  • the voting tuple Can be used as voting content to open the voting phase. It is understood that the target voter vi can choose a random address in the blockchain to send this transaction so that no one can find out who sent this transaction.
  • the point B of an ECC elliptic curve is calculated. Subsequently, the algorithm obtains the coordinate data of the X-axis of the points of the elliptic curve. Next, the algorithm commits to the original Perform a SHA256 hash with the X-axis coordinate of point B to get a hash value. If the promise is valid, the value should match the input value same. Finally, the algorithm outputs True or False based on this judgment.
  • the blockchain-based anonymous and trusted voting method may also include:
  • Step S109 obtain the voting tuple from the blockchain And use the preset algorithm V to pair the signature tuple authenticating.
  • Step S110 if the signature tuple Signature elements that exceed the preset proportion in If the verification is passed, the promise tuple is obtained through the preset algorithm. and to verify the original voting content.
  • the above step S110 uses a preset algorithm to obtain the commitment tuple from and
  • the process of verifying the original voting content may include:
  • pair of promise tuples Perform string serialization and transportation to obtain the promise tuple after string serialization.
  • Algorithm V the content of Algorithm V is as follows:
  • serialize() in algorithm V means string serialization of o. and then judge Is it equal to the input c? If so, the vote verification is passed and True is output, otherwise False is output.
  • the following describes the anonymous and trusted voting device based on blockchain provided by the embodiment of the present application.
  • the anonymous and trusted voting device based on blockchain described below and the anonymous and trusted voting method based on blockchain described above can interact with each other. Corresponding reference.
  • the anonymous and trusted voting device based on blockchain provided by the embodiment of this application may include:
  • Commitment unit 21 is used to perform a hash operation on the original voting content to obtain a hash output, where the hash output includes a commitment value
  • the blinding unit 22 is used to combine the information of other voters to determine the commitment value. Perform blinding processing to obtain the commitment value tuple and
  • Signature unit 23 used to sign the commitment value tuple through the ESDSA algorithm Sign and get the signature tuple
  • Voting unit 24 for tuples based on commitment values Signature tuple and the signature tuples of each other voter Construct voting tuple and will vote the tuple and a tuple of promise values On-chain, the voting tuple Used as voting content for the voting stage;
  • the signature tuple Sign tuples for each other voter pair Verified and generated after verification is passed; promise value tuple Used to decrypt the voting tuple.
  • the commitment unit 21 performs a hash operation on the original voting content to obtain the commitment value
  • the process may include:
  • o is a randomly generated string.
  • the blinding unit 22 combines the information of other voters to determine the commitment value. Perform blinding processing to obtain the commitment value tuple and The process may include:
  • the signature unit 23 performs the ESDSA algorithm on the commitment value tuple. Sign and get the signature tuple The process may include:
  • pair tuple Perform a hash operation to get the signature tuple
  • ID i and addr i are the identity identification and address information of the target voter, is a tuple of promise values corresponds to the commitment value of voter n v .
  • the hash output mentioned by the commitment unit 21 also includes a commitment value
  • the blockchain-based anonymous and trusted voting device may also include an open voting unit 30 for:
  • voting tuple Used as voting content to open the voting stage.
  • the blockchain-based anonymous and trusted voting device may also include a verification and counting unit 40 for:
  • the signature tuple Signature elements that exceed the preset proportion in If the verification is passed, the promise tuple is obtained through the preset algorithm. and to verify the original voting content.
  • the verification vote counting unit 40 uses a preset algorithm to obtain the result from the commitment tuple. and The process of verifying the original voting content may include:
  • the input original vote content m and the string serialized promise tuple Perform a hash operation to get the hash value
  • FIG. 6 shows a block diagram of the hardware structure of the anonymous and trusted voting device based on the blockchain.
  • the hardware structure of the anonymous and trusted voting device based on the blockchain may include: at least one processor 31, At least one communication interface 32, at least one memory 33 and at least one communication bus 34.
  • the number of the processor 31, the communication interface 32, the memory 33, and the communication bus 34 is at least one, and the processor 31, the communication interface 32, and the memory 33 complete communication with each other through the communication bus 34;
  • the processor 31 may be a central processing unit CPU, or an application specific integrated circuit ASIC (Application Specific Integrated Circuit), or one or more integrated circuits configured to implement embodiments of the present application, etc.;
  • ASIC Application Specific Integrated Circuit
  • the memory 32 may include high-speed RAM memory, and may also include non-volatile memory (non-volatile memory), etc., such as at least one disk memory;
  • the memory 33 stores a program, and the processor 31 can call the program stored in the memory 33.
  • the program is used for:
  • the original vote content is hashed to obtain a hash output that includes the commitment value
  • the commitment value Perform blinding processing to obtain the commitment value tuple and
  • the signature tuple Sign tuples for each other voter pair Verified and generated after verification is passed; promise value tuple Used to decrypt the voting tuple.
  • Embodiments of the present application also provide a storage medium, which can store a program suitable for execution by a processor, where the program is used for:
  • the original vote content is hashed to obtain a hash output that includes the commitment value
  • the commitment value Perform blinding processing to obtain the commitment value tuple and
  • the signature tuple Sign tuples for each other voter pair Verified and generated after verification is passed; promise value tuple Used to decrypt the voting tuple.
  • This application first performs a hash operation on the original voting content to obtain a hash output, which includes the commitment value
  • the hash operation enables the original voting content to be better hidden.
  • the commitment value Perform blinding processing to obtain the commitment value tuple and After blinding, the identity of the voter can be better hidden.
  • the commitment value tuple is processed through the ESDSA algorithm Sign and get the signature tuple
  • the voting content can be authenticated by the target voter himself and prevent others from forging the voting content.
  • this application has the unique characteristics of blockchain such as decentralization, traceability and tamper resistance. In addition, it is different from other blockchain-based distributed timestamp schemes. In comparison, this proposal is more efficient.
  • This application efficiently achieves seven security design goals, namely: fairness (ensuring that no one can obtain the voting results of others before submitting their own ballot, which means that the voter's choice will not be affected by those who voted in advance) , decentralization (any kind of trusted third party, such as election administrators or independent observers, should not be present in the voting protocol), legality (before a voter starts voting, his/her rights should be checked; In addition, legality requires that each voter can only vote once), anonymity (requires protecting the privacy of the voter and not allowing anyone to know who the owner of the ballot is in the final voting results), compatibility (requiring a voting scheme should be as simple as possible to be integrated into the information system of the Energy Internet), verifiability (guaranteing that all stages of voting can be audite
  • this application is an anonymous and trusted voting solution based on the blockchain. Compared with the current anonymous and trusted voting solutions implemented by a large number of platforms such as PoW consensus algorithms, it has faster transaction processing.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

一种基于区块链的匿名可信投票方法、装置及相关设备,该方法包括:对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值 Cvi;结合其他各投票人的信息对承诺值Cvi进行盲化处理,得到承诺值元组c ̃和x ̃;通过ESDSA算法对承诺值元组c ̃进行签名,得到签名元组s ̃;基于承诺值元组c ̃、签名元组s ̃以及其他各投票人的签名元组d ̃,构建投票元组(c ̃,s ̃,d ̃)并将投票元组(c ̃,s ̃,d ̃)以及承诺值元组 x ̃上链,所述投票元组(c ̃,s ̃,d ̃)用作投票阶段的投票内容;其中,签名元组d ̃为其他各投票人对签名元组s ̃进行验证,且在验证通过后生成的;承诺值元组 x ̃用于对所述投票元组进行解密。通过上述处理过程,实现了投票内容隐藏、投票匿名及可验证。

Description

一种基于区块链的匿名可信投票方法、装置及相关设备
本申请要求于2022年04月21日提交中国专利局、申请号为202210422851.X、发明名称为“一种基于区块链的匿名可信投票方法、装置及相关设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及区块链技术领域,特别涉及一种基于区块链的匿名可信投票方法、装置及相关设备。
背景技术
智能电网系统的快速发展催生了一种名为“能源互联网”(IoE)的现代电力系统,引起了许多国家的极大兴趣。作为能源问题的互联网式解决方案,IoE有许多关键技术和挑战需要解决。其中,投票是IoE中最常见的活动之一。例如,我们可以通过电子投票选择一个合适的能源经纪人。虽然有很多电子投票方案,但IoE中的方案有更严格的要求。
除了电子投票方案的一些常见要求,如正确性、合格性和抗胁迫性等,在IoE中部署投票服务时,还需要满足去中心化、匿名性、可验证性和效率等要求。首先,由于IoE的开放和分布式性质,在没有任何类型的可信第三方(TTP)的情况下处理投票是很重要的;其次,提供足够的投票人匿名性也是至关重要的,因为在IoE的点对点市场中,候选人可能有更多不受监控的方式来损害投票人;然后,必须提供可验证性,因为非法行为应该在IoE中进行审计和惩罚;最后,IoE中的基本服务应该是高效的,并且与系统兼容。
虽然过去的研究(如Helios及Backes等人提出的电子投票方案:[Ben Adida.Helios:Web-based open-audit voting.In USENIX security symposium,volume 17,2018]和[Michael Backes,Martin Gagné,and Malte Skoruppa.Using mobile device communication to strengthen e-voting protocols.In Proceedings of the 12th ACM workshop on Workshop on privacy in the  electronic society,pages 237–242,2013])为匿名电子投票提出了一系列有效的协议,但是他们中的大多数方案需要管理员或当局实施的web服务器提供一个一致的视图,由此涉及到一个可信任的第三方。然而,对于可信的第三方,协议将受到单点故障的影响,不能用于新型互联网不可信的环境。
另一个问题是提供可验证性和匿名性,这似乎是两个相互矛盾的设计目标。一些投票方案(如Yang等人提出的基于区块链的匿名投票方案:[Xuechao Yang,Xun Yi,Surya Nepal,Andrei Kelarev,and Fengling Han.Blockchain voting:Publicly verifiable online voting protocol without trusted tallying authorities.Future Generation Computer Systems,112:859-874,2020])已经通过区块链技术建解决了这个问题,然而,效率问题是他们技术最大一个缺陷。
发明内容
有鉴于此,本申请提供了一种基于区块链的匿名可信投票方法、装置及相关设备,以实现去中心化的匿名投票。
为实现上述目的,本申请第一方面提供了一种基于区块链的匿名可信投票方法,包括:
对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
Figure PCTCN2022116770-appb-000001
结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000002
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000003
Figure PCTCN2022116770-appb-000004
通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000005
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000006
基于承诺值元组
Figure PCTCN2022116770-appb-000007
签名元组
Figure PCTCN2022116770-appb-000008
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000009
构建投票元组
Figure PCTCN2022116770-appb-000010
并将投票元组
Figure PCTCN2022116770-appb-000011
以及承诺值元组
Figure PCTCN2022116770-appb-000012
上链,所述投票元组
Figure PCTCN2022116770-appb-000013
用作投票阶段的投票内容;
其中,签名元组
Figure PCTCN2022116770-appb-000014
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000015
进行验证,且在验证通过后生成的;承诺值元组
Figure PCTCN2022116770-appb-000016
用于对所述投票元组进行解密。
优选地,所述对原始投票内容进行散列运算,得到承诺值
Figure PCTCN2022116770-appb-000017
的过程,包括:
对原始投票内容m和字符串o进行哈希运算,得到承诺值
Figure PCTCN2022116770-appb-000018
其中,o为随机生成的字符串。
优选地,所述结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000019
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000020
Figure PCTCN2022116770-appb-000021
的过程,包括:
对于其他每一投票人的公钥信息pk j
Figure PCTCN2022116770-appb-000022
进行椭圆曲线ECC的点乘操作,得到盲化因子t j
基于盲化因子t j将承诺值
Figure PCTCN2022116770-appb-000023
哈希到新的承诺值x j及c j
汇聚各承诺值x j得到承诺值元组
Figure PCTCN2022116770-appb-000024
以及采用私钥sk i对各承诺值c j进行签名,得到承诺值元组
Figure PCTCN2022116770-appb-000025
优选地,所述通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000026
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000027
的过程,包括:
对元组
Figure PCTCN2022116770-appb-000028
进行哈希运算,得到签名元组
Figure PCTCN2022116770-appb-000029
其中,ID i和addr i为目标投票人的身份标识及地址信息,
Figure PCTCN2022116770-appb-000030
为承诺值元组
Figure PCTCN2022116770-appb-000031
中对应于投票人n v的承诺值。
优选地,所述散列输出还包括承诺值
Figure PCTCN2022116770-appb-000032
所述方法还包括:
从区块链获取签名元组
Figure PCTCN2022116770-appb-000033
和承诺值元组
Figure PCTCN2022116770-appb-000034
并基于签名元组
Figure PCTCN2022116770-appb-000035
计算得到其他各投票人的签名元组
Figure PCTCN2022116770-appb-000036
基于承诺值
Figure PCTCN2022116770-appb-000037
和承诺值元组
Figure PCTCN2022116770-appb-000038
采用预设的算法VerifyS对
Figure PCTCN2022116770-appb-000039
的有效性进行验证,得到验证通过的各签名元素
Figure PCTCN2022116770-appb-000040
其中,
Figure PCTCN2022116770-appb-000041
是签名元组
Figure PCTCN2022116770-appb-000042
中对应于投票人n v的签名元素;
获取对应于验证通过的每一签名元素
Figure PCTCN2022116770-appb-000043
的承诺字符串
Figure PCTCN2022116770-appb-000044
并基于验证通过的各签名元素
Figure PCTCN2022116770-appb-000045
构建新的签名元组
Figure PCTCN2022116770-appb-000046
基于各承诺字符串
Figure PCTCN2022116770-appb-000047
构建新的承诺元组
Figure PCTCN2022116770-appb-000048
采用随机地址将投票元组
Figure PCTCN2022116770-appb-000049
上链,投票元组
Figure PCTCN2022116770-appb-000050
用作打开投票阶段的投票内容。
优选地,所述基于区块链的匿名可信投票方法还包括:
从区块链获取投票元组
Figure PCTCN2022116770-appb-000051
并采用预设的算法V对签名元组
Figure PCTCN2022116770-appb-000052
进行验证;
若签名元组
Figure PCTCN2022116770-appb-000053
中超过预设比例的签名元素
Figure PCTCN2022116770-appb-000054
验证通过,则通过预设的算法从承诺元组
Figure PCTCN2022116770-appb-000055
Figure PCTCN2022116770-appb-000056
中验证原始投票内容。
优选地,所述通过预设的算法从承诺元组
Figure PCTCN2022116770-appb-000057
Figure PCTCN2022116770-appb-000058
中验证原始投票内容的过程,包括:
对承诺元组
Figure PCTCN2022116770-appb-000059
进行字符串序列化运输,得到字符串序列化后的承诺元组
Figure PCTCN2022116770-appb-000060
对输入的原始投票内容m和字符串序列化后的承诺元组
Figure PCTCN2022116770-appb-000061
进行哈希运算,得到哈希值
Figure PCTCN2022116770-appb-000062
判断
Figure PCTCN2022116770-appb-000063
Figure PCTCN2022116770-appb-000064
是否相等,若是,则原始投票内容m验证通过。
本申请第二方面提供了一种基于区块链的匿名可信投票装置,包括:
承诺单元,用于对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
Figure PCTCN2022116770-appb-000065
盲化单元,用于结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000066
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000067
Figure PCTCN2022116770-appb-000068
签名单元,用于通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000069
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000070
投票单元,用于基于承诺值元组
Figure PCTCN2022116770-appb-000071
签名元组
Figure PCTCN2022116770-appb-000072
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000073
构建投票元组
Figure PCTCN2022116770-appb-000074
并将投票元组
Figure PCTCN2022116770-appb-000075
以及承诺值元组
Figure PCTCN2022116770-appb-000076
上链,所述投票元组
Figure PCTCN2022116770-appb-000077
用作投票阶段的投票内容;
其中,签名元组
Figure PCTCN2022116770-appb-000078
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000079
进行验证,且在验证通过后生成的;承诺值元组
Figure PCTCN2022116770-appb-000080
用于对所述投票元组进行解密。
本申请第三方面提供了一种基于区块链的匿名可信投票设备,包括:存储器和处理器;
所述存储器,用于存储程序;
所述处理器,用于执行所述程序,实现上述的基于区块链的匿名可信投票方法的各个步骤。
本申请第四方面提供了一种存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时,实现如上述的基于区块链的匿名可信投票方法的各个步骤。
经由上述的技术方案可知,本申请首先对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
Figure PCTCN2022116770-appb-000081
所述散列运算使得原始投票内容能够得到较好的隐藏。然后,结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000082
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000083
Figure PCTCN2022116770-appb-000084
经过盲化处理,使得投票人身份能够得到较好的隐藏。接着,通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000085
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000086
通过投票人自身对其承诺值元组进行签名,使得投票内容得到目标投票人本人的认证,并防止他人伪造投票内容。最后,基于承诺值元组
Figure PCTCN2022116770-appb-000087
签名元组
Figure PCTCN2022116770-appb-000088
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000089
构建投票元组
Figure PCTCN2022116770-appb-000090
并将投票元组
Figure PCTCN2022116770-appb-000091
以及承诺值元组
Figure PCTCN2022116770-appb-000092
上链,所述投票元组
Figure PCTCN2022116770-appb-000093
用作投票阶段的投票内容。其中,签名元组
Figure PCTCN2022116770-appb-000094
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000095
进行验证,且在验证通过后生成的。通过其他各投票人的验证签名,使得目标投票人本人无法篡改投票内容。承诺值元组
Figure PCTCN2022116770-appb-000096
用于对所述投票元组进行解密,便于后续打开投票内容并进行计票。本申请通过上述处理过程,实现了投票内容隐藏、投票匿名及可验证。
附图说明
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的实施例,对于本领域普通技术人员来讲, 在不付出创造性劳动的前提下,还可以根据提供的附图获得其他的附图。
图1为本申请实施例公开的基于区块链的匿名可信投票方法的整体设计示意图;
图2为本申请实施例公开的基于区块链的匿名可信投票方法的流示意图;
图3为本申请实施例公开的基于区块链的匿名可信投票装置的示意图;
图4为本申请实施例公开的基于区块链的匿名可信投票装置的另一示意图;
图5为本申请实施例公开的基于区块链的匿名可信投票装置的再一示意图;
图6为本申请实施例公开的基于区块链的匿名可信投票设备的示意图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
为便于理解,首先介绍本申请的基于区块链的匿名可信投票方法的整体设计思路。请参阅图1,本技术方案的主要思想是当用户想对一个选票进行投票时,用户先对投票消息进行承诺(实现可信)、盲化(实现匿名)和签名(实现可验证)三个密码学操作,得到一个对原始投票内容的匿名可信投票结果;再用一个盲签名算法对匿名可信投票结果进行盲签名(可验证),最后得到对一个选票信息的投票信息(三元组)。然后用户将在区块链中上传其对选票的投票信息,其中,盲签名的结果直接上传到区块链中,而进行了承诺、盲化后的选票消息将由用户利用一个打开投票阶段打开其承诺,进行处理后上传到区块链中,最后在区块链中将记录下投票人对选票的投票内容(四元组)。最后,用户可以在区块链中验证投票是否有效,如果有效,则进行计票操作,对投票结果进行统计。
下面详细介绍本申请实施例提供的基于区块链的匿名可信投票方法。可以理解的是,能源互联网系统(IoE)中的任何人都可以通过本提案发起投票。所有想要参加投票的投票人都应该提供他们的公钥和身份证明。因此,在进入投票之前必须经过一个初始化阶段,在这个初始化阶段,投票人的所有公共信息通过预设的智能合约广播到区块链中。假设有n v个不同的投票人
Figure PCTCN2022116770-appb-000097
每个投票人v i通过椭圆曲线ECC密钥生成两个密钥对
Figure PCTCN2022116770-appb-000098
Figure PCTCN2022116770-appb-000099
Figure PCTCN2022116770-appb-000100
为投票人v i在以太坊网络中的公开地址,
Figure PCTCN2022116770-appb-000101
表示投票人的身份。那么每个投票人v i的公共信息是一个元组
Figure PCTCN2022116770-appb-000102
每个投票人都可以从区块链得到这个信息来验证它的有效性。在完成了上述的初始化工作后,请参阅图2,本申请实施例提供的基于区块链的匿名可信投票方法可以包括如下步骤:
步骤S101,对原始投票内容进行散列运算,得到散列输出。
其中,散列运算可以把任意长度的输入(又叫做预映射pre-image)通过散列算法变换成固定长度的散列输出,在本步骤中,该散列输出包括承诺值
Figure PCTCN2022116770-appb-000103
这种转换是一种压缩映射,也就是,散列输出的空间通常远小于输入的空间,不同的输入可能会散列成相同的散列输出,所以不可能从散列输出来确定唯一的输入值。通过散列运算,将原始投票内容m散列到一个承诺值
Figure PCTCN2022116770-appb-000104
使得投票内容可以得到很好的隐藏,在投票解开前,其他投票人都无法获知具体的投票内容。
步骤S102,结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000105
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000106
Figure PCTCN2022116770-appb-000107
其中,该盲化处理可以通过预设的盲承诺算法来完成,通过盲化处理,可以将其他各投票人的信息嵌入到承诺值
Figure PCTCN2022116770-appb-000108
中,从而隐藏目标投票人的身份信息,达到匿名投票的目的。
步骤S103,通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000109
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000110
通过ESDSA算法结合目标投票人的私钥,对承诺值元组
Figure PCTCN2022116770-appb-000111
进行签名,使得投票内容得到目标投票人本人的认证,并防止他人伪造投票内容。
步骤S104,基于承诺值元组
Figure PCTCN2022116770-appb-000112
签名元组
Figure PCTCN2022116770-appb-000113
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000114
构建投票元组
Figure PCTCN2022116770-appb-000115
并将投票元组
Figure PCTCN2022116770-appb-000116
以及承诺值元组
Figure PCTCN2022116770-appb-000117
上链。
其中,签名元组
Figure PCTCN2022116770-appb-000118
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000119
进行验证,且在验证通过后生成的;承诺值元组
Figure PCTCN2022116770-appb-000120
用于对所述投票元组进行解密,该投票元组
Figure PCTCN2022116770-appb-000121
用作投票阶段的投票内容。
本申请实施例首先对原始投票内容进行散列运算,得到散列输出,该散列输出包括承诺值
Figure PCTCN2022116770-appb-000122
该散列运算使得原始投票内容能够得到较好的隐藏。然后,结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000123
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000124
Figure PCTCN2022116770-appb-000125
经过盲化处理,使得投票人身份能够得到较好的隐藏。接着,通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000126
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000127
通过投票人自身对其承诺值元组进行签名,使得投票内容得到目标投票人本人的认证,并防止他人伪造投票内容。最后,基于承诺值元组
Figure PCTCN2022116770-appb-000128
签名元组
Figure PCTCN2022116770-appb-000129
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000130
构建投票元组
Figure PCTCN2022116770-appb-000131
并将投票元组
Figure PCTCN2022116770-appb-000132
以及承诺值元组
Figure PCTCN2022116770-appb-000133
上链,该投票元组
Figure PCTCN2022116770-appb-000134
用作投票阶段的投票内容。其中,签名元组
Figure PCTCN2022116770-appb-000135
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000136
进行验证,且在验证通过后生成的。通过其他各投票人的验证签名,使得目标投票人本人无法篡改投票内容。承诺值元组
Figure PCTCN2022116770-appb-000137
用于对所述投票元组进行解密,便于后续打开投票内容并进行计票。本申请通过上述处理过程,实现了投票内容隐藏、投票匿名及可验证。
在本申请的一些实施例中,上述步骤S101对原始投票内容进行散列运算,得到承诺值
Figure PCTCN2022116770-appb-000138
的过程,可以包括:
对原始投票内容m和字符串o进行哈希运算,得到承诺值
Figure PCTCN2022116770-appb-000139
其中,o为随机生成的字符串。
示例性地,可以通过算法C实现上述散列运算,即
Figure PCTCN2022116770-appb-000140
其中,算法C的具体内容如下:
Figure PCTCN2022116770-appb-000141
具体地,算法C首先生成一个32字节的随机字符串作为承诺中的开放字符串o,然后承诺字符串c是原始选票m和o运行SHA256抗碰撞哈希算法后的哈希值,其中算法C中的serialize()表示对o进行字符串序列化。
在本申请的一些实施例中,上述步骤S102结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000142
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000143
Figure PCTCN2022116770-appb-000144
的过程,可以包括:
S1,对于其他每一投票人的公钥信息pk j
Figure PCTCN2022116770-appb-000145
进行椭圆曲线ECC的点乘操作,得到盲化因子t j
S2,基于盲化因子t j将承诺值
Figure PCTCN2022116770-appb-000146
哈希到新的承诺值x j及c j
S3,汇聚各承诺值x j得到承诺值元组
Figure PCTCN2022116770-appb-000147
以及采用私钥sk i对各承诺值c j进行签名,得到承诺值元组
Figure PCTCN2022116770-appb-000148
示例性地,可以通过算法BlindX进行上述盲化处理,即通过
Figure PCTCN2022116770-appb-000149
为除其以外的不同投票人
Figure PCTCN2022116770-appb-000150
生成盲化后的承诺值元组
Figure PCTCN2022116770-appb-000151
Figure PCTCN2022116770-appb-000152
Figure PCTCN2022116770-appb-000153
(注意,在本说明书中,小写字母上标为~的情况表示其为 一个字符串向量,字符串个数为n v个,小写字母上标为^的情况表示其为一个字符串)。其中,算法BlindX的具体内容如下:
Figure PCTCN2022116770-appb-000154
具体地,算法BlindX首先随机生成两个32字节的随机字符串γ和δ,用于对输入的公钥信息进行椭圆曲线ECC的点乘操作(第四行)。随后,取椭圆曲线的点的X轴的坐标数据作为盲化的一个因子(第五行),其中,getXpointFromPubkey函数是椭圆曲线ECC中的取某个点X轴坐标值的函数。接着,对原始承诺
Figure PCTCN2022116770-appb-000155
进行盲化得到一个新的承诺值(第六、七行)。此外,还需对盲化后的承诺进行签名,以用于后续真实性验证。具体地, 调用一个ECDSA算法的签名算法Sign,并用投票人v i的私钥sk i来进行签名。最后,算法返回
Figure PCTCN2022116770-appb-000156
作为盲化结果。
算法BlindX中,需调用一个区块链智能合约算法setAnmVote,其作用是把投票人的地址信息、盲化后的字符串承诺信息以及签名信息通过智能合约交易上链。首先,需要一个数据结构来记录与投票人绑定的信息,示例性地,可以采用表1中的构造作为区块链中存储的记录的数据结构(voters)。其中,如表1所示,address、PK、PKs、ID为基本公共信息,其他三个映射数据对应投票人对选票的投票元组
Figure PCTCN2022116770-appb-000157
其数据类型是一个映射向量,其特点是采用区块链的地址数据类型来表示向量的索引。
表1投票人的区块链数据结构
数据类型 数据描述
address voter
string PK
string PKs
string ID
mapping(address string) si
mapping(address string) ci
mapping(address string) dsigs
算法setAnmVote是一个上链操作,它没有输出,示例性地,其具体内容如下:
Figure PCTCN2022116770-appb-000158
其中,iV和iS在以太坊区块链中分别代表投票人地址和潜在签名者 地址。iS i、iC i是在BlindX算法中生成的数据。而投票人voters是表1中数据结构对应的数组。第一行msg.sender是指区块链中调用该智能合约算法的交易发送者地址,该要求确保只有投票人自己可以设置数据(当它调用智能合约时才有效)。最后,算法一旦成功运行,该算法将把iS i、iC i上链,数据将在区块链中被记录下来,没有人可以重置它,包括投票人自己。
在本申请的一些实施例中,上述步骤S103通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000159
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000160
的过程,可以包括:
对元组
Figure PCTCN2022116770-appb-000161
进行哈希运算,得到签名元组
Figure PCTCN2022116770-appb-000162
其中,ID i和addr i为目标投票人的身份标识及地址信息,
Figure PCTCN2022116770-appb-000163
为承诺值元组
Figure PCTCN2022116770-appb-000164
中对应于投票人n v的承诺值。
具体地,首先计算元组
Figure PCTCN2022116770-appb-000165
对于不同投票人
Figure PCTCN2022116770-appb-000166
的哈希值
Figure PCTCN2022116770-appb-000167
其中,
Figure PCTCN2022116770-appb-000168
v i为目标投票人本人。然后通过ESDSA算法中的签名算法
Figure PCTCN2022116770-appb-000169
对其他不同投票人进行签名,得到签名元组
Figure PCTCN2022116770-appb-000170
随后,
Figure PCTCN2022116770-appb-000171
的信息通过智能合约记录到区块链中,使用的是一个智能合约算法setAnmVote。另外需要注意的是,
Figure PCTCN2022116770-appb-000172
在这个阶段被投票人v i本人秘密保存。
在本申请的一些实施例中,上述步骤S104中,其他各投票人的签名元组
Figure PCTCN2022116770-appb-000173
可以通过预设的算法BlindS计算得到。
具体地,首先,每一个其他投票人通过ECDSA验证算法验证签名的有效性,为了验证该签名,需要使用一个智能合约算法getAnmVote把区块链中的签名查询出来。验证如果有效,则每一个其他的投票人通过盲签名算法BlindS在盲签名协议中生成盲签名
Figure PCTCN2022116770-appb-000174
即通过
Figure PCTCN2022116770-appb-000175
并使用一个智能合约算法signAnmVote将
Figure PCTCN2022116770-appb-000176
上传到区块链。最后,令
Figure PCTCN2022116770-appb-000177
为对于不同的投票人
Figure PCTCN2022116770-appb-000178
的盲签名元组。
示例性地,算法BlindS的具体内容如下:
Figure PCTCN2022116770-appb-000179
具体地,首先,签名者将使用智能合约算法getAnmVote来查询为他投票人生成的承诺数据
Figure PCTCN2022116770-appb-000180
其中,任何人都可以根据区块链的公共账户地址查询承诺数据。然后,算法利用密码学的SHA256哈希算法和ECDSA的验证算法来对承诺数据中的签名进行有效性确认(这两步生成一个验证结果S),如果有效(S==True),则根据输入的私钥参数,作为签名者的投票人通过
Figure PCTCN2022116770-appb-000181
生成对查询到的承诺
Figure PCTCN2022116770-appb-000182
的一个盲签名
Figure PCTCN2022116770-appb-000183
随后,该盲签名也需要上链,调用的是一个上链操作智能合约算法 signAnmVote。类似地,第2行中的要求确保只有签名者自己可以设置相应的数据。一旦签名被记录下来,没有人可以重置它,包括签名者自己。最后,算法BlindS返回生成的盲签名
Figure PCTCN2022116770-appb-000184
进一步地,上述算法BlindS中,调用了两个区块链智能合约算法getAnmVote和signAnmVote,其中getAnmVote算法是一个查询操作算法。示例性地,算法getAnmVote的具体内容如下:
Figure PCTCN2022116770-appb-000185
具体地,它有两个输入参数iV和iS,在以太坊区块链中分别代表投票人地址和潜在签名者地址,输出为一个地址V,以及当前区块链区块中记录的投票人的签名is i和承诺ic i。算法开始后,直接返回当前地址为iV的voters数据结构中的voter、si的iV位置和ci的iV位置字段。
算法signAnmVote是一个上链操作,它也没有输出,其作用是将算法BlindS生成的盲签名上链。示例性地,算法signAnmVote的具体内容如下:
Figure PCTCN2022116770-appb-000186
算法signAnmVote有两个输入参数iV和idsig,在区块链中分别代表投票人地址和对应地址实现的一个盲签名。第一行msg.sender是指区块链中调用该智能合约算法的交易发送者地址(该盲签名的签名者地址),该要求确保只有签名者自己才可以上链数据。
以上完成了投票阶段的工作流程。在这一阶段的最后,
Figure PCTCN2022116770-appb-000187
则为目标投票人v i对选票
Figure PCTCN2022116770-appb-000188
的投票元组。
接着描述打开投票阶段。在本申请的一些实施例中,上述步骤S101中提及的散列输出还包括承诺值
Figure PCTCN2022116770-appb-000189
该基于区块链的匿名可信投票方法还 可以包括:
步骤S105,从区块链获取签名元组
Figure PCTCN2022116770-appb-000190
和承诺值元组
Figure PCTCN2022116770-appb-000191
并基于签名元组
Figure PCTCN2022116770-appb-000192
计算得到其他各投票人的签名元组
Figure PCTCN2022116770-appb-000193
步骤S106,基于承诺值
Figure PCTCN2022116770-appb-000194
和承诺值元组
Figure PCTCN2022116770-appb-000195
采用预设的算法VerifyS对签名元素
Figure PCTCN2022116770-appb-000196
的有效性进行验证,得到验证通过的各签名元素
Figure PCTCN2022116770-appb-000197
具体地,给定
Figure PCTCN2022116770-appb-000198
目标投票人v i可以通过一算法
Figure PCTCN2022116770-appb-000199
验证
Figure PCTCN2022116770-appb-000200
的有效性,其中,
Figure PCTCN2022116770-appb-000201
也是保存在区块链中的一个承诺值,
Figure PCTCN2022116770-appb-000202
是签名元组
Figure PCTCN2022116770-appb-000203
中对应于投票人n v对承诺值
Figure PCTCN2022116770-appb-000204
的签名元素,目标投票人v i可以通过计算
Figure PCTCN2022116770-appb-000205
得到
Figure PCTCN2022116770-appb-000206
Figure PCTCN2022116770-appb-000207
γ是一个随机密钥。
步骤S107,获取对应于验证通过的每一签名元素
Figure PCTCN2022116770-appb-000208
的承诺字符串
Figure PCTCN2022116770-appb-000209
并基于验证通过的各签名元素
Figure PCTCN2022116770-appb-000210
构建新的签名元组
Figure PCTCN2022116770-appb-000211
基于各承诺字符串
Figure PCTCN2022116770-appb-000212
构建新的承诺元组
Figure PCTCN2022116770-appb-000213
步骤S108,采用随机地址将投票元组
Figure PCTCN2022116770-appb-000214
上链。
其中,投票元组
Figure PCTCN2022116770-appb-000215
可以用作打开投票阶段的投票内容。可以理解的是,目标投票人v i可以在区块链中选择一个随机地址来发送这个交易,以便任何人都不能找出谁发送了这个交易。
示例性地,算法VerifyS的具体内容如下:
Figure PCTCN2022116770-appb-000216
Figure PCTCN2022116770-appb-000217
首先,计算生成一个ECC椭圆曲线的点B。随后,算法取椭圆曲线的点的X轴的坐标数据。接着,算法对原始承诺
Figure PCTCN2022116770-appb-000218
与B点的X轴坐标进行SHA256哈希得到一个哈希值。如果承诺有效,则该值应该与输入值
Figure PCTCN2022116770-appb-000219
相同。最后,算法根据该判断输出True或False。
接下来介绍验证/计票阶段。在本申请的一些实施例中,该基于区块链的匿名可信投票方法还可以包括:
步骤S109,从区块链获取投票元组
Figure PCTCN2022116770-appb-000220
并采用预设的算法V对签名元组
Figure PCTCN2022116770-appb-000221
进行验证。
步骤S110,若签名元组
Figure PCTCN2022116770-appb-000222
中超过预设比例的签名元素
Figure PCTCN2022116770-appb-000223
验证通过,则通过预设的算法从承诺元组
Figure PCTCN2022116770-appb-000224
Figure PCTCN2022116770-appb-000225
中验证原始投票内容。
在本申请的一些实施例中,上述步骤S110通过预设的算法从承诺元组
Figure PCTCN2022116770-appb-000226
Figure PCTCN2022116770-appb-000227
中验证原始投票内容的过程,可以包括:
S1,对承诺元组
Figure PCTCN2022116770-appb-000228
进行字符串序列化运输,得到字符串序列化后的承诺元组
Figure PCTCN2022116770-appb-000229
S2,对输入的原始投票内容m和字符串序列化后的承诺元组
Figure PCTCN2022116770-appb-000230
进行哈希运算,得到哈希值
Figure PCTCN2022116770-appb-000231
S3,判断
Figure PCTCN2022116770-appb-000232
Figure PCTCN2022116770-appb-000233
是否相等,若是,则原始投票内容m验证通过。
示例性地,在验证/计票阶段,算法V的内容如下:
Figure PCTCN2022116770-appb-000234
首先对输入的原始投票内容m和o进行SHA256哈希算法得到哈希值
Figure PCTCN2022116770-appb-000235
其中算法V中的serialize()表示对o进行字符串序列化。然后判断
Figure PCTCN2022116770-appb-000236
与输入的c是否相等,如果是,则说明投票验证通过,输出True,否则输出False。
下面对本申请实施例提供的基于区块链的匿名可信投票装置进行描述,下文描述的基于区块链的匿名可信投票装置与上文描述的基于区块链的匿名可信投票方法可相互对应参照。
请参见图3,本申请实施例提供的基于区块链的匿名可信投票装置,可以包括:
承诺单元21,用于对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
Figure PCTCN2022116770-appb-000237
盲化单元22,用于结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000238
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000239
Figure PCTCN2022116770-appb-000240
签名单元23,用于通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000241
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000242
投票单元24,用于基于承诺值元组
Figure PCTCN2022116770-appb-000243
签名元组
Figure PCTCN2022116770-appb-000244
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000245
构建投票元组
Figure PCTCN2022116770-appb-000246
并将投票元组
Figure PCTCN2022116770-appb-000247
以及承诺值元组
Figure PCTCN2022116770-appb-000248
上链,所述投票元组
Figure PCTCN2022116770-appb-000249
用作投票阶段的投票内容;
其中,签名元组
Figure PCTCN2022116770-appb-000250
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000251
进行验证,且在验证通过后生成的;承诺值元组
Figure PCTCN2022116770-appb-000252
用于对所述投票元组进行解密。
在本申请的一些实施例中,承诺单元21对原始投票内容进行散列运算,得到承诺值
Figure PCTCN2022116770-appb-000253
的过程,可以包括:
对原始投票内容m和字符串o进行哈希运算,得到承诺值
Figure PCTCN2022116770-appb-000254
其中,o为随机生成的字符串。
在本申请的一些实施例中,盲化单元22结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000255
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000256
Figure PCTCN2022116770-appb-000257
的过程,可以包括:
对于其他每一投票人的公钥信息pk j
Figure PCTCN2022116770-appb-000258
进行椭圆曲线ECC的点乘操作,得到盲化因子t j
基于盲化因子t j将承诺值
Figure PCTCN2022116770-appb-000259
哈希到新的承诺值x j及c j
汇聚各承诺值x j得到承诺值元组
Figure PCTCN2022116770-appb-000260
以及采用私钥sk i对各承诺值c j进行签名,得到承诺值元组
Figure PCTCN2022116770-appb-000261
在本申请的一些实施例中,签名单元23通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000262
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000263
的过程,可以包括:
对元组
Figure PCTCN2022116770-appb-000264
进行哈希运算,得到签名元组
Figure PCTCN2022116770-appb-000265
其中,ID i和addr i为目标投票人的身份标识及地址信息,
Figure PCTCN2022116770-appb-000266
为承诺值元组
Figure PCTCN2022116770-appb-000267
中对应于投票人n v的承诺值。
在本申请的一些实施例中,承诺单元21提及的散列输出还包括承诺值
Figure PCTCN2022116770-appb-000268
请参阅图4,该基于区块链的匿名可信投票装置还可以包括打开投票单元30,用于:
从区块链获取签名元组
Figure PCTCN2022116770-appb-000269
和承诺值元组
Figure PCTCN2022116770-appb-000270
并基于签名元组
Figure PCTCN2022116770-appb-000271
计算得到其他各投票人的签名元组
Figure PCTCN2022116770-appb-000272
基于承诺值
Figure PCTCN2022116770-appb-000273
和承诺值元组
Figure PCTCN2022116770-appb-000274
采用预设的算法VerifyS对
Figure PCTCN2022116770-appb-000275
的有效性进行验证,得到验证通过的各签名元素
Figure PCTCN2022116770-appb-000276
其中,
Figure PCTCN2022116770-appb-000277
是签名元组
Figure PCTCN2022116770-appb-000278
中对应于投票人n v的签名元素;
获取对应于验证通过的每一签名元素
Figure PCTCN2022116770-appb-000279
的承诺字符串
Figure PCTCN2022116770-appb-000280
并基于验 证通过的各签名元素
Figure PCTCN2022116770-appb-000281
构建新的签名元组
Figure PCTCN2022116770-appb-000282
基于各承诺字符串
Figure PCTCN2022116770-appb-000283
构建新的承诺元组
Figure PCTCN2022116770-appb-000284
采用随机地址将投票元组
Figure PCTCN2022116770-appb-000285
上链,投票元组
Figure PCTCN2022116770-appb-000286
用作打开投票阶段的投票内容。
在本申请的一些实施例中,请参阅图5,该基于区块链的匿名可信投票装置还可以包括验证计票单元40,用于:
从区块链获取投票元组
Figure PCTCN2022116770-appb-000287
并采用预设的算法V对签名元组
Figure PCTCN2022116770-appb-000288
进行验证;
若签名元组
Figure PCTCN2022116770-appb-000289
中超过预设比例的签名元素
Figure PCTCN2022116770-appb-000290
验证通过,则通过预设的算法从承诺元组
Figure PCTCN2022116770-appb-000291
Figure PCTCN2022116770-appb-000292
中验证原始投票内容。
在本申请的一些实施例中,验证计票单元40通过预设的算法从承诺元组
Figure PCTCN2022116770-appb-000293
Figure PCTCN2022116770-appb-000294
中验证原始投票内容的过程,可以包括:
对承诺元组
Figure PCTCN2022116770-appb-000295
进行字符串序列化运输,得到字符串序列化后的承诺元组
Figure PCTCN2022116770-appb-000296
对输入的原始投票内容m和字符串序列化后的承诺元组
Figure PCTCN2022116770-appb-000297
进行哈希运算,得到哈希值
Figure PCTCN2022116770-appb-000298
判断
Figure PCTCN2022116770-appb-000299
Figure PCTCN2022116770-appb-000300
是否相等,若是,则原始投票内容m验证通过。
本申请实施例提供的基于区块链的匿名可信投票装置可应用于基于区块链的匿名可信投票设备,如计算机等。可选的,图6示出了基于区块链的匿名可信投票设备的硬件结构框图,参照图6,基于区块链的匿名可信投票设备的硬件结构可以包括:至少一个处理器31,至少一个通信接口32,至少一个存储器33和至少一个通信总线34。
在本申请实施例中,处理器31、通信接口32、存储器33、通信总线34的数量为至少一个,且处理器31、通信接口32、存储器33通过通信总 线34完成相互间的通信;
处理器31可能是一个中央处理器CPU,或者是特定集成电路ASIC(Application Specific Integrated Circuit),或者是被配置成实施本申请实施例的一个或多个集成电路等;
存储器32可能包含高速RAM存储器,也可能还包括非易失性存储器(non-volatile memory)等,例如至少一个磁盘存储器;
其中,存储器33存储有程序,处理器31可调用存储器33存储的程序,所述程序用于:
对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
Figure PCTCN2022116770-appb-000301
结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000302
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000303
Figure PCTCN2022116770-appb-000304
通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000305
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000306
基于承诺值元组
Figure PCTCN2022116770-appb-000307
签名元组
Figure PCTCN2022116770-appb-000308
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000309
构建投票元组
Figure PCTCN2022116770-appb-000310
并将投票元组
Figure PCTCN2022116770-appb-000311
以及承诺值元组
Figure PCTCN2022116770-appb-000312
上链,所述投票元组
Figure PCTCN2022116770-appb-000313
用作投票阶段的投票内容;
其中,签名元组
Figure PCTCN2022116770-appb-000314
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000315
进行验证,且在验证通过后生成的;承诺值元组
Figure PCTCN2022116770-appb-000316
用于对所述投票元组进行解密。
可选的,所述程序的细化功能和扩展功能可参照上文描述。
本申请实施例还提供一种存储介质,该存储介质可存储有适于处理器执行的程序,所述程序用于:
对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
Figure PCTCN2022116770-appb-000317
结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000318
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000319
Figure PCTCN2022116770-appb-000320
通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000321
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000322
基于承诺值元组
Figure PCTCN2022116770-appb-000323
签名元组
Figure PCTCN2022116770-appb-000324
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000325
构建 投票元组
Figure PCTCN2022116770-appb-000326
并将投票元组
Figure PCTCN2022116770-appb-000327
以及承诺值元组
Figure PCTCN2022116770-appb-000328
上链,所述投票元组
Figure PCTCN2022116770-appb-000329
用作投票阶段的投票内容;
其中,签名元组
Figure PCTCN2022116770-appb-000330
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000331
进行验证,且在验证通过后生成的;承诺值元组
Figure PCTCN2022116770-appb-000332
用于对所述投票元组进行解密。
可选的,所述程序的细化功能和扩展功能可参照上文描述。
综上所述:
本申请首先对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
Figure PCTCN2022116770-appb-000333
所述散列运算使得原始投票内容能够得到较好的隐藏。然后,结合其他各投票人的信息对承诺值
Figure PCTCN2022116770-appb-000334
进行盲化处理,得到承诺值元组
Figure PCTCN2022116770-appb-000335
Figure PCTCN2022116770-appb-000336
经过盲化处理,使得投票人身份能够得到较好的隐藏。接着,通过ESDSA算法对承诺值元组
Figure PCTCN2022116770-appb-000337
进行签名,得到签名元组
Figure PCTCN2022116770-appb-000338
通过投票人自身对其承诺值元组进行签名,使得投票内容得到目标投票人本人的认证,并防止他人伪造投票内容。最后,基于承诺值元组
Figure PCTCN2022116770-appb-000339
签名元组
Figure PCTCN2022116770-appb-000340
以及其他各投票人的签名元组
Figure PCTCN2022116770-appb-000341
构建投票元组
Figure PCTCN2022116770-appb-000342
并将投票元组
Figure PCTCN2022116770-appb-000343
以及承诺值元组
Figure PCTCN2022116770-appb-000344
上链,所述投票元组
Figure PCTCN2022116770-appb-000345
用作投票阶段的投票内容。其中,签名元组
Figure PCTCN2022116770-appb-000346
为其他各投票人对签名元组
Figure PCTCN2022116770-appb-000347
进行验证,且在验证通过后生成的。通过其他各投票人的验证签名,使得目标投票人本人无法篡改投票内容。承诺值元组
Figure PCTCN2022116770-appb-000348
用于对所述投票元组进行解密,便于后续打开投票内容并进行计票。本申请通过上述处理过程,实现了投票内容隐藏、投票匿名及可验证。
进一步地,与传统的去中心化匿名投票方案相对,本申请具有去中心化、可追溯性和防篡改性等区块链特有的特性,此外,与其他基于区块链的分布式时间戳方案相比,本提案具有更高的效率。本申请高效实现了七个安全设计目标,即:公平性(确保任何人在提交自己的选票之前,不能获得他人的投票结果,意味着投票人的选择不会受到那些提前投票的人的影响)、去中心化(任何一种可信的第三方,比如选举管理员或独立观察员,都不应该出现在投票协议中)、合法性(在投票人开始投票之前,应检查他/她的权利;此外,合法性要求每个投票人只能投一次票)、匿名性(要求保护投票人的隐私,不能让任何人在最后的投票结果中知道选票的主人是 谁)、兼容性(要求投票方案应该尽可能简单,以便集成到能源互联网的信息化系统中)、可验证性(保证了投票的所有阶段都可以被投票人审计。此外,每张选票的有效性应该能够被任何人验证)、抵制胁迫性(为了避免有人试图强迫投票人按照他们的指示投票,一个投票方案应该是抵制胁迫的)。特别地,本申请是基于区块链实现的匿名可信投票方案,对比目前大量的采用PoW共识算法等平台实现的匿名可信投票方案,具有更快的交易处理。
最后,还需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。
本说明书中各个实施例采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间可以根据需要进行组合,且相同相似部分互相参见即可。
对所公开的实施例的上述说明,使本领域专业技术人员能够实现或使用本申请。对这些实施例的多种修改对本领域的专业技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本申请的精神或范围的情况下,在其它实施例中实现。因此,本申请将不会被限制于本文所示的这些实施例,而是要符合与本文所公开的原理和新颖特点相一致的最宽的范围。

Claims (10)

  1. 一种基于区块链的匿名可信投票方法,其特征在于,包括:
    对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
    Figure PCTCN2022116770-appb-100001
    结合其他各投票人的信息对承诺值
    Figure PCTCN2022116770-appb-100002
    进行盲化处理,得到承诺值元组
    Figure PCTCN2022116770-appb-100003
    Figure PCTCN2022116770-appb-100004
    通过ESDSA算法对承诺值元组
    Figure PCTCN2022116770-appb-100005
    进行签名,得到签名元组
    Figure PCTCN2022116770-appb-100006
    基于承诺值元组
    Figure PCTCN2022116770-appb-100007
    签名元组
    Figure PCTCN2022116770-appb-100008
    以及其他各投票人的签名元组
    Figure PCTCN2022116770-appb-100009
    构建投票元组
    Figure PCTCN2022116770-appb-100010
    并将投票元组
    Figure PCTCN2022116770-appb-100011
    以及承诺值元组
    Figure PCTCN2022116770-appb-100012
    上链,所述投票元组
    Figure PCTCN2022116770-appb-100013
    用作投票阶段的投票内容;
    其中,签名元组
    Figure PCTCN2022116770-appb-100014
    为其他各投票人对签名元组
    Figure PCTCN2022116770-appb-100015
    进行验证,且在验证通过后生成的;承诺值元组
    Figure PCTCN2022116770-appb-100016
    用于对所述投票元组进行解密。
  2. 根据权利要求1所述的方法,其特征在于,所述对原始投票内容进行散列运算,得到承诺值
    Figure PCTCN2022116770-appb-100017
    的过程,包括:
    对原始投票内容m和字符串o进行哈希运算,得到承诺值
    Figure PCTCN2022116770-appb-100018
    其中,o为随机生成的字符串。
  3. 根据权利要求1所述的方法,其特征在于,所述结合其他各投票人的信息对承诺值
    Figure PCTCN2022116770-appb-100019
    进行盲化处理,得到承诺值元组
    Figure PCTCN2022116770-appb-100020
    Figure PCTCN2022116770-appb-100021
    的过程,包括:
    对于其他每一投票人的公钥信息pk j
    Figure PCTCN2022116770-appb-100022
    进行椭圆曲线ECC的点乘操作,得到盲化因子t j
    基于盲化因子t j将承诺值
    Figure PCTCN2022116770-appb-100023
    哈希到新的承诺值x j及c j
    汇聚各承诺值x j得到承诺值元组
    Figure PCTCN2022116770-appb-100024
    以及采用私钥sk i对各承诺值c j进行签名,得到承诺值元组
    Figure PCTCN2022116770-appb-100025
  4. 根据权利要求1所述的方法,其特征在于,所述通过ESDSA算法对承诺值元组
    Figure PCTCN2022116770-appb-100026
    进行签名,得到签名元组
    Figure PCTCN2022116770-appb-100027
    的过程,包括:
    对元组
    Figure PCTCN2022116770-appb-100028
    进行哈希运算,得到签名元组
    Figure PCTCN2022116770-appb-100029
    其中,ID i和addr i为目标投票人的身份标识及地址信息,
    Figure PCTCN2022116770-appb-100030
    为承诺值元组
    Figure PCTCN2022116770-appb-100031
    中对应于投票人n v的承诺值。
  5. 根据权利要求1所述的方法,其特征在于,所述散列输出还包括承诺值
    Figure PCTCN2022116770-appb-100032
    所述方法还包括:
    从区块链获取签名元组
    Figure PCTCN2022116770-appb-100033
    和承诺值元组
    Figure PCTCN2022116770-appb-100034
    并基于签名元组
    Figure PCTCN2022116770-appb-100035
    计算得到其他各投票人的签名元组
    Figure PCTCN2022116770-appb-100036
    基于承诺值
    Figure PCTCN2022116770-appb-100037
    和承诺值元组
    Figure PCTCN2022116770-appb-100038
    采用预设的算法VerifyS对
    Figure PCTCN2022116770-appb-100039
    的有效性进行验证,得到验证通过的各签名元素
    Figure PCTCN2022116770-appb-100040
    其中,
    Figure PCTCN2022116770-appb-100041
    是签名元组
    Figure PCTCN2022116770-appb-100042
    中对应于投票人n v的签名元素;
    获取对应于验证通过的每一签名元素
    Figure PCTCN2022116770-appb-100043
    的承诺字符串
    Figure PCTCN2022116770-appb-100044
    并基于验证通过的各签名元素
    Figure PCTCN2022116770-appb-100045
    构建新的签名元组
    Figure PCTCN2022116770-appb-100046
    基于各承诺字符串
    Figure PCTCN2022116770-appb-100047
    构建新的承诺元组
    Figure PCTCN2022116770-appb-100048
    采用随机地址将投票元组
    Figure PCTCN2022116770-appb-100049
    上链,投票元组
    Figure PCTCN2022116770-appb-100050
    用作打开投票阶段的投票内容。
  6. 根据权利要求5所述的方法,其特征在于,还包括:
    从区块链获取投票元组
    Figure PCTCN2022116770-appb-100051
    并采用预设的算法V对签名元组
    Figure PCTCN2022116770-appb-100052
    进行验证;
    若签名元组
    Figure PCTCN2022116770-appb-100053
    中超过预设比例的签名元素
    Figure PCTCN2022116770-appb-100054
    验证通过,则通过预设的算法从承诺元组
    Figure PCTCN2022116770-appb-100055
    Figure PCTCN2022116770-appb-100056
    中验证原始投票内容。
  7. 根据权利要求5所述的方法,其特征在于,所述通过预设的算法从承诺元组
    Figure PCTCN2022116770-appb-100057
    Figure PCTCN2022116770-appb-100058
    中验证原始投票内容的过程,包括:
    对承诺元组
    Figure PCTCN2022116770-appb-100059
    进行字符串序列化运输,得到字符串序列化后的承诺元 组
    Figure PCTCN2022116770-appb-100060
    对输入的原始投票内容m和字符串序列化后的承诺元组
    Figure PCTCN2022116770-appb-100061
    进行哈希运算,得到哈希值
    Figure PCTCN2022116770-appb-100062
    判断
    Figure PCTCN2022116770-appb-100063
    Figure PCTCN2022116770-appb-100064
    是否相等,若是,则原始投票内容m验证通过。
  8. 一种基于区块链的匿名可信投票装置,其特征在于,包括:
    承诺单元,用于对原始投票内容进行散列运算,得到散列输出,所述散列输出包括承诺值
    Figure PCTCN2022116770-appb-100065
    盲化单元,用于结合其他各投票人的信息对承诺值
    Figure PCTCN2022116770-appb-100066
    进行盲化处理,得到承诺值元组
    Figure PCTCN2022116770-appb-100067
    Figure PCTCN2022116770-appb-100068
    签名单元,用于通过ESDSA算法对承诺值元组
    Figure PCTCN2022116770-appb-100069
    进行签名,得到签名元组
    Figure PCTCN2022116770-appb-100070
    投票单元,用于基于承诺值元组
    Figure PCTCN2022116770-appb-100071
    签名元组
    Figure PCTCN2022116770-appb-100072
    以及其他各投票人的签名元组
    Figure PCTCN2022116770-appb-100073
    构建投票元组
    Figure PCTCN2022116770-appb-100074
    并将投票元组
    Figure PCTCN2022116770-appb-100075
    以及承诺值元组
    Figure PCTCN2022116770-appb-100076
    上链,所述投票元组
    Figure PCTCN2022116770-appb-100077
    用作投票阶段的投票内容;
    其中,签名元组
    Figure PCTCN2022116770-appb-100078
    为其他各投票人对签名元组
    Figure PCTCN2022116770-appb-100079
    进行验证,且在验证通过后生成的;承诺值元组
    Figure PCTCN2022116770-appb-100080
    用于对所述投票元组进行解密。
  9. 一种基于区块链的匿名可信投票设备,其特征在于,包括:存储器和处理器;
    所述存储器,用于存储程序;
    所述处理器,用于执行所述程序,实现如权利要求1~7中任一项所述的基于区块链的匿名可信投票方法的各个步骤。
  10. 一种存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时,实现如权利要求1~7中任一项所述的基于区块链的匿名可信投票方法的各个步骤。
PCT/CN2022/116770 2022-04-21 2022-09-02 一种基于区块链的匿名可信投票方法、装置及相关设备 WO2023201962A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210422851.XA CN114629660B (zh) 2022-04-21 2022-04-21 一种基于区块链的匿名可信投票方法、装置及相关设备
CN202210422851.X 2022-04-21

Publications (1)

Publication Number Publication Date
WO2023201962A1 true WO2023201962A1 (zh) 2023-10-26

Family

ID=81905331

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/116770 WO2023201962A1 (zh) 2022-04-21 2022-09-02 一种基于区块链的匿名可信投票方法、装置及相关设备

Country Status (2)

Country Link
CN (1) CN114629660B (zh)
WO (1) WO2023201962A1 (zh)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114629660B (zh) * 2022-04-21 2024-03-08 南方电网科学研究院有限责任公司 一种基于区块链的匿名可信投票方法、装置及相关设备
CN116436979B (zh) * 2023-06-15 2023-08-11 湖南湘江树图信息科技创新中心有限公司 联盟区块链调用外部服务的方法及系统

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104392534A (zh) * 2014-11-21 2015-03-04 西南交通大学 一种基于手指静脉特征识别的电子投票系统
CN108833082A (zh) * 2018-06-25 2018-11-16 东北大学秦皇岛分校 一种基于区块链去中心化的隐私保护投票系统
CN114629660A (zh) * 2022-04-21 2022-06-14 南方电网科学研究院有限责任公司 一种基于区块链的匿名可信投票方法、装置及相关设备

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107833135A (zh) * 2017-10-30 2018-03-23 中山大学 一种基于区块链的公平电子投票协议
CN108109257A (zh) * 2018-01-05 2018-06-01 杭州电子科技大学 一种基于区块链的匿名电子投票方法
FR3091108B1 (fr) * 2018-12-24 2022-11-04 Orange Procédé et système de vote électronique
CN109903450B (zh) * 2019-03-28 2021-04-09 深圳职业技术学院 电子投票方法以及系统
CN110232764B (zh) * 2019-05-16 2021-09-21 暨南大学 基于区块链的匿名电子投票方法及系统
CN111612457A (zh) * 2020-04-27 2020-09-01 深圳壹账通智能科技有限公司 基于区块链的电子投票方法、装置及存储介质

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104392534A (zh) * 2014-11-21 2015-03-04 西南交通大学 一种基于手指静脉特征识别的电子投票系统
CN108833082A (zh) * 2018-06-25 2018-11-16 东北大学秦皇岛分校 一种基于区块链去中心化的隐私保护投票系统
CN114629660A (zh) * 2022-04-21 2022-06-14 南方电网科学研究院有限责任公司 一种基于区块链的匿名可信投票方法、装置及相关设备

Also Published As

Publication number Publication date
CN114629660A (zh) 2022-06-14
CN114629660B (zh) 2024-03-08

Similar Documents

Publication Publication Date Title
WO2023201962A1 (zh) 一种基于区块链的匿名可信投票方法、装置及相关设备
Lin et al. A new transitively closed undirected graph authentication scheme for blockchain-based identity management systems
Tsaur et al. A smart card-based remote scheme for password authentication in multi-server Internet services
JP2019053269A (ja) 電子投票によって収集した投票者の票を判定するシステムおよび方法
CN113129518B (zh) 电动车辆充电系统及其资源管理方法
CN109413078B (zh) 一种基于标准模型下群签名的匿名认证方法
Goodrich et al. Super-efficient verification of dynamic outsourced databases
CN111612600A (zh) 区块链拍卖方法、设备、存储介质及区块链系统
CN113221089A (zh) 基于可验证声明的隐私保护属性认证系统及方法
Nguyen Thi et al. Enhanced security in internet voting protocol using blind signatures and dynamic ballots
Miao et al. Blockchain assisted multi-copy provable data possession with faults localization in multi-cloud storage
CN114866259B (zh) 一种基于秘密分享的区块链受控可追溯身份隐私方法
CN111817855A (zh) 基于以太坊区块链的电子投票方法及系统
Lin et al. Blockchain-based complete self-tallying E-voting protocol
US20220239502A1 (en) System to Securely Issue and Count Electronic Ballots
Wang et al. Cryptanalysis of a public authentication protocol for outsourced databases with multi-user modification
CN112733192B (zh) 基于联盟链同态加密的司法电子证据系统及方法
Liu et al. A blockchain-based cross-domain authentication management system for IoT devices
CN115147975B (zh) 一种基于区块链的加密网络投票方法
WO2019174404A1 (zh) 一种群组数字签名、验证方法及其设备和装置
JPH10285157A (ja) 認証システムにおける登録鍵重複防止装置
Helbach et al. Code voting with linkable group signatures
Lu et al. Self-tallying e-voting with public traceability based on blockchain
Haghighat et al. An efficient and provably-secure coercion-resistant e-voting protocol
Lijuan et al. Electronic Voting Scheme Based on Blockchain and SM2 Cryptographic Algorithm Zero-Knowledge Proof

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: 22938187

Country of ref document: EP

Kind code of ref document: A1