[go: up one dir, main page]

TWI695331B - Random object selection method and device based on blockchain - Google Patents

Random object selection method and device based on blockchain Download PDF

Info

Publication number
TWI695331B
TWI695331B TW108108599A TW108108599A TWI695331B TW I695331 B TWI695331 B TW I695331B TW 108108599 A TW108108599 A TW 108108599A TW 108108599 A TW108108599 A TW 108108599A TW I695331 B TWI695331 B TW I695331B
Authority
TW
Taiwan
Prior art keywords
candidate
blockchain
transaction
reference number
period
Prior art date
Application number
TW108108599A
Other languages
Chinese (zh)
Other versions
TW202009810A (en
Inventor
張文彬
Original Assignee
香港商阿里巴巴集團服務有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 香港商阿里巴巴集團服務有限公司 filed Critical 香港商阿里巴巴集團服務有限公司
Publication of TW202009810A publication Critical patent/TW202009810A/en
Application granted granted Critical
Publication of TWI695331B publication Critical patent/TWI695331B/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0207Discounts or incentives, e.g. coupons or rebates
    • G06Q30/0212Chance discounts or incentives

Landscapes

  • Business, Economics & Management (AREA)
  • Accounting & Taxation (AREA)
  • Finance (AREA)
  • Engineering & Computer Science (AREA)
  • Strategic Management (AREA)
  • Development Economics (AREA)
  • Theoretical Computer Science (AREA)
  • Marketing (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Economics (AREA)
  • Technology Law (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Game Theory and Decision Science (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

本說明書的一個或多個實施例提供了一種基於區塊鏈的隨機物件選取方法和裝置,應用於包含多個參選物件節點的區塊鏈,所述方法包括:接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,所述參選交易基於所述參選物件節點確定的物件參考數產生;根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,其中,所述指定事件的特徵值為根據預設的映射演算法,對發生在所述第一時段之後的指定事件計算所得的特徵值,所述指定事件的特徵值在所述指定事件發生之前不可被預知;根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點。One or more embodiments of this specification provide a random object selection method and device based on a blockchain, which are applied to a blockchain including multiple candidate object nodes. The method includes: receiving multiple candidate object nodes Participation transactions issued to the distributed database of the blockchain within the first period of time, the participation transactions are generated based on the object reference number determined by the object node; according to the preset calculation rules, based on the specified event The characteristic value of and the reference number of the object corresponding to the participating transaction respectively calculate the values corresponding to multiple participating object nodes, wherein the characteristic value of the specified event is based on a preset mapping algorithm The characteristic value calculated after the specified event, the characteristic value of the specified event cannot be predicted before the specified event occurs; according to the preset selection rule, the candidate is selected based on the corresponding value of the multiple candidate object nodes Object node.

Description

基於區塊鏈的隨機物件選取方法和裝置Random object selection method and device based on blockchain

本說明書有關資料處理技術領域,尤其有關一種基於區塊鏈的隨機物件選取方法和裝置。This specification relates to the field of data processing technology, in particular to a method and device for random object selection based on blockchain.

隨機物件選取常用在電腦隨機分配資源、隨機分配任務或其他任意所需的業務場景下,基於一台電腦或伺服器的隨機物件選取方法難以確保隨機選取過程的公平性和可驗證性,因為一台電腦或伺服器所施行的選取方法極易被人為操控,難以做到真正的「隨機」選取,而且外界在事中和事後都難以監測和驗證其施行的選取方法是否沒有被操控。Random object selection is commonly used in computers randomly allocating resources, randomly allocating tasks, or any other required business scenarios. The random object selection method based on a computer or server is difficult to ensure the fairness and verifiability of the random selection process, because one The selection method implemented by a computer or a server is extremely easy to be manipulated, and it is difficult to achieve a truly "random" selection, and it is difficult for the outside world to monitor and verify whether the selection method it implements has not been manipulated during and after the event.

有鑑於此,本說明書一個或多個實施例提供一種基於區塊鏈的隨機物件選取方法及裝置、電子設備。 為實現上述目的,本說明書一個或多個實施例提供技術方案如下: 根據本說明書一個或多個實施例的第一態樣,提出了一種基於區塊鏈的隨機物件選取方法,應用於包含多個參選物件節點的區塊鏈,所述方法包括: 接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,所述參選交易基於所述參選物件節點確定的物件參考數產生; 根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,其中,所述指定事件的特徵值為根據預設的映射演算法,對發生在所述第一時段之後的指定事件計算所得的特徵值,所述指定事件的特徵值在所述指定事件發生之前不可被預知; 根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點。 根據本說明書一個或多個實施例的第二態樣,提出了一種基於區塊鏈的隨機物件選取裝置,應用於包含多個參選物件節點的區塊鏈,所述裝置包括: 接收單元,接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,所述參選交易基於所述參選物件節點確定的物件參考數產生; 計算單元,根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,其中,所述指定事件的特徵值為根據預設的映射演算法,對發生在所述第一時段之後的指定事件計算所得的特徵值,所述指定事件的特徵值在所述指定事件發生之前不可被預知; 選取單元,根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點。 相應的,本說明書還提供了一種電腦設備,包括:記憶體和處理器;所述記憶體上儲存有可由處理器運行的電腦程式;所述處理器運行所述電腦程式時,執行上述基於區塊鏈的隨機物件選取方法所述的步驟。 本說明書還提供了一種電腦可讀儲存媒體,其上儲存有電腦程式,所述電腦程式被處理器運行時,執行上述基於區塊鏈的隨機物件選取方法所述的步驟。 由以上技術方案可見,本說明書提供的基於區塊鏈的隨機物件選取方法及裝置,依賴於參選物件提供的物件參考數和之後發生的、不可被預測的、指定事件的特徵值進行計算,從而保證了選取過程免除了人為操縱、更改結果的可能性:基於區塊鏈技術的分散式資料庫儲存機制,參選物件所選擇發布的物件參考數被去中心化地記錄或存證在區塊鏈的所有節點中,且基於區塊鏈的共識機制,每個參選物件所發布的物件參考數不會在提供後被篡改,防止選取過程透過修改參選物件的物件參考數進行操控;進一步地,指定事件只有在物件參考數提供階段結束後才會發生,且其特徵值在指定事件發生前是不可預測的,這樣參選物件無法基於預設的規則和該特徵值進行預測算以選取合適的物件參考數,從而保證該物件參考數的提供是真正隨機的,進而保證了整個隨機物件選取過程的隨機性和公平性,而且事中和事後外界都可以監測和驗證過程中的每一步。 In view of this, one or more embodiments of this specification provide a random object selection method and device based on blockchain, and electronic equipment. To achieve the above purpose, one or more embodiments of this specification provide technical solutions as follows: According to a first aspect of one or more embodiments of the present specification, a random object selection method based on a blockchain is proposed, which is applied to a blockchain including a plurality of candidate object nodes. The method includes: Receiving a plurality of participating object nodes in the first period of time to the distributed database of the distributed transaction, the participating transaction is generated based on the reference number of objects determined by the participating object node; According to a preset calculation rule, based on the feature value of the specified event and the reference number of the object corresponding to the participating transaction, respectively calculate values corresponding to multiple candidate object nodes, wherein the feature value of the designated event is calculated according to the preset mapping Method, a characteristic value calculated for a specified event that occurs after the first period of time, and the characteristic value of the specified event cannot be predicted before the specified event occurs; According to the preset selection rule, select the candidate object nodes based on the values corresponding to the multiple candidate object nodes. According to a second aspect of one or more embodiments of this specification, a random object selection device based on a blockchain is proposed, which is applied to a blockchain including a plurality of candidate object nodes. The device includes: A receiving unit, receiving a plurality of participating object nodes in the first period of time to the distributed database of the distributed transaction, the participating transaction is generated based on the reference number of objects determined by the participating object nodes; The calculation unit calculates the values corresponding to a plurality of candidate object nodes based on the characteristic value of the specified event and the object reference number corresponding to the participation transaction according to the preset calculation rules, wherein the characteristic value of the specified event is according to the preset The mapping algorithm of, calculates the characteristic value of the specified event that occurs after the first period of time, and the characteristic value of the specified event cannot be predicted before the specified event occurs; The selection unit selects a candidate object node based on the corresponding values of the multiple candidate object nodes according to a preset selection rule. Correspondingly, this specification also provides a computer device, including: a memory and a processor; a computer program executable by the processor is stored on the memory; when the processor runs the computer program, the above-mentioned area-based The steps described in the random object selection method of the blockchain. This specification also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps described in the above-described method for random object selection based on a blockchain are performed. It can be seen from the above technical solutions that the random object selection method and device based on blockchain provided in this specification rely on the object reference number provided by the candidate object and the characteristic value of the specified event that occurs afterwards and cannot be predicted, This ensures that the selection process avoids the possibility of human manipulation and modification of results: based on the distributed database storage mechanism of blockchain technology, the reference numbers of the objects selected for the selected objects are recorded or decentralized in the area. Among all the nodes of the blockchain, and based on the consensus mechanism of the blockchain, the reference number of objects issued by each candidate object will not be tampered after being provided, preventing the selection process from being manipulated by modifying the reference number of objects of the candidate object; Further, the specified event will only occur after the end of the object reference number provision phase, and its characteristic value is unpredictable before the specified event occurs, so that the candidate object cannot be predicted based on the preset rules and the characteristic value. Choose a suitable object reference number, so as to ensure that the provision of the object reference number is truly random, thereby ensuring the randomness and fairness of the entire random object selection process, and the outside world can monitor and verify every event during and after the event. step.

這裡將詳細地對示例性實施例進行說明,其示例表示在圖式中。下面的描述涉及圖式時,除非另有表示,不同圖式中的相同數字表示相同或相似的元件。以下示例性實施例中所描述的實施方式並不代表與本說明書一個或多個實施例相一致的所有實施方式。相反,它們僅是與如所附申請專利範圍中所詳述的、本說明書一個或多個實施例的一些態樣相一致的裝置和方法的例子。 需要說明的是:在其他實施例中並不一定按照本說明書示出和描述的順序來執行相應方法的步驟。在一些其他實施例中,其方法所包括的步驟可以比本說明書所描述的更多或更少。此外,本說明書中所描述的單個步驟,在其他實施例中可能被分解為多個步驟進行描述;而本說明書中所描述的多個步驟,在其他實施例中也可能被合併為單個步驟進行描述。 如圖1所示,本說明書一示意性實施例提供了一種基於區塊鏈的隨機物件選取方法,應用於包含多個參選物件節點的區塊鏈,所述方法包括: 步驟102,接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,所述參選交易基於所述參選物件節點所選擇的物件參考數產生。 上述實施例所述的區塊鏈,具體可指一個各節點透過共識機制達成的、具有分散式資料儲存結構的P2P網路系統,該區塊鏈內的資料分佈在時間上相連的一個個「區塊(block)」之內,後一區塊包含前一區塊的資料摘要,且根據具體的共識機制(如POW、POS、DPOS或PBFT等)的不同,達成全部或部分節點的資料全備份。本領域的技術人員熟知,由於區塊鏈系統在相應共識機制下運行,已收錄至區塊鏈資料庫內的資料很難被任意的節點篡改,例如採用Pow共識的區塊鏈,至少需要全網51%算力的攻擊才有可能篡改已有資料,因此區塊鏈系統有著其他中心化資料庫系統所無法比擬的保證資料安全、防攻擊篡改的特性。由此可知,在本說明書所提供的實施例中,被收錄至區塊鏈的分散式資料庫中的資料不會被攻擊或篡改,從而保證了所述參選物件節點所選擇的物件參考數的真實性。 上述實施例所述的參選物件節點可以為參與本說明書所述的隨機物件選取過程的區塊鏈節點、區塊鏈輕節點,還可以為與區塊鏈的節點連接的其他設備終端或客戶端,在本說明書中不作限定。另外,為方便描述本說明書各實施例提供的隨機物件選取方法所基於的區塊鏈技術,本說明書所述的「區塊鏈節點」或「節點」可以包括區塊鏈網路中的節點設備、輕節點設備、其他設備終端或客戶端,以下不再贅述。 上述實施例所述的參選物件節點確定的物件參考數可以是參選物件確定或選取的任意數值,在本說明書中不作限定。參選交易基於上述物件參考數產生,在本說明書中所描述的交易(transaction),是指用戶透過區塊鏈的客戶端創建,並需要最終發布至區塊鏈的分散式資料庫中的一筆資料。其中,區塊鏈中的交易,存在狹義的交易以及廣義的交易之分。狹義的交易是指用戶向區塊鏈發布的一筆價值轉移;例如,在傳統的比特幣區塊鏈網路中,交易可以是用戶在區塊鏈中發起的一筆轉帳。而廣義的交易是指用戶向區塊鏈發布的一筆具有業務意圖的業務資料;例如,本說明書的上述實施例所述的發布至上述區塊鏈中的、基於物件參考數產生的參與本次隨機物件選取過程的一筆或多筆資料,上述參選交易還可以有著既定的資料內容格式,在本說明書中不作限定。 上述實施例所述的第一時段,可以為有著具體物理起始時刻和物理結束時刻的一段物理時間,也可以為以具有邏輯先後順序的兩個事件所確定的起始時刻和解決時刻的一段邏輯時間,更可兼而有之,在本說明書中不作限定。例如,第一時段可以表示為從2018年1月1日零時起至2018年6月30日24時止,也可以表示為從比特幣區塊鏈高度為10000的區塊的產生時刻起至比特幣區塊鏈高度為20000的區塊的產生時刻止,等等。 在本說明書示出的一實施例中,上述參選交易可包括參選物件發布的物件參考數的明文,由於區塊鏈中各個節點設備發布至區塊鏈的交易是公開透明的,上述實施方案通常用於即使得知其他參選物件節點的物件參考數,也不會對自身提供的物件參考數產生任何影響的計算及選取規則中。 在本說明書示出的又一實施例中,由於區塊鏈上的發布的交易可以被區塊鏈的多個或所有節點查看,為防止一參選物件發布的物件參考數被其他參選物件透過區塊鏈獲知,以使其他物件參考數根據所述一參選物件發布的物件參考數,修改本節點尚未發布的物件參考數,而在發布物件參考數的過程中引起不公平現象的發生,可將上述第一時段劃分為至少兩個階段。 在所述第一時段的第一分時段,參選物件節點向上述區塊鏈的分散式資料庫發布第一參選交易,該第一參選交易包含加密後的物件參考數;發布在區塊鏈上的物件參考數密文即使被其他參選物件節點獲知,其他參選物件節點也不能得知物件參考數的實際的值,從而保證發布物件參考數階段的公平性。 在所述第一時段的第二分時段,參選物件節點向上述區塊鏈的分散式資料庫發布第二參選交易,該第二參選交易包含解密後的物件參考數,用以公開自身節點在第一分時段發布的加密的物件參考數;且所述第二分時段為所述第一分時段結束後的時段,在該第二分時段,各參選物件節點已經不可以再發送第一參選交易,因此,有效防止了參選物件節點依據其他參選物件節點公開的物件參考數而修改自身尚未發布的物件參考數的現象發生;所述加密後的物件參考數可被所述解密後的物件參考數證明,保證了參選物件在第二分時段發布的解密後的物件參考數確實為第一分時段發布的加密的物件參考數,防止參選物件在第二分時段篡改自身在第一分時段發布的物件參考數。 在上述實施例中,當參選物件節點所確定的物件參考數為一個或多個亂數時,本領域的技術人員很容易想到,上述第一參選交易所包含的加密後的物件參考數可以為基於上述一個或多個亂數的Pedersen承諾,上述第二參選交易所包含的解密後的物件參考數即可為上述一個或多個亂數。 步驟104,根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,其中,所述指定事件的特徵值為根據預設的映射演算法,對發生在第一時段之後的指定事件計算所得的特徵值,所述指定事件的特徵值在所述指定事件發生之前不可被預知。 上述實施例所述的多個參選物件節點對應的值,是用於對上述多個參選物件進行選擇時所依據的參考值,本說明書並不限定上述預設的計算規則的具體演算法。 上述實施例所述的指定事件為發生在第一時段結束後的一指定事件,為防止該指定事件對應的特徵值具有邏輯可知性而使上述預設的計算規則喪失隨機性和公平性,由該指定事件依據預設的映射演算法算出的特徵值,在該指定事件發生之前是不可被預知的。例如,當一區塊鏈的出塊速率維持為非常穩定的值,那一固定時段後該區塊鏈的區塊高度即為可以預知的值,則上述區塊高度便不可以作為指定事件的特徵值;雖然該區塊高度值可以預知,但該區塊的區塊雜湊值卻是不可被預知的,因此指定固定時段後新生區塊的雜湊值、或指定高度的未來新生區塊的雜湊值均可以作為該指定事件的特徵值參與到上述對多個參選物件節點對應的值的計算中。 本說明書並不限定上述指定事件的類型,例如指定事件可以是某區塊鏈在上述第一時段之後新生的區塊,也可以是第一時段之後發生的彩票中獎號碼,還可以是第一時段之後某醫院的新生兒出生率等任何預設的計算規則規定的指定事件。本說明書也不限定上述指定事件的特徵值的計算方法,例如可以是雜湊等數學摘要演算法、同比或環比增長率等,只要滿足上述指定事件的特徵值是根據預設的映射演算法,對發生在第一時段之後的指定事件計算所得的、在所述指定事件發生之前不可被預知的特徵值,即可至少由上述指定事件的特徵值的隨機性與公平性,確保上述預設的計算規則的隨機性和公平性。 步驟106,根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點。 本說明書中並不限定上述預設的具體選取規則,可以基於上述多個參選物件節點對應的值選擇最大的、或最小的、或中間值、或任一排位的值等對應的參選物件節點,由於本說明書所提供的上述實施例,至少由上述指定事件的特徵值隨機性與公平性,確保上述預設的計算規則的隨機性和公平性,則基於上述計算規則進行選取的選取規則,也具有了相應的隨機性和公平性。 在本說明書提供的一實施例中,上述步驟104和106所述的、根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,和根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點的過程,可以由部署在接收參選交易的區塊鏈上的智慧合約來執行完成。 智慧合約是被區塊鏈的各節點共識、且發布在區塊鏈的分散式資料庫內的一段電腦程式,這種程式經調用而自主地執行全部或部分和合約相關的操作,並產生相應地可以被驗證的證據,來說明執行合約操作的有效性。在部署智慧合約之前,與合約相關的所有條款的邏輯流程就已經被制定好了。智慧合約通常具有一個用戶介面,以供用戶與已制定的合約進行互動,這些互動行為都嚴格遵守此前制定的邏輯。得益於密碼學技術,這些互動行為能夠被嚴格地驗證,以確保合約能夠按照此前制定的規則順利執行,從而防止出現違約行為。 因此,上述步驟104和106的過程包括:調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行程序,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 在上述實施例中,透過將上述計算規則和選取規則編譯部署到智慧合約中,上述智慧合約經由區塊鏈的節點共識同意後才可被部署上鏈,即是首先從其所包含的協議或合約內容上確保了上述計算規則和選取規則的公平性。進一步地,該智慧合約經調用而自主執行,且執行的結果可被該區塊鏈上的任一節點所驗證,更加保證了上述計算和選取過程的公平公正性,有效防止了中心化的隨機物件選取平臺依靠自身的伺服器對上述的計算和選取過程不施行透明公開,而私自操縱上述隨機選取過程的行為。而且,智慧合約可以應區塊鏈節點設備的調用而實時準確執行,方便快捷地進行如上的計算和選取過程。 在本說明書提供的又一實施例中,當多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布第一參選交易,所述第一參選交易包含加密後的物件參考數;且多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布第二參選交易,所述第二參選交易包含解密後的物件參考數,所述第二分時段為所述第一分時段結束後的時段,所述加密後的物件參考數可被所述解密後的物件參考數證明時,上述步驟104和106的過程可以包括:調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行程序,基於指定事件的特徵值和所述第二參選交易對應的物件參考數,分別計算多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 更佳地,上述實施例所述的智慧合約還設置有白名單,在該智慧合約執行步驟104所述的計算步驟時,可基於指定事件的特徵值和所述白名單所包括的參選物件節點發布的第二參選交易所對應的物件參考數,分別計算所述白名單內包含的參選物件節點對應的值,相應地,步驟106所述的選取步驟則應基於上述白名單內包含的參選物件節點對應的值實施。 本說明書並不限定上述白名單的創建條件,在執行本說明書所述的隨機物件選取方法之前,可根據預設的計算規則、選取規則或其他參選規則等為智慧合約的創建過濾條件,過濾條件可包括參選物件節點的身份過濾條件、時間過濾條件、物件參考數過濾條件等等,將符合過濾條件的參選物件節點的公鑰、或帳戶地址、或其他與參選物件節點的身份相關的標識資訊加入到上述白名單,基於白名單內的參選物件節點所提供的物件參考數,執行相應的計算和選取過程。另外值得注意的是,作為本說明書所提供的創建或篩選智慧合約的白名單的一種特殊的實現方式,將不符合條件的參選物件加入智慧合約的黑名單也應在本說明書所提供的技術方案的保護範圍內;以下所述的各種篩選或過濾智慧合約的白名單的方式,也都可以相應地由向智慧合約的黑名單中增加參選物件而實現;或者由同時篩選或過濾白名單用戶且新增黑名單用戶來實現,以下不再贅述。 在一示出的實施例中,上述智慧合約內還宣告有交易驗證程序,透過對參選物件節點發布的交易進行合法性驗證來創建或篩選上述白名單。具體地,在上述區塊鏈的任一節點設備接收多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布的第一參選交易之後,還包括:調用所述智慧合約,執行所述智慧合約中宣告的交易驗證程序,驗證所述第一參選交易是否合法,並將不合法的第一參選交易對應的參選物件從所述智慧合約的白名單中去除。 值得注意的是,上述利用智慧合約對第一參選交易進行合法性驗證通常是應第一參選交易的發布而自動調用的,因此透過上述合法性驗證而篩選白名單的執行過程通常也發生在第一時段的第一分時段。 在又一示出的實施例中,為防止參選物件節點在第二分時段公開的物件參考數與其在第一分時段確定的物件參考數不同,上述區塊鏈的任一節點設備在接收到多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布的第二參選交易之後,還包括:調用所述智慧合約,執行所述智慧合約中宣告的物件參考數驗證程序,驗證所述白名單內的參選物件所發布的第二參選交易所包含的物件參考數是否可驗證所述第一參選交易所包含的物件參考數密文,並將不可驗證的第二參選交易對應的參選物件從所述智慧合約的白名單中去除。 類似地,上述利用智慧合約對第二參選交易進行物件參考數驗證通常是應第二參選交易的發布而自動調用的,因此透過上述合法性驗證而篩選白名單的執行過程通常也發生在第一時段的第二分時段。 透過上述一次或多次的白名單創建或過濾過程,將最終符合各種參選規則設置、且交易內容或格式合格的參選物件甄選出來,針對白名單中的參選物件執行上述的計算及選取步驟,最終公平而隨機地選擇出參選物件。 為了便於理解,下面以區塊鏈網路中的物件節點的抽獎過程為例,對本說明書的技術方案進行詳細說明。本領域的技術人員熟知,本說明書所述的隨機物件選取過程或方法不僅限於抽獎的業務場景,還可適用在任何基於區塊鏈的隨機物件選取以執行任務或分配資源的場景中。圖2是一示例性實施例提供的一種在區塊鏈網路中實施抽獎的示意圖。如圖2所示,假定有用戶P 1,…,P n所對應的節點設備參與本次抽獎過程,其中,本說明書中的「用戶」可以表現為所登錄的用戶帳號或用戶身份公鑰,上述用戶帳號實際可以歸屬於個人或組織甚至終端設備,本說明書並不對此進行限制。 參選用戶設備P 1,…,P n上可以運行有區塊鏈的客戶端程序,使得上述參選用戶設備可作為區塊鏈的節點,根據上述區塊鏈所施行的具體的共識規則,參選用戶節點P 1,…,P n發布的交易可以經區塊鏈上所有或多數節點的共識驗證後被收錄至上述區塊鏈的分散式資料庫中,且上述參選用戶節點P 1,…,P n發布的交易還可以觸發調用部署在上述區塊鏈中的智慧合約,以執行智慧合約宣告的隨機物件選取相關的計算或選取邏輯。上述被收錄至區塊鏈的分散式資料庫中的交易、及由智慧合約執行相關邏輯後的輸出結果均可被上述區塊鏈的任一節點驗證,從而防止其他任何節點或設備對抽獎過程涉及到的參數篡改或對預設的計算或選取規則篡改以操縱抽獎過程。 圖2所示的抽獎過程可以根據時間劃分為三個階段,且使用區塊高度作為邏輯時間計時器,區塊高度為T0-T1為第一階段,區塊高度T1-T2為第二階段,區塊高度T2之後為第三階段,且在圖2所示意的抽獎過程中,將區塊高度為T2+h(h是一個事先規定好的非負整數,比如h可以為1)的區塊的區塊雜湊值作為指定事件的特徵值,參與到本次抽獎的計算過程中來。 步驟201,在區塊高度為T0-T1的第一階段,參選用戶節點P 1,…,P n向區塊鏈的分散式資料庫上發布第一參選交易J 1,…,J n,該第一參選交易是基於參選用戶確定的亂數而加密產生的。在本實施例中,實際具有參選資格的用戶個數可以大於n,但在第一階段結束之前,區塊鏈的分散式資料庫上收到n個參選用戶節點發來的第一參選交易。 在一示出的實施方式中,上述第一參選交易是基於參選用戶確定的兩個亂數(r i,R i)作出的Pedersen承諾——C i=r iG+R iH,其中,G、H為Pedersen承諾的公共參數。本領域的技術人員熟知,為防止其他節點仿冒本節點進而偽造本節點發布的參選交易,參選交易通常包括本節點對參選交易內容的電子簽章,及驗證電子簽章所需的公鑰或地址等身份資訊,因此,上述第一參選交易J i=(C i,p i,S i),其中,p i為參選用戶的公鑰,S i為參選用戶節點i利用公鑰p i對應的私鑰、對包括Pedersen承諾C i的交易內容所作的電子簽章。 步驟202,在區塊高度為T0-T1的第一階段,智慧合約對上述第一參選交易進行交易合法性驗證,並根據上述驗證的結果篩選白名單。 上述區塊鏈上可部署有執行抽獎業務邏輯的智慧合約,且該智慧合約宣告有對上述第一參選交易進行交易的合法性驗證的邏輯程序,並隨第一參選交易的發布而被調用,例如,將上述第一參選交易J i=(C i,p i,S i)發送至上述智慧合約的地址以調用上述智慧合約。上述合法性驗證可以包括:該用戶是否在可參選的用戶列表中,電子簽章是否合法、或物件參考數的加密方式是否符合要求、或同一參選用戶是否有雙重提交等方面。該智慧合約可預先設置具有參選資格的用戶白名單,透過對第一參選交易的格式或內容的驗證,執行對該用戶白名單篩選過程。可選地,該智慧合約還可透過本次對第一參選交易的合法性驗證而首次創建白名單。本發明對該智慧合約的白名單的具體設置時機和條件並不作限定。可選的,該智慧合約還可將不合法的第一參選交易對應的參選用戶加入到黑名單中,以作為創建或篩選白名單的一種特殊的實施方式。 在示出的一實施例中,上述智慧合約的白名單內收錄了合法的第一參選交易所對應的參選用戶的公鑰p i。 步驟203,在區塊高度為T1-T2的第二階段,參選用戶P i公開其在第一階段選擇確定的的亂數(r i,R i),該公開過程可以包括:參選用戶P i首先對(r i,R i)進行電子簽章S' i,再向區塊鏈的分散式資料庫提交第二參選交易J' i=(p i,r i,R i,S' i)。 步驟204,在區塊高度為T1-T2的第二階段,智慧合約對上述第二參選交易所包含的亂數是否可以證明上述第一參選交易的亂數密文而進行驗證,並根據上述驗證的結果篩選白名單。 上述區塊鏈上部署的關於抽獎業務邏輯的智慧合約還可宣告有物件參考數驗證程序,用以驗證白名單中的參選用戶所發布的第二參選交易所包含的亂數(r i,R i)是否可驗證該參選用戶之前所發布的第一參選交易所包含的亂數密文C i,並將不可驗證的第二參選交易對應的參選用戶從上述智慧合約的白名單中去除。上述智慧合約中宣告的物件參考數驗證程序可以隨著第二參選交易的發布被調用,例如將第二參選交易J'i=(p i,r i,R i,S' i)發送至上述智慧合約的地址以調用上述智慧合約,驗證同一參選用戶發布的第二參選交易是否能與其發布的第一參選交易基於相同的亂數,進一步防止參選用戶可能發生的錯誤行為而影響抽獎結果的公平性。 步驟205,在區塊高度T2之後的階段,在上述關於抽獎業務邏輯的智慧合約執行完對步驟202所觸發的對第二參選交易的驗證後,應指定事件發生的觸發或應其他指令的觸發,進一步執行所述智慧合約中宣告的、與該抽獎的計算規則對應的執行程序。圖2所述的指定事件為高度為T2+h的區塊的產生,且約定該T2+h的區塊的區塊雜湊值作為指定事件的特徵值H 0,上述關於抽獎業務邏輯的智慧合約基於指定事件的特徵值R和白名單內的參選用戶P j1,…,P jm對應的亂數(r ji,R ji)分別計算白名單內的參選用戶節點對應的值H'' i。 圖2所述實施例中白名單內的參選用戶節點對應的值H'' i的計算規則定義如下: H i=Hash (p ji, R ji); H' i=Hash (H i, H 0); H'' i=|H' i-H i|。 步驟206,上述智慧合約依據上述計算規則逐一計算H'' i的值,且從H'' 1,…,H'' m中選擇符合預設的選擇規則的H'' k對應的參選用戶P k作為中獎用戶,輸出該參選用戶的公鑰或其他身份標識,用以公佈中獎用戶。 本領域的技術人員熟知,本說明書提供的隨機物件選取方法並不限定隨機物件選取所依據的具體的計算規則或選取規則;而且,執行圖2所示的抽獎過程的三個階段所對應的智慧合約既可以為同一個智慧合約,也可以為不同的智慧合約,在本說明書中也不作限定。 圖2所示的基於本說明書所提供的隨機物件選取方法的抽獎過程,依賴於參選用戶提供亂數和在提供亂數階段結束後發生的、不可被預測的指定區塊的區塊雜湊值進行計算,利用區塊鏈的防篡改機制保證了上述抽獎過程免於人為操縱而產生不公平的結果;而且,圖2所示的抽獎過程,依賴於智慧合約自主完成上述對用戶提供亂數的驗證、及基於指定事件的特徵值和上述亂數的計算和選取過程,全程避免了人為參與,且抽獎全過程在區塊鏈上透明可見、可被驗證,更加自主、準確、公平地執行了上述的抽獎過程。 與上述流程實現對應,本說明書的實施例還提供了一種基於區塊鏈的隨機物件選取裝置。該裝置可以透過軟體實現,也可以透過硬體或者軟硬體結合的方式實現。以軟體實現為例,作為邏輯意義上的裝置,是透過所在設備的CPU(Central Process Unit,中央處理器)將對應的電腦程式指令讀取到內部記憶體中運行形成的。從硬體層面而言,除了圖4所示的CPU、內部記憶體以及記憶體之外,網路風險業務的實現裝置所在的設備通常還包括用於進行無線信號收發的晶片等其他硬體,和/或用於實現網路通信功能的板卡等其他硬體。 圖3所示為一種基於區塊鏈的隨機物件選取裝置30,應用於包含多個參選物件節點的區塊鏈,所述裝置30包括: 接收單元302,接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,所述參選交易基於所述參選物件節點確定的物件參考數產生; 計算單元304,根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,其中,所述指定事件的特徵值為根據預設的映射演算法,對發生在所述第一時段之後的指定事件計算所得的特徵值,所述指定事件的特徵值在所述指定事件發生之前不可被預知; 選取單元306,根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點。 在本說明書示出的又一實施例中,所述計算單元304: 調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行程序,基於指定事件的特徵值和參選交易對應的物件參考數分別計算多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 在本說明書示出的又一實施例中,所述接收單元302: 接收多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布的第一參選交易,所述第一參選交易包含加密後的物件參考數; 接收多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布的第二參選交易,所述第二參選交易包含解密後的物件參考數; 其中,所述第二分時段為所述第一分時段結束後的時段,所述加密後的物件參考數可被所述解密後的物件參考數證明。 在本說明書示出的又一實施例中,所述計算單元304: 調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行程序,基於指定事件的特徵值和所述第二參選交易對應的物件參考數,分別計算多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 在本說明書示出的又一實施例中,所述智慧合約設置有白名單; 所述計算單元304: 基於指定事件的特徵值和所述白名單所包括的參選物件節點發布的第二參選交易所對應的物件參考數,分別計算所述白名單內包含的參選物件節點對應的值。 在本說明書示出的又一實施例中,所述接收單元302在接收多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布的第一參選交易之後,還用於: 調用所述智慧合約,執行所述智慧合約中宣告的交易驗證程序,驗證所述第一參選交易是否合法,並將合法的第一參選交易對應的參選物件加入到所述智慧合約的白名單。 在本說明書示出的又一實施例中,所述接收單元302在接收多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布的第二參選交易之後,還用於: 調用所述智慧合約,執行所述智慧合約中宣告的物件參考數驗證程序,驗證所述白名單內的參選物件所發布的第二參選交易所包含的物件參考數是否可驗證所述第一參選交易所包含的物件參考數密文,並將不可驗證的第二參選交易對應的參選物件從所述智慧合約的白名單中去除。 在本說明書示出的又一實施例中,所述指定事件的特徵值為所述區塊鏈在所述第一時段之後產生的指定區塊的雜湊值。 在本說明書示出的又一實施例中,所述第一時段為與所述區塊鏈的區塊高度相關的邏輯時段。 在本說明書示出的又一實施例中,所述物件參考數為亂數,所述加密後的物件參考數為基於所述亂數的Pedersen承諾。 上述裝置中各個單元的功能和作用的實現過程具體詳見上述方法中對應步驟的實現過程,相關之處參見方法實施例的部分說明即可,在此不再贅述。 以上所描述的裝置實施例僅僅是示意性的,其中所述作為分離部件說明的單元可以是或者也可以不是物理上分開的,作為單元顯示的部件可以是或者也可以不是物理模組,即可以位於一個地方,或者也可以分佈到多個網路模組上。可以根據實際的需要選擇其中的部分或者全部單元或模組來實現本說明書方案的目的。本發明所屬技術領域中具有通常知識者在不付出創造性勞動的情況下,即可以理解並實施。 上述實施例闡明的裝置、單元、模組,具體可以由電腦晶片或實體實現,或者由具有某種功能的產品來實現。一種典型的實現設備為電腦,電腦的具體形式可以是個人電腦、膝上型電腦、蜂巢式電話、相機電話、智慧電話、個人位助理、媒體播放器、導航設備、電子郵件收發設備、遊戲控制台、平板電腦、穿戴式設備或者這些設備中的任意幾種設備的組合。 與上述方法實施例相對應,本說明書的實施例還提供了一種電腦設備,該電腦設備包括記憶體和處理器。其中,記憶體上儲存有能夠由處理器運行的電腦程式;處理器在運行儲存的電腦程式時,執行本說明書實施例中基於區塊鏈的隨機物件選取方法的各個步驟。對基於區塊鏈的隨機物件選取方法的各個步驟的詳細描述請參見之前的內容,不再重複。 與上述方法實施例相對應,本說明書的實施例還提供了一種電腦可讀儲存媒體,該儲存媒體上儲存有電腦程式,這些電腦程式在被處理器運行時,執行本說明書實施例中基於區塊鏈的隨機物件選取方法的各個步驟。對基於區塊鏈的隨機物件選取方法的各個步驟的詳細描述請參見之前的內容,不再重複。 以上所述僅為本說明書的較佳實施例而已,並不用以限制本說明書,凡在本說明書的精神和原則之內,所做的任何修改、等同替換、改進等,均應包含在本說明書保護的範圍之內。 在一個典型的配置中,計算設備包括一個或多個處理器(CPU)、輸入/輸出介面、網路介面和內部記憶體。 內部記憶體可能包括電腦可讀媒體中的非永久性記憶體,隨機存取記憶體(RAM)和/或非易失性內部記憶體等形式,如唯讀記憶體(ROM)或閃存(flash RAM)。內部記憶體是電腦可讀媒體的示例。 電腦可讀媒體包括永久性和非永久性、可移動和非可移動媒體可以由任何方法或技術來實現資訊儲存。資訊可以是電腦可讀指令、資料結構、程式的模組或其他資料。 電腦的儲存媒體的例子包括,但不限於相變內部記憶體(PRAM)、靜態隨機存取記憶體(SRAM)、動態隨機存取記憶體(DRAM)、其他類型的隨機存取記憶體(RAM)、唯讀記憶體(ROM)、電可擦除可編程唯讀記憶體(EEPROM)、快閃記憶體或其他內部記憶體技術、唯讀光碟唯讀記憶體(CD-ROM)、數字多功能光碟(DVD)或其他光學儲存、磁盒式磁帶,磁帶磁碟儲存或其他磁性儲存設備或任何其他非傳輸媒體,可用於儲存可以被運算設備訪問的資訊。按照本文中的界定,電腦可讀媒體不包括暫態性電腦可讀媒體(transitory media),如調變的資料信號和載波。 還需要說明的是,術語「包括」、「包含」或者其任何其他變體意在涵蓋非排他性的包含,從而使得包括一系列元件的過程、方法、商品或者設備不僅包括那些元件,而且還包括沒有明確列出的其他元件,或者是還包括為這種過程、方法、商品或者設備所固有的元件。在沒有更多限制的情況下,由語句「包括一個……」限定的元件,並不排除在包括所述元件的過程、方法、商品或者設備中還存在另外的相同元件。 本領域技術人員應明白,本說明書的實施例可提供為方法、系統或電腦程式產品。因此,本說明書的實施例可採用完全硬體實施例、完全軟體實施例或結合軟體和硬體方面的實施例的形式。而且,本說明書的實施例可採用在一個或多個其中包含有電腦可用程式碼的電腦可用儲存媒體(包括但不限於磁碟記憶體、CD-ROM、光學記憶體等)上實施的電腦程式產品的形式。 Exemplary embodiments will be described in detail here, examples of which are shown in the drawings. When the following description refers to drawings, unless otherwise indicated, the same numerals in different drawings represent the same or similar elements. The implementations described in the following exemplary embodiments do not represent all implementations consistent with one or more embodiments of this specification. Rather, they are merely examples of devices and methods that are consistent with some aspects of one or more embodiments of this specification, as detailed in the appended patent application. It should be noted that in other embodiments, the steps of the corresponding method are not necessarily performed in the order shown and described in this specification. In some other embodiments, the method may include more or fewer steps than described in this specification. In addition, the single step described in this specification may be decomposed into multiple steps for description in other embodiments; and the multiple steps described in this specification may also be combined into a single step in other embodiments. description. As shown in FIG. 1, an exemplary embodiment of the present specification provides a random object selection method based on a blockchain, which is applied to a blockchain including a plurality of candidate object nodes. The method includes: Step 102, receiving multiple Participating object nodes publish the participating transactions to the distributed database of the blockchain in the first period, and the participating transactions are generated based on the object reference number selected by the participating object nodes. The blockchain described in the above embodiment may specifically refer to a P2P network system with distributed data storage structure achieved by each node through a consensus mechanism. The data in the blockchain is distributed in time and connected to each other. Within the "block", the latter block contains the data summary of the previous block, and according to the specific consensus mechanism (such as POW, POS, DPOS, or PBFT, etc.), all or part of the node's data is achieved. Backup. Those skilled in the art are familiar with the fact that since the blockchain system operates under the corresponding consensus mechanism, the data that has been included in the blockchain database is difficult to be tampered with by any node. For example, the blockchain using Pow consensus requires at least a full Only an attack of 51% of the network's computing power is likely to tamper with the existing data. Therefore, the blockchain system has the characteristics of ensuring data security and preventing attack and tampering that are unmatched by other centralized database systems. It can be seen that, in the embodiment provided in this specification, the data included in the distributed database of the blockchain will not be attacked or tampered, thereby ensuring the reference number of objects selected by the participating object nodes Authenticity. The participating object nodes described in the above embodiments may be blockchain nodes, blockchain light nodes participating in the random object selection process described in this specification, or other device terminals or customers connected to the blockchain nodes It is not limited in this specification. In addition, in order to facilitate the description of the blockchain technology on which the random object selection methods provided by the embodiments of this specification are based, the “blockchain nodes” or “nodes” described in this specification may include node devices in the blockchain network , Light node devices, other device terminals or clients, which will not be repeated below. The object reference number determined by the participating object node described in the foregoing embodiment may be any value determined or selected by the participating object, and is not limited in this specification. The participation transaction is generated based on the above object reference number. The transaction described in this specification refers to a transaction created by the user through the client of the blockchain and needs to be finally released to the distributed database of the blockchain. data. Among them, there are transactions in the narrow sense and transactions in the broad sense in the blockchain. A narrowly defined transaction refers to a value transfer issued by the user to the blockchain; for example, in the traditional Bitcoin blockchain network, the transaction can be a transfer initiated by the user in the blockchain. The generalized transaction refers to a piece of business data released by the user to the blockchain with business intent; for example, the participation in this time based on the reference number of objects posted to the blockchain as described in the above embodiments of this specification One or more pieces of data in the random object selection process, the above-mentioned participation transaction can also have a predetermined data content format, which is not limited in this manual. The first time period described in the above embodiment may be a period of physical time with a specific physical start time and physical end time, or a period of start time and resolution time determined by two events having a logical sequence Logical time can be both, and is not limited in this manual. For example, the first time period can be expressed as from 0:00 on January 1, 2018 to 24:00 on June 30, 2018, or from the generation time of a block with a Bitcoin blockchain height of 10,000 to The generation time of blocks with a Bitcoin blockchain height of 20,000, and so on. In an embodiment shown in this specification, the above-mentioned participating transaction may include the plain text of the object reference number issued by the participating object. Since the transaction issued by each node device in the blockchain to the blockchain is open and transparent, the above implementation The scheme is usually used in calculation and selection rules that let you know the object reference numbers of other participating object nodes and will not have any impact on the object reference numbers provided by yourself. In yet another embodiment shown in this specification, since the published transactions on the blockchain can be viewed by multiple or all nodes of the blockchain, in order to prevent the reference number of objects published by one participating object from being rejected by other participating objects Learned through the blockchain, so that other object reference numbers modify the object reference numbers that have not been released by this node according to the object reference numbers issued by the one selected object, and cause unfairness in the process of publishing the object reference numbers , The above first period may be divided into at least two stages. In the first sub-period of the first period, the participating object node publishes the first participating transaction to the distributed database of the blockchain, the first participating transaction includes the encrypted object reference number; Even if the ciphertext of the object reference number on the block chain is known by other candidate object nodes, the other candidate object nodes cannot know the actual value of the object reference number, thus ensuring the fairness of the stage of issuing the object reference number. In the second sub-period of the first period, the candidate object node issues a second candidate transaction to the decentralized database of the blockchain. The second candidate transaction includes the decrypted object reference number for disclosure The reference number of the encrypted object issued by the own node in the first sub-period; and the second sub-period is the time period after the end of the first sub-period. In this second sub-period, each participating object node can no longer The first reference transaction is sent, thus effectively preventing the reference object node from modifying the reference number of the object that has not been released according to the reference number of objects disclosed by other reference object nodes; the encrypted object reference number can be used The decrypted object reference number certificate ensures that the decrypted object reference number issued by the candidate object in the second divided period is indeed the encrypted object reference number issued in the first divided period, preventing the candidate object from being distributed in the second The time period tampers with the reference number of objects released by itself in the first minute period. In the above embodiment, when the object reference number determined by the participating object node is one or more random numbers, those skilled in the art can easily think of the encrypted object reference number included in the first participating exchange It may be a Pedersen commitment based on the one or more random numbers, and the reference number of the decrypted object included in the second candidate exchange may be the one or more random numbers. Step 104: According to a preset calculation rule, calculate values corresponding to a plurality of candidate object nodes based on the feature value of the designated event and the object reference number corresponding to the candidate transaction, wherein the feature value of the designated event is based on a preset The mapping algorithm calculates the characteristic value of the specified event that occurs after the first period of time. The characteristic value of the specified event cannot be predicted before the specified event occurs. The values corresponding to the multiple candidate object nodes described in the above embodiments are the reference values used to select the multiple candidate objects. This specification does not limit the specific algorithm of the preset calculation rule . The designated event described in the above embodiment is a designated event that occurs after the end of the first time period. To prevent the characteristic value corresponding to the designated event from being logically known, the preset calculation rule loses randomness and fairness, by The characteristic value calculated by the specified event according to the preset mapping algorithm is unpredictable before the specified event occurs. For example, when the block-out rate of a blockchain is maintained at a very stable value, the block height of the blockchain after a fixed period of time is a predictable value, then the above block height cannot be used as a specified event Characteristic value; although the block height value can be predicted, the block hash value of the block is unpredictable, so the hash value of the new block after a fixed period of time, or the hash of the future new block at a specified height The values can all be used as the characteristic values of the specified event to participate in the calculation of the values corresponding to the plurality of candidate object nodes. This specification does not limit the types of the above-mentioned designated events. For example, the designated event may be a new block of a blockchain after the above-mentioned first period, or a lottery winning number after the first period, or it may be the first period. Afterwards, the birth rate of a newborn in a hospital and other specified events specified by any preset calculation rules. This specification also does not limit the calculation method of the eigenvalues of the above-mentioned designated events. For example, it may be a mathematical summary algorithm such as hashing, year-on-year or chain growth rate, etc., as long as the eigenvalues of the above-mentioned designated events are based on the preset mapping algorithm. The characteristic value calculated after the specified event that occurs after the first period of time and unpredictable before the specified event occurs can be ensured by at least the randomness and fairness of the characteristic value of the specified event The randomness and fairness of the rules. Step 106: Select a candidate object node based on the corresponding values of the multiple candidate object nodes according to a preset selection rule. This specification does not limit the specific selection rules of the preset, and the corresponding selections such as the largest, the smallest, or the intermediate value, or the value of any rank can be selected based on the values corresponding to the multiple object nodes The object node, due to the above-mentioned embodiments provided in this specification, at least the randomness and fairness of the characteristic values of the specified events to ensure the randomness and fairness of the preset calculation rules are selected based on the calculation rules The rules also have corresponding randomness and fairness. In an embodiment provided in this specification, according to the preset calculation rules described in steps 104 and 106 above, based on the characteristic value of the specified event and the reference number of the object corresponding to the participating transaction, the corresponding correspondences between multiple participating object nodes are calculated. , And the process of selecting a candidate object node based on the corresponding values of the multiple candidate object nodes according to the default selection rules can be performed by a smart contract deployed on the blockchain that receives the candidate transaction . A smart contract is a piece of computer program that is agreed by each node of the blockchain and published in the distributed database of the blockchain. This program is called to autonomously perform all or part of the contract-related operations and generate corresponding The ground can be verified by the evidence to explain the effectiveness of the execution of the contract operation. Before deploying a smart contract, the logical flow of all terms related to the contract has been formulated. Smart contracts usually have a user interface for users to interact with established contracts. These interactions strictly follow the previously established logic. Thanks to cryptography technology, these interactive behaviors can be strictly verified to ensure that the contract can be executed smoothly in accordance with the previously established rules, thereby preventing breaches. Therefore, the above steps 104 and 106 include: calling a smart contract published on the blockchain, executing the execution program corresponding to the calculation rule and the selection rule declared in the smart contract, based on the specified event The characteristic value of and the reference number of the object corresponding to the participating transaction respectively calculate the values corresponding to the multiple object nodes, and select the object node based on the values corresponding to the plurality of object nodes. In the above embodiment, by compiling and deploying the above calculation rules and selection rules into the smart contract, the above smart contract can be deployed on the chain only after the consensus of the nodes of the blockchain, that is, from the protocol or The content of the contract ensures the fairness of the above calculation rules and selection rules. Further, the smart contract is executed autonomously upon invocation, and the result of the execution can be verified by any node on the blockchain, which further ensures the fairness and fairness of the above calculation and selection process and effectively prevents centralized randomization The object selection platform relies on its own server to not transparently disclose the above calculation and selection process, but privately manipulates the behavior of the above random selection process. Moreover, the smart contract can be accurately executed in real time in response to the call of the blockchain node device, and the above calculation and selection process can be performed conveniently and quickly. In yet another embodiment provided by this specification, when a plurality of candidate object nodes publish a first candidate transaction to the decentralized database of the blockchain during the first sub-period of the first period, the first An election transaction includes the encrypted object reference number; and a plurality of election object nodes publish the second election transaction to the distributed database of the blockchain in the second sub-period of the first time period. The second election transaction includes the decrypted object reference number, the second sub-period is the time period after the end of the first sub-period, the encrypted object reference number can be used by the decrypted object reference number For certification, the above steps 104 and 106 may include: calling a smart contract published on the blockchain, and executing the execution program corresponding to the calculation rule and the selection rule declared in the smart contract, based on The feature value of the designated event and the object reference number corresponding to the second participating transaction are respectively calculated for the values corresponding to the multiple participating object nodes, and the participating object nodes are selected based on the values corresponding to the multiple participating object nodes. More preferably, the smart contract described in the above embodiment is also provided with a white list, and when the smart contract performs the calculation step described in step 104, it may be based on the feature value of the specified event and the candidate objects included in the white list The reference number of the object corresponding to the second candidate exchange issued by the node respectively calculates the value corresponding to the node of the candidate object included in the white list. Accordingly, the selection step described in step 106 should be based on the The value corresponding to the candidate object node is implemented. This specification does not limit the creation conditions of the above whitelist. Before executing the random object selection method described in this specification, you can create filter conditions for smart contract creation according to preset calculation rules, selection rules, or other selection rules. Conditions can include the identity filtering conditions, time filtering conditions, object reference number filtering conditions, etc. of the candidate object node, the public key, or account address, or other identity of the candidate object node that will meet the filter conditions The relevant identification information is added to the above-mentioned white list, and the corresponding calculation and selection process is performed based on the object reference number provided by the participating object nodes in the white list. It is also worth noting that as a special implementation of the whitelist for creating or filtering smart contracts provided in this manual, adding unqualified candidate objects to the blacklist of smart contracts should also be based on the technology provided in this manual. Within the scope of protection of the scheme; the various methods of filtering or filtering the white list of smart contracts described below can also be achieved by adding candidate objects to the black list of the smart contract accordingly; or by filtering or filtering the white list at the same time Users and new blacklist users to achieve, will not repeat them below. In an illustrated embodiment, a transaction verification program is also declared in the smart contract, and the white list is created or filtered by verifying the validity of the transaction issued by the candidate object node. Specifically, after any node device of the above-mentioned blockchain receives the first candidature transaction issued by multiple candidate object nodes to the distributed database of the blockchain in the first sub-period of the first time period , Which also includes: calling the smart contract, executing the transaction verification procedure declared in the smart contract, verifying whether the first contest transaction is legal, and removing the contest object corresponding to the illegal first contest transaction from all Removed from the white list of smart contracts. It is worth noting that the above-mentioned use of smart contracts to verify the legitimacy of the first candidate transaction is usually automatically called upon the issuance of the first candidate transaction. Therefore, the execution process of filtering the white list through the above-mentioned legitimacy verification usually also occurs In the first sub-period of the first period. In yet another illustrated embodiment, in order to prevent the object reference numbers disclosed by the participating object nodes in the second sub-period from being different from the object reference numbers determined in the first sub-period, any node device of the above-mentioned blockchain is receiving After the second participating transaction that multiple participating object nodes publish to the distributed database of the blockchain in the second sub-period of the first time period, the method further includes: calling the smart contract and executing the An object reference number verification procedure declared in the smart contract, to verify whether the object reference numbers included in the second candidate exchange issued by the candidate objects in the white list can verify the objects included in the first candidate exchange Refer to the digital ciphertext, and remove the candidate object corresponding to the unverifiable second candidate transaction from the white list of the smart contract. Similarly, the use of smart contracts to verify the object reference number of the second candidate transaction is usually automatically invoked in response to the issuance of the second candidate transaction, so the process of filtering the white list through the above-mentioned legality verification usually also occurs in The second sub-period of the first period. Through the one or more whitelist creation or filtering processes mentioned above, the selection objects that finally meet the various selection rule settings and the transaction content or format are qualified are selected, and the above calculation and selection are performed for the selection objects in the whitelist In the step, the candidate objects are finally selected fairly and randomly. For ease of understanding, the technical solution of this specification will be described in detail below by taking the lottery process of object nodes in the blockchain network as an example. It is well known to those skilled in the art that the random object selection process or method described in this specification is not limited to the business scenario of lottery drawing, but can also be applied to any scenario where blockchain-based random object selection is used to perform tasks or allocate resources. 2 is a schematic diagram of a lottery implemented in a blockchain network provided by an exemplary embodiment. As shown in FIG. 2, assume that the node devices corresponding to users P 1 , ..., P n participate in this lottery process, where “user” in this specification can be represented as a logged-in user account or user identity public key, The above user accounts can actually belong to individuals or organizations or even terminal devices, and this manual does not limit this. The candidate user devices P 1 ,..., P n can run a client program of the blockchain, so that the candidate user device can be used as a node of the blockchain, according to the specific consensus rules implemented by the blockchain, The transactions issued by the participating user nodes P 1 , ..., P n can be included in the distributed database of the above-mentioned blockchain after being verified by consensus of all or most nodes on the blockchain, and the above-mentioned participating user node P 1 ..., P n issued transactions can also trigger calls to smart contracts deployed in the above-mentioned blockchains to perform calculations or selection logic related to the selection of random objects declared by the smart contracts. The above-mentioned transactions included in the distributed database of the blockchain, and the output results after the execution of the relevant logic by the smart contract can be verified by any node of the above-mentioned blockchain, thereby preventing any other nodes or devices from the lottery process Involve parameter tampering or tampering with preset calculations or selection rules to manipulate the lottery process. The lottery process shown in Figure 2 can be divided into three stages according to time, and the block height is used as the logical time timer, the block height is T0-T1 is the first stage, and the block height T1-T2 is the second stage, The block height T2 is the third stage, and in the lottery process illustrated in Figure 2, the block height is T2+h (h is a predetermined non-negative integer, such as h can be 1) The block hash value is used as the characteristic value of the specified event and participates in the calculation process of this lottery. Step 201, in the first stage with a block height of T0-T1, the participating user nodes P 1 ,..., P n publish the first participating transaction J 1 ,..., J n to the distributed database of the blockchain The first candidate transaction is encrypted based on the random number determined by the candidate. In this embodiment, the actual number of qualified users can be greater than n, but before the end of the first phase, the distributed database of the blockchain receives the first parameters sent by n participating user nodes Choose transactions. In an illustrated embodiment, the above-mentioned first candidate transaction is a Pedersen commitment made based on two random numbers (r i , R i ) determined by the candidate user—C i =r i G+R i H, Among them, G and H are public parameters promised by Pedersen. It is well known to those skilled in the art that in order to prevent other nodes from spoofing this node and forging the participation transaction issued by this node, the participation transaction usually includes the electronic signature of the node on the content of the participation transaction and the public signature required to verify the electronic signature. Identity information such as key or address, therefore, the above-mentioned first candidate transaction J i =(C i , p i , S i ), where p i is the public key of the candidate user and S i is used by the candidate user node i The private key corresponding to the public key p i and the electronic signature made on the transaction content including Pedersen's commitment C i . Step 202: In the first stage where the block height is T0-T1, the smart contract performs transaction legality verification on the above-mentioned first candidate transaction, and screens the white list according to the verification result. A smart contract that executes the business logic of the lottery can be deployed on the above blockchain, and the smart contract declares that there is a logic program for verifying the legality of the transaction for the above-mentioned first candidate transaction, and is issued with the release of the first candidate transaction Call, for example, send the above-mentioned first candidate transaction J i =(C i , p i , S i ) to the address of the above-mentioned smart contract to call the above-mentioned smart contract. The above-mentioned legality verification may include: whether the user is in the list of available users, whether the electronic signature is legal, or whether the encryption method of the object reference number meets the requirements, or whether the same participating user has double submission. The smart contract may pre-set a whitelist of users who are eligible to participate in the election, and perform a screening process for the whitelist of users by verifying the format or content of the first contest. Optionally, the smart contract can also create a whitelist for the first time through the verification of the legitimacy of the first participating transaction. The present invention does not limit the specific setting timing and conditions of the white list of the smart contract. Optionally, the smart contract may also add candidate users corresponding to the illegal first candidate transaction to the blacklist as a special implementation for creating or filtering whitelists. In the illustrated embodiment, the whitelist of the smart contract contains the public key p i of the participating user corresponding to the legitimate first participating exchange. Step 203, in the second stage where the block height is T1-T2, the participating user P i discloses the random number (r i , R i ) selected in the first stage. The disclosure process may include: participating users first, P i (r i, R i) electronic signature S 'i, submitted again distributed database transaction candidates second block chain J' i = (p i, r i, R i, S ' i ). Step 204: In the second stage of block height T1-T2, the smart contract verifies whether the random number included in the second candidate exchange can prove the random number ciphertext of the first candidate transaction and based on The results of the above verification filter the white list. The smart contract on the lottery business logic deployed on the above blockchain can also declare an object reference number verification procedure to verify the random number contained in the second candidate exchange issued by the candidate users in the white list (r i , R i ) whether it is possible to verify the random number cipher text C i included in the first participating exchange previously released by the participating user, and remove the unverifiable second participating transaction corresponding to the participating user from the above smart contract’s Removed from the white list. Wisdom above objects declared in the contract with reference number verification program can be invoked with the release of the second candidate transaction, for example, the second candidate transaction J'i = (p i, r i , R i, S 'i) transmit Go to the address of the above smart contract to call the above smart contract to verify whether the second contest transaction issued by the same contestant can be based on the same random number as the first contest transaction published by the contestant, to further prevent possible misbehaviors of contestants And affect the fairness of the draw results. Step 205, in the stage after the block height T2, after the above smart contract regarding the lottery business logic executes the verification of the second candidate transaction triggered by step 202, it should specify the trigger of the occurrence of the event or should be other instructions Trigger to further execute the execution program declared in the smart contract and corresponding to the calculation rule of the lottery. The designated event described in FIG. 2 is the generation of a block with a height of T2+h, and the block hash value of the T2+h block is agreed as the eigenvalue H 0 of the designated event. The above smart contract regarding the business logic of the lottery Based on the feature value R of the specified event and the random users ( j ji , R ji ) corresponding to the candidate users P j1 , ..., P jm in the white list, the values H'' i corresponding to the candidate user nodes in the white list are calculated respectively . FIG 2 in the user node candidates embodiment whitelist embodiment corresponding value H 'calculating rule i is defined as follows: H i = Hash (p ji , R ji); H' i = Hash (H i, H 0 ); H'' i =|H' i -H i |. Step 206, the above wisdom contract individually calculating H 'according to the above-described calculation rule' value of i, and the H '' H conforms to a predetermined selection rule to select the m '' 1, ..., H ' ' k corresponding to the user election As a winning user, P k outputs the public key or other identity of the participating user to announce the winning user. It is well known to those skilled in the art that the random object selection method provided in this specification does not limit the specific calculation rules or selection rules on which random object selection is based; moreover, the wisdom corresponding to the three stages of performing the lottery process shown in FIG. 2 The contract can be either the same smart contract or different smart contracts, and is not limited in this manual. The lottery process shown in Figure 2 based on the random object selection method provided in this specification relies on the random hash provided by the participating user and the block hash value of the specified block that occurs after the end of the random number provision stage and is unpredictable Perform calculations and use the blockchain's anti-tampering mechanism to ensure that the above lottery process is free from artificial manipulation and produce unfair results; moreover, the lottery process shown in Figure 2 relies on smart contracts to independently complete the above-mentioned random number of users. The verification and calculation and selection process based on the characteristic values of the specified events and the above random numbers avoid human participation throughout the process, and the whole lottery process is transparently visible on the blockchain, can be verified, and is more autonomous, accurate and fair. The above lottery process. Corresponding to the above process implementation, the embodiments of the present specification also provide a random object selection device based on blockchain. The device can be realized by software, or by hardware or a combination of hardware and software. Taking software implementation as an example, as a logical device, it is formed by reading the corresponding computer program instructions into the internal memory through the CPU (Central Process Unit) of the device. From the hardware level, in addition to the CPU, internal memory, and memory shown in FIG. 4, the equipment where the network risk service implementation device is located usually includes other hardware such as chips for wireless signal transmission and reception. And/or other hardware such as boards for network communication. FIG. 3 shows a random object selection device 30 based on a blockchain, which is applied to a blockchain including multiple candidate object nodes. The device 30 includes: a receiving unit 302 that receives multiple candidate object nodes in the first Participating transactions issued to the distributed database of the blockchain within a period of time, the participating transactions are generated based on the object reference number determined by the participating object nodes; the calculation unit 304, based on the preset calculation rules, is based on The characteristic value of the specified event and the reference number of the object corresponding to the participating transaction respectively calculate the values corresponding to multiple participating object nodes, wherein the characteristic value of the specified event is based on the preset mapping algorithm A characteristic value calculated after a specified event after a period of time, and the characteristic value of the specified event cannot be predicted before the specified event occurs; the selection unit 306, based on the preset selection rules, is based on the plurality of candidate object nodes The corresponding value selects the object node. In yet another embodiment shown in this specification, the calculation unit 304: invokes a smart contract published on the blockchain, and executes the calculation rules and the selection rules declared in the smart contract Executes the program, calculates the values corresponding to multiple candidate object nodes based on the feature value of the specified event and the object reference number corresponding to the candidate transaction, and selects the candidate object node based on the values corresponding to the multiple candidate object nodes. In yet another embodiment shown in this specification, the receiving unit 302: receives the first article published by multiple candidate object nodes to the distributed database of the blockchain in the first sub-period of the first period An election transaction, the first election transaction includes the encrypted object reference number; receiving multiple election object nodes into the distributed database of the blockchain in the second sub-period of the first time period A second participating transaction issued, the second participating transaction includes the decrypted object reference number; wherein, the second sub-period is the time period after the end of the first sub-period, and the encrypted object reference The number can be proved by the decrypted object reference number. In yet another embodiment shown in this specification, the calculation unit 304: invokes a smart contract published on the blockchain, and executes the calculation rules and the selection rules declared in the smart contract The execution procedure of is based on the characteristic value of the specified event and the object reference number corresponding to the second participating transaction, respectively calculating the values corresponding to multiple participating object nodes, and selecting based on the values corresponding to the multiple participating object nodes Refer to the object node. In yet another embodiment shown in this specification, the smart contract is provided with a white list; the calculation unit 304: based on the feature value of the specified event and the second parameter issued by the participating object node included in the white list Select the reference number of the object corresponding to the exchange, and calculate the value corresponding to the node of the candidate object included in the white list. In yet another embodiment shown in this specification, the receiving unit 302 receives the first issue that multiple candidate object nodes publish to the distributed database of the blockchain within the first sub-period of the first time period. After an election transaction, it is also used to: call the smart contract, execute the transaction verification program declared in the smart contract, verify whether the first election transaction is legal, and compare the legal first election transaction with The participating objects are added to the white list of the smart contract. In yet another embodiment shown in this specification, the receiving unit 302 receives a plurality of candidate object nodes that are distributed to the distributed database of the blockchain in the second divided period of the first period After the second candidature transaction, it is also used to: call the smart contract, execute the object reference number verification procedure declared in the smart contract, and verify the second candidacy exchange issued by the candidated objects in the whitelist Whether the included object reference number can verify the ciphertext of the object reference number included in the first participating exchange, and remove the candidate objects corresponding to the unverifiable second participating transaction from the white list of the smart contract. In yet another embodiment shown in this specification, the characteristic value of the specified event is a hash value of the specified block generated by the blockchain after the first period of time. In yet another embodiment shown in this specification, the first time period is a logical time period that is highly correlated with blocks of the blockchain. In another embodiment shown in this specification, the object reference number is a random number, and the encrypted object reference number is a Pedersen commitment based on the random number. For the implementation process of the functions and functions of the units in the above device, please refer to the implementation process of the corresponding steps in the above method for specific details. For the relevant parts, please refer to the description of the method embodiments, which will not be repeated here. The device embodiments described above are only schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical modules, that is, may Located in one place, or can be distributed to multiple network modules. Some or all of the units or modules can be selected according to actual needs to achieve the purpose of the solution in this specification. Those with ordinary knowledge in the technical field to which the present invention belongs can understand and implement without paying creative work. The devices, units, and modules illustrated in the above embodiments may be specifically implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer, and the specific form of the computer may be a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal assistant, a media player, a navigation device, an email sending and receiving device, and a game control Desk, tablet, wearable device, or any combination of these devices. Corresponding to the above method embodiments, the embodiments of the present specification also provide a computer device, which includes a memory and a processor. Among them, a computer program that can be executed by the processor is stored on the memory; when the processor runs the stored computer program, each step of the random object selection method based on the blockchain in the embodiment of the present specification is executed. For a detailed description of the various steps of the random object selection method based on the blockchain, please refer to the previous content, and it will not be repeated. Corresponding to the above method embodiments, the embodiments of the present specification also provide a computer-readable storage medium that stores computer programs on the storage media. When the computer programs are executed by the processor, the computer-based storage medium executes the region-based The various steps of the random object selection method of the blockchain. For a detailed description of the various steps of the random object selection method based on the blockchain, please refer to the previous content, and it will not be repeated. The above are only the preferred embodiments of this specification and are not intended to limit this specification. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of this specification should be included in this specification Within the scope of protection. In a typical configuration, the computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and internal memory. Internal memory may include non-permanent memory, random access memory (RAM) and/or non-volatile internal memory in computer-readable media, such as read-only memory (ROM) or flash memory (flash) RAM). Internal memory is an example of computer-readable media. Computer-readable media, including permanent and non-permanent, removable and non-removable media, can be stored by any method or technology. The information can be computer readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change internal memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), and other types of random access memory (RAM ), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other internal memory technology, read-only disc read-only memory (CD-ROM), digital multi Functional Disc (DVD) or other optical storage, magnetic cassette tape, magnetic tape storage or other magnetic storage devices or any other non-transmission media can be used to store information that can be accessed by computing devices. As defined in this article, computer-readable media does not include transient computer-readable media (transitory media), such as modulated data signals and carrier waves. It should also be noted that the terms "include", "include", or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity, or device that includes a series of elements includes not only those elements, but also includes Other elements not explicitly listed, or include elements inherent to this process, method, commodity, or equipment. Without more restrictions, an element defined by the sentence "including one..." does not exclude that there are other identical elements in the process, method, commodity, or equipment that includes the element. Those skilled in the art should understand that the embodiments of this specification can be provided as methods, systems, or computer program products. Therefore, the embodiments of the present specification may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present specification may employ computer programs implemented on one or more computer usable storage media (including but not limited to disk memory, CD-ROM, optical memory, etc.) containing computer usable program code The form of the product.

104:方法步驟 106:方法步驟 201:方法步驟 202:方法步驟 203:方法步驟 204:方法步驟 205:方法步驟 206:方法步驟 30:裝置 302:接收單元 304:計算單元 306:選取單元 104: Method steps 106: Method steps 201: Method steps 202: Method steps 203: Method steps 204: Method steps 205: Method steps 206: Method steps 30: device 302: receiving unit 304: calculation unit 306: Select unit

圖1為本說明書所提供的一實施例所示的基於區塊鏈的隨機物件選取方法的流程圖; 圖2為本說明書一示例性實施例提供的隨機物件選取方法的過程示意圖; 圖3為本說明書所提供的一實施例提供的基於區塊鏈的隨機物件選取裝置的示意圖; 圖4為運行本說明書所提供的基於區塊鏈的隨機物件選取裝置實施例的一種硬體結構圖。 FIG. 1 is a flowchart of a random object selection method based on blockchain shown in an embodiment provided by this specification; 2 is a schematic diagram of a process of a random object selection method provided by an exemplary embodiment of the present specification; FIG. 3 is a schematic diagram of a block-based random object selection device provided by an embodiment provided by this specification; FIG. 4 is a hardware structure diagram of an embodiment of a random object selection device based on blockchain provided in this specification.

Claims (20)

一種基於區塊鏈的隨機物件選取方法,應用於包含多個參選物件節點的區塊鏈,所述方法包括:接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,所述參選交易基於所述參選物件節點確定的物件參考數產生;根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算所述多個參選物件節點對應的值,其中,所述指定事件的特徵值為根據預設的映射演算法,對發生在所述第一時段之後的指定事件計算所得的特徵值,所述指定事件的特徵值在所述指定事件發生之前不可被預知;以及根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點,其中,所述接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,包括:接收所述多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布的第一參選交易,所述第一參選交易包含加密後的物件參考數;以及接收所述多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布的第二參選交易,所述第二參選交易包含解密後的物件參 考數,其中,所述第二分時段為所述第一分時段結束後的時段,所述加密後的物件參考數可被所述解密後的物件參考數證明。 A random object selection method based on a blockchain is applied to a blockchain containing multiple candidate object nodes. The method includes: receiving multiple distributed object nodes in a distributed manner to the blockchain within a first period of time Participation transactions published by the database, the participation transactions are generated based on the object reference number determined by the object node; according to the preset calculation rules, based on the characteristic value of the specified event and the object reference number corresponding to the participation transaction Calculating values corresponding to the plurality of candidate object nodes, wherein the characteristic value of the specified event is a characteristic value calculated according to a preset mapping algorithm for the specified event occurring after the first period of time, and The characteristic value of the specified event cannot be predicted before the specified event occurs; and the selected object node is selected based on the values corresponding to the multiple selected object nodes according to a preset selection rule, wherein the received multiple The participation transaction that the candidate object node publishes to the decentralized database of the blockchain in the first period includes: receiving the plurality of candidate object nodes in the first sub-period of the first period The first candidate transaction issued by the distributed database of the blockchain, the first candidate transaction includes the encrypted object reference number; and the second node that receives the plurality of candidate object nodes in the first period A second contest transaction issued to the distributed database of the blockchain within a period of time, the second contest transaction includes decrypted object parameters A number of tests, where the second divided period is a period after the end of the first divided period, and the encrypted object reference number can be proved by the decrypted object reference number. 根據申請專利範圍第1項所述的方法,所述根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算所述多個參選物件節點對應的值,根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點,包括:調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行程序,基於指定事件的特徵值和參選交易對應的物件參考數分別計算所述多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 According to the method described in item 1 of the patent application scope, the values corresponding to the plurality of candidate object nodes are calculated based on the preset calculation rules based on the characteristic value of the specified event and the object reference number corresponding to the candidate transaction, According to the preset selection rules, selecting candidate object nodes based on the corresponding values of the multiple candidate object nodes includes: invoking a smart contract published on the blockchain, and executing the The calculation rule and the execution program corresponding to the selection rule respectively calculate the values corresponding to the plurality of candidate object nodes based on the characteristic value of the specified event and the object reference number corresponding to the candidate transaction, and based on the plurality of candidates The value corresponding to the object node selects the reference object node. 根據申請專利範圍第1項所述的方法,所述根據預設的計算規則,基於指定事件的特徵值和參選交易對應的物件參考數分別計算所述多個參選物件節點對應的值,根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點,包括:調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行程序,基於指定事件的特徵值和所述第二參選交易對應的 物件參考數,分別計算所述多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 According to the method described in item 1 of the patent application scope, the values corresponding to the plurality of candidate object nodes are calculated based on the preset calculation rules based on the characteristic value of the specified event and the object reference number corresponding to the candidate transaction, According to the preset selection rules, selecting candidate object nodes based on the corresponding values of the multiple candidate object nodes includes: invoking a smart contract published on the blockchain, and executing the The execution procedure corresponding to the calculation rule and the selection rule is based on the characteristic value of the specified event and the corresponding The object reference number respectively calculates the values corresponding to the plurality of candidate object nodes, and selects the candidate object nodes based on the values corresponding to the plurality of candidate object nodes. 根據申請專利範圍第3項所述的方法,所述智慧合約設置有白名單;所述基於指定事件的特徵值和所述第二參選交易對應的物件參考數,分別計算所述多個參選物件節點對應的值,包括:基於指定事件的特徵值和所述白名單所包括的參選物件節點發布的第二參選交易所對應的物件參考數,分別計算所述白名單內包含的參選物件節點對應的值。 According to the method described in item 3 of the patent application scope, the smart contract is provided with a white list; the multiple parameters are calculated separately based on the feature value of the specified event and the object reference number corresponding to the second participating transaction The value corresponding to the selected object node includes: based on the characteristic value of the specified event and the reference number of the object corresponding to the second participating exchange issued by the participating object node included in the white list, respectively calculating the content included in the white list Refer to the value corresponding to the object node. 根據申請專利範圍第4項所述的方法,在接收所述多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布的第一參選交易之後,還包括:調用所述智慧合約,執行所述智慧合約中宣告的交易驗證程序,驗證所述第一參選交易是否合法,並將合法的第一參選交易對應的參選物件加入到所述智慧合約的白名單。 According to the method described in item 4 of the patent application scope, after receiving the first candidate that the multiple candidate object nodes publish to the decentralized database of the blockchain in the first divided period of the first period After the transaction, it also includes: calling the smart contract, executing the transaction verification program declared in the smart contract, verifying whether the first candidate transaction is legal, and adding the candidate object corresponding to the legitimate first candidate transaction To the white list of the smart contract. 根據申請專利範圍第4或5項所述的方法,在接收所述多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布的第二參選交易之後,還包 括:調用所述智慧合約,執行所述智慧合約中宣告的物件參考數驗證程序,驗證所述白名單內的參選物件所發布的第二參選交易所包含的物件參考數是否可驗證所述第一參選交易所包含的物件參考數密文,並將不可驗證的第二參選交易對應的參選物件從所述智慧合約的白名單中去除。 According to the method described in item 4 or 5 of the patent application scope, after receiving the plurality of candidate object nodes that are released to the distributed database of the blockchain in the second sub-period of the first time period After the second election transaction, also include Including: calling the smart contract, executing the object reference number verification procedure declared in the smart contract, and verifying whether the object reference number included in the second candidate exchange issued by the candidate objects in the white list can be verified Describe the reference number ciphertext of the objects included in the first participating exchange, and remove the candidate objects corresponding to the unverifiable second participating transaction from the white list of the smart contract. 根據申請專利範圍第1至5項中任一項所述的方法,所述指定事件的特徵值為所述區塊鏈在所述第一時段之後產生的指定區塊的雜湊值。 According to the method described in any one of items 1 to 5 of the patent application range, the characteristic value of the specified event is a hash value of the specified block generated by the blockchain after the first period of time. 根據申請專利範圍第1至5項中任一項所述的方法,所述第一時段為與所述區塊鏈的區塊高度相關的邏輯時段。 According to the method of any one of items 1 to 5 of the patent application scope, the first time period is a logical time period that is highly correlated with blocks of the blockchain. 根據申請專利範圍第1、3至5項中任一項所述的方法,所述物件參考數為亂數,所述加密後的物件參考數為基於所述亂數的Pedersen承諾。 According to the method described in any one of items 1 to 3 to 5 of the patent application range, the object reference number is a random number, and the encrypted object reference number is a Pedersen commitment based on the random number. 一種基於區塊鏈的隨機物件選取裝置,應用於包含多個參選物件節點的區塊鏈,所述裝置包括:接收單元,接收多個參選物件節點在第一時段內向所述區塊鏈的分散式資料庫發布的參選交易,所述參選交易基於所述參選物件節點確定的物件參考數產生;計算單元,根據預設的計算規則,基於指定事件的特 徵值和參選交易對應的物件參考數分別計算所述多個參選物件節點對應的值,其中,所述指定事件的特徵值為根據預設的映射演算法,對發生在所述第一時段之後的指定事件計算所得的特徵值,所述指定事件的特徵值在所述指定事件發生之前不可被預知;以及選取單元,根據預設的選取規則,基於所述多個參選物件節點對應的值選取參選物件節點,其中,所述接收單元:接收所述多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布的第一參選交易,所述第一參選交易包含加密後的物件參考數;以及接收所述多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布的第二參選交易,所述第二參選交易包含解密後的物件參考數,其中,所述第二分時段為所述第一分時段結束後的時段,所述加密後的物件參考數可被所述解密後的物件參考數證明。 A random object selection device based on a blockchain is applied to a blockchain including a plurality of candidate object nodes. The device includes: a receiving unit that receives a plurality of candidate object nodes to the blockchain within a first time period Participating transactions issued by the distributed database of the database, the participating transactions are generated based on the object reference number determined by the participating object node; the calculation unit is based on the characteristics of the specified event according to the preset calculation rules The levy value and the object reference number corresponding to the participating transaction respectively calculate the values corresponding to the multiple participating object nodes, wherein the characteristic value of the specified event is according to a preset mapping algorithm, which occurs in the first Calculated characteristic values of the specified event after the time period, the characteristic values of the specified event cannot be predicted before the specified event occurs; and the selection unit, based on the preset selection rules, based on the correspondence of the plurality of candidate object nodes The value of the selected object node is selected, wherein the receiving unit: receives the first published by the plurality of object node to the distributed database of the blockchain in the first sub-period of the first period A participating transaction, the first participating transaction includes an encrypted object reference number; and receiving distributed data from the multiple participating object nodes to the blockchain in a second divided period of the first period The second election transaction published in the library, the second election transaction includes the decrypted object reference number, wherein the second sub-period is the period after the end of the first sub-period, and the encrypted The object reference number can be proved by the decrypted object reference number. 根據申請專利範圍第10項所述的裝置,所述計算單元:調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行 程序,基於指定事件的特徵值和參選交易對應的物件參考數分別計算所述多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 According to the device described in item 10 of the patent application scope, the calculation unit: invokes a smart contract published on the blockchain, and executes the smart contract announced in the smart contract corresponding to the calculation rule and the selection rule carried out The program calculates the values corresponding to the plurality of candidate object nodes based on the feature value of the specified event and the object reference number corresponding to the candidate transaction, and selects the candidate object node based on the values corresponding to the plurality of candidate object nodes. 根據申請專利範圍第10項所述的裝置,所述計算單元:調用發布在所述區塊鏈上的智慧合約,執行所述智慧合約中宣告的與所述計算規則和所述選取規則對應的執行程序,基於指定事件的特徵值和所述第二參選交易對應的物件參考數,分別計算所述多個參選物件節點對應的值,並基於所述多個參選物件節點對應的值選取參選物件節點。 According to the device described in item 10 of the patent application scope, the calculation unit: invokes a smart contract published on the blockchain, and executes the smart contract announced in the smart contract corresponding to the calculation rule and the selection rule Execute a program to calculate the values corresponding to the plurality of candidate object nodes based on the characteristic values of the specified event and the object reference numbers corresponding to the second candidate transaction, and based on the values corresponding to the plurality of candidate object nodes Select the selected object node. 根據申請專利範圍第12項所述的裝置,所述智慧合約設置有白名單;所述計算單元:基於指定事件的特徵值和所述白名單所包括的參選物件節點發布的第二參選交易所對應的物件參考數,分別計算所述白名單內包含的參選物件節點對應的值。 According to the device described in item 12 of the patent application scope, the smart contract is provided with a white list; the calculation unit: based on the feature value of the specified event and the second candidate issued by the candidate object node included in the white list For the reference numbers of objects corresponding to the exchange, the values corresponding to the candidate object nodes included in the white list are calculated respectively. 根據申請專利範圍第13項所述的裝置,所述接收單元在接收所述多個參選物件節點在所述第一時段的第一分時段內向所述區塊鏈的分散式資料庫發布的第一參選交易之後,還用於: 調用所述智慧合約,執行所述智慧合約中宣告的交易驗證程序,驗證所述第一參選交易是否合法,並將合法的第一參選交易對應的參選物件加入到所述智慧合約的白名單。 According to the device described in item 13 of the patent application scope, the receiving unit distributes the plurality of candidate object nodes to the distributed database of the blockchain within the first sub-period of the first time period. After the first election transaction, it is also used to: Invoke the smart contract, execute the transaction verification procedure declared in the smart contract, verify whether the first candidate transaction is legal, and add the candidate object corresponding to the legitimate first candidate transaction to the smart contract whitelist. 根據申請專利範圍第13或14項所述的裝置,所述接收單元在接收所述多個參選物件節點在所述第一時段的第二分時段內向所述區塊鏈的分散式資料庫內發布的第二參選交易之後,還用於:調用所述智慧合約,執行所述智慧合約中宣告的物件參考數驗證程序,驗證所述白名單內的參選物件所發布的第二參選交易所包含的物件參考數是否可驗證所述第一參選交易所包含的物件參考數密文,並將不可驗證的第二參選交易對應的參選物件從所述智慧合約的白名單中去除。 According to the device described in item 13 or 14 of the patent application scope, the receiving unit receives the plurality of candidate object nodes from the distributed database of the blockchain in the second divided period of the first period After the second candidacy transaction published within, it is also used to: call the smart contract, execute the object reference number verification procedure declared in the smart contract, and verify the second parameter issued by the candidacy object in the whitelist Whether the reference number of the object included in the selected exchange can verify the ciphertext of the reference number of the object included in the first selected exchange, and remove the selected object corresponding to the second unselectable transaction from the white list of the smart contract Remove. 根據申請專利範圍第10至14項中任一項所述的裝置,所述指定事件的特徵值為所述區塊鏈在所述第一時段之後產生的指定區塊的雜湊值。 According to the device of any one of claims 10 to 14, the characteristic value of the specified event is a hash value of the specified block generated by the blockchain after the first period of time. 根據申請專利範圍第10至14項中任一項所述的裝置,所述第一時段為與所述區塊鏈的區塊高度相關的邏輯時段。 According to the device of any one of items 10 to 14 of the patent application range, the first time period is a logical time period that is highly correlated with blocks of the blockchain. 根據申請專利範圍第10、12至14項中任一項所述的裝 置,所述物件參考數為亂數,所述加密後的物件參考數為基於所述亂數的Pedersen承諾。 According to the device described in any of items 10, 12 to 14 of the patent application range The object reference number is a random number, and the encrypted object reference number is a Pedersen commitment based on the random number. 一種電腦設備,包括:記憶體和處理器;所述記憶體上儲存有可由處理器運行的電腦程式;所述處理器運行所述電腦程式時,執行如申請專利範圍第1到9項中任一項所述的方法。 A computer device, including: a memory and a processor; a computer program executable by the processor is stored on the memory; when the processor runs the computer program, any of the items 1 to 9 of the patent application scope is executed One of the methods. 一種電腦可讀儲存媒體,其上儲存有電腦程式,所述電腦程式被處理器運行時,執行如申請專利範圍第1到9項中任一項所述的方法。A computer-readable storage medium on which a computer program is stored, and when the computer program is run by a processor, the method described in any one of items 1 to 9 of the patent application scope is executed.
TW108108599A 2018-08-30 2019-03-14 Random object selection method and device based on blockchain TWI695331B (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811003752.8 2018-08-30
CN201811003752.8A CN109360091B (en) 2018-08-30 2018-08-30 Random object selection method and device based on block chain

Publications (2)

Publication Number Publication Date
TW202009810A TW202009810A (en) 2020-03-01
TWI695331B true TWI695331B (en) 2020-06-01

Family

ID=65350302

Family Applications (1)

Application Number Title Priority Date Filing Date
TW108108599A TWI695331B (en) 2018-08-30 2019-03-14 Random object selection method and device based on blockchain

Country Status (3)

Country Link
CN (1) CN109360091B (en)
TW (1) TWI695331B (en)
WO (1) WO2020042775A1 (en)

Families Citing this family (19)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109360091B (en) * 2018-08-30 2020-09-01 阿里巴巴集团控股有限公司 Random object selection method and device based on block chain
CN109886750A (en) * 2019-02-25 2019-06-14 浪潮软件集团有限公司 A transparent random lottery implementation method based on blockchain
CN111666582B (en) * 2019-03-08 2024-05-03 深圳市网安计算机安全检测技术有限公司 Data cleaning method, device, equipment and storage medium based on block chain
CN113438068B (en) * 2019-05-31 2024-01-09 创新先进技术有限公司 Method and device for dynamic encryption based on block height
CN110223440B (en) * 2019-06-13 2020-10-02 北京瑞策科技有限公司 Random number shaking method and equipment for application block chain
CN110223439B (en) * 2019-06-13 2020-10-02 北京瑞策科技有限公司 Random number shaking method and device for application block chain
CN110189465B (en) * 2019-06-13 2020-12-25 北京瑞策科技有限公司 Random lottery method and equipment by means of block chain
CN110365479A (en) * 2019-07-11 2019-10-22 湖南天河国云科技有限公司 Random digit generation method and device based on block chain
CN110648447B (en) * 2019-08-08 2021-08-06 杭州复杂美科技有限公司 Game random number generation method, application, device, equipment and storage medium
US11520904B2 (en) * 2019-08-27 2022-12-06 Accenture Global Solutions Limited AI-based blockchain hybrid consensus
CN110572477A (en) * 2019-09-26 2019-12-13 腾讯科技(深圳)有限公司 Priority evaluation method and related equipment thereof
CN110855777B (en) * 2019-11-12 2022-09-13 腾讯科技(深圳)有限公司 Node management method and device based on block chain
CN116739660A (en) * 2019-11-28 2023-09-12 湖南天河国云科技有限公司 Lottery drawing method and system based on block chain
CN111311386A (en) * 2020-01-19 2020-06-19 深圳壹账通智能科技有限公司 Block chain-based bead shaking method and system, electronic device and storage medium
CN111599079A (en) * 2020-04-21 2020-08-28 深圳市芯链科技有限公司 Block chain shaking method, device, equipment and storage medium
CN111815455B (en) * 2020-09-04 2021-02-26 支付宝(杭州)信息技术有限公司 Transaction execution method, system and device
CN113128850B (en) * 2021-04-02 2024-04-19 深圳市易讯天空网络技术有限公司 Lottery flow management method, system, terminal equipment and storage medium
CN114693451B (en) * 2022-03-30 2025-06-17 蚂蚁区块链科技(上海)有限公司 Computation method and device based on smart contract, and electronic device
WO2024065217A1 (en) * 2022-09-27 2024-04-04 Wormholes Lab Pte. Ltd. Random number generation in a blockchain system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105913174A (en) * 2016-04-07 2016-08-31 彭军红 Lottery issuing method based on block chains
US20160358165A1 (en) * 2015-06-08 2016-12-08 Blockstream Corporation Cryptographically concealing amounts transacted on a ledger while preserving a network's ability to verify the transaction
CN106504174A (en) * 2016-09-27 2017-03-15 布比(北京)网络技术有限公司 Lottery industry publishing system and device based on block chain
CN107103097A (en) * 2017-05-22 2017-08-29 中链科技有限公司 Drawing method and terminal device based on block chain technology
CN108038954A (en) * 2017-12-01 2018-05-15 中国联合网络通信集团有限公司 Transaction operation method and digging ore deposit node based on block chain
CN108447014A (en) * 2018-03-19 2018-08-24 成都零光量子科技有限公司 A kind of block chain lottery industry method and system

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8219608B2 (en) * 2002-06-20 2012-07-10 Koninklijke Philips Electronics N.V. Scalable architecture for web services
CN105976248A (en) * 2016-04-29 2016-09-28 邓迪 Crowd funding lotting method and system
WO2017190175A1 (en) * 2016-05-06 2017-11-09 Othera Pty Ltd Methods and systems for blockchain based "segmented risk based securities"
CN107566124B (en) * 2017-08-24 2020-06-19 深圳市易成自动驾驶技术有限公司 Hash operation-based consensus establishing method, block chain system and storage medium
CN109360091B (en) * 2018-08-30 2020-09-01 阿里巴巴集团控股有限公司 Random object selection method and device based on block chain

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160358165A1 (en) * 2015-06-08 2016-12-08 Blockstream Corporation Cryptographically concealing amounts transacted on a ledger while preserving a network's ability to verify the transaction
CN105913174A (en) * 2016-04-07 2016-08-31 彭军红 Lottery issuing method based on block chains
CN106504174A (en) * 2016-09-27 2017-03-15 布比(北京)网络技术有限公司 Lottery industry publishing system and device based on block chain
CN107103097A (en) * 2017-05-22 2017-08-29 中链科技有限公司 Drawing method and terminal device based on block chain technology
CN108038954A (en) * 2017-12-01 2018-05-15 中国联合网络通信集团有限公司 Transaction operation method and digging ore deposit node based on block chain
CN108447014A (en) * 2018-03-19 2018-08-24 成都零光量子科技有限公司 A kind of block chain lottery industry method and system

Also Published As

Publication number Publication date
CN109360091B (en) 2020-09-01
CN109360091A (en) 2019-02-19
WO2020042775A1 (en) 2020-03-05
TW202009810A (en) 2020-03-01

Similar Documents

Publication Publication Date Title
TWI695331B (en) Random object selection method and device based on blockchain
Conti et al. A survey on security and privacy issues of bitcoin
TWI771618B (en) Method and device for distribution of copyright of works based on blockchain
TWI759563B (en) Asset management method and device, electronic equipment
TWI735820B (en) Asset management method and device, electronic equipment
CN111882745B (en) Object selection method and device, electronic equipment
JP2022106997A (en) Systems and methods realized by blockchain
JP2020108044A (en) Token management system and token management method
TW202016818A (en) Blockchain transaction method and device
US20170338963A1 (en) Decentralized exchanges in a distributed autonomous platform
CN110580245B (en) Private data sharing method and device
TW202016853A (en) Blockchain-based data storage and evidence collection method and device
CN110009498A (en) Resource allocation methods and device based on block chain
TW202013272A (en) A method and apparatus for allocating virtual resources
TWM561279U (en) Blockchain system and node server for processing strategy model scripts of financial assets
JP6404435B1 (en) Item transaction system and item transaction program
CN108492180A (en) Assets management method and device, electronic equipment
CN110599178A (en) Data processing method and device based on intelligent contract and storage medium
Gayvoronskaya et al. Blockchain
CN111047443A (en) User scoring method and device, electronic equipment and computer readable storage medium
US20230318833A1 (en) Systems and methods for managing tokens
CN112651836A (en) Copyright distribution method and device based on block chain
JP7636335B2 (en) COMPUTER-IMPLEMENTED METHOD AND SYSTEM FOR PSEUDO-RANDOM DATA GENERATION - Patent application
Clark et al. Research perspectives and challenges for bitcoin and cryptocurrencies
CN110784315B (en) Block chain-based number shaking method and device, computer equipment and storage medium