Nothing Special   »   [go: up one dir, main page]

CN108711212A - Card method, apparatus and system are deposited in ballot - Google Patents

Card method, apparatus and system are deposited in ballot Download PDF

Info

Publication number
CN108711212A
CN108711212A CN201810491132.7A CN201810491132A CN108711212A CN 108711212 A CN108711212 A CN 108711212A CN 201810491132 A CN201810491132 A CN 201810491132A CN 108711212 A CN108711212 A CN 108711212A
Authority
CN
China
Prior art keywords
block
node
information
ballot
voting
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
CN201810491132.7A
Other languages
Chinese (zh)
Other versions
CN108711212B (en
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.)
China United Network Communications Group Co Ltd
Original Assignee
China United Network Communications Group 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 China United Network Communications Group Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN201810491132.7A priority Critical patent/CN108711212B/en
Publication of CN108711212A publication Critical patent/CN108711212A/en
Application granted granted Critical
Publication of CN108711212B publication Critical patent/CN108711212B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/3226Cryptographic 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 a predetermined code, e.g. password, passphrase or PIN
    • 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
    • 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

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

本发明提供一种投票存证方法、装置及系统,该方法,包括:在预设时间段内接收投票者节点发送的投票信息;对所述投票信息进行验证,并根据验证结果生成投票区块,其中,验证通过的投票信息为有效票信息,验证失败的投票信息为无效票信息;将所述投票区块发送给区块链网络中的所有节点;其中,所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;获取所述区块链网络中的所有节点对所述投票区块的验证结果;若所述投票区块的验证结果为通过,则控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息,得到投票结果。本发明可以记录每个投票者的投票信息,形成真实可靠,不可篡改的投票记录,保证投票结果的可靠性。

The present invention provides a voting certificate storage method, device and system. The method includes: receiving voting information sent by a voter node within a preset time period; verifying the voting information, and generating a voting block according to the verification result , wherein, the voting information that passes the verification is valid ticket information, and the voting information that fails the verification is invalid ticket information; the voting block is sent to all nodes in the blockchain network; wherein, the voting information in the blockchain network The nodes include: an auditor node, a voter node, and a vote counter node; obtain the verification results of the voting block from all nodes in the blockchain network; if the verification result of the voting block is passed, then Controlling the vote counter node to count valid vote information and invalid vote information in the voting block to obtain a voting result. The present invention can record the voting information of each voter, form a true and reliable voting record that cannot be tampered with, and guarantee the reliability of the voting result.

Description

投票存证方法、装置及系统Voting certificate storage method, device and system

技术领域technical field

本发明涉及数据处理技术领域,尤其涉及一种投票存证方法、装置及系统。The present invention relates to the technical field of data processing, in particular to a voting certificate storage method, device and system.

背景技术Background technique

随着网络技术的发展,传统的投票方式正在逐渐被电子投票系统所替代。With the development of network technology, traditional voting methods are gradually being replaced by electronic voting systems.

现有的电子投票系统,在投票过程需要有一个中心化组织,用于接收投票者的选票信息,并对这些信息进行统计后形成最终的投票结果。这也意味着,投票者将投票信息发送给选票接受系统,由选票接受系统的运维方(中心化组织)进行存储、统计,并发布最终结果。In the existing electronic voting system, a centralized organization is required in the voting process to receive the ballot information of voters, and to form the final voting result after counting the information. This also means that voters send voting information to the ballot acceptance system, and the operation and maintenance party (centralized organization) of the ballot acceptance system stores, counts, and publishes the final results.

但是,通过中心化组织对选票进行统计的方式,无法避免中心化组织对投票者投票的篡改行为。虽然可以通过引入监管机构对选票的统计过程进行监督,但是仍然存在选票被人为篡改的可能,从而影响投票的公正性。However, it is impossible to avoid the tampering of voters' votes by the centralized organization through the way of counting the votes by the centralized organization. Although it is possible to supervise the counting process of ballots by introducing regulatory agencies, there is still the possibility of ballots being tampered with, thereby affecting the fairness of voting.

发明内容Contents of the invention

本发明提供一种投票存证方法、装置及系统,以避免投票信息被篡改,保证投票结果的可靠性。The invention provides a voting certificate storage method, device and system, so as to avoid tampering of voting information and ensure the reliability of voting results.

第一方面,本发明实施例提供一种投票存证方法,包括:In the first aspect, the embodiment of the present invention provides a method for voting certificate deposit, including:

在预设时间段内接收投票者节点发送的投票信息;Receive the voting information sent by the voter node within the preset time period;

对所述投票信息进行验证,并根据验证结果生成投票区块,其中,验证通过的投票信息为有效票信息,验证失败的投票信息为无效票信息;Verifying the voting information, and generating a voting block according to the verification result, wherein the voting information that passes the verification is valid ticket information, and the voting information that fails the verification is invalid ticket information;

将所述投票区块发送给区块链网络中的所有节点;其中,所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;Send the voting block to all nodes in the blockchain network; wherein, the nodes in the blockchain network include: auditor nodes, voter nodes, and vote counter nodes;

获取所述区块链网络中的所有节点对所述投票区块的验证结果;Obtain the verification results of all nodes in the blockchain network for the voting block;

若所述投票区块的验证结果为通过,则控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息,得到投票结果。If the verification result of the voting block is passed, the vote counter node is controlled to count the valid vote information and invalid vote information in the voting block to obtain the voting result.

可选地,所述在预设时间段内接收投票者节点发送的投票信息之前,还包括:Optionally, before receiving the voting information sent by the voter node within the preset time period, it also includes:

接收区块链网络中的所有节点发布的公钥、身份信息,并将所述公钥、身份信息打包成创始区块;其中,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;Receive the public key and identity information issued by all nodes in the blockchain network, and pack the public key and identity information into a genesis block; wherein, the block header of the genesis block records the current genesis block hash value, timestamp, hash value of the previous block;

将所述创始区块发送给所述区块链网络中的所有节点;sending the genesis block to all nodes in the blockchain network;

获取所述区块链网络中的所有节点对所述创始区块的验证结果;Obtain the verification results of all nodes in the blockchain network for the genesis block;

若所述创始区块的验证结果为通过,则控制所述投票者节点发送投票信息;其中,所述投票信息采用对应投票者节点的私钥进行签名处理。If the verification result of the founding block is passed, the voter node is controlled to send voting information; wherein, the voting information is signed with the private key of the corresponding voter node.

可选地,所述对所述投票信息进行验证,并根据验证结果生成投票区块,包括:Optionally, the verifying the voting information and generating a voting block according to the verification result includes:

根据所述创始区块中存储的公钥、身份信息,对预设时间段内接收到的投票信息进行验证;Verify the voting information received within the preset time period according to the public key and identity information stored in the genesis block;

若所述创始区块中存储的公钥、身份信息与所述投票信息对应的私钥匹配,则验证通过;If the public key and identity information stored in the genesis block match the private key corresponding to the voting information, the verification is passed;

根据预设时间段内接收到的所有投票信息的验证结果生成投票区块;其中,所述投票区块的区块头中记录了当前投票区块的hash值、时间戳、前一区块的hash值。A voting block is generated according to the verification results of all voting information received within a preset time period; wherein, the hash value of the current voting block, the timestamp, and the hash of the previous block are recorded in the block header of the voting block value.

可选地,获取所述区块链网络中的所有节点对所述投票区块的验证结果,包括:Optionally, obtaining verification results of all nodes in the blockchain network for the voting block, including:

接收所述区块链网络中每个节点对所述投票区块的验证结果;receiving the verification result of each node in the blockchain network for the voting block;

统计所述区块链网络中所有节点针对所述投票区块的通过率;Count the pass rate of all nodes in the blockchain network for the voting block;

若所述通过率大于第一预设值,则确定所述投票区块的验证通过;If the pass rate is greater than a first preset value, it is determined that the verification of the voting block is passed;

若所述通过率小于或等于第一预设值,则确定所述投票区块的验证失败,重新根据投票信息的验证结果生成新的投票区块。If the pass rate is less than or equal to the first preset value, it is determined that the verification of the voting block fails, and a new voting block is generated again according to the verification result of the voting information.

可选地,获取所述区块链网络中的所有节点对所述创始区块的验证结果,包括:Optionally, obtaining the verification results of all nodes in the blockchain network for the genesis block, including:

接收所述区块链网络中每个节点对所述创始区块的验证结果;receiving the verification result of each node in the blockchain network for the founding block;

统计所述区块链网络中所有节点针对所述创始区块的通过率;Count the pass rate of all nodes in the blockchain network for the founding block;

若所述通过率大于第二预设值,则确定所述创始区块的验证通过;If the pass rate is greater than a second preset value, it is determined that the verification of the creation block is passed;

若所述通过率小于或等于第二预设值,则确定所述创始区块的验证失败,重新根据投票信息的验证结果生成新的创始区块。If the pass rate is less than or equal to the second preset value, it is determined that the verification of the creation block fails, and a new creation block is generated again according to the verification result of the voting information.

第二方面,本发明实施例提供一种投票存证方法,包括:In the second aspect, an embodiment of the present invention provides a method for voting certificate deposit, including:

在预设时间段内向审计者节点发送投票信息;Send voting information to the auditor node within the preset time period;

接收所述审计者节点发送的投票区块;Receive the voting block sent by the auditor node;

对所述投票区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果。The voting block is verified, and the verification result of the voting block is sent to the auditor node.

可选地,所述在预设时间段内向审计者节点发送投票信息之前,还包括:Optionally, before sending the voting information to the auditor node within the preset time period, it also includes:

向所述审计者节点发送公钥、身份信息;Send the public key and identity information to the auditor node;

