PHP blockchain algorithm
jinwowo group analyzes the functions of its hash algorithm as follows:
the hash value of the blockchain can uniquely and accurately identify a block. Any node in the blockchain obtains the hash value of the block through simple hash calculation, and the calculated hash value does not change, which means that the information in the blockchain has not been tampered with.
asymmetric encryption algorithm is a function that converts the original plaintext file or data into a series of unreadable ciphertext codes by using an encryption key. The encryption process is irreversible. Only holding the corresponding decryption key can the encrypted information be decrypted into readable plaintext. Encryption enables private data to be transmitted through the public network under the condition of low risk, and protects the data from being stolen and read by the third party
the core advantage of blockchain technology is decentralization, which can realize point-to-point transaction, coordination and cooperation based on decentralized credit in a distributed system without mutual trust by means of data encryption, time stamp, distributed consensus and economic incentive, so as to solve the high cost and low cost of centralized institutions Low efficiency and data storage insecurity provide solutions
the application fields of blockchain include digital currency, token, finance, anti-counterfeiting traceability, privacy protection, supply chain, entertainment, etc. with the popularity of blockchain and bitcoin, many related top domain names have been registered, which has a great impact on the domain name instry.
FST network is a blockchain application technology service platform, which is committed to further application of blockchain. Its pillar proct FST network engine mole is an infrastructure built for enterprises to save development time. The FST network engine mole, through comprehensive molar logic construction, allows anyone to manage the certificate business without coding environment, reces the threshold of the blockchain development community, and saves the development cycle.
let me analyze it:
1: bitcoin has been broken in China, and its price has dropped sharply, which is unexpected by the global mining pool
2: compared with the current mining cost of bitcoin, it makes money entirely by cheap electricity bills
3: there are only 21 million bitcoins, and most of them have been g up in the early stage, which makes it difficult to dig those bitcoins that have not been g up in the future, and there is too much competition. Many small mines are in a state of loss
and why do many well-known mines turn to TCD
first of all, bitcoin is the optimized and upgraded version of bitcoin, with a constant number of 100 million. The early mining is very good. Unlike bitcoin, which has too high cost and low cost performance ratio, it is appropriate to use bitcoin as a supplement to compare bitcoin. Bitcoin is used for large amount payment and bitcoin is used for small amount payment.
the concept of blockchain is a new application mode of distributed data storage, point-to-point transmission, consensus mechanism, encryption algorithm and other computer technologies. Since it is a mode, it is not limited to language, only that language is more suitable
blockchain needs a lot of storage, calculation and transmission. PHP is not suitable for these characteristics, especially the efficiency of PHP
if you want to study this, look at the article of blockchain more:
understanding of blockchain,
51 lines of code to realize a simple PHP blockchain
As an emerging technology, blockchain has attracted more and more attention. It is a new application of traditional technology in the Internet era, including distributed data storage technology, consensus mechanism and cryptography. With the establishment of various blockchain research alliances, more and more funds and personnel support related research. Hash algorithm, zero knowledge proof, ring signature and other cryptographic algorithms used in blockchain:
hash algorithm
as the basic technology of blockchain, the essence of hash function is to map a set of data of any length (limited) to a set of defined length data stream. If this function satisfies the following conditions:
(1) the calculation of hash value for any group of data is very simple
(2) it is difficult to find two different data with the same hash value
hash functions satisfying the above two properties are also called encrypted hash functions. In case of no contradiction, hash functions usually refer to encrypted hash functions. For the hash function, finding such that is called a collision. The current popular hash functions are MD5, SHA1, Sha2, Sha3
bitcoin uses sha256, and most blockchain systems use sha256 algorithm. So here's sha256< Step 1: additional filling bits. The length of the message is congruent with that of 448 mod512 (length = 448 mod512). The number of bits to be filled ranges from 1 to 512. The highest bit of the filled bit string is 1, and the rest bits are 0
Step2: additional length value. The bit length of the initial message (before filling) represented by 64 bit is appended to the result of step 1 (the low byte takes precedence)
Step3: initialize cache. A 256 bit cache is used to store the intermediate and final results of the hash function
Step 4: process 512 bit (16 word) packet sequence. The algorithm uses six basic logic functions and consists of 64 steps of iterative operation. Each step takes the 256 bit cache value as the input, and then updates the cache content. Each step uses a 32-bit constant KT and a 32-bit wt. Where WT is the packet after the packet, t = 1,2,..., 16
step5: after all 512 bit packets are processed, the output of the last packet of sha256 algorithm is 256 bit packet< In 2001, Rivest, Shamir and TauMan proposed ring signature for the first time. It is a simplified group signature, only ring members have no manager, and it does not need the cooperation between ring members. In the ring signature scheme, the signer first selects a temporary signer set, which includes signers. Then the signer can generate the signature independently by using his private key and the public key of others in the signature set without the help of others. Members of the signer collection may not know that they are included in it
ring signature scheme consists of the following parts:
(1) key generation. A key pair (public key PKI, private key ski) is generated for each member of the ring
(2) signature. The signer uses his private key and the public keys of any n ring members (including himself) to generate the signature a for the message M
(3) signature verification. According to the ring signature and message M, the verifier verifies whether the signature is signed by the member in the ring. If it is valid, it will be received, otherwise it will be discarded
ring signature satisfies the following properties:
(1) unconditional anonymity: the attacker can not determine which member of the ring generated the signature, even if the private key of the ring member is obtained, the probability is not more than 1 / n
(2) Correctness: the signature must be verifiable by all others
(3) unforgeability: other members of the ring can't forge the real signer's signature, and even if an external attacker obtains a valid ring signature, he can't forge a signature for message M
(1) anonymity. The verifier can verify that the signature is signed by a member of the group, but can't know which member it is, so that the signer can be anonymous< (2) traceability. In group signature, the existence of group administrator ensures the traceability of signature. The group administrator can revoke the signature and expose the real signer. The ring signature itself cannot reveal the signer unless the signer wants to expose or add additional information to the signature. A verifiable ring signature scheme is proposed. In this scheme, the real signer wants the verifier to know his identity. At this time, the real signer can confirm his identity by disclosing his secret information< (3) management system. Group signature is managed by group administrator, ring signature does not need to be managed, signer can only select a set of possible signers, obtain its public key, and then publish the set, all members are equalthe Xueshuo innovation blockchain Technology Workstation of Lianqiao ecation online is the only approved "blockchain Technology Specialty" pilot workstation of "smart learning workshop 2020 Xueshuo innovation workstation" launched by the school planning, construction and development center of the Ministry of ecation of China. Based on providing diversified growth paths for students, the professional station promotes the reform of the training mode of the combination of professional degree research, proction, learning and research, and constructs the applied and compound talent training system< br />