WO2020082883A1 - 对象选取方法及装置、电子设备 - Google Patents
对象选取方法及装置、电子设备 Download PDFInfo
- Publication number
- WO2020082883A1 WO2020082883A1 PCT/CN2019/102777 CN2019102777W WO2020082883A1 WO 2020082883 A1 WO2020082883 A1 WO 2020082883A1 CN 2019102777 W CN2019102777 W CN 2019102777W WO 2020082883 A1 WO2020082883 A1 WO 2020082883A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- block
- application
- smart contract
- blockchain
- candidate
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G07—CHECKING-DEVICES
- G07C—TIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
- G07C15/00—Generating random numbers; Lottery apparatus
- G07C15/006—Generating random numbers; Lottery apparatus electronically
Definitions
- One or more embodiments of this specification relate to the field of blockchain technology, and in particular, to an object selection method and apparatus, and electronic equipment.
- the preset number of objects can be randomly selected from these candidate objects. For example, when the system contains 10 devices, if you want to configure an architecture with 2 master devices and 8 slave devices, you can randomly select 2 master devices from the 10 devices, and the remaining 8 devices are slave devices. .
- one or more embodiments of this specification provide an object selection method and apparatus, and electronic equipment.
- an object selection method is proposed, which is applied to blockchain nodes; the method includes:
- the smart contract is used to publish an application record related to the candidate application to the first block of the blockchain, and generate a random seed based on the block content of the second block in the blockchain, And generate a pseudo-random number based on the random seed through a pseudo-random number generator, so that the candidate object matching the pseudo-random number is selected as the target object; wherein, the block height of the second block is greater than The block height of the first block.
- an object selection device for use in a blockchain node; the device includes:
- the obtaining unit obtains the candidate application submitted by the candidate
- the calling unit invokes a smart contract, which is used to publish application records related to the candidature application to the first block of the blockchain, generated according to the block content of the second block in the blockchain A random seed, and a pseudo-random number based on the random seed is generated by a pseudo-random number generator, so that the candidate object matching the pseudo-random number is selected as the target object; wherein, the area of the second block The block height is greater than the block height of the first block.
- an electronic device including:
- Memory for storing processor executable instructions
- the processor executes the executable instruction to implement the method as described in any one of the above embodiments.
- FIG. 1 is a flowchart of an object selection method provided by an exemplary embodiment.
- Fig. 2 is a schematic diagram of a real estate purchased by a number sign provided by an exemplary embodiment.
- FIG. 3 is a schematic diagram of a signing process based on a smart contract provided by an exemplary embodiment.
- FIG. 4 is a schematic structural diagram of a device provided by an exemplary embodiment.
- FIG. 5 is a block diagram of an object selection device provided by an exemplary embodiment.
- the steps of the corresponding method are not necessarily performed in the order shown and described in this specification.
- the method may include more or fewer steps than described in this specification.
- 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.
- FIG. 1 is a flowchart of an object selection method provided by an exemplary embodiment. As shown in Figure 1, this method is applied to blockchain nodes and can include the following steps:
- Step 102 Obtain a candidate application submitted by a candidate.
- the candidate object submits a candidate application so that the smart contract can publish the corresponding application record to the blockchain, thereby ensuring that the corresponding candidate object can participate in the selection process of the object.
- the candidate application may contain the identity information of the candidate object, such as the signature generated by the candidate object through the private key, and the identity information may be added to the application record to indicate that the application record and the The relationship between candidate objects.
- a smart contract is invoked.
- the smart contract is used to publish an application record related to the participation application to the first block of the blockchain, which is generated according to the block content of the second block in the blockchain A random seed, and a pseudo-random number based on the random seed is generated by a pseudo-random number generator, so that the candidate object matching the pseudo-random number is selected as the target object; wherein, the area of the second block The block height is greater than the block height of the first block.
- a transaction can be created on the client of the blockchain, so that the application record corresponding to the candidate object can be posted to the blockchain through the transaction, becoming a distributed database in the blockchain A piece of data.
- 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 with business intent that users release to the blockchain; for example, the operator can build an alliance chain based on actual business needs, relying on the alliance chain to deploy some other types that have nothing to do with value transfer Online business (for example, object selection business, rental business, vehicle scheduling business, insurance claims business, credit service, medical service, etc.), and in this type of alliance chain, the transaction can be a sum of money posted by the user in the alliance chain.
- the transactions in this manual should tend to be understood as transactions in a broad sense.
- the blockchain uses a distributed database, the application records posted on the blockchain cannot be tampered with, which can ensure authenticity and reliability.
- the random seed is related to the second block whose block height is greater than the first block, based on each block in the blockchain.
- the chain relationship between the applications makes the addition of application records increase the uncertainty of random seeds and cannot be predicted and set by criminals, so that the pseudo-random numbers generated based on the random seeds are also highly random and can be greatly reduced Possibilities for fraud and fraud.
- the smart contract can determine the matching situation with the pseudo-random number according to the identification information in the digital form that each candidate object already has.
- the identification information may be the user ID of each candidate object, the value of the public key, etc. This specification does not limit this.
- the smart contract is also used to: separately generate an application number for each candidate object, and each application number corresponds to a unique candidate object; wherein, when the pseudo-random number and any application number When they are the same, the candidate object corresponding to any one of the application numbers is determined to match the pseudo-random number.
- application numbers can be generated for candidate objects in a preset manner, such as the order in which each candidate object submits a candidate application, the value of the public key of each candidate object, etc. limit.
- the application number is related to the value of the unique identifier corresponding to the candidate object, and the value of the unique identifier is composed of a hash value related to a historical block in the blockchain and the candidate
- the user's public key is obtained by hash calculation, which can increase the randomness of the value of the unique identifier and reduce the possibility of being manipulated by criminals.
- the winning rate of the candidate object is x times the standard winning rate
- the smart contract after receiving the application for selection of any object, can determine whether the object meets the requirements according to the predefined selection conditions, and when it meets the requirements, it can be set as the above-mentioned backup Select users so that they can participate in the object selection process.
- the smart contract can determine the signing rate based on the information of the candidate user; for example, the smart contract can query the number of participant selections in the candidate object's history from the blockchain ledger and determine it according to the set calculation formula Out-of-winning rate, which can be positively correlated with the number of times.
- the smart contract is used to hash the hash value related to the historical block in the blockchain and the public key of the candidate object to obtain the corresponding unique identifier; when x When the values include x1 ⁇ xn from small to large, the smart contract is used to sequentially select x1 ⁇ xn; where, when xi is selected, the smart contract will select candidates whose winning rate is not less than xi times the standard winning rate
- the corresponding unique identifiers are arranged in order from small to large, and after the existing application numbers are generated, the corresponding application numbers are successively generated according to the arrangement order, 1 ⁇ i ⁇ n.
- the total number of the target objects is w; the smart contract is used to input the random seed and sampling interval [M, N] as the input when the number of selected target objects does not reach w
- a pseudo-random number is generated by the pseudo-random number generator, where M is the minimum value of the application number and N is the maximum value of the application number.
- the sampling interval used covers all application numbers without excluding the application number corresponding to the selected target object, which can ensure the actual probability of winning each candidate object every time.
- Pseudo-random numbers are generated at the same time, to avoid excluding the application number corresponding to the target object, resulting in an increase in the probability of actual winning of other candidate users, thereby ensuring fairness.
- the smart contract is used to store the application number corresponding to each candidate object in the blockchain, so that the candidate user or supervisor can check the application number from the blockchain at any time. Avoid fraud and cheating.
- the random seed is also related to the block content of one or more other blocks in the blockchain, so that even if the criminal has the ability to block attack, he must attack the second block and the block separately. Only other blocks can achieve their goals, resulting in extremely high attack costs, which can greatly reduce the possibility of criminals operating random seeds.
- the one or more other blocks include: a block containing at least one application record, so that all the application records can affect the random seed, which can increase the uncertainty of the random seed and reduce the illegality The possibility of molecular guessing or manipulation.
- the one or more other blocks include: one or more blocks adjacent to the second block. For example, when the number of the one or more other blocks is r, you can select r blocks before the second block; or, you can wait for r blocks to continue to be generated in the blockchain after generating the second block Block, and generate a random seed based on the second block and the r blocks.
- the smart contract is used for the second block and r other blocks (such as the one or more blocks containing the application record described above or located after the second block by the following formula The content of one or more blocks) is processed to determine the actual result:
- H’1 H (Hp, Hr),
- H’i H (H ’(i-1), H (r-i + 1)), where 1 ⁇ i ⁇ r;
- H is a preset hash function
- Hp is a hash value related to the block content of the second block
- Hi is a hash value related to the block content of the i-th other block
- r other blocks may be sequentially arranged in a preset order to form the first other block, ..., the rth other block,
- the preset order may include the order of the block height from small to large, and the order of the hash value of the block content from small to large, etc., which is not limited in this specification.
- the smart contract is used to generate the random seed after generating the third block in the blockchain; wherein the block height of the third block is greater than the second block, And the height difference is the preset value.
- the smart contract determines the random seed based on the block content of the second block, the random seed is not determined immediately after the second block is generated, but the random seed is determined after waiting for a preset number of blocks , To ensure the security of the second block, so that the attacker must continuously attack all the blocks between the second block and the third block, making the attack cost extremely high, which can greatly reduce the possibility of criminals operating random seeds Sex.
- 2 is a schematic diagram of a real estate purchase provided by an exemplary embodiment; as shown in FIG. 2, assuming that user A wishes to participate in the real estate for a real estate, the user A can submit an application through the mobile phone 21 with the client installed
- the number-sharing application required for number-sharing qualifications such as identification documents, deposit certification materials, public keys corresponding to digital identities, personal data, etc., depends on the requirements of the property developer or relevant laws and regulations.
- the device 22 is configured as a server of the number dialing system.
- the device 22 interacts with the mobile phone 21 used by the user A on the one hand to assist him in applying for the number dialing qualification, and interacts with the device 23 on the other hand.
- the device 23 is configured as a blockchain node in the blockchain. Based on the information provided by the device 22, a smart contract can be configured and issued, and the smart contract can be invoked to implement the application for the qualification of the number shaking and the number shaking operation.
- the real estate developer or the number notarization department can configure the smart contract to set the application conditions for the number qualification and the stages involved in the number shaking process (such as dividing the stages based on time or dividing the stages based on the block height on the blockchain Etc.), the processing logic adopted at each stage, etc., so that the smart contract can be used to implement the object selection scheme of this specification to complete the corresponding number-sharing operation.
- the number-sharing process shown in FIG. 3 can be implemented.
- the process can include the following steps:
- step 301 the user applies for the qualification to shake the number.
- user A can submit a lottery application to device 22 through mobile phone 21, and submit a transaction containing the lottery application to the blockchain via device 23.
- the type of the transaction can be configured or marked as applying for a lottery qualification Types of.
- other users can also apply for the lottery qualification in the above manner, so as to participate in the lottery together with user A.
- user A can also submit a transaction containing a shake request to the blockchain through other blockchain nodes.
- the mobile phone 21 can be configured as a blockchain Node, then user A can submit a transaction containing a shake request to the blockchain based on the mobile phone 21.
- the above-mentioned transactions that include a lottery application can be recorded in the blockchain ledger, and smart contracts can be queried and accessed from the blockchain ledger to obtain the lottery applications included in these transactions, thereby verifying whether the corresponding user can obtain the qualification .
- the device 23 can learn information such as the name or location of the smart contract, so that the device 23 can directly send the lottery application to the smart contract, and the smart contract can verify the received lottery application To determine whether the corresponding user can obtain the lottery qualification.
- Step 302 the smart contract verifies the user information.
- a smart contract after a smart contract obtains a user's number application, it can verify the number application according to the pre-defined application conditions to determine whether it meets the application conditions; if it is satisfied, it is determined that the corresponding user has the number application Qualification, otherwise it is judged that it does not have the qualification to shake the number.
- the number-sharing application contains the corresponding user's public key and other personal information, and the number-sharing application should be signed by the user's private key to ensure that the content is authentic and valid and cannot be tampered with.
- step 303 the smart contract stores the verification result in the blockchain ledger.
- the verification result in the blockchain ledger, it is equivalent to publicizing the verification result, which makes the verification result transparent and traceable, and the verification result cannot be tampered with at will, ensuring that the verification of the shaker application meets the requirements To avoid dark box operations.
- Step 304 the smart contract generates a qualification number for the authenticated user, and stores the qualification number in the blockchain ledger.
- the smart contract can define the block height range corresponding to each stage such as the application stage, the numbering stage, the shaking phase, etc.
- the block height corresponding to the application stage is T0- T1
- the block height corresponding to the numbering stage is T2-T3
- the block height corresponding to the number shaking stage is T4-T5.
- the smart contract can read the lottery applications recorded in the block at the height of T0-T1 from the blockchain ledger. Only these lottery applications may participate in this lottery process, while other areas The lottery application within the block cannot participate in this lottery process.
- the smart contract can generate the qualification number for the authenticated user in a preset manner, which is not limited in this specification.
- the qualification number can be generated as follows:
- Smart contracts can read and count the lottery activities that each user has historically participated in from the blockchain ledger, and determine the winning rate based on the statistical data; for example, when the number of historically participated lotteries is not greater than the first value, the winning rate It can be the standard lottery rate. When the number of lottery times is greater than the first value and not greater than the second value, the lottery rate can be twice the standard lottery rate. When the number of lottery numbers is greater than the second value and not greater than the third value, the lottery rate can be 3 times the standard winning rate, and so on.
- the winning rate of each user can also be calculated by other methods and recorded in the blockchain ledger, and the smart contract only needs to read the corresponding winning rate of each verified user from the blockchain ledger.
- the smart contract can calculate the transition ID corresponding to each user based on the verified public key pk of each user and the hash value PreH of the specified historical block.
- a hash function H () can be set in the smart contract, then the transition ID corresponding to each user can be H (PreH, pk), that is, the hash value PreH and the public key pk are performed by the hash function H () After calculation, the corresponding hash value is obtained, so that the transition ID has extremely high randomness and cannot be manipulated by criminals.
- the smart contract can give each user a corresponding qualification number according to the generated transition ID. Assuming that the verified users are U1 ⁇ Um, and the winning rates of these users are 1 times, 2 times, 3 times ... n times, respectively, then the smart contract can implement the following operations:
- the qualification number generated at this time can be started from the beginning, such as generating the qualification number 1 for the user with the smallest transition ID and generating the qualification number 2 for the user with the second lowest transition ID, until the transition The user ID with the largest ID is m. Therefore, for all users whose winning rate is not less than 1 times the standard winning rate, corresponding m qualification numbers can be generated at this time, which are the above 1 ⁇ m; in other words, each user has one corresponding qualification at this time. Numbering.
- the users U1 to Um select all users whose winning rate is not less than twice the standard winning rate, that is, users whose winning rate is 2 to n times the standard winning rate, assuming that the number of these users is a; according to the transition
- the IDs are arranged in ascending order of the selected a users, and then the corresponding qualification numbers are generated based on the arrangement order. Since the generated qualification numbers 1 to m exist, the qualification numbers are generated successively at this time. For example, the qualification number for the user with the smallest transition ID is m + 1, and the qualification number for the user with the second smallest transition ID is m + 2. Until the qualification number m + a is generated for the user with the largest transition ID.
- a corresponding qualification number can be generated at this time, which is the above-mentioned m + 1 ⁇ m + a.
- each user has one qualification number; and for a user whose winning rate is not less than 2 times the standard winning rate, each user has 2 qualification numbers.
- the users U1 to Um select all users whose winning rate is not less than 3 times the standard winning rate, that is, users whose winning rate is 3 to n times the standard winning rate, assuming that the number of these users is b; according to the transition
- the IDs are arranged in ascending order of the selected b users, and then the corresponding qualification number is generated based on the arrangement order. Since the generated qualification numbers 1 to m + a exist, the qualification numbers are generated successively at this time, for example, the qualification number for the user with the smallest transition ID is m + a + 1, and the qualification number for the user with the second smallest transition ID is m + a + 2, until the user with the highest transition ID has the qualification number m + a + b.
- corresponding b qualification numbers can be generated at this time, which are the above m + a + 1 to m + a + b, respectively.
- each user has one qualification number; and for a user whose winning rate is not less than 2 times the standard winning rate, each user has 2 qualification numbers; and For users whose winning rate is not less than 3 times the standard winning rate, each user has 3 qualification numbers.
- the smart contract can allocate the corresponding qualification numbers to the corresponding users in the above manner for each winning rate, and finally enable users with a winning rate of i times the standard winning rate to be assigned i qualification numbers, of which 1 ⁇ i ⁇ n.
- the qualification numbers of each user are open, transparent, queryable, and cannot be tampered. Therefore, in the subsequent lottery process, Based on the qualification number, it can be accurately determined whether each user is shaken, with extremely high fairness, openness and credibility.
- step 305 the smart contract monitors the generated blocks in the blockchain ledger. When the block height of the most recent block reaches P, it waits for Q blocks to continue to be generated in the blockchain ledger, and then proceeds to step 306.
- P and Q are predefined arbitrary values.
- the block height range corresponding to the shaking phase is T4-T5
- the value of Q can be 0, that is, after the block height reaches P, it can be transferred to step 306 Instead of waiting.
- Q>0 the value of Q is related to the speed of generating blocks in the blockchain. It only needs to ensure that after Q blocks, the block of height P will not change; and by waiting for Q A block can guarantee the security of the block with a height of P.
- the attacker must continuously attack all blocks with a height between P and P + Q, which makes the attack cost extremely high and can greatly reduce the number of criminals controlling the shaker. possibility.
- Step 306 the smart contract generates a random seed.
- the smart contract can separately determine blocks with a height of P, and the block chain contains r blocks related to the lottery application related to this lottery, and obtain the hash values of these blocks (
- the hash value is related to the block content of the corresponding block), for example: the block with a height of P corresponds to the hash value Hp, and the hash values corresponding to the r blocks are H1 ⁇ Hr (for example, according to the block Arrange the height from small to large).
- the smart contract can be calculated according to the following formula:
- H’1 H (Hp, Hr),
- H’i H (H ’(i-1), H (r-i + 1)), where 1 ⁇ i ⁇ r;
- H is a preset hash function
- H (Hp, Hr) means that Hp and Hr are hashed by the hash function H, and the corresponding hash value is H'1; similarly, H (H '(i-1), H (r-i + 1)) means that H' (i-1) and H (r-i + 1) are hashed by the hash function H to obtain the corresponding hash
- the value is H'i.
- H’1 H (Hp, HQ),
- H’i H (H ’(i-1), H (Q-i + 1)), where 1 ⁇ i ⁇ Q;
- H is the preset hash function
- step 307 the smart contract generates a winning number, and deposits the winning number in the blockchain ledger.
- the smart contract can call a set pseudo-random number generator for generating a winning number.
- the input data for the pseudo-random number generator may include: a random seed and a sampling interval; where: the random seed is the Hf generated in the above process, and the sampling interval may be generated according to the value range of the qualification number of each user, such as when When the minimum value of the qualification number is 1 and the maximum value is Y, the sampling interval can be set to [1, Y] so that the winning number generated by the pseudo-random number generator is in this range [1, Y].
- the smart contract can generate a winning number that matches the random seed Hf and the sampling interval [1, Y] through the pseudo-random number generator, and then determines that it matches the winning lot After the qualification number of the number, confirm whether the user corresponding to the qualification number has previously won the lottery. If the user has not won the lottery, confirm that the user has been drawn. Otherwise, the number won this time is invalid and the extraction needs to be continued.
- users or supervisors can conduct verification and verification at any time to avoid tampering by criminals.
- user A can initiate a query request to device 22 through mobile phone 21, device 22 can query the blockchain ledger through device 23, and return the result of the search to the mobile phone 21 for viewing by user A , To ensure that you have the right to purchase real estate; similarly, when user A has an objection to the number shaking process, the same process can also be used to retrospectively query the relevant data in the blockchain ledger. Both are open and transparent.
- FIG. 4 is a schematic structural diagram of a device provided by an exemplary embodiment. Please refer to FIG. 4.
- the device includes a processor 402, an internal bus 404, a network interface 406, a memory 408, and a non-volatile memory 410.
- the processor 402 reads the corresponding computer program from the non-volatile memory 410 into the memory 408 and then runs it to form an object selection device at a logical level.
- one or more embodiments of this specification do not exclude other implementations, such as logic devices or a combination of hardware and software, etc., that is to say, the execution body of the following processing flow is not limited to each
- the logic unit may also be a hardware or logic device.
- the object selection device is applied to the blockchain node; the device may include:
- the obtaining unit 51 obtains the candidate application submitted by the candidate object
- Calling unit 52 calling a smart contract
- the smart contract is used to publish the application record related to the candidate application to the first block of the blockchain, according to the block content of the second block in the blockchain Generate a random seed, and generate a pseudo-random number based on the random seed through a pseudo-random number generator, so that the candidate object matching the pseudo-random number is selected as the target object; wherein, the second block The block height is greater than the block height of the first block.
- the smart contract is also used to: separately generate an application number for each candidate object, and each application number corresponds to a unique candidate object; wherein, when the pseudo-random number is the same as any application number , The candidate object corresponding to any one of the application numbers is determined to match the pseudo-random number.
- the application number is related to the value of the unique identifier corresponding to the candidate object, and the value of the unique identifier is composed of a hash value related to a historical block in the blockchain and the candidate The public key of the user is hashed.
- the winning rate of the candidate object is x times the standard winning rate, there are x application numbers for the candidate object; wherein, x is a positive integer.
- the smart contract is used to hash the hash value related to the historical block in the blockchain and the public key of the candidate object to obtain a corresponding unique identifier;
- the smart contract When the value of x includes x1 to xn from small to large, the smart contract is used to sequentially select x1 to xn; wherein, when xi is selected, the smart contract will have a winning rate of not less than xi times the standard winning rate
- the unique identifiers corresponding to the candidate objects are arranged in order from small to large, and after the existing application numbers are generated, the corresponding application numbers are successively generated according to the order of arrangement, 1 ⁇ i ⁇ n.
- the total number of the target objects is w; the smart contract is used when the number of selected target objects does not reach w, the random seed and sampling interval [M, N] are used as input, through the The pseudo-random number generator generates a pseudo-random number, where M is the minimum value of the application number and N is the maximum value of the application number.
- the smart contract is used to store the application number corresponding to each candidate object in the blockchain.
- the random seed is also related to the block content of one or more other blocks in the blockchain.
- the one or more other blocks include: a block containing at least one application record.
- the one or more other blocks include: one or more blocks adjacent to the second block.
- the smart contract is used to process the block content of the second block and r other blocks by the following formula to determine the actual result:
- H’1 H (Hp, Hr),
- H’i H (H ’(i-1), H (r-i + 1)), where 1 ⁇ i ⁇ r;
- H is a preset hash function
- Hp is a hash value related to the block content of the second block
- Hi is a hash value related to the block content of the i-th other block
- the smart contract is used to generate the random seed after generating the third block in the blockchain; wherein the block height of the third block is greater than the second block, and the height The difference is the preset value.
- the system, device, module or unit explained in the above embodiments may be specifically implemented by a computer chip or entity, or by a product having a certain function.
- 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 digital assistant, a media player, a navigation device, an email sending and receiving device, and a game control Desk, tablet computer, wearable device, or any combination of these devices.
- the computer includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.
- processors CPUs
- input / output interfaces output interfaces
- network interfaces network interfaces
- memory volatile and non-volatile memory
- the memory may include non-permanent memory, random access memory (RAM) and / or non-volatile memory in computer-readable media, such as read only memory (ROM) or flash memory (flash RAM). Memory is an example of computer-readable media.
- RAM random access memory
- ROM read only memory
- flash RAM flash memory
- Computer-readable media including permanent and non-permanent, removable and non-removable media, can store information by any method or technology.
- the information may 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 memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, read-only compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, Magnetic cassette tapes, magnetic disk storage, quantum memory, graphene-based storage media or other magnetic storage devices or any other non-transmission media can be used to store information that can be accessed by computing devices.
- computer-readable media does not include temporary computer-readable media (transitory media), such as modulated data signals and carrier waves.
- first, second, third, etc. may use the terms first, second, third, etc. to describe various information, the information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other.
- first information may also be referred to as second information, and similarly, the second information may also be referred to as first information.
- word "if” as used herein may be interpreted as "when” or “when” or “in response to a determination”.
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
一种对象选取方法及装置、电子设备,应用于区块链节点;方法包括:获取备选对象提交的参选申请(102);调用智能合约,智能合约被用于向区块链的第一区块发布与参选申请相关的申请记录,根据区块链中的第二区块的区块内容生成随机种子,并通过伪随机数发生器生成基于随机种子的伪随机数,以使得匹配于伪随机数的备选对象被选取为目标对象;其中,第二区块的区块高度大于第一区块的区块高度(104)。
Description
本说明书一个或多个实施例涉及区块链技术领域,尤其涉及一种对象选取方法及装置、电子设备。
当某一事件被设定为由预设数量的对象实施时,如果备选对象的数量超出该预设数量,则需要从这些备选对象中进行选择。当这些备选对象对于该事件的实施并无明显区别时,可以从这些备选对象中随机选取上述预设数量的对象。例如,当系统内包含10台设备时,如果希望配置为2台主设备、8台从设备的架构,可以从该10台设备中随机选取2台主设备,则剩余的8台设备为从设备。
发明内容
有鉴于此,本说明书一个或多个实施例提供一种对象选取方法及装置、电子设备。
为实现上述目的,本说明书一个或多个实施例提供技术方案如下:
根据本说明书一个或多个实施例的第一方面,提出了一种对象选取方法,应用于区块链节点;所述方法包括:
获取备选对象提交的参选申请;
调用智能合约,所述智能合约被用于向区块链的第一区块发布与所述参选申请相关的申请记录,根据区块链中的第二区块的区块内容生成随机种子,并通过伪随机数发生器生成基于所述随机种子的伪随机数,以使得匹配于所述伪随机数的备选对象被选取为目标对象;其中,所述第二区块的区块高度大于所述第一区块的区块高度。
根据本说明书一个或多个实施例的第二方面,提出了一种对象选取装置,应用于区块链节点;所述装置包括:
获取单元,获取备选对象提交的参选申请;
调用单元,调用智能合约,所述智能合约被用于向区块链的第一区块发布与所述参 选申请相关的申请记录,根据区块链中的第二区块的区块内容生成随机种子,并通过伪随机数发生器生成基于所述随机种子的伪随机数,以使得匹配于所述伪随机数的备选对象被选取为目标对象;其中,所述第二区块的区块高度大于所述第一区块的区块高度。
根据本说明书一个或多个实施例的第三方面,提出了一种电子设备,包括:
处理器;
用于存储处理器可执行指令的存储器;
其中,所述处理器通过运行所述可执行指令以实现如上述实施例中任一所述的方法。
图1是一示例性实施例提供的一种对象选取方法的流程图。
图2是一示例性实施例提供的一种摇号选购不动产的示意图。
图3是一示例性实施例提供的一种基于智能合约的摇号过程的示意图。
图4是一示例性实施例提供的一种设备的结构示意图。
图5是一示例性实施例提供的一种对象选取装置的框图。
这里将详细地对示例性实施例进行说明,其示例表示在附图中。下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本说明书一个或多个实施例相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本说明书一个或多个实施例的一些方面相一致的装置和方法的例子。
需要说明的是:在其他实施例中并不一定按照本说明书示出和描述的顺序来执行相应方法的步骤。在一些其他实施例中,其方法所包括的步骤可以比本说明书所描述的更多或更少。此外,本说明书中所描述的单个步骤,在其他实施例中可能被分解为多个步骤进行描述;而本说明书中所描述的多个步骤,在其他实施例中也可能被合并为单个步骤进行描述。
图1是一示例性实施例提供的一种对象选取方法的流程图。如图1所示,该方法应用于区块链节点,可以包括以下步骤:
步骤102,获取备选对象提交的参选申请。
在一实施例中,备选对象通过提交参选申请,使得智能合约可以向区块链发布相应的申请记录,从而确保相应的备选对象能够参与到对象的选取过程中。
在一实施例中,参选申请可以包含备选对象的身份信息,比如该备选对象通过私钥生成的签名等,而该身份信息可以被添加至申请记录中,以表明该申请记录与该备选对象之间的关联关系。
步骤104,调用智能合约,所述智能合约被用于向区块链的第一区块发布与所述参选申请相关的申请记录,根据区块链中的第二区块的区块内容生成随机种子,并通过伪随机数发生器生成基于所述随机种子的伪随机数,以使得匹配于所述伪随机数的备选对象被选取为目标对象;其中,所述第二区块的区块高度大于所述第一区块的区块高度。
在一实施例中,可以在区块链的客户端上创建交易(transfer),从而通过该交易将备选对象对应的申请记录发布至区块链上,成为区块链的分布式数据库中的一笔数据。需要指出的是:区块链中的交易,存在狭义的交易以及广义的交易之分。狭义的交易是指用户向区块链发布的一笔价值转移;例如,在传统的比特币区块链网络中,交易可以是用户在区块链中发起的一笔转账。而广义的交易是指用户向区块链发布的一笔具有业务意图的业务数据;例如,运营方可以基于实际的业务需求搭建一个联盟链,依托于联盟链部署一些与价值转移无关的其它类型的在线业务(比如,对象选取业务、租房业务、车辆调度业务、保险理赔业务、信用服务、医疗服务等),而在这类联盟链中,交易可以是用户在联盟链中发布的一笔具有业务意图的业务消息或者业务请求。本说明书中的交易,应当倾向于理解为广义上的交易。
在一实施例中,由于区块链采用分布式数据库,使得发布至区块链上的申请记录无法被篡改,可以确保真实、可靠。
在一实施例中,当申请记录被发布至区块链中的第一区块,而随机种子与区块高度大于第一区块的第二区块相关时,基于区块链中各个区块之间的链式关系,使得申请记录的加入可以增加随机种子的不确定性,无法被不法分子预测和设定,使得基于该随机种子产生的伪随机数同样具备高度随机性,可以极大地降低不法分子造假作弊的可能性。
同时,由于随机种子的生成过程、伪随机数的生成过程均由智能合约实现,而智能合约被存证于区块链中,使得该智能合约的内容公开且不可篡改,使得对于目标对象的选择过程公平、公开、可验证,进一步降低了不法分子造假作弊的可能性。
在一实施例中,智能合约可以根据每一备选对象已有的数字形式的标识信息,确定与伪随机数之间的匹配情况。例如,该标识信息可以为各个备选对象的用户ID、公钥的取值等,本说明书并不对此进行限制。
在一实施例中,所述智能合约还用于:为每一备选对象分别生成申请编号,每一申请编号对应于唯一的备选对象;其中,当所述伪随机数与任一申请编号相同时,所述任一申请编号对应的备选对象被确定为匹配于所述伪随机数。
在一实施例中,可以按照预设方式为备选对象生成申请编号,比如各个备选对象提交参选申请的顺序、各个备选对象的公钥的取值大小等,本说明书并不对此进行限制。举例而言,所述申请编号与所述备选对象对应的唯一标识的取值相关,所述唯一标识的取值由与区块链中的历史区块相关的哈希值和所述备选用户的公钥进行哈希计算而得到,这样可以增加该唯一标识的取值的随机性,降低被不法分子操控的可能性。
在一实施例中,当所述备选对象的中签率为标准中签率的x倍时,所述备选对象存在x个申请编号;其中,x为正整数。比如,当x=1时,备选对象存在1个申请编号,当x=2时,备选对象存在2个申请编号;当申请编号的数量越多时,备选对象被选中的概率也越大,即中签率更高。
在一实施例中,智能合约在收到任一对象的参选申请后,可以根据预定义的参选条件判断该任一对象是否符合要求,当符合要求时可以将其设定为上述的备选用户,使其能够参与到对象选取过程中。同时,智能合约可以基于该备选用户的信息,确定其中签率;例如,智能合约可以从区块链账本中查询该备选对象历史上参与对象选取的次数,并按照设定的计算公式确定出中签率,其中该中签率可以与次数呈正相关。
在一实施例中,所述智能合约用于将与区块链中的历史区块相关的哈希值与所述备选对象的公钥进行哈希计算,得到相应的唯一标识;当x的取值从小至大地分别包括x1~xn时,所述智能合约用于依次选取x1~xn;其中,当选取xi时,所述智能合约将中签率不小于标准中签率的xi倍的备选对象对应的唯一标识按照从小至大依次排列,并在已有申请编号之后、按照排列次序接续生成相应的申请编号,1≤i≤n。
假定备选对象的数量为m个。在依次选取x1~xn时:首先选取x1并假定x1=1,那么“中签率不小于标准中签率的xi倍的备选对象”为所有的m个备选对象,并且此时尚未存在申请编号,因而可以直接生成相应的m个申请编号为1~m;然后选取x2并假定x2=2,那么“中签率不小于标准中签率的xi倍的备选对象”为x2~xn倍中签率的备 选对象、不包含x1倍中签率的备选对象,譬如x2~xn倍中签率的备选对象的数量为a,由于已存在上述的申请编号1~m,因而可以在m之后接续生成a个申请编号,即m+1~m+a,此时x1倍中签率的备选对象存在1个申请编号、x2~xn倍中签率的备选对象存在2个申请编号;然后选取x3并假定x3=3,那么“中签率不小于标准中签率的xi倍的备选对象”为x3~xn倍中签率的备选对象、不包含x1-x2倍中签率的备选对象,譬如x3~xn倍中签率的备选对象的数量为b,由于已存在上述的申请编号1~m+a,因而可以在m+a之后接续生成b个申请编号,即m+a+1~m+a+b,此时x1倍中签率的备选对象存在1个申请编号、x2倍中签率的备选对象存在2个申请编号、x3~xn倍中签率的备选对象存在3个申请编号。类似地,通过上述方式依次选取至xn后,可以确保备选对象具有的申请编号的数量与其对应的中签率倍数相同。
在一实施例中,所述目标对象的总数为w;所述智能合约用于在已选取的目标对象的数量未达到w时,将所述随机种子和采样区间[M,N]作为输入、通过所述伪随机数发生器生成1个伪随机数,其中M为申请编号的最小值、N为申请编号的最大值。换言之,在每次生成伪随机数时,采用的采样区间均覆盖所有的申请编号,而不会剔除已被选取的目标对象对应的申请编号,可以确保各个备选对象的实际中签概率在每次产生伪随机数时都不变,避免剔除目标对象对应的申请编号而导致其他备选用户的实际中签概率增大,从而确保公平性。
在一实施例中,所述智能合约用于将每一备选对象对应的申请编号存证于区块链中,使得备选用户或监管方可以随时从区块链中对申请编号进行查验,避免发生造假作弊。
在一实施例中,所述随机种子还与区块链中的一个或多个其他区块的区块内容相关,使得不法分子即便具备区块攻击能力,也必须分别攻击第二区块和该其他区块才能够达成目的,造成了极高的攻击成本,可以极大地降低不法分子操控随机种子的可能性。
在一实施例中,所述一个或多个其他区块包括:包含至少一条申请记录的区块,使得所有的申请记录均可以影响到随机种子,可以增加随机种子的不确定性,降低被不法分子猜测或操控的可能性。
在一实施例中,所述一个或多个其他区块包括:与所述第二区块相邻的一个或多个区块。比如当该一个或多个其他区块的数量为r时,可以选取第二区块之前的r个区块;或者,可以在生成第二区块之后,等待区块链中继续产生r个区块,并基于该第二区块和该r个区块生成随机种子。
在一实施例中,所述智能合约用于通过下述公式对所述第二区块和r个其他区块(比如上述包含申请记录的一个或多个区块,或者位于第二区块之后的一个或多个区块)的区块内容进行处理,以确定出所述实际结果:
H’1=H(Hp,Hr),
H’i=H(H’(i-1),H(r-i+1)),其中1<i≤r;
其中,H为预设的哈希函数,Hp为与所述第二区块的区块内容相关的哈希值,Hi为与第i个其他区块的区块内容相关的哈希值,所述随机种子为Hf=H(H’r,Hp)。
在一实施例中,在通过上述公式进行计算的过程中,r个其他区块之间可以按照预设顺序进行依次排列,形成第1个其他区块、……、第r个其他区块,比如该预设顺序可以包括区块高度从小至大的顺序、区块内容的哈希值从小至大的顺序等,本说明书并不对此进行限制。
在一实施例中,所述智能合约用于在区块链中产生第三区块后,生成所述随机种子;其中,所述第三区块的区块高度大于所述第二区块,且高度差为预设数值。换言之,智能合约虽然基于第二区块的区块内容来确定随机种子,但是产生该第二区块后并不立即确定随机种子,而是等待预设数量个区块之后,才确定该随机种子,保证了第二区块的安全性,使得攻击者必须连续攻击第二区块与第三区块之间的所有区块,使得攻击成本极高,可以极大地降低不法分子操控随机种子的可能性。
为了便于理解,下面以选购不动产时的摇号过程为例,对本说明书的对象选取方案进行描述。图2是一示例性实施例提供的一种摇号选购不动产的示意图;如图2所示,假定用户A希望参与针对某一楼盘的摇号,该用户A可以通过安装有客户端的手机21提交申请摇号资格所需的摇号申请,比如身份证明材料、存款证明材料、对应于数字身份的公钥、个人资料等,这取决于楼盘开发商或相关法律法规的要求。
设备22被配置为摇号系统的服务端,该设备22一方面与用户A使用的手机21进行交互、以协助其申请摇号资格,另一方面与设备23进行交互。设备23被配置为区块链中的一个区块链节点,基于设备22所提供的信息,可以配置、发布智能合约,并通过调用智能合约以实现摇号资格的申请和摇号操作等。楼盘开发商或摇号公证部门可以对智能合约进行配置,以设定对摇号资格的申请条件、摇号过程包含的各个阶段(如基于时间划分各个阶段或者基于区块链上的区块高度划分各个阶段等)、每一阶段所采取的处理逻辑等,使得该智能合约可以用于实现本说明书的对象选取方案,以完成相应的 摇号操作。
假定已完成对智能合约的配置过程,并且该智能合约已被发布至区块链中,那么基于该智能合约可以实现如图3所示的摇号过程,该过程可以包括以下步骤:
步骤301,用户申请摇号资格。
在一实施例中,用户A可以通过手机21向设备22提交摇号申请,并经由设备23向区块链中提交包含该摇号申请的交易,该交易的类型可以被配置或标记为申请摇号资格的类型。类似地,其他用户也可以通过上述方式申请摇号资格,从而与用户A一并参与摇号。
除了通过设备23向区块链提交包含摇号申请的交易之外,用户A也可以通过其他区块链节点向区块链提交包含摇号申请的交易,比如该手机21可以被配置为一区块链节点,那么用户A可以基于该手机21向区块链提交包含摇号申请的交易。
上述包含摇号申请的交易可以被记录至区块链账本中,智能合约可以从区块链账本中进行查询和访问,以获取这些交易中包含的摇号申请,从而验证相应的用户是否可以获得摇号资格。
在一实施例中,以设备23为例,设备23可以获知智能合约的名称或位置等信息,使得设备23可以直接将摇号申请发送至智能合约,而智能合约可以针对收到的摇号申请进行验证,以确定相应的用户是否可以获得摇号资格。
步骤302,智能合约验证用户信息。
在一实施例中,智能合约获得某一用户的摇号申请后,可以按照预先定义的申请条件对该摇号申请进行验证,以确定其是否满足该申请条件;如果满足,则判定相应的用户具备摇号资格,否则判定为不具备摇号资格。
在一实施例中,摇号申请中包含对应用户的公钥和其他个人信息,且摇号申请应当由用户的私钥进行签名,以确保其内容的真实有效、不可篡改。
步骤303,智能合约将验证结果存证于区块链账本中。
在一实施例中,通过将验证结果存证于区块链账本中,相当于对验证结果进行公示,使得验证结果透明、可追溯,并且无法随意篡改验证结果,确保对于摇号申请的验证符合要求,避免暗箱操作。
步骤304,智能合约为通过验证的用户生成资格编号,并将资格编号存证于区块链 账本中。
在一实施例中,假定以区块高度来划分各个阶段,智能合约可以定义申请阶段、编号阶段、摇号阶段等每一阶段对应的区块高度范围,比如申请阶段对应的区块高度为T0-T1、编号阶段对应的区块高度为T2-T3、摇号阶段对应的区块高度为T4-T5。那么,对于申请阶段而言,智能合约可以从区块链账本中读取处于T0-T1高度的区块内记录的摇号申请,只有这些摇号申请有可能参与到本次摇号过程中,而其他区块内的摇号申请则无法参与到本次摇号过程中。
在一实施例中,智能合约可以按照预设的方式为通过验证的用户生成资格编号,本说明书并不对此进行限制。举例而言,可以通过如下方式生成资格编号:
首先,确定各个用户的中签率。智能合约可以从区块链账本中读取和统计各个用户在历史上参与的摇号活动,并基于该统计数据确定中签率;例如,当历史上参与的摇号次数不大于第一数值时,中签率可以为标准中签率,当摇号次数大于第一数值、不大于第二数值时,中签率可以为标准中签率的2倍,当摇号次数大于第二数值、不大于第三数值时,中签率可以为标准中签率的3倍,以此类推。当然,各个用户的中签率也可以通过其他方式计算得到,并记录至区块链账本中,而智能合约只需要从区块链账本中读取通过验证的各个用户分别对应的中签率即可。
其次,智能合约可以基于通过验证的各个用户的公钥pk、指定的历史区块的哈希值PreH,分别计算各个用户对应的过渡ID。例如,智能合约中可以设定有哈希函数H(),则各个用户对应的过渡ID可以为H(PreH,pk),即通过哈希函数H()对哈希值PreH和公钥pk进行计算,得到相应的哈希值,使得该过渡ID具有极高的随机性,无法被不法分子操控。
然后,智能合约可以根据生成的过渡ID,为各个用户分别赋予相应的资格编号。假定通过验证的用户为U1~Um,这些用户的中签率分别为标准中签率的1倍、2倍、3倍……n倍,那么智能合约可以实施下述操作:
从用户U1~Um中,选取中签率不小于标准中签率的1倍的所有用户,即用户U1~Um均被选中;按照过渡ID从小至大的顺序,对被选中的m个用户进行依次排列,然后基于排列次序生成相应的资格编号。由于尚未存在已生成的资格编号,因而此时生成的资格编号可以从头开始,比如为过渡ID最小的用户生成资格编号为1、为过渡ID第二小的用户生成资格编号为2,直至为过渡ID最大的用户生成资格编号为m。因此,针对 中签率不小于标准中签率的1倍的所有用户,此时可以生成相应的m个资格编号,分别为上述的1~m;换言之,此时每一用户分别具有1个对应的资格编号。
进一步地,从用户U1~Um中,选取中签率不小于标准中签率的2倍的所有用户,即中签率为标准中签率的2~n倍的用户,假定这些用户的数量为a;按照过渡ID从小至大的顺序,对被选中的a个用户进行依次排列,然后基于排列次序生成相应的资格编号。由于存在已生成的资格编号1~m,因而此时接续生成资格编号,比如为过渡ID最小的用户生成资格编号为m+1、为过渡ID第二小的用户生成资格编号为m+2,直至为过渡ID最大的用户生成资格编号为m+a。因此,针对中签率不小于标准中签率的2倍的所有用户,此时可以生成相应的a个资格编号,分别为上述的m+1~m+a。此时,对于中签率为标准中签率的1倍的用户,每一用户存在1个资格编号;而对于中签率不小于标准中签率的2倍的用户,每一用户存在2个资格编号。
进一步地,从用户U1~Um中,选取中签率不小于标准中签率的3倍的所有用户,即中签率为标准中签率的3~n倍的用户,假定这些用户的数量为b;按照过渡ID从小至大的顺序,对被选中的b个用户进行依次排列,然后基于排列次序生成相应的资格编号。由于存在已生成的资格编号1~m+a,因而此时接续生成资格编号,比如为过渡ID最小的用户生成资格编号为m+a+1、为过渡ID第二小的用户生成资格编号为m+a+2,直至为过渡ID最大的用户生成资格编号为m+a+b。因此,针对中签率不小于标准中签率的3倍的所有用户,此时可以生成相应的b个资格编号,分别为上述的m+a+1~m+a+b。此时,对于中签率为标准中签率的1倍的用户,每一用户存在1个资格编号;而对于中签率不小于标准中签率的2倍的用户,每一用户存在2个资格编号;而对于中签率不小于标准中签率的3倍的用户,每一用户存在3个资格编号。
以此类推,智能合约可以针对每一中签率,分别通过上述方式对相应用户分配对应的资格编号,最终使得中签率为标准中签率的i倍的用户,能够分配得到i个资格编号,其中1≤i≤n。
在一实施例中,通过将所有参与摇号的用户对应的资格编号存证于区块链账本中,使得各个用户的资格编号公开、透明、可查询且不可篡改,因而在后续的摇号过程中,可以基于该资格编号准确地确定各个用户是否摇中,具有极高的公平性、公开性和可信度。
步骤305,智能合约监控区块链账本中已生成的区块,在最近区块的区块高度达到P时,等待区块链账本中继续生成Q个区块后,转入步骤306。
在一实施例中,P和Q均为预定义的任意取值。当摇号阶段对应的区块高度范围为T4-T5时,应当确保T4<P≤P+Q<T5;换言之,Q的取值可以为0,即区块高度到达P后即可转入步骤306,而并非必须等待。当Q>0时,Q的取值与区块链中生成区块的速度相关,只需要确保在Q个区块后,该高度为P的区块不会发生变化即可;而通过等待Q个区块,可以保证高度为P的区块的安全性,攻击者必须连续攻击高度为P和P+Q之间的所有区块,使得攻击成本极高,可以极大地降低不法分子操控摇号的可能性。
步骤306,智能合约生成随机种子。
在一实施例中,智能合约可以分别确定出高度为P的区块,以及区块链中包含与本次摇号相关的摇号申请的r个区块,并分别获取这些区块的哈希值(哈希值与对应区块的区块内容相关),比如:高度为P的区块对应于哈希值Hp,而r个区块对应的哈希值分别为H1~Hr(譬如可以按照区块高度从小至大的顺序进行排列)。进一步的,智能合约可以按照下述公式进行计算:
H’1=H(Hp,Hr),
H’i=H(H’(i-1),H(r-i+1)),其中1<i≤r;
其中,H为预设的哈希函数,H(Hp,Hr)表示通过该哈希函数H对Hp和Hr进行哈希运算、得到相应的哈希值为H’1;类似地,H(H’(i-1),H(r-i+1))表示通过该哈希函数H对H’(i-1)和H(r-i+1)进行哈希运算、得到相应的哈希值为H’i。最终,可以计算得到计算结果为H’r,而随机种子为Hf=H(H’r,Hp),使得所有用户提供的摇号申请均可以对随机种子的取值产生影响,而不法分子无法对所有用户提交的摇号申请进行控制,因而无法对随机种子的取值进行操控。
当然,这里除了选用包含摇号申请的r个区块之外,还可以选用其他类型的区块,本说明书并不对此进行限制。例如,在等待高度为P的区块生成后,继续等待上述的Q个区块,并基于该Q个区块和高度为P的区块生成随机种子;其中:
H’1=H(Hp,HQ),
H’i=H(H’(i-1),H(Q-i+1)),其中1<i≤Q;
其中,H为预设的哈希函数,H(Hp,HQ)表示通过该哈希函数H对Hp和HQ(假定高度为P的区块的哈希值为Hp,此后的Q个区块的哈希值分别为H1、H2……HQ)进行哈希运算、得到相应的哈希值为H’1;类似地,H(H’(i-1),H(Q-i+1))表示通过该哈希函数H对H’(i-1)和H(Q-i+1)进行哈希运算、得到相应的哈希值为H’i。最终,可以计 算得到计算结果为H’Q,而随机种子为Hf=H(H’Q,Hp)。
步骤307,智能合约生成中签号码,将中签号码存证于区块链账本中。
在一实施例中,智能合约可以调用设定的伪随机数发生器,以用于生成中签号码。针对为伪随机数发生器的输入数据可以包括:随机种子和采样区间;其中:随机种子为上述过程中生成的Hf,而采样区间可以根据各个用户的资格编号的取值范围而生成,比如当资格编号的最小值为1、最大值为Y时,可以将采样区间设定为[1,Y],使得伪随机数发生器生成的中签号码处于该范围[1,Y]中。
假定中签数量为w,当已中签的用户数量小于w时,智能合约可以通过伪随机数发生器生成匹配于随机种子Hf、采样区间[1,Y]的中签号码,并在确定出匹配于中签号码的资格编号后,确认该资格编号对应的用户是否先前已中签,若未中签则确认该用户被抽中,否则本次中签号码无效,需要继续抽取。虽然在此过程中,不断产生已中签的用户,但是应当确保采样区间始终不变、不剔除已中签用户对应的资格编号,以确保每一用户对应的实际中签概率在整个过程中不会发生变化,不会由于剔除已中签用户而导致实际中签概率增大,可以保证摇号的公平性。
在一实施例中,通过将中签号码存证于区块链账本上,使得用户或监管方可以随时进行查证核验,避免不法分子进行篡改。以用户A为例,用户A可以通过手机21向设备22发起查询请求,设备22可以通过设备23对区块链账本进行查询,并将查询到的摇号结果返回手机21,以由用户A进行查看,确保自己是否具备不动产的选购权限;类似地,当用户A对摇号过程存在异议时,同样可以通过上述过程,对区块链账本中的相关数据进行追溯查询,整个过程及其产生的数据均公开透明。
图4是一示例性实施例提供的一种设备的示意结构图。请参考图4,在硬件层面,该设备包括处理器402、内部总线404、网络接口406、内存408以及非易失性存储器410,当然还可能包括其他业务所需要的硬件。处理器402从非易失性存储器410中读取对应的计算机程序到内存408中然后运行,在逻辑层面上形成对象选取装置。当然,除了软件实现方式之外,本说明书一个或多个实施例并不排除其他实现方式,比如逻辑器件抑或软硬件结合的方式等等,也就是说以下处理流程的执行主体并不限定于各个逻辑单元,也可以是硬件或逻辑器件。
请参考图5,在软件实施方式中,该对象选取装置应用于区块链节点;该装置可以包括:
获取单元51,获取备选对象提交的参选申请;
调用单元52,调用智能合约,所述智能合约被用于向区块链的第一区块发布与所述参选申请相关的申请记录,根据区块链中的第二区块的区块内容生成随机种子,并通过伪随机数发生器生成基于所述随机种子的伪随机数,以使得匹配于所述伪随机数的备选对象被选取为目标对象;其中,所述第二区块的区块高度大于所述第一区块的区块高度。
可选的,所述智能合约还用于:为每一备选对象分别生成申请编号,每一申请编号对应于唯一的备选对象;其中,当所述伪随机数与任一申请编号相同时,所述任一申请编号对应的备选对象被确定为匹配于所述伪随机数。
可选的,所述申请编号与所述备选对象对应的唯一标识的取值相关,所述唯一标识的取值由与区块链中的历史区块相关的哈希值和所述备选用户的公钥进行哈希计算而得到。
可选的,当所述备选对象的中签率为标准中签率的x倍时,所述备选对象存在x个申请编号;其中,x为正整数。
可选的,所述智能合约用于将与区块链中的历史区块相关的哈希值与所述备选对象的公钥进行哈希计算,得到相应的唯一标识;
当x的取值从小至大地分别包括x1~xn时,所述智能合约用于依次选取x1~xn;其中,当选取xi时,所述智能合约将中签率不小于标准中签率的xi倍的备选对象对应的唯一标识按照从小至大依次排列,并在已有申请编号之后、按照排列次序接续生成相应的申请编号,1≤i≤n。
可选的,所述目标对象的总数为w;所述智能合约用于在已选取的目标对象的数量未达到w时,将所述随机种子和采样区间[M,N]作为输入、通过所述伪随机数发生器生成1个伪随机数,其中M为申请编号的最小值、N为申请编号的最大值。
可选的,所述智能合约用于将每一备选对象对应的申请编号存证于区块链中。
可选的,所述随机种子还与区块链中的一个或多个其他区块的区块内容相关。
可选的,所述一个或多个其他区块包括:包含至少一条申请记录的区块。
可选的,所述一个或多个其他区块包括:与所述第二区块相邻的一个或多个区块。
可选的,所述智能合约用于通过下述公式对所述第二区块和r个其他区块的区块内容进行处理,以确定出所述实际结果:
H’1=H(Hp,Hr),
H’i=H(H’(i-1),H(r-i+1)),其中1<i≤r;
其中,H为预设的哈希函数,Hp为与所述第二区块的区块内容相关的哈希值,Hi为与第i个其他区块的区块内容相关的哈希值,所述随机种子为Hf=H(H’r,Hp)。
可选的,所述智能合约用于在区块链中产生第三区块后,生成所述随机种子;其中,所述第三区块的区块高度大于所述第二区块,且高度差为预设数值。
上述实施例阐明的系统、装置、模块或单元,具体可以由计算机芯片或实体实现,或者由具有某种功能的产品来实现。一种典型的实现设备为计算机,计算机的具体形式可以是个人计算机、膝上型计算机、蜂窝电话、相机电话、智能电话、个人数字助理、媒体播放器、导航设备、电子邮件收发设备、游戏控制台、平板计算机、可穿戴设备或者这些设备中的任意几种设备的组合。
在一个典型的配置中,计算机包括一个或多个处理器(CPU)、输入/输出接口、网络接口和内存。
内存可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM)。内存是计算机可读介质的示例。
计算机可读介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(PRAM)、静态随机存取存储器(SRAM)、动态随机存取存储器(DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带、磁盘存储、量子存储器、基于石墨烯的存储介质或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。按照本文中的界定,计算机可读介质不包括暂存电脑可读媒体(transitory media),如调制的数据信号和载波。
还需要说明的是,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、商品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、商品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不 排除在包括所述要素的过程、方法、商品或者设备中还存在另外的相同要素。
上述对本说明书特定实施例进行了描述。其它实施例在所附权利要求书的范围内。在一些情况下,在权利要求书中记载的动作或步骤可以按照不同于实施例中的顺序来执行并且仍然可以实现期望的结果。另外,在附图中描绘的过程不一定要求示出的特定顺序或者连续顺序才能实现期望的结果。在某些实施方式中,多任务处理和并行处理也是可以的或者可能是有利的。
在本说明书一个或多个实施例使用的术语是仅仅出于描述特定实施例的目的,而非旨在限制本说明书一个或多个实施例。在本说明书一个或多个实施例和所附权利要求书中所使用的单数形式的“一种”、“所述”和“该”也旨在包括多数形式,除非上下文清楚地表示其他含义。还应当理解,本文中使用的术语“和/或”是指并包含一个或多个相关联的列出项目的任何或所有可能组合。
应当理解,尽管在本说明书一个或多个实施例可能采用术语第一、第二、第三等来描述各种信息,但这些信息不应限于这些术语。这些术语仅用来将同一类型的信息彼此区分开。例如,在不脱离本说明书一个或多个实施例范围的情况下,第一信息也可以被称为第二信息,类似地,第二信息也可以被称为第一信息。取决于语境,如在此所使用的词语“如果”可以被解释成为“在……时”或“当……时”或“响应于确定”。
以上所述仅为本说明书一个或多个实施例的较佳实施例而已,并不用以限制本说明书一个或多个实施例,凡在本说明书一个或多个实施例的精神和原则之内,所做的任何修改、等同替换、改进等,均应包含在本说明书一个或多个实施例保护的范围之内。
Claims (25)
- 一种对象选取方法,应用于区块链节点;所述方法包括:获取备选对象提交的参选申请;调用智能合约,所述智能合约被用于向区块链的第一区块发布与所述参选申请相关的申请记录,根据区块链中的第二区块的区块内容生成随机种子,并通过伪随机数发生器生成基于所述随机种子的伪随机数,以使得匹配于所述伪随机数的备选对象被选取为目标对象;其中,所述第二区块的区块高度大于所述第一区块的区块高度。
- 根据权利要求1所述的方法,所述智能合约还用于:为每一备选对象分别生成申请编号,每一申请编号对应于唯一的备选对象;其中,当所述伪随机数与任一申请编号相同时,所述任一申请编号对应的备选对象被确定为匹配于所述伪随机数。
- 根据权利要求2所述的方法,所述申请编号与所述备选对象对应的唯一标识的取值相关,所述唯一标识的取值由与区块链中的历史区块相关的哈希值和所述备选用户的公钥进行哈希计算而得到。
- 根据权利要求2所述的方法,当所述备选对象的中签率为标准中签率的x倍时,所述备选对象存在x个申请编号;其中,x为正整数。
- 根据权利要求4所述的方法,所述智能合约用于将与区块链中的历史区块相关的哈希值与所述备选对象的公钥进行哈希计算,得到相应的唯一标识;当x的取值从小至大地分别包括x1~xn时,所述智能合约用于依次选取x1~xn;其中,当选取xi时,所述智能合约将中签率不小于标准中签率的xi倍的备选对象对应的唯一标识按照从小至大依次排列,并在已有申请编号之后、按照排列次序接续生成相应的申请编号,1≤i≤n。
- 根据权利要求2所述的方法,所述目标对象的总数为w;所述智能合约用于在已选取的目标对象的数量未达到w时,将所述随机种子和采样区间[M,N]作为输入、通过所述伪随机数发生器生成1个伪随机数,其中M为申请编号的最小值、N为申请编号的最大值。
- 根据权利要求2所述的方法,所述智能合约用于将每一备选对象对应的申请编号存证于区块链中。
- 根据权利要求1所述的方法,所述随机种子还与区块链中的一个或多个其他区块的区块内容相关。
- 根据权利要求8所述的方法,所述一个或多个其他区块包括:包含至少一条申 请记录的区块。
- 根据权利要求8所述的方法,所述一个或多个其他区块包括:与所述第二区块相邻的一个或多个区块。
- 根据权利要求8所述的方法,所述智能合约用于通过下述公式对所述第二区块和r个其他区块的区块内容进行处理,以确定出所述实际结果:H’1=H(Hp,Hr),H’i=H(H’(i-1),H(r-i+1)),其中1<i≤r;其中,H为预设的哈希函数,Hp为与所述第二区块的区块内容相关的哈希值,Hi为与第i个其他区块的区块内容相关的哈希值,所述随机种子为Hf=H(H’r,Hp)。
- 根据权利要求1所述的方法,所述智能合约用于在区块链中产生第三区块后,生成所述随机种子;其中,所述第三区块的区块高度大于所述第二区块,且高度差为预设数值。
- 一种对象选取装置,应用于区块链节点;所述装置包括:获取单元,获取备选对象提交的参选申请;调用单元,调用智能合约,所述智能合约被用于向区块链的第一区块发布与所述参选申请相关的申请记录,根据区块链中的第二区块的区块内容生成随机种子,并通过伪随机数发生器生成基于所述随机种子的伪随机数,以使得匹配于所述伪随机数的备选对象被选取为目标对象;其中,所述第二区块的区块高度大于所述第一区块的区块高度。
- 根据权利要求13所述的装置,所述智能合约还用于:为每一备选对象分别生成申请编号,每一申请编号对应于唯一的备选对象;其中,当所述伪随机数与任一申请编号相同时,所述任一申请编号对应的备选对象被确定为匹配于所述伪随机数。
- 根据权利要求14所述的装置,所述申请编号与所述备选对象对应的唯一标识的取值相关,所述唯一标识的取值由与区块链中的历史区块相关的哈希值和所述备选用户的公钥进行哈希计算而得到。
- 根据权利要求14所述的装置,当所述备选对象的中签率为标准中签率的x倍时,所述备选对象存在x个申请编号;其中,x为正整数。
- 根据权利要求16所述的装置,所述智能合约用于将与区块链中的历史区块相关的哈希值与所述备选对象的公钥进行哈希计算,得到相应的唯一标识;当x的取值从小至大地分别包括x1~xn时,所述智能合约用于依次选取x1~xn;其中,当选取xi时,所述智能合约将中签率不小于标准中签率的xi倍的备选对象对应的 唯一标识按照从小至大依次排列,并在已有申请编号之后、按照排列次序接续生成相应的申请编号,1≤i≤n。
- 根据权利要求14所述的装置,所述目标对象的总数为w;所述智能合约用于在已选取的目标对象的数量未达到w时,将所述随机种子和采样区间[M,N]作为输入、通过所述伪随机数发生器生成1个伪随机数,其中M为申请编号的最小值、N为申请编号的最大值。
- 根据权利要求14所述的装置,所述智能合约用于将每一备选对象对应的申请编号存证于区块链中。
- 根据权利要求13所述的装置,所述随机种子还与区块链中的一个或多个其他区块的区块内容相关。
- 根据权利要求20所述的装置,所述一个或多个其他区块包括:包含至少一条申请记录的区块。
- 根据权利要求20所述的装置,所述一个或多个其他区块包括:与所述第二区块相邻的一个或多个区块。
- 根据权利要求20所述的装置,所述智能合约用于通过下述公式对所述第二区块和r个其他区块的区块内容进行处理,以确定出所述实际结果:H’1=H(Hp,Hr),H’i=H(H’(i-1),H(r-i+1)),其中1<i≤r;其中,H为预设的哈希函数,Hp为与所述第二区块的区块内容相关的哈希值,Hi为与第i个其他区块的区块内容相关的哈希值,所述随机种子为Hf=H(H’r,Hp)。
- 根据权利要求13所述的装置,所述智能合约用于在区块链中产生第三区块后,生成所述随机种子;其中,所述第三区块的区块高度大于所述第二区块,且高度差为预设数值。
- 一种电子设备,包括:处理器;用于存储处理器可执行指令的存储器;其中,所述处理器通过运行所述可执行指令以实现如权利要求1-12中任一项所述的方法。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201811258150.7 | 2018-10-26 | ||
| CN201811258150.7A CN109584432B (zh) | 2018-10-26 | 2018-10-26 | 对象选取方法及装置、电子设备 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2020082883A1 true WO2020082883A1 (zh) | 2020-04-30 |
Family
ID=65920850
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2019/102777 Ceased WO2020082883A1 (zh) | 2018-10-26 | 2019-08-27 | 对象选取方法及装置、电子设备 |
Country Status (3)
| Country | Link |
|---|---|
| CN (2) | CN109584432B (zh) |
| TW (1) | TW202016813A (zh) |
| WO (1) | WO2020082883A1 (zh) |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112954039A (zh) * | 2021-02-04 | 2021-06-11 | 上海百姓装潢有限公司 | 一种区块链存证方法 |
| CN115115365A (zh) * | 2022-06-29 | 2022-09-27 | 中国银行股份有限公司 | 一种区块链哈希值更新方法及相关设备 |
| EP4465585A1 (en) * | 2023-05-17 | 2024-11-20 | Fujitsu Limited | Account selection program, account selection device, and account selection method |
Families Citing this family (13)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109584432B (zh) * | 2018-10-26 | 2020-06-30 | 阿里巴巴集团控股有限公司 | 对象选取方法及装置、电子设备 |
| CN110163753A (zh) * | 2019-04-23 | 2019-08-23 | 阿里巴巴集团控股有限公司 | 基于区块链的房屋信息存证、应用方法和装置 |
| CN110780847B (zh) * | 2019-10-15 | 2022-02-25 | 腾讯科技(深圳)有限公司 | 随机数生成方法、随机数生成装置及电子设备 |
| CN110990808B (zh) * | 2019-11-21 | 2022-04-01 | 杭州趣链科技有限公司 | 一种基于区块链的公证摇号方法 |
| CN110910559B (zh) * | 2019-11-25 | 2021-06-25 | 杭州趣链科技有限公司 | 一种基于区块链的抽奖方法 |
| CN111429643B (zh) * | 2020-03-18 | 2022-07-08 | 南京巨公科技有限公司 | 一种摇号的方法、装置以及存储介质 |
| CN111626850B (zh) * | 2020-06-05 | 2023-04-18 | 中国银行股份有限公司 | 存款信息的处理方法、装置、可读介质及设备 |
| CN111884807B (zh) * | 2020-07-13 | 2021-10-26 | 腾讯科技(深圳)有限公司 | 基于区块链的物品预约方法、装置、设备以及介质 |
| CN111562969B (zh) * | 2020-07-15 | 2020-10-20 | 百度在线网络技术(北京)有限公司 | 一种区块链的智能合约实现方法、装置、设备和介质 |
| CN112163237B (zh) * | 2020-09-01 | 2025-04-15 | 北京字节跳动网络技术有限公司 | 数据处理方法、装置和电子设备 |
| CN112562168B (zh) * | 2020-11-27 | 2022-08-02 | 中国联合网络通信集团有限公司 | 基于区块链的线上摇号方法、系统、设备及存储介质 |
| CN113672763B (zh) * | 2021-07-30 | 2023-10-10 | 北京奇艺世纪科技有限公司 | 视频数据抽取方法、装置、电子设备及存储介质 |
| CN115083062B (zh) * | 2022-07-22 | 2022-12-09 | 阿里健康科技(杭州)有限公司 | 信息处理方法、信息发送方法、计算机设备及存储介质 |
Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2009169489A (ja) * | 2008-01-11 | 2009-07-30 | Oki Electric Ind Co Ltd | 暗号化方法、復号化方法、暗号化装置、復号化装置 |
| CN108269090A (zh) * | 2018-01-19 | 2018-07-10 | 中国科学院软件研究所 | 基于无协商随机抽签的用于区块链系统的共识方法和装置 |
| CN108648323A (zh) * | 2018-05-10 | 2018-10-12 | 广州市申迪计算机系统有限公司 | 目标信息的选取方法、装置、计算机设备和存储介质 |
| CN108665272A (zh) * | 2018-05-02 | 2018-10-16 | 百度在线网络技术(北京)有限公司 | 区块链数据处理方法、装置、设备和存储介质 |
| CN109242677A (zh) * | 2018-07-27 | 2019-01-18 | 阿里巴巴集团控股有限公司 | 对象选取方法及装置、电子设备 |
| CN109584432A (zh) * | 2018-10-26 | 2019-04-05 | 阿里巴巴集团控股有限公司 | 对象选取方法及装置、电子设备 |
| CN109615370A (zh) * | 2018-10-25 | 2019-04-12 | 阿里巴巴集团控股有限公司 | 对象选取方法及装置、电子设备 |
Family Cites Families (15)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101364928A (zh) * | 2007-08-06 | 2009-02-11 | 曹炜斌 | 一种提高网络信息资源分布的方法及系统 |
| CN105162760B (zh) * | 2015-07-28 | 2018-08-14 | 郝孟一 | 随机抽取方法、装置以及系统 |
| CN105069561A (zh) * | 2015-07-30 | 2015-11-18 | 四川建设网有限责任公司 | 一种评标专家抽取方法及装置 |
| US20170109955A1 (en) * | 2015-10-20 | 2017-04-20 | Follow My Vote, Inc. | Blockchain electronic voting system and method |
| CN105871855B (zh) * | 2016-04-11 | 2019-09-13 | 杨鹏 | 一种电子设备标识码生成、存储和识别的方法及系统 |
| CN106157142A (zh) * | 2016-06-30 | 2016-11-23 | 惠众商务顾问(北京)有限公司 | 一种区块链共识及同步方法、系统和装置 |
| CN106296200A (zh) * | 2016-08-13 | 2017-01-04 | 深圳市樊溪电子有限公司 | 基于区块链技术的分布式光伏电力交易平台 |
| CN106980488A (zh) * | 2017-03-14 | 2017-07-25 | 腾讯科技(深圳)有限公司 | 随机数生成方法及装置 |
| CN107103097A (zh) * | 2017-05-22 | 2017-08-29 | 中链科技有限公司 | 基于区块链技术的抽签方法和终端设备 |
| CN107294727B (zh) * | 2017-05-22 | 2020-06-19 | 联动优势科技有限公司 | 一种电子投票方法、终端设备以及区块链网络 |
| CN107146318A (zh) * | 2017-06-05 | 2017-09-08 | 上海交通大学 | 基于虚拟货币的投票系统 |
| CN107341695A (zh) * | 2017-07-12 | 2017-11-10 | 重庆浩品峰电子商务有限公司 | 抽奖方法以及装置 |
| CN107820690B (zh) * | 2017-08-21 | 2020-11-10 | 达闼科技成都有限公司 | 信息选取方法、装置、电子设备及计算机可读存储介质 |
| CN108109257A (zh) * | 2018-01-05 | 2018-06-01 | 杭州电子科技大学 | 一种基于区块链的匿名电子投票方法 |
| CN108665274A (zh) * | 2018-05-14 | 2018-10-16 | 北京链享未来科技有限公司 | 一种记账节点智能选择方法 |
-
2018
- 2018-10-26 CN CN201811258150.7A patent/CN109584432B/zh active Active
- 2018-10-26 CN CN202010753642.4A patent/CN111882745B/zh active Active
-
2019
- 2019-03-21 TW TW108109778A patent/TW202016813A/zh unknown
- 2019-08-27 WO PCT/CN2019/102777 patent/WO2020082883A1/zh not_active Ceased
Patent Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2009169489A (ja) * | 2008-01-11 | 2009-07-30 | Oki Electric Ind Co Ltd | 暗号化方法、復号化方法、暗号化装置、復号化装置 |
| CN108269090A (zh) * | 2018-01-19 | 2018-07-10 | 中国科学院软件研究所 | 基于无协商随机抽签的用于区块链系统的共识方法和装置 |
| CN108665272A (zh) * | 2018-05-02 | 2018-10-16 | 百度在线网络技术(北京)有限公司 | 区块链数据处理方法、装置、设备和存储介质 |
| CN108648323A (zh) * | 2018-05-10 | 2018-10-12 | 广州市申迪计算机系统有限公司 | 目标信息的选取方法、装置、计算机设备和存储介质 |
| CN109242677A (zh) * | 2018-07-27 | 2019-01-18 | 阿里巴巴集团控股有限公司 | 对象选取方法及装置、电子设备 |
| CN109615370A (zh) * | 2018-10-25 | 2019-04-12 | 阿里巴巴集团控股有限公司 | 对象选取方法及装置、电子设备 |
| CN109584432A (zh) * | 2018-10-26 | 2019-04-05 | 阿里巴巴集团控股有限公司 | 对象选取方法及装置、电子设备 |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112954039A (zh) * | 2021-02-04 | 2021-06-11 | 上海百姓装潢有限公司 | 一种区块链存证方法 |
| CN115115365A (zh) * | 2022-06-29 | 2022-09-27 | 中国银行股份有限公司 | 一种区块链哈希值更新方法及相关设备 |
| EP4465585A1 (en) * | 2023-05-17 | 2024-11-20 | Fujitsu Limited | Account selection program, account selection device, and account selection method |
Also Published As
| Publication number | Publication date |
|---|---|
| TW202016813A (zh) | 2020-05-01 |
| CN111882745A (zh) | 2020-11-03 |
| CN111882745B (zh) | 2022-12-20 |
| CN109584432B (zh) | 2020-06-30 |
| CN109584432A (zh) | 2019-04-05 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN111882745B (zh) | 对象选取方法及装置、电子设备 | |
| US20240214180A1 (en) | Systems and methods for storage, generation and verification of tokens used to control access to a resource | |
| TWI735820B (zh) | 資產管理方法及裝置、電子設備 | |
| TWI736809B (zh) | 資產管理方法及裝置、電子設備 | |
| CN110059495B (zh) | 数据共享方法、装置及系统、电子设备 | |
| TW202022857A (zh) | 基於區塊鏈的發票創建方法及裝置、電子設備 | |
| TWI759563B (zh) | 資產管理方法及裝置、電子設備 | |
| TWI709055B (zh) | 權益分配方法及裝置、電子設備 | |
| WO2020082873A1 (zh) | 对象选取方法及装置、电子设备 | |
| CN110189122B (zh) | 为区块链上的数据锚定时间的方法及装置、电子设备 | |
| CN110046945A (zh) | 基于区块链的发票创建方法及装置、电子设备 | |
| TW202040478A (zh) | 基於區塊鏈的資源配置方法及裝置和電子設備 | |
| JP2020522927A (ja) | 一般的な計算のためのブロックチェーン | |
| CN111383114A (zh) | 基于区块链的资产信息管理方法和装置 | |
| CN109847365B (zh) | 一种面向区块链应用的防作弊方法及系统 | |
| CN111402033A (zh) | 基于区块链的资产信息管理方法和装置 | |
| US20220393892A1 (en) | Composite Cryptographic Systems with Variable Configuration Parameters and Memory Bound Functions | |
| CN111461691A (zh) | 基于区块链的流量统计系统、方法及装置 | |
| WO2020082869A1 (zh) | 事件预测方法及装置、电子设备 | |
| CN112070342A (zh) | 微服务评价方法和装置、电子设备和计算机可读存储介质 | |
| TW202008270A (zh) | 區塊發佈方法及裝置、電子設備 | |
| US12020242B2 (en) | Fair transaction ordering in blockchains | |
| CN115018489B (zh) | 交易数据处理系统、方法、电子设备及可读存储介质 | |
| CN113626881B (zh) | 对象评估方法、装置、电子设备及存储介质 | |
| HK40039793B (zh) | 对象选取方法及装置、电子设备 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 19877200 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 19877200 Country of ref document: EP Kind code of ref document: A1 |