接收所述审计者节点发送的创始区块,所述创始区块是由所述审计者节点根据区块链网络中的所有节点发布的公钥、身份信息打包生成的,其中,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;Receive the genesis block sent by the auditor node, the genesis block is generated by the auditor node according to the public key and identity information issued by all nodes in the blockchain network, wherein the genesis block The hash value of the current genesis block, the timestamp, and the hash value of the previous block are recorded in the block header of the block; the nodes in the blockchain network include: auditor nodes, voter nodes, and vote counter nodes;

对所述创始区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果;Verifying the genesis block, and sending the verification result of the voting block to the auditor node;

若所述创始区块的验证结果为通过,则采用私钥对投票信息进行签名处理,得到处理后的投票信息。If the verification result of the genesis block is passed, the voting information is signed using the private key to obtain the processed voting information.

可选地,所述对所述投票区块进行验证,包括:Optionally, the verifying the voting block includes:

根据发送的投票信息,对所述投票区块中存储的对应投票节点的投票信息进行验证;Verifying the voting information of the corresponding voting node stored in the voting block according to the sent voting information;

若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息一致,则验证通过;If the sent voting information is consistent with the voting information of the corresponding voting node stored in the voting block, the verification is passed;

若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息不一致,则验证失败。If the sent voting information is inconsistent with the voting information of the corresponding voting node stored in the voting block, the verification fails.

可选地,所述对所述创始区块进行验证,包括:Optionally, the verification of the creation block includes:

根据预先接收到的区块链网络中的所有节点发布的公钥、身份信息,对所述创始区块中存储的所有节点的公钥、身份信息进行验证;Verify the public keys and identity information of all nodes stored in the genesis block according to the pre-received public keys and identity information issued by all nodes in the blockchain network;

若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息一致,则验证通过;If the public keys and identity information issued by all nodes in the blockchain network received in advance are consistent with the public keys and identity information of all nodes stored in the genesis block, the verification is passed;

若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息不一致,则验证失败。If the pre-received public keys and identity information issued by all nodes in the blockchain network are inconsistent with the public keys and identity information of all nodes stored in the genesis block, the verification fails.

可选地,还包括:Optionally, also include:

接收计票者节点发送的投票结果;其中,所述投票结果是在所述投票区块的验证结果为通过时,审计者节点通过控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息得到的。Receive the voting result sent by the voter node; wherein, the voting result is that when the verification result of the voting block is passed, the auditor node controls the voter node to count the valid votes in the voting block. Ticket information and invalid ticket information are obtained.

第三方面,本发明实施例提供一种投票存证装置,包括:In a third aspect, an embodiment of the present invention provides a voting certificate storage device, including:

接收模块,用于在预设时间段内接收投票者节点发送的投票信息;The receiving module is used to receive the voting information sent by the voter node within the preset time period;

验证模块,用于对所述投票信息进行验证,并根据验证结果生成投票区块,其中,验证通过的投票信息为有效票信息,验证失败的投票信息为无效票信息;The verification module is used to verify the voting information, and generate a voting block according to the verification result, wherein, the voting information that passes the verification is valid ticket information, and the voting information that fails the verification is invalid ticket information;

发送模块,用于将所述投票区块发送给区块链网络中的所有节点;其中,所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;A sending module, configured to send the voting block to all nodes in the blockchain network; wherein, the nodes in the blockchain network include: auditor nodes, voter nodes, and vote counter nodes;

获取模块,用于获取所述区块链网络中的所有节点对所述投票区块的验证结果;An acquisition module, configured to acquire verification results of the voting block by all nodes in the blockchain network;

控制模块,用于在所述投票区块的验证结果为通过时,控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息,得到投票结果。The control module is configured to control the vote counter node to count valid vote information and invalid vote information in the voting block when the verification result of the voting block is passed, to obtain a voting result.

可选地,所述接收模块,还用于在预设时间段内接收投票者节点发送的投票信息之前,接收区块链网络中的所有节点发布的公钥、身份信息,并将所述公钥、身份信息打包成创始区块;其中,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;Optionally, the receiving module is further configured to receive public keys and identity information issued by all nodes in the blockchain network before receiving voting information sent by voter nodes within a preset time period, and Key and identity information are packaged into a genesis block; wherein, the hash value of the current genesis block, the timestamp, and the hash value of the previous block are recorded in the block header of the genesis block;

将所述创始区块发送给所述区块链网络中的所有节点;sending the genesis block to all nodes in the blockchain network;

获取所述区块链网络中的所有节点对所述创始区块的验证结果;Obtain the verification results of all nodes in the blockchain network for the genesis block;

若所述创始区块的验证结果为通过,则控制所述投票者节点发送投票信息;其中,所述投票信息采用对应投票者节点的私钥进行签名处理。If the verification result of the founding block is passed, the voter node is controlled to send voting information; wherein, the voting information is signed with the private key of the corresponding voter node.

可选地,所述验证模块,具体用于:Optionally, the verification module is specifically used for:

根据所述创始区块中存储的公钥、身份信息,对预设时间段内接收到的投票信息进行验证;Verify the voting information received within the preset time period according to the public key and identity information stored in the genesis block;

若所述创始区块中存储的公钥、身份信息与所述投票信息对应的私钥匹配,则验证通过;If the public key and identity information stored in the genesis block match the private key corresponding to the voting information, the verification is passed;

根据预设时间段内接收到的所有投票信息的验证结果生成投票区块;其中,所述投票区块的区块头中记录了当前投票区块的hash值、时间戳、前一区块的hash值。A voting block is generated according to the verification results of all voting information received within a preset time period; wherein, the hash value of the current voting block, the timestamp, and the hash of the previous block are recorded in the block header of the voting block value.

可选地,所述获取模块,具体用于:Optionally, the acquisition module is specifically used for:

接收所述区块链网络中每个节点对所述投票区块的验证结果;receiving the verification result of each node in the blockchain network for the voting block;

统计所述区块链网络中所有节点针对所述投票区块的通过率;Count the pass rate of all nodes in the blockchain network for the voting block;

若所述通过率大于第一预设值,则确定所述投票区块的验证通过;If the pass rate is greater than a first preset value, it is determined that the verification of the voting block is passed;

若所述通过率小于或等于第一预设值,则确定所述投票区块的验证失败,重新根据投票信息的验证结果生成新的投票区块。If the pass rate is less than or equal to the first preset value, it is determined that the verification of the voting block fails, and a new voting block is generated again according to the verification result of the voting information.

可选地,获取所述区块链网络中的所有节点对所述创始区块的验证结果,包括:Optionally, obtaining the verification results of all nodes in the blockchain network for the genesis block, including:

接收所述区块链网络中每个节点对所述创始区块的验证结果;receiving the verification result of each node in the blockchain network for the founding block;

统计所述区块链网络中所有节点针对所述创始区块的通过率;Count the pass rate of all nodes in the blockchain network for the founding block;

若所述通过率大于第二预设值,则确定所述创始区块的验证通过;If the pass rate is greater than a second preset value, it is determined that the verification of the creation block is passed;

若所述通过率小于或等于第二预设值,则确定所述创始区块的验证失败,重新根据投票信息的验证结果生成新的创始区块。If the pass rate is less than or equal to the second preset value, it is determined that the verification of the creation block fails, and a new creation block is generated again according to the verification result of the voting information.

第四方面,本发明实施例提供一种投票存证装置,包括:In a fourth aspect, an embodiment of the present invention provides a voting certificate storage device, including:

发送模块,用于在预设时间段内向审计者节点发送投票信息;The sending module is used to send voting information to the auditor node within a preset time period;

接收模块,用于接收所述审计者节点发送的投票区块;A receiving module, configured to receive the voting block sent by the auditor node;

验证模块,用于对所述投票区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果。A verification module, configured to verify the voting block, and send the verification result of the voting block to the auditor node.

可选地,所述发送模块,还用于在预设时间段内向审计者节点发送投票信息之前,向所述审计者节点发送公钥、身份信息;Optionally, the sending module is further configured to send a public key and identity information to the auditor node before sending voting information to the auditor node within a preset time period;

所述接收模块,还用于接收所述审计者节点发送的创始区块,所述创始区块是由所述审计者节点根据区块链网络中的所有节点发布的公钥、身份信息打包生成的,其中,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;The receiving module is also used to receive the genesis block sent by the auditor node, the genesis block is generated by the auditor node according to the public key and identity information issued by all nodes in the blockchain network wherein, the block header of the genesis block records the hash value of the current genesis block, the timestamp, and the hash value of the previous block; the nodes in the blockchain network include: auditor nodes, voting voter node, vote counter node;

所述验证模块,还用于对所述创始区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果;The verification module is also used to verify the creation block, and send the verification result of the voting block to the auditor node;

若所述创始区块的验证结果为通过,则采用私钥对投票信息进行签名处理,得到处理后的投票信息。If the verification result of the genesis block is passed, the voting information is signed using the private key to obtain the processed voting information.

可选地,所述验证模块,具体用于:Optionally, the verification module is specifically used for:

根据发送的投票信息,对所述投票区块中存储的对应投票节点的投票信息进行验证;Verifying the voting information of the corresponding voting node stored in the voting block according to the sent voting information;

若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息一致,则验证通过;If the sent voting information is consistent with the voting information of the corresponding voting node stored in the voting block, the verification is passed;

若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息不一致,则验证失败。If the sent voting information is inconsistent with the voting information of the corresponding voting node stored in the voting block, the verification fails.

可选地,所述验证模块,具体用于:Optionally, the verification module is specifically used for:

根据预先接收到的区块链网络中的所有节点发布的公钥、身份信息,对所述创始区块中存储的所有节点的公钥、身份信息进行验证;Verify the public keys and identity information of all nodes stored in the genesis block according to the pre-received public keys and identity information issued by all nodes in the blockchain network;

若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息一致,则验证通过;If the public keys and identity information issued by all nodes in the blockchain network received in advance are consistent with the public keys and identity information of all nodes stored in the genesis block, the verification is passed;

若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息不一致,则验证失败。If the pre-received public keys and identity information issued by all nodes in the blockchain network are inconsistent with the public keys and identity information of all nodes stored in the genesis block, the verification fails.

