Tamper-proof method of reputation information based on block chain

Tamper-proof method of reputation information based on block chain

  • CN 106,779,975 B
  • Filed: 01/11/2017
  • Issued: 06/26/2020
  • Est. Priority Date: 01/11/2017
  • Status: Active Grant
First Claim
Patent Images

1. A tamper-proof method of reputation information based on a block chain is applied to a transaction system in which a plurality of buyers and sellers participate, and any seller is marked as a reputation user u;

  • the method is characterized by comprising the following steps;

    step one, establishing a reputation block chain for storing the reputation information;

    step 1.1, establishing an initial block of the reputation block chain;

    making the block head of the initial block be the ID of a credit user u;

    making the block body of the initial block be the time for constructing the initial block;

    making the block tail of the initial block be the encryption information of the block head and the block body of the initial block;

    step 1.2, defining a variable i, and initializing i to be 1;

    taking the initial block as an ith block;

    step 1.3, assuming that the credit user u provides the ith block to the trading system;

    the transaction system calculates an ith credit value of the credit user u by using the first i blocks;

    step 1.4, any buyer judges whether to carry out transaction according to the ith credit value of the credit user u, if so, the transaction system obtains the ith transaction information of the credit user u;

    otherwise, returning to the step 1.4;

    step 1.5, establishing the (i +

         1) th block of the reputation block chain;

    making the block head of the (i +

         1) th block be the address of the ith block;

    making the block main body of the (i +

         1) th block be the ith transaction information;

    making the block tail of the (i +

         1) th block be the encryption information of the block head and the block body of the (i +

         1) th block;

    step two, removing possible forks in the reputation block chain;

    step 2.1, traversing the credit block chain of the credit user u to obtain the addresses of the predecessor blocks and successor blocks of all the blocks and the number m of all the blocks in the credit block chain;

    step 2.2, defining a variable j, and initializing j to be 1;

    step 2.3, judging whether the jth block in the credit block chain of the credit user u has the addresses of 2 subsequent blocks;

    if yes, executing step 2.4;

    otherwise, after j +1 is assigned to j, returning to step 2.3 until j equals m, and executing step 2.8;

    step 2.4, marking 2 subsequent blocks of the jth block as a block α and

    a block β

    respectively, and marking 2 blocks without subsequent blocks as a block lambda and a block gamma, judging whether the block α

    is the block lambda, if so, indicating that the block α

    is a fork, and changing the block head of the block α

    into the address of the block gamma, and making the block tail of the block α

    be the encrypted information of the block head and the block main body of the block α

    , otherwise, executing the step 2.5;

    step 2.5, judging whether the block α

    is a block gamma, if so, indicating that the block α

    is a bifurcation, changing the block head of the block α

    into the address of a block lambda, and enabling the block tail of the block α

    to be the encrypted information of the block head and the block body of the block α

    , otherwise, executing step 2.6;

    step 2.6, judging whether the block β

    is a block lambda, if so, indicating that the block β

    is a bifurcation, changing the block head of the block β

    into the address of a block gamma, and enabling the block tail of the block β

    to be the encrypted information of the block head and the block body of the block β

    , otherwise, executing the step 2.7;

    step 2.7, representing that the block β

    is forked, and changing the block head of the block β

    into the address of a block lambda, and making the block tail of the block β

    be the encryption information of the block head and the block body of the block β

    ;

    and 2.8, assigning m to i, and returning to the step 1.3.

View all claims
    ×
    ×

    Thank you for your feedback

    ×
    ×