可选地,所述接收模块,还用于:Optionally, the receiving module is also used for:

接收计票者节点发送的投票结果;其中,所述投票结果是在所述投票区块的验证结果为通过时,审计者节点通过控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息得到的。Receive the voting result sent by the voter node; wherein, the voting result is that when the verification result of the voting block is passed, the auditor node controls the voter node to count the valid votes in the voting block. Ticket information and invalid ticket information are obtained.

第五方面,本发明实施例提供一种投票存证系统,包括:In the fifth aspect, the embodiment of the present invention provides a voting certificate storage system, including:

存储器,用于存储程序;memory for storing programs;

处理器,用于执行所述存储器存储的所述程序,当所述程序被执行时,所述处理器用于执行如第一方面中任一项所述的方法,和/或如第二方面中任一项所述的方法。A processor, configured to execute the program stored in the memory, when the program is executed, the processor is configured to execute the method as described in any one of the first aspects, and/or as described in the second aspect any one of the methods described.

第六方面,本发明实施例提供一种计算机可读存储介质,包括:计算机程序,当其在计算机上运行时,使得计算机执行第一方面和/或如第二方面中任一所述的方法。In a sixth aspect, an embodiment of the present invention provides a computer-readable storage medium, including: a computer program that, when run on a computer, causes the computer to execute the method described in any one of the first aspect and/or the second aspect .

本发明提供的投票存证方法、装置及系统,通过在预设时间段内接收投票者节点发送的投票信息;对所述投票信息进行验证,并根据验证结果生成投票区块,其中,验证通过的投票信息为有效票信息,验证失败的投票信息为无效票信息;将所述投票区块发送给区块链网络中的所有节点;其中,所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;获取所述区块链网络中的所有节点对所述投票区块的验证结果;若所述投票区块的验证结果为通过,则控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息,得到投票结果。本发明可以记录每个投票者的投票信息,形成真实可靠,不可篡改的投票记录,保证投票结果的可靠性。The voting certificate storage method, device and system provided by the present invention receive the voting information sent by the voter node within a preset time period; verify the voting information, and generate a voting block according to the verification result, wherein the verification passes The voting information is valid vote information, and the voting information that fails to be verified is invalid vote information; the voting block is sent to all nodes in the blockchain network; wherein, the nodes in the blockchain network include: auditors Node, voter node, vote counter node; obtain the verification results of all nodes in the blockchain network for the voting block; if the verification result of the voting block is passed, then control the vote counting The voter node counts the valid vote information and invalid vote information in the voting block to obtain the voting result. The present invention can record the voting information of each voter, form an authentic and reliable voting record that cannot be tampered with, and guarantee the reliability of the voting result.

附图说明Description of drawings

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作一简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description These are some embodiments of the present invention. For those skilled in the art, other drawings can also be obtained according to these drawings without any creative effort.

图1为本发明实施例提供的应用场景的结构示意图;FIG. 1 is a schematic structural diagram of an application scenario provided by an embodiment of the present invention;

图2为本发明实施例一提供的投票存证方法的流程图;Fig. 2 is a flow chart of the voting certificate storage method provided by Embodiment 1 of the present invention;

图3为创始区块的结构示意图;Figure 3 is a schematic diagram of the structure of the genesis block;

图4为投票区块的结构示意图;Figure 4 is a schematic structural diagram of a voting block;

图5为本发明实施例二提供的投票存证方法的流程图;FIG. 5 is a flow chart of the method for depositing certificates by voting provided in Embodiment 2 of the present invention;

图6为本发明实施例三提供的投票存证装置的结构示意图;FIG. 6 is a schematic structural diagram of a voting certificate storage device provided by Embodiment 3 of the present invention;

图7为本发明实施例四提供的投票存证装置的结构示意图;Fig. 7 is a schematic structural diagram of a voting certificate storage device provided in Embodiment 4 of the present invention;

图8为本发明实施例五提供的投票存证系统的结构示意图。FIG. 8 is a schematic structural diagram of a voting certificate storage system provided by Embodiment 5 of the present invention.

具体实施方式Detailed ways

为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments It is a part of embodiments of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the protection scope of the present invention.

本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”、“第三”、“第四”等(如果存在)是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本发明的实施例例如能够以除了在这里图示或描述的那些以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。The terms "first", "second", "third", "fourth", etc. (if any) in the description and claims of the present invention and the above drawings are used to distinguish similar objects, and not necessarily Used to describe a specific sequence or sequence. It is to be understood that the data so used are interchangeable under appropriate circumstances such that the embodiments of the invention described herein are, for example, capable of practice in sequences other than those illustrated or described herein. Furthermore, the terms "comprising" and "having", as well as any variations thereof, are intended to cover a non-exclusive inclusion, for example, a process, method, system, product or device comprising a sequence of steps or elements is not necessarily limited to the expressly listed instead, may include other steps or elements not explicitly listed or inherent to the process, method, product or apparatus.

下面以具体地实施例对本发明的技术方案进行详细说明。下面这几个具体的实施例可以相互结合,对于相同或相似的概念或过程可能在某些实施例不再赘述。The technical solution of the present invention will be described in detail below with specific embodiments. The following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.

以下,对本申请中的部分用语进行解释说明,以便于本领域技术人员理解:Below, some terms in this application are explained, so that those skilled in the art can understand:

1)区块链(Blockchain)是利用块链式数据结构来验证与存储数据、利用分布式节点共识算法来生成和更新数据、利用密码学的方式保证数据传输和访问的安全、利用由自动化脚本代码组成的智能合约来编程和操作数据的一种全新的分布式基础架构与计算方式。1) Blockchain (Blockchain) uses block chain data structure to verify and store data, uses distributed node consensus algorithm to generate and update data, and uses cryptography to ensure the security of data transmission and access. A new distributed infrastructure and computing method for programming and manipulating data through smart contracts composed of code.

图1为本发明实施例提供的应用场景的结构示意图,如图1所示,多个节点构成的区块链网络,多个所述节点包括:审计者节点1、投票者节点2、计票者节点3。在区块链网络中,可以选择一个节点作为审计者节点,一个节点作为计票者节点,其余的节点作为投票者节点。如图1所示,投票者节点2的数量可以为多个,并且区块链网络中任意节点之间可以实现数据的传输,例如以广播方式向其他节点发送信息。审计者节点1、投票者节点2、计票者节点3是根据其在投票过程中所扮演的角色,或者说是执行的功能进行划分的。任意节点均可以根据设定执行审计者节点1、投票者节点2、计票者节点3中的任一功能。具体地,审计者节点1主要用于接收投票者节点发送的投票信息,并创建投票区块;投票者节点2用于发起投票,并将投票信息发送给审计者节点1进行验证;计票者节点3用于在投票结束后对所述投票区块中的投票信息进行统计,以得到投票结果。在整个投票过程中,区块链网络中的任何一个节点都对其他节点进行监管,使得投票信息不可被篡改,从而确保了投票结果的可靠性。Fig. 1 is a schematic structural diagram of an application scenario provided by an embodiment of the present invention. As shown in Fig. 1 , a block chain network composed of multiple nodes, the multiple nodes include: auditor node 1, voter node 2, vote counting node Or node 3. In the blockchain network, one node can be selected as the auditor node, one node as the voter node, and the rest of the nodes as voter nodes. As shown in Figure 1, the number of voter nodes 2 can be multiple, and data transmission can be realized between any nodes in the blockchain network, for example, sending information to other nodes by broadcasting. Auditor node 1, voter node 2, and voter node 3 are divided according to their roles in the voting process, or the functions they perform. Any node can perform any function of auditor node 1, voter node 2, and vote counter node 3 according to the settings. Specifically, the auditor node 1 is mainly used to receive the voting information sent by the voter node and create a voting block; the voter node 2 is used to initiate a vote and send the voting information to the auditor node 1 for verification; Node 3 is used to count the voting information in the voting block after the voting is over, so as to obtain the voting result. During the entire voting process, any node in the blockchain network supervises other nodes, so that the voting information cannot be tampered with, thereby ensuring the reliability of the voting results.

下面以具体地实施例对本发明的技术方案以及本申请的技术方案如何解决上述技术问题进行详细说明。下面这几个具体的实施例可以相互结合,对于相同或相似的概念或过程可能在某些实施例中不再赘述。下面将结合附图,对本发明的实施例进行描述。The technical solution of the present invention and how the technical solution of the present application solves the above technical problems will be described in detail below with specific embodiments. The following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present invention will be described below with reference to the accompanying drawings.

图2为本发明实施例一提供的投票存证方法的流程图,如图2所示,本实施例中的方法可以包括:Fig. 2 is a flow chart of the voting certificate storage method provided by Embodiment 1 of the present invention. As shown in Fig. 2, the method in this embodiment may include:

S101、在预设时间段内接收投票者节点发送的投票信息。S101. Receive voting information sent by a voter node within a preset time period.

本实施例应用在包含审计者节点、投票者节点、计票者节点所构成的区块链网络中;参见图1,预先设置包含多个节点的区块链网络中各个节点的功能。需要说明的是,本实施例区块链网络中所有的节点都参与整个投票和审票过程,各个节点之间相互独立,采用点对点的方式组成网络。This embodiment is applied in a blockchain network composed of auditor nodes, voter nodes, and vote counter nodes; referring to FIG. 1 , the functions of each node in a blockchain network including multiple nodes are preset. It should be noted that all nodes in the blockchain network of this embodiment participate in the entire voting and review process, each node is independent of each other, and forms a network in a point-to-point manner.

可选地,在预设时间段内接收投票者节点发送的投票信息之前,所述区块链网络中的节点生成公私钥对以及身份信息,并向该区块链网络中的其他节点发布公钥、身份信息。审计者节点接收区块链网络中的所有节点发布的公钥、身份信息,并将所述公钥、身份信息打包成创始区块;将所述创始区块发送给所述区块链网络中的所有节点;获取所述区块链网络中的所有节点对所述创始区块的验证结果;若所述创始区块的验证结果为通过,则控制所述投票者节点发送投票信息;其中,所述投票信息采用对应投票者节点的私钥进行签名处理。Optionally, before receiving the voting information sent by the voter node within a preset period of time, the nodes in the blockchain network generate public-private key pairs and identity information, and issue public and private key pairs to other nodes in the blockchain network. key, identity information. The auditor node receives the public key and identity information issued by all nodes in the blockchain network, and packages the public key and identity information into a genesis block; sends the genesis block to the blockchain network all nodes of the block chain network; obtain the verification results of all nodes in the blockchain network to the genesis block; if the verification result of the genesis block is passed, then control the voter node to send voting information; wherein, The voting information is signed using the private key of the corresponding voter node.

可选地,获取所述区块链网络中的所有节点对所述创始区块的验证结果,包括:接收所述区块链网络中每个节点对所述创始区块的验证结果;统计所述区块链网络中所有节点针对所述创始区块的通过率;若所述通过率大于第二预设值,则确定所述创始区块的验证通过;若所述通过率小于或等于第二预设值,则确定所述创始区块的验证失败,重新根据投票信息的验证结果生成新的创始区块。具体地,假设第二预设值为50%,表明如果区块链网络中有一半以上的节点对所述创始区块验证通过,那么该创始区块的验证结果为通过。需要说明的是,第二预设值可以根据实际需要进行调整,本实施例中不对第二预设值的具体取值进行限定。Optionally, obtaining the verification results of all nodes in the blockchain network for the genesis block includes: receiving the verification results of each node in the blockchain network for the genesis block; The pass rate of all nodes in the block chain network for the genesis block; if the pass rate is greater than the second preset value, it is determined that the verification of the genesis block is passed; if the pass rate is less than or equal to the first two preset values, it is determined that the verification of the creation block fails, and a new creation block is generated again according to the verification result of the voting information. Specifically, assuming that the second preset value is 50%, it indicates that if more than half of the nodes in the blockchain network pass the verification of the founding block, then the verification result of the founding block is passed. It should be noted that the second preset value can be adjusted according to actual needs, and the specific value of the second preset value is not limited in this embodiment.

图3为创始区块的结构示意图,如图3所示,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;且该创始区块中保存了区块链网络中所有节点的公钥、身份信息。Fig. 3 is a structural schematic diagram of the genesis block, as shown in Fig. 3, the hash value of the current genesis block, the timestamp, and the hash value of the previous block are recorded in the block header of the genesis block; and the genesis block The block stores the public keys and identity information of all nodes in the blockchain network.

本实施例中,审计者节点在预设时间段内接收投票者节点发送的投票信息。需要说明的是,预设时间段可以根据实际情况进行调整,例如开放投票的有效时间段为1小时,那么审计者节点仅接受在该1个小时内的投票信息。In this embodiment, the auditor node receives the voting information sent by the voter node within a preset time period. It should be noted that the preset time period can be adjusted according to the actual situation. For example, if the valid time period for open voting is 1 hour, then the auditor node will only accept voting information within the 1 hour.

S102、对所述投票信息进行验证,并根据验证结果生成投票区块。S102. Verify the voting information, and generate a voting block according to the verification result.

可选地,审计者节点根据所述创始区块中存储的公钥、身份信息,对预设时间段内接收到的投票信息进行验证;若所述创始区块中存储的公钥、身份信息与所述投票信息对应的私钥匹配,则验证通过;根据预设时间段内接收到的所有投票信息的验证结果生成投票区块。Optionally, the auditor node verifies the voting information received within a preset time period according to the public key and identity information stored in the genesis block; if the public key and identity information stored in the genesis block If the private key corresponding to the voting information matches, the verification is passed; and a voting block is generated according to the verification results of all voting information received within a preset time period.

图4为投票区块的结构示意图,如图4所示,所述投票区块的区块头中记录了当前投票区块的hash值、时间戳、前一区块的hash值;且该投票区块中保存了有效票信息和无效票的信息。具体地,有效票信息和无效票信息中都可以包含投票者节点的身份信息。Fig. 4 is the structural representation of voting block, as shown in Fig. 4, the hash value of current voting block, timestamp, the hash value of previous block are recorded in the block head of described voting block; And this voting area The valid ticket information and the invalid ticket information are stored in the block. Specifically, both the valid ticket information and the invalid ticket information may contain the identity information of the voter node.

本实施例中,将审计者节点验证通过的投票信息作为有效票信息,验证失败的投票信息作为无效票信息,并创建投票区块来保存有效票信息和无效票信息。In this embodiment, the voting information passed by the auditor node verification is regarded as valid ticket information, and the voting information failed to be verified is regarded as invalid ticket information, and a voting block is created to store valid ticket information and invalid ticket information.

S103、将所述投票区块发送给区块链网络中的所有节点。S103. Send the voting block to all nodes in the blockchain network.

本实施例中,审计者节点将所述投票区块发送给区块链网络中所有节点,例如:审计者节点、投票者节点、计票者节点等均可以接收到该投票区块。In this embodiment, the auditor node sends the voting block to all nodes in the blockchain network, for example, the auditor node, voter node, vote counter node, etc. can all receive the voting block.

S104、获取所述区块链网络中的所有节点对所述投票区块的验证结果。S104. Obtain verification results of the voting block by all nodes in the blockchain network.

本实施例中,审计者节点可以接收所述区块链网络中每个节点对所述投票区块的验证结果;统计所述区块链网络中所有节点针对所述投票区块的通过率;若所述通过率大于第一预设值,则确定所述投票区块的验证通过;若所述通过率小于或等于第一预设值,则确定所述投票区块的验证失败,重新根据投票信息的验证结果生成新的投票区块。In this embodiment, the auditor node can receive the verification result of each node in the blockchain network for the voting block; count the pass rate of all nodes in the blockchain network for the voting block; If the pass rate is greater than the first preset value, it is determined that the verification of the voting block is passed; The verification result of the voting information generates a new voting block.

S105、若所述投票区块的验证结果为通过,则控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息,得到投票结果。S105. If the verification result of the voting block is passed, control the vote counter node to count valid vote information and invalid vote information in the voting block to obtain a voting result.

本实施例中,假设统计所述投票区块的通过率大于50%,则可以认为所述投票区块的验证结果为通过,此时,计票者节点开始统计所述投票区块中的有效票信息和无效票信息,得到投票结果。最后,计票者节点可以以广播的形式将投票结果发布给所述区块链网络中的其他节点。需要说明的是,第一预设值可以根据实际情况进行调整,本实施例仅以50%为例进行举例说明,并不对第一预设值进行限定。In this embodiment, assuming that the pass rate of the voting block is greater than 50%, it can be considered that the verification result of the voting block is passed. vote information and invalid vote information to get the voting result. Finally, the voter node can broadcast the voting result to other nodes in the blockchain network. It should be noted that the first preset value can be adjusted according to actual conditions, and this embodiment only uses 50% as an example for illustration, and does not limit the first preset value.

本实施例,通过在预设时间段内接收投票者节点发送的投票信息;对所述投票信息进行验证,并根据验证结果生成投票区块,其中,验证通过的投票信息为有效票信息,验证失败的投票信息为无效票信息;将所述投票区块发送给区块链网络中的所有节点;其中,所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;获取所述区块链网络中的所有节点对所述投票区块的验证结果;若所述投票区块的验证结果为通过,则控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息,得到投票结果。本发明可以记录每个投票者的投票信息,形成真实可靠,不可篡改的投票记录,保证投票结果的可靠性。In this embodiment, by receiving the voting information sent by the voter node within a preset time period; verifying the voting information, and generating a voting block according to the verification result, wherein the verified voting information is valid ticket information, and the verification The failed voting information is invalid vote information; the voting block is sent to all nodes in the blockchain network; wherein, the nodes in the blockchain network include: auditor nodes, voter nodes, and vote counters node; obtain the verification results of all nodes in the block chain network to the voting block; if the verification result of the voting block is passed, then control the vote counter node to count the votes in the voting block Valid vote information and invalid vote information to get the voting result. The present invention can record the voting information of each voter, form an authentic and reliable voting record that cannot be tampered with, and guarantee the reliability of the voting result.

图5为本发明实施例二提供的投票存证方法的流程图,如图5所示,本实施例中的方法可以包括:Fig. 5 is a flow chart of the voting certificate storage method provided by Embodiment 2 of the present invention. As shown in Fig. 5, the method in this embodiment may include:

S201、在预设时间段内向审计者节点发送投票信息。S201. Send voting information to the auditor node within a preset time period.

本实施例应用在包含审计者节点、投票者节点、计票者节点所构成的区块链网络中;参见图1,预先设置包含多个节点的区块链网络中各个节点的功能。需要说明的是,本实施例区块链网络中所有的节点都参与整个投票和审票过程,各个节点之间相互独立,采用点对点的方式组成网络。This embodiment is applied in a blockchain network composed of auditor nodes, voter nodes, and vote counter nodes; referring to FIG. 1 , the functions of each node in a blockchain network including multiple nodes are preset. It should be noted that all nodes in the blockchain network of this embodiment participate in the entire voting and review process, each node is independent of each other, and forms a network in a point-to-point manner.

可选地,在预设时间段内向审计者节点发送投票信息之前,投票者节点首先向所述审计者节点发送公钥、身份信息;接收所述审计者节点发送的创始区块,所述创始区块是由所述审计者节点根据区块链网络中的所有节点发布的公钥、身份信息打包生成的,其中,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;对所述创始区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果;若所述创始区块的验证结果为通过,则采用私钥对投票信息进行签名处理,得到处理后的投票信息。Optionally, before sending voting information to the auditor node within a preset period of time, the voter node first sends the public key and identity information to the auditor node; receives the genesis block sent by the auditor node, and the genesis The block is generated by the auditor node according to the public key and identity information issued by all nodes in the blockchain network, wherein the block header of the founding block records the hash value of the current founding block, Timestamp, the hash value of the previous block; the nodes in the block chain network include: auditor node, voter node, vote counter node; verify the founding block, and report to the auditor The node sends the verification result of the voting block; if the verification result of the creation block is passed, the private key is used to sign the voting information to obtain the processed voting information.

可选地,投票者节点根据预先接收到的区块链网络中的所有节点发布的公钥、身份信息,对所述创始区块中存储的所有节点的公钥、身份信息进行验证;若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息一致,则验证通过;若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息不一致,则验证失败。Optionally, the voter node verifies the public keys and identity information of all nodes stored in the genesis block according to the public keys and identity information issued by all nodes in the blockchain network received in advance; The received public keys and identity information issued by all nodes in the blockchain network are consistent with the public keys and identity information of all nodes stored in the genesis block, and the verification is passed; if the pre-received blockchain network If the public keys and identity information issued by all nodes in the block are inconsistent with the public keys and identity information of all nodes stored in the genesis block, the verification will fail.

本实施例中,投票者节点在预设时间段内向审计者节点发送投票信息。需要说明的是,预设时间段可以根据实际情况进行调整,例如开放投票的有效时间段为1小时,那么投票者节点只能在该1个小时内向所述审计者节点发送投票信息。In this embodiment, the voter node sends voting information to the auditor node within a preset time period. It should be noted that the preset time period can be adjusted according to the actual situation. For example, if the valid time period for open voting is 1 hour, then the voter node can only send voting information to the auditor node within the 1 hour.

S202、接收所述审计者节点发送的投票区块。S202. Receive the voting block sent by the auditor node.

本实施例中,投票者节点接收所述审计者节点发送的投票区块,所述投票区块的区块头中记录了当前投票区块的hash值、时间戳、前一区块的hash值;且该投票区块中保存了有效票信息和无效票的信息。In this embodiment, the voter node receives the voting block sent by the auditor node, and the block header of the voting block records the hash value of the current voting block, the timestamp, and the hash value of the previous block; And the voting block stores the information of valid votes and invalid votes.

S203、对所述投票区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果。S203. Verify the voting block, and send the verification result of the voting block to the auditor node.

本实施例中,投票者节点根据发送的投票信息,对所述投票区块中存储的对应投票节点的投票信息进行验证;若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息一致,则验证通过;若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息不一致,则验证失败。In this embodiment, the voter node verifies the voting information of the corresponding voting node stored in the voting block according to the sent voting information; if the sent voting information matches the voting information of the corresponding voting node stored in the voting block If the voting information is consistent, the verification is passed; if the sent voting information is inconsistent with the voting information of the corresponding voting node stored in the voting block, the verification fails.

可选地,若审计者节点对所述投票区块的验证结果进行统计后,所述投票区块的通过率大于第一预设值,则审计者节点控制计票者节点统计所述投票区块中的有效票信息和无效票信息。投票者节点接收所述计票者节点发送的投票结果。Optionally, if the auditor node counts the verification results of the voting block and the pass rate of the voting block is greater than the first preset value, the auditor node controls the vote counter node to count the voting area Valid ticket information and invalid ticket information in the block. The voter node receives the voting result sent by the voter node.

本实施例,通过在预设时间段内向审计者节点发送投票信息;接收所述审计者节点发送的投票区块;对所述投票区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果。从而可以使得每个投票者对自身的投票信息进行验证,避免了投票过程中投票信息被篡改,保证投票结果的可靠性。In this embodiment, by sending voting information to the auditor node within a preset period of time; receiving the voting block sent by the auditor node; verifying the voting block, and sending the verification to the auditor node Validation result of voting block. Therefore, each voter can verify his own voting information, avoiding tampering of voting information during the voting process, and ensuring the reliability of voting results.

图6为本发明实施例三提供的投票存证装置的结构示意图,如图6所示,本实施例中的装置可以包括:Fig. 6 is a schematic structural diagram of a voting certificate storage device provided in Embodiment 3 of the present invention. As shown in Fig. 6, the device in this embodiment may include:

接收模块10,用于在预设时间段内接收投票者节点发送的投票信息;The receiving module 10 is used to receive the voting information sent by the voter node within a preset time period;

验证模块20,用于对所述投票信息进行验证,并根据验证结果生成投票区块,其中,验证通过的投票信息为有效票信息,验证失败的投票信息为无效票信息;The verification module 20 is used to verify the voting information, and generate a voting block according to the verification result, wherein the voting information passed through verification is valid ticket information, and the voting information failed to verify is invalid ticket information;

发送模块30,用于将所述投票区块发送给区块链网络中的所有节点;其中,所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;The sending module 30 is configured to send the voting block to all nodes in the block chain network; wherein, the nodes in the block chain network include: auditor nodes, voter nodes, and vote counter nodes;

获取模块40,用于获取所述区块链网络中的所有节点对所述投票区块的验证结果;An acquisition module 40, configured to acquire verification results of the voting block by all nodes in the blockchain network;

控制模块50,用于在所述投票区块的验证结果为通过时,控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息,得到投票结果。The control module 50 is configured to control the vote counter node to count valid vote information and invalid vote information in the voting block to obtain the voting result when the verification result of the voting block is passed.

可选地,所述接收模块10,还用于在预设时间段内接收投票者节点发送的投票信息之前,接收区块链网络中的所有节点发布的公钥、身份信息,并将所述公钥、身份信息打包成创始区块;其中,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;Optionally, the receiving module 10 is also configured to receive the public keys and identity information issued by all nodes in the blockchain network before receiving the voting information sent by the voter node within a preset time period, and send the The public key and identity information are packaged into a genesis block; wherein, the hash value of the current genesis block, the timestamp, and the hash value of the previous block are recorded in the block header of the genesis block;

将所述创始区块发送给所述区块链网络中的所有节点;sending the genesis block to all nodes in the blockchain network;

获取所述区块链网络中的所有节点对所述创始区块的验证结果;Obtain the verification results of all nodes in the blockchain network for the genesis block;

若所述创始区块的验证结果为通过,则控制所述投票者节点发送投票信息;其中,所述投票信息采用对应投票者节点的私钥进行签名处理。If the verification result of the founding block is passed, the voter node is controlled to send voting information; wherein, the voting information is signed with the private key of the corresponding voter node.

可选地,所述验证模块20,具体用于:Optionally, the verification module 20 is specifically used for:

根据所述创始区块中存储的公钥、身份信息,对预设时间段内接收到的投票信息进行验证;Verify the voting information received within the preset time period according to the public key and identity information stored in the genesis block;

若所述创始区块中存储的公钥、身份信息与所述投票信息对应的私钥匹配,则验证通过;If the public key and identity information stored in the genesis block match the private key corresponding to the voting information, the verification is passed;

根据预设时间段内接收到的所有投票信息的验证结果生成投票区块;其中,所述投票区块的区块头中记录了当前投票区块的hash值、时间戳、前一区块的hash值。A voting block is generated according to the verification results of all voting information received within a preset time period; wherein, the hash value of the current voting block, the timestamp, and the hash of the previous block are recorded in the block header of the voting block value.

可选地,所述获取模块40,具体用于:Optionally, the acquiring module 40 is specifically used for:

接收所述区块链网络中每个节点对所述投票区块的验证结果;receiving the verification result of each node in the blockchain network for the voting block;

统计所述区块链网络中所有节点针对所述投票区块的通过率;Count the pass rate of all nodes in the blockchain network for the voting block;

若所述通过率大于第一预设值,则确定所述投票区块的验证通过;If the pass rate is greater than a first preset value, it is determined that the verification of the voting block is passed;

若所述通过率小于或等于第一预设值,则确定所述投票区块的验证失败,重新根据投票信息的验证结果生成新的投票区块。If the pass rate is less than or equal to the first preset value, it is determined that the verification of the voting block fails, and a new voting block is generated again according to the verification result of the voting information.

可选地,获取所述区块链网络中的所有节点对所述创始区块的验证结果,包括:Optionally, obtaining the verification results of all nodes in the blockchain network for the genesis block, including:

接收所述区块链网络中每个节点对所述创始区块的验证结果;receiving the verification result of each node in the blockchain network for the founding block;

统计所述区块链网络中所有节点针对所述创始区块的通过率;Count the pass rate of all nodes in the blockchain network for the founding block;

若所述通过率大于第二预设值,则确定所述创始区块的验证通过;If the pass rate is greater than a second preset value, it is determined that the verification of the creation block is passed;

若所述通过率小于或等于第二预设值,则确定所述创始区块的验证失败,重新根据投票信息的验证结果生成新的创始区块。If the pass rate is less than or equal to the second preset value, it is determined that the verification of the creation block fails, and a new creation block is generated again according to the verification result of the voting information.

本实施例可以执行上述图2所示的方法中的技术方案,其实现过程和技术效果与上述方法类似,此处不再赘述。This embodiment can implement the technical solution in the method shown in FIG. 2 above, and its implementation process and technical effect are similar to those of the above method, and will not be repeated here.

图7为本发明实施例四提供的投票存证装置的结构示意图,如图7所示,本实施例中的装置可以包括:Fig. 7 is a schematic structural diagram of a voting certificate storage device provided in Embodiment 4 of the present invention. As shown in Fig. 7, the device in this embodiment may include:

发送模块60,用于在预设时间段内向审计者节点发送投票信息;A sending module 60, configured to send voting information to the auditor node within a preset time period;

接收模块70,用于接收所述审计者节点发送的投票区块;A receiving module 70, configured to receive the voting block sent by the auditor node;

验证模块80,用于对所述投票区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果。The verification module 80 is configured to verify the voting block, and send the verification result of the voting block to the auditor node.

可选地,所述发送模块60,还用于在预设时间段内向审计者节点发送投票信息之前,向所述审计者节点发送公钥、身份信息;Optionally, the sending module 60 is further configured to send the public key and identity information to the auditor node before sending voting information to the auditor node within a preset time period;

所述接收模块70,还用于接收所述审计者节点发送的创始区块,所述创始区块是由所述审计者节点根据区块链网络中的所有节点发布的公钥、身份信息打包生成的,其中,所述创始区块的区块头中记录了当前创始区块的hash值、时间戳、前一区块的hash值;所述区块链网络中的节点包括:审计者节点、投票者节点、计票者节点;The receiving module 70 is also used to receive the genesis block sent by the auditor node, the genesis block is packaged by the auditor node according to the public key and identity information issued by all nodes in the blockchain network Generated, wherein, the hash value of the current genesis block, the timestamp, and the hash value of the previous block are recorded in the block header of the genesis block; the nodes in the blockchain network include: auditor node, Voter node, vote counter node;

所述验证模块80,还用于对所述创始区块进行验证,并向所述审计者节点发送对所述投票区块的验证结果;The verification module 80 is also used to verify the creation block, and send the verification result of the voting block to the auditor node;

若所述创始区块的验证结果为通过,则采用私钥对投票信息进行签名处理,得到处理后的投票信息。If the verification result of the genesis block is passed, the voting information is signed using the private key to obtain the processed voting information.

可选地,所述验证模块80,具体用于:Optionally, the verification module 80 is specifically used for:

根据发送的投票信息,对所述投票区块中存储的对应投票节点的投票信息进行验证;Verifying the voting information of the corresponding voting node stored in the voting block according to the sent voting information;

若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息一致,则验证通过;If the sent voting information is consistent with the voting information of the corresponding voting node stored in the voting block, the verification is passed;

若发送的投票信息与所述投票区块中存储的对应投票节点的投票信息不一致,则验证失败。If the sent voting information is inconsistent with the voting information of the corresponding voting node stored in the voting block, the verification fails.

可选地,所述验证模块80,具体用于:Optionally, the verification module 80 is specifically used for:

根据预先接收到的区块链网络中的所有节点发布的公钥、身份信息,对所述创始区块中存储的所有节点的公钥、身份信息进行验证;Verify the public keys and identity information of all nodes stored in the genesis block according to the pre-received public keys and identity information issued by all nodes in the blockchain network;

若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息一致,则验证通过;If the public keys and identity information issued by all nodes in the blockchain network received in advance are consistent with the public keys and identity information of all nodes stored in the genesis block, the verification is passed;

若预先接收到的区块链网络中的所有节点发布的公钥、身份信息与所述创始区块中存储的所有节点的公钥、身份信息不一致,则验证失败。If the pre-received public keys and identity information issued by all nodes in the blockchain network are inconsistent with the public keys and identity information of all nodes stored in the genesis block, the verification fails.

可选地,所述接收模块70,还用于:Optionally, the receiving module 70 is also used for:

接收计票者节点发送的投票结果;其中,所述投票结果是在所述投票区块的验证结果为通过时,审计者节点通过控制所述计票者节点统计所述投票区块中的有效票信息和无效票信息得到的。Receive the voting result sent by the voter node; wherein, the voting result is that when the verification result of the voting block is passed, the auditor node controls the voter node to count the valid votes in the voting block. Ticket information and invalid ticket information are obtained.

本实施例可以执行上述图5所示的方法中的技术方案,其实现过程和技术效果与上述方法类似,此处不再赘述。This embodiment can implement the technical solution in the method shown in FIG. 5 above, and its implementation process and technical effect are similar to those of the above method, and will not be repeated here.

图8为本发明实施例五提供的投票存证系统的结构示意图,如图6所示,本实施例中的投票存证系统90包括:处理器91和存储器92;FIG. 8 is a schematic structural diagram of a voting certificate storage system provided in Embodiment 5 of the present invention. As shown in FIG. 6 , the voting certificate storage system 90 in this embodiment includes: a processor 91 and a memory 92;

存储器92,用于存储计算机程序(如实现上述投票存证方法的应用程序、功能模块等)、计算机指令等,上述的计算机程序、计算机指令等可以分区存储在一个或多个存储器92中。并且上述的计算机程序、计算机指令、数据等可以被处理器91调用。The memory 92 is used to store computer programs (such as application programs, functional modules, etc. for realizing the above-mentioned method of voting and depositing certificates), computer instructions, etc., and the above-mentioned computer programs, computer instructions, etc. can be stored in one or more memories 92 in partitions. And the above-mentioned computer programs, computer instructions, data, etc. can be invoked by the processor 91 .

处理器91,用于执行所述存储器92存储的所述计算机程序,以实现上述实施例涉及的方法中的各个步骤。具体可以参见前面方法实施例中的相关描述。其中,存储器92、处理器91可以通过总线93耦合连接。The processor 91 is configured to execute the computer program stored in the memory 92, so as to implement each step in the method involved in the foregoing embodiments. For details, refer to the related descriptions in the foregoing method embodiments. Wherein, the memory 92 and the processor 91 may be coupled and connected through the bus 93 .

本实施例可以执行上述图2、图5所示的方法中的技术方案,其实现过程和技术效果与上述方法类似,此处不再赘述。This embodiment can execute the technical solutions in the methods shown in the above-mentioned FIG. 2 and FIG. 5 , and its implementation process and technical effect are similar to those of the above-mentioned method, and will not be repeated here.

此外,本申请实施例还提供一种计算机可读存储介质,计算机可读存储介质中存储有计算机执行指令,当用户设备的至少一个处理器执行该计算机执行指令时,用户设备执行上述各种可能的方法。In addition, an embodiment of the present application also provides a computer-readable storage medium, in which computer-executable instructions are stored. When at least one processor of the user equipment executes the computer-executable instructions, the user equipment executes the above-mentioned various possibilities. Methods.

其中,计算机可读介质包括计算机存储介质和通信介质,其中通信介质包括便于从一个地方向另一个地方传送计算机程序的任何介质。存储介质可以是通用或专用计算机能够存取的任何可用介质。一种示例性的存储介质耦合至处理器,从而使处理器能够从该存储介质读取信息,且可向该存储介质写入信息。当然,存储介质也可以是处理器的组成部分。处理器和存储介质可以位于ASIC中。另外,该ASIC可以位于用户设备中。当然,处理器和存储介质也可以作为分立组件存在于通信设备中。Among other things, computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer. An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. Of course, the storage medium may also be a component of the processor. The processor and storage medium can be located in the ASIC. Additionally, the ASIC may be located in the user equipment. Of course, the processor and the storage medium can also exist in the communication device as discrete components.

本领域普通技术人员可以理解:实现上述各方法实施例的全部或部分步骤可以通过程序指令相关的硬件来完成。前述的程序可以存储于一计算机可读取存储介质中。该程序在执行时,执行包括上述各方法实施例的步骤;而前述的存储介质包括:ROM、RAM、磁碟或者光盘等各种可以存储程序代码的介质。Those of ordinary skill in the art can understand that all or part of the steps for implementing the above method embodiments can be completed by program instructions and related hardware. The aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps including the above-mentioned method embodiments; and the aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other various media that can store program codes.

最后应说明的是:以上各实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述各实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分或者全部技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的范围。Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present invention, rather than limiting them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: It is still possible to modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some or all of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the technical solutions of the various embodiments of the present invention. scope.

Claims (21)

1. card method is deposited in a kind of ballot, which is characterized in that including:
The vote information that voter's node is sent is received within a preset period of time;
The vote information is verified, and ballot block is generated according to verification result, wherein the vote information being verified Vote information for valid ballot information, authentication failed is invalid ballots information;
The ballot block is sent to all nodes in block chain network;Wherein, the node packet in the block chain network It includes:Audit person's node, voter's node, count of votes person's node;
Obtain verification result of all nodes in the block chain network to the ballot block;
If the verification result of the ballot block is to pass through, control described in count of votes person's node statistics that voting district is in the block to be had Ticket information and invalid ballots information are imitated, voting results are obtained.
2. according to the method described in claim 1, it is characterized in that, the voter's node that receives within a preset period of time is sent Vote information before, further include:
Public key, the identity information of all nodes publication in block chain network are received, and the public key, identity information are packaged into Original block;Wherein, the Hash hash values of current original block, timestamp, preceding are had recorded in the block head of the original block The Hash hash values of one block;
The original block is sent to all nodes in the block chain network;
Obtain verification result of all nodes in the block chain network to the original block;
If the verification result of the original block is to pass through, controls voter's node and send vote information;Wherein, described Vote information carries out signature processing using the private key of corresponding voter's node.
3. according to the method described in claim 2, it is characterized in that, described verify the vote information, and according to testing It demonstrate,proves result and generates ballot block, including:
According to public key, the identity information stored in the original block, the vote information received in preset time period is carried out Verification;
If the private key matching corresponding with the vote information of the public key stored in the original block, identity information, verification are logical It crosses;
Ballot block is generated according to the verification result of all vote informations received in preset time period;Wherein, the ballot The hash values of current ballot block, the Hash hash values of timestamp, previous block are had recorded in the block head of block.
4. according to the method described in claim 1, it is characterized in that, obtaining all nodes in the block chain network to described The verification result of ballot block, including:
Receive the verification result of each node in the block chain network to the ballot block;
Count the percent of pass that all nodes in the block chain network are directed to the ballot block;
If the percent of pass is more than the first preset value, it is determined that the ballot block is verified;
If the percent of pass is less than or equal to the first preset value, it is determined that the authentication failed of the ballot block, again according to throwing The verification result of ticket information generates new ballot block.
5. according to the method described in claim 2, it is characterized in that, obtaining all nodes in the block chain network to described The verification result of original block, including:
Each node is received in the block chain network to the verification result of the original block;
Count the percent of pass that all nodes in the block chain network are directed to the original block;
If the percent of pass is more than the second preset value, it is determined that the original block is verified;
If the percent of pass is less than or equal to the second preset value, it is determined that the authentication failed of the original block, again according to throwing The verification result of ticket information generates new original block.
6. card method is deposited in a kind of ballot, which is characterized in that including:
Within a preset period of time vote information is sent to audit person's node;
Receive the ballot block that audit person's node is sent;
The ballot block is verified, and the verification result to the ballot block is sent to audit person's node.
7. according to the method described in claim 6, it is characterized in that, described sent within a preset period of time to audit person's node is thrown Before ticket information, further include:
Public key, identity information are sent to audit person's node;
The original block that audit person's node is sent is received, the original block is by audit person's node according to block chain Public key, the identity information of all nodes publication in network are packaged generation, wherein are recorded in the block head of the original block Hash hash values, the Hash hash values of timestamp, previous block of current original block;Node in the block chain network Including:Audit person's node, voter's node, count of votes person's node;
The original block is verified, and the verification result to the ballot block is sent to audit person's node;
If the verification result of the original block is to pass through, signature processing is carried out to vote information using private key, is handled Vote information afterwards.
8. according to the method described in claim 6, it is characterized in that, described verify the ballot block, including:
It is verified according to the vote information of the vote information of transmission, the corresponding ballot node to being stored in the ballot block;
If the vote information sent is consistent with the vote information of the corresponding ballot node stored in the ballot block, verification is logical It crosses;
If the vote information sent and the vote information of the corresponding ballot node stored in the ballot block are inconsistent, verify Failure.
9. the method according to the description of claim 7 is characterized in that described verify the original block, including:
According to public key, the identity information of all nodes publication in the block chain network being previously received, to the original block Public key, the identity information of all nodes of middle storage are verified;
If public key, the identity information of all nodes publication in the block chain network being previously received are deposited with the original block Public key, the identity information of all nodes of storage are consistent, then are verified;
If public key, the identity information of all nodes publication in the block chain network being previously received are deposited with the original block Public key, the identity information of all nodes of storage are inconsistent, then authentication failed.
10. according to the method described in any one of claim 6-9, which is characterized in that further include:
Receive the voting results that count of votes person's node is sent;Wherein, the voting results are the verification results in the ballot block For by when, audit person's node is by controlling voting district valid ballot information in the block described in count of votes person's node statistics and invalid Ticket information obtains.
11. card device is deposited in a kind of ballot, which is characterized in that including:
Receiving module, the vote information sent for receiving voter's node within a preset period of time;
Authentication module generates ballot block, wherein verification for being verified to the vote information, and according to verification result By vote information be valid ballot information, the vote information of authentication failed is invalid ballots information;
Sending module, for the ballot block to be sent to all nodes in block chain network;Wherein, the block link network Node in network includes:Audit person's node, voter's node, count of votes person's node;
Acquisition module, the verification result for obtaining all nodes in the block chain network to the ballot block;
Control module, for it is described ballot block verification result be by when, control described in count of votes person's node statistics Voting district valid ballot information in the block and invalid ballots information, obtain voting results.
12. according to the devices described in claim 11, which is characterized in that
The receiving module is additionally operable to before the vote information for receiving the transmission of voter's node within a preset period of time, reception area Public key, the identity information of all nodes publication in block chain network, and the public key, identity information are packaged into original block; Wherein, the Hash hash values of current original block, the Kazakhstan of timestamp, previous block are had recorded in the block head of the original block Uncommon hash values;
The original block is sent to all nodes in the block chain network;
Obtain verification result of all nodes in the block chain network to the original block;
If the verification result of the original block is to pass through, controls voter's node and send vote information;Wherein, described Vote information carries out signature processing using the private key of corresponding voter's node.
13. device according to claim 12, which is characterized in that the authentication module is specifically used for:
According to public key, the identity information stored in the original block, the vote information received in preset time period is carried out Verification;
If the private key matching corresponding with the vote information of the public key stored in the original block, identity information, verification are logical It crosses;
Ballot block is generated according to the verification result of all vote informations received in preset time period;Wherein, the ballot The Hash hash values of current ballot block, the Hash hash values of timestamp, previous block are had recorded in the block head of block.
14. according to the devices described in claim 11, which is characterized in that the acquisition module is specifically used for:
Receive the verification result of each node in the block chain network to the ballot block;
Count the percent of pass that all nodes in the block chain network are directed to the ballot block;
If the percent of pass is more than the first preset value, it is determined that the ballot block is verified;
If the percent of pass is less than or equal to the first preset value, it is determined that the authentication failed of the ballot block, again according to throwing The verification result of ticket information generates new ballot block.
15. device according to claim 12, which is characterized in that obtain all nodes in the block chain network to institute The verification result of original block is stated, including:
Each node is received in the block chain network to the verification result of the original block;
Count the percent of pass that all nodes in the block chain network are directed to the original block;
If the percent of pass is more than the second preset value, it is determined that the original block is verified;
If the percent of pass is less than or equal to the second preset value, it is determined that the authentication failed of the original block, again according to throwing The verification result of ticket information generates new original block.
16. card device is deposited in a kind of ballot, which is characterized in that including:
Sending module, for sending vote information to audit person's node within a preset period of time;
Receiving module, the ballot block sent for receiving audit person's node;
Authentication module is sent for being verified to the ballot block, and to audit person's node to the ballot block Verification result.
17. device according to claim 16, which is characterized in that
The sending module, before being additionally operable to send vote information to audit person's node within a preset period of time, to the audit Person's node sends public key, identity information;
The receiving module is additionally operable to receive the original block that audit person's node is sent, and the original block is by described Audit person's node is packaged generation according to public key, the identity information of all nodes publication in block chain network, wherein the wound Hash values, the hash values of timestamp, previous block of current original block are had recorded in the block head of beginning block;The block chain Node in network includes:Audit person's node, voter's node, count of votes person's node;
The authentication module is additionally operable to verify the original block, and is sent to audit person's node to the throwing The verification result of ticket block;
If the verification result of the original block is to pass through, signature processing is carried out to vote information using private key, is handled Vote information afterwards.
18. device according to claim 16, which is characterized in that the authentication module is specifically used for:
It is verified according to the vote information of the vote information of transmission, the corresponding ballot node to being stored in the ballot block;
If the vote information sent is consistent with the vote information of the corresponding ballot node stored in the ballot block, verification is logical It crosses;
If the vote information sent and the vote information of the corresponding ballot node stored in the ballot block are inconsistent, verify Failure.
19. device according to claim 17, which is characterized in that the authentication module is specifically used for:
According to public key, the identity information of all nodes publication in the block chain network being previously received, to the original block Public key, the identity information of all nodes of middle storage are verified;
If public key, the identity information of all nodes publication in the block chain network being previously received are deposited with the original block Public key, the identity information of all nodes of storage are consistent, then are verified;
If public key, the identity information of all nodes publication in the block chain network being previously received are deposited with the original block Public key, the identity information of all nodes of storage are inconsistent, then authentication failed.
20. according to the device described in any one of claim 16-19, which is characterized in that the receiving module is additionally operable to:
Receive the voting results that count of votes person's node is sent;Wherein, the voting results are the verification results in the ballot block For by when, audit person's node is by controlling voting district valid ballot information in the block described in count of votes person's node statistics and invalid Ticket information obtains.
21. a kind of ballot deposit system, which is characterized in that including:
Memory, for storing program;
Processor, the described program for executing the memory storage, when described program is performed, the processor is used for Execute the method as described in any one of claim 1-5, and/or the method as described in any one of claim 6-10.
CN201810491132.7A 2018-05-21 2018-05-21 Voting certificate deposit method, device and system Active CN108711212B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810491132.7A CN108711212B (en) 2018-05-21 2018-05-21 Voting certificate deposit method, device and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810491132.7A CN108711212B (en) 2018-05-21 2018-05-21 Voting certificate deposit method, device and system

Publications (2)

Publication Number Publication Date
CN108711212A true CN108711212A (en) 2018-10-26
CN108711212B CN108711212B (en) 2021-03-09

Family

ID=63868452

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810491132.7A Active CN108711212B (en) 2018-05-21 2018-05-21 Voting certificate deposit method, device and system

Country Status (1)

Country Link
CN (1) CN108711212B (en)

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109905244A (en) * 2018-12-26 2019-06-18 顺丰科技有限公司 The management method and device of alliance
CN109981673A (en) * 2019-04-04 2019-07-05 上海人行道网络信息技术有限公司 Data based on block chain deposit card method, apparatus, equipment and storage medium
CN110427772A (en) * 2019-06-27 2019-11-08 布比(北京)网络技术有限公司 A kind of secret protection electronic voting method and system based on block chain
CN110474779A (en) * 2019-08-09 2019-11-19 深圳前海微众银行股份有限公司 Card method, apparatus, equipment and readable storage medium storing program for executing are deposited in ballot based on block chain
CN110853651A (en) * 2019-11-13 2020-02-28 支付宝(杭州)信息技术有限公司 Voice voting method, voting content verification method and system thereof
CN110933098A (en) * 2019-12-05 2020-03-27 全链通有限公司 Electronic voting method, device and storage medium based on block chain
CN111010431A (en) * 2019-12-05 2020-04-14 全链通有限公司 Electronic voting method, device and storage medium based on block chain
CN111478772A (en) * 2020-06-22 2020-07-31 杭州趣链科技有限公司 Assembly line friendly signature and signature verification method, device and storage medium
CN111836258A (en) * 2020-07-10 2020-10-27 国网冀北电力有限公司电力科学研究院 Method and device for secure access of power distribution Internet of Things nodes
US20210075599A1 (en) * 2018-06-11 2021-03-11 Douglas J. Pepe Blockchain voting system and method with audit trail verification
CN112685751A (en) * 2020-12-25 2021-04-20 联想(北京)有限公司 Data processing method and device and electronic voting system
CN112907811A (en) * 2021-01-29 2021-06-04 山西特信环宇信息技术有限公司 Election system and voting method for cone block chain
US11341509B1 (en) 2020-11-13 2022-05-24 Gleipnir Technologies Llc Voting system to prevent fraud using blockchain technology
CN114692221A (en) * 2019-11-28 2022-07-01 杭州趣链科技有限公司 Proposal voting method
US11386437B2 (en) 2020-11-13 2022-07-12 Gleipnir Technologies Llc Voting system to prevent fraud using blockchain technology

Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1579065A (en) * 2001-11-06 2005-02-09 国际商业机器公司 Method and system for the supply of data, transactions and electronic voting
CN200941220Y (en) * 2006-06-14 2007-08-29 陈江山 Auxiliary device for vote counting and monitoring
CN101233545A (en) * 2005-05-26 2008-07-30 Iml有限公司 Voting system
TW201133398A (en) * 2010-03-17 2011-10-01 Gui-Sen Chen Auditing mechanism for valuable bills
US20150347222A1 (en) * 2014-05-29 2015-12-03 Teledyne Scientific & Imaging, Llc Single event upset protection circuit and method
CN105490925A (en) * 2015-12-22 2016-04-13 北京奇虎科技有限公司 Verification method and apparatus of information validity
CN105704117A (en) * 2015-12-29 2016-06-22 金华鸿正科技有限公司 Internet online voting system
CN106411503A (en) * 2016-11-28 2017-02-15 中国银行股份有限公司 Accounting method, accounting system, voting node and accounting node under block chain voting and accounting mode
US20170061398A1 (en) * 2014-06-19 2017-03-02 Jim Austin Joseph Cryptographic currency block chain based voting system
US20170109955A1 (en) * 2015-10-20 2017-04-20 Follow My Vote, Inc. Blockchain electronic voting system and method
US9645553B1 (en) * 2016-01-28 2017-05-09 Raytheon Bbn Technologies Corp. Secure time reference using multiple time sources
CN107124403A (en) * 2017-04-14 2017-09-01 朱清明 The generation method and computing device of common recognition block in block chain
WO2017213779A1 (en) * 2016-06-08 2017-12-14 Qualcomm Incorporated System and method for false pass detection in lockstep dual core or triple modular redundancy (tmr) systems
CN108027867A (en) * 2015-07-14 2018-05-11 Fmr有限责任公司 Calculate efficient transfer accounts processing, audit and searcher, method and system

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1579065A (en) * 2001-11-06 2005-02-09 国际商业机器公司 Method and system for the supply of data, transactions and electronic voting
CN101233545A (en) * 2005-05-26 2008-07-30 Iml有限公司 Voting system
CN200941220Y (en) * 2006-06-14 2007-08-29 陈江山 Auxiliary device for vote counting and monitoring
TW201133398A (en) * 2010-03-17 2011-10-01 Gui-Sen Chen Auditing mechanism for valuable bills
US20150347222A1 (en) * 2014-05-29 2015-12-03 Teledyne Scientific & Imaging, Llc Single event upset protection circuit and method
US20170061398A1 (en) * 2014-06-19 2017-03-02 Jim Austin Joseph Cryptographic currency block chain based voting system
CN108027867A (en) * 2015-07-14 2018-05-11 Fmr有限责任公司 Calculate efficient transfer accounts processing, audit and searcher, method and system
US20170109955A1 (en) * 2015-10-20 2017-04-20 Follow My Vote, Inc. Blockchain electronic voting system and method
CN105490925A (en) * 2015-12-22 2016-04-13 北京奇虎科技有限公司 Verification method and apparatus of information validity
CN105704117A (en) * 2015-12-29 2016-06-22 金华鸿正科技有限公司 Internet online voting system
US9645553B1 (en) * 2016-01-28 2017-05-09 Raytheon Bbn Technologies Corp. Secure time reference using multiple time sources
WO2017213779A1 (en) * 2016-06-08 2017-12-14 Qualcomm Incorporated System and method for false pass detection in lockstep dual core or triple modular redundancy (tmr) systems
CN106411503A (en) * 2016-11-28 2017-02-15 中国银行股份有限公司 Accounting method, accounting system, voting node and accounting node under block chain voting and accounting mode
CN107124403A (en) * 2017-04-14 2017-09-01 朱清明 The generation method and computing device of common recognition block in block chain

Cited By (25)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20210075599A1 (en) * 2018-06-11 2021-03-11 Douglas J. Pepe Blockchain voting system and method with audit trail verification
CN109905244A (en) * 2018-12-26 2019-06-18 顺丰科技有限公司 The management method and device of alliance
CN109981673A (en) * 2019-04-04 2019-07-05 上海人行道网络信息技术有限公司 Data based on block chain deposit card method, apparatus, equipment and storage medium
CN109981673B (en) * 2019-04-04 2021-10-08 上海人行道网络信息技术有限公司 Block chain-based data evidence storage method, device, equipment and storage medium
CN110427772A (en) * 2019-06-27 2019-11-08 布比(北京)网络技术有限公司 A kind of secret protection electronic voting method and system based on block chain
CN110474779B (en) * 2019-08-09 2024-06-25 深圳前海微众银行股份有限公司 Voting evidence-storing method, device and equipment based on blockchain and readable storage medium
CN110474779A (en) * 2019-08-09 2019-11-19 深圳前海微众银行股份有限公司 Card method, apparatus, equipment and readable storage medium storing program for executing are deposited in ballot based on block chain
CN110853651A (en) * 2019-11-13 2020-02-28 支付宝(杭州)信息技术有限公司 Voice voting method, voting content verification method and system thereof
CN110853651B (en) * 2019-11-13 2021-06-01 支付宝(杭州)信息技术有限公司 Voting content verification method and system
CN114692221A (en) * 2019-11-28 2022-07-01 杭州趣链科技有限公司 Proposal voting method
CN110933098A (en) * 2019-12-05 2020-03-27 全链通有限公司 Electronic voting method, device and storage medium based on block chain
CN110933098B (en) * 2019-12-05 2022-04-08 全链通有限公司 Electronic voting method, device and storage medium based on block chain
CN111010431A (en) * 2019-12-05 2020-04-14 全链通有限公司 Electronic voting method, device and storage medium based on block chain
CN111010431B (en) * 2019-12-05 2022-09-02 全链通有限公司 Electronic voting method, device and storage medium based on block chain
CN111478772A (en) * 2020-06-22 2020-07-31 杭州趣链科技有限公司 Assembly line friendly signature and signature verification method, device and storage medium
WO2021258549A1 (en) * 2020-06-22 2021-12-30 杭州趣链科技有限公司 Assembly line friendly signing and signature verifying methods, device, and storage medium
JP7407925B2 (en) 2020-06-22 2024-01-04 杭州趣鏈科技有限公司 Flowline friendly signature and signature verification methods, equipment and storage media
JP2022553995A (en) * 2020-06-22 2022-12-27 杭州趣鏈科技有限公司 Flowline-friendly signature and signature verification methods, facilities and storage media
CN111836258A (en) * 2020-07-10 2020-10-27 国网冀北电力有限公司电力科学研究院 Method and device for secure access of power distribution Internet of Things nodes
CN111836258B (en) * 2020-07-10 2024-04-23 国网冀北电力有限公司电力科学研究院 Method and device for safely accessing nodes of power distribution Internet of things
US11386437B2 (en) 2020-11-13 2022-07-12 Gleipnir Technologies Llc Voting system to prevent fraud using blockchain technology
US11341509B1 (en) 2020-11-13 2022-05-24 Gleipnir Technologies Llc Voting system to prevent fraud using blockchain technology
CN112685751B (en) * 2020-12-25 2024-04-26 联想(北京)有限公司 Data processing method, device and electronic voting system
CN112685751A (en) * 2020-12-25 2021-04-20 联想(北京)有限公司 Data processing method and device and electronic voting system
CN112907811A (en) * 2021-01-29 2021-06-04 山西特信环宇信息技术有限公司 Election system and voting method for cone block chain

Also Published As

Publication number Publication date
CN108711212B (en) 2021-03-09

Similar Documents

Publication Publication Date Title
CN108711212A (en) Card method, apparatus and system are deposited in ballot
CN110110555B (en) A voting method and device in blockchain
CN111445333B (en) Block generation method, device, computer equipment and storage medium
CN111314067B (en) Block storage method and device, computer equipment and storage medium
Culnane et al. A peered bulletin board for robust use in verifiable voting systems
EP4050542B1 (en) Blockchain-based data processing method and apparatus, and device and readable storage medium
CN110351133A (en) Method and device for the host node hand-off process in block catenary system
CN109327528A (en) A kind of node administration method and device based on block chain
CN109508982A (en) REPB common recognition based on the more subchains of block chain main chain adduction row
CN111654395B (en) Voting information processing method, device, equipment and storage medium
CN112929383A (en) Multi-center authentication system with block issuing mechanism
CN115701078B (en) Cross-chain transaction processing method, device, electronic equipment and storage medium
WO2023009231A1 (en) End-to-end verifiable proof of votes cast in elections
KR20200087913A (en) System and method for providing secret electronic voting service based on blockchain
CN111556115B (en) Block chain-based data processing method, device, equipment and storage medium
CN111489143A (en) Auditable encrypted digital currency supervision method based on alliance side chain
CN113569226B (en) Blockchain-based parking space management system and method
CN111787034B (en) Block generation method, synchronization method, device, blockchain system and storage medium
CN115147975B (en) Encryption network voting method based on block chain
CN113869901B (en) Key generation method, key generation device, computer-readable storage medium and computer equipment
CN108924089A (en) A kind of client device recognition methods, device and client device
CN108882230B (en) Call record management method, device and system
CN116311661A (en) Voting system and method for multi-device consensus based on blockchain
CN114969714A (en) User login authentication method, device and equipment based on block chain
CN110766407A (en) Transaction verification method, accounting node and medium based on block chain

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