Blockchain synchronization file
blockchain is a new application mode of distributed data storage, point-to-point transmission, consensus mechanism, encryption algorithm and other computer technologies. Blockchain is an important concept of bitcoin,
in essence, it is a decentralized database. At the same time, as the underlying technology of bitcoin, it is a series of data blocks generated by using cryptographic methods. Each data block contains a batch of information of bitcoin network transactions, Used to verify the validity of its information (anti-counterfeiting) and generate the next block
extended data
most blockchain public chains are limited by scalability. The biggest feature of blockchain technology is decentralization, which requires that all accounts in the network need to deal with the accounting process. Distributed accounting has high security, low misoperation rate, political neutrality and correctness
however, blockchain technology embraces these features at the same time, sacrificing scalability, unable to meet the personalized supervision, and slightly insufficient in protecting data privacy. Moreover, with the increase of the number of ledger, the interaction delay will increase exponentially, that is to say, the more ledger in the blockchain network, the higher the delay
constructor(index,timestamp,data,previousHash=' 39;)< br />{
this.index=index;< br />this.timestamp=timestamp;< br />this.data=data;< br />this.previousHash=previousHash;< br />$this.hash=this.calculateHash();< br />}
calculateHash(){
return SHA256(this,index+this.previousHash+this.timestamp+JSON.stringify(this.data)).tostring();< br />}
}
class Blockchain{
constructor(){
this.chain=[this.createGenesisBlock()];<
}
/ / create a generated information block
creategenesis block() {
return new block (0, & quot; 01/01/2019",& quot; Genesis block", 0);
/ / the date is the user's data. In fact, it is the hash value obtained by adding several values together. Here, the information is encrypted and the picture is encrypted. Then the data is still stored in the database, but all the data are hash values. To get this data, you must know the hash value of the previous data block. Then, if the hacker needs to crack all the nodes, the hash value is decrypted, Then all the blocks from the first node to the last node can be decrypted to get the real data. So the security of data stored in the blockchain depends on whether the data is encrypted. If the plaintext is not encrypted, then it is not a blockchain
}
/ / get the last block
getlatesblock() {
return this.chain [this.chain. Length-1]
}
/ / create block
addblock (newblock) {
newblock. Previoushash = this. Getlatesblock(). Hash< br />newBlock.hash=newBlock.calculateHash();< br />this.chain.push(newBlock);< br />}
}
generally, the blockchain platform will provide corresponding interfaces, such as RPC, json-rpc, HTTP, etc. of course, the platforms are not the same, and the degree of friendliness is different
some companies specializing in API, such as blockcypher, can provide friendly calling interfaces, and it is not very convenient to write answers on the mobile phone, Search below
as for the storage content, add a point: in addition to the conventional cloud storage, file entities on the file hash record chain also have blockchain based storage schemes, such as IPFs, storej and so on
According to reports, blockchain has the advantages of decentralization, distrust and tamper proof
compared with the Internet, the blockchain network conceived by Cosmos not only realizes information interaction, but also realizes the transmission of asset value. Through the IBC cross chain protocol, the token can be transferred across the chain between the blockchains based on Cosmos' tendermint core. For the public chains based on POW consensus mechanism like Ethereum, pegged zone can be used to bridge
Article source: bit110 network
Everbright Caesar travel white card gift
time: before June 30, 2018
Object: Everbright Caesar joint platinum MasterCard customers
ring the activity, customers who activate their credit cards and brush Everbright Caesar joint platinum MasterCard for the first time can enjoy 16 days of free overseas WiFi rights
you need to send self recording videos overseas, so you don't have to worry about non flow money anymore! It should be noted that each customer can only enjoy the right once a month, and only the top 300 customers can enjoy the right once a month
Everbright Caesar travel white card gift
event time: before June 30, 2018
event object: Everbright Caesar joint platinum card MasterCard customer
as long as Everbright Caesar joint platinum card MasterCard customer, ring the event period, the first brush and single currency transaction over $500 or more, you can get the value of 500 yuan of Jingdong e card rights
at the end of the next month after card consumption, the equity password of JD e card will be sent to your mobile phone in the form of SMS, regardless of name, no loss reporting, no cash exchange, and need to be kept properly
here is an introction to the opening ceremony and the first brush ceremony of Everbright Kaiser travel white. Of course, there are a lot of exclusive activities and services, such as Jingdong Mall's card consumption of 300 minus 100, the one-way airport shuttle service of 2 times / year, etc
recently, China Everbright Bank and Caesar tourism released their first joint brand card "Everbright Bank Caesar tourism platinum joint brand credit card" in Beijing. It is reported that the card is the highest level tourism exclusive card launched by both sides and is expected to cover millions of middle-class people in China
the Everbright Bank Kaiser Travel Co branded card launched this time is a platinum grade credit card, which is divided into UnionPay card and MasterCard. The design elements are mainly Aurora, and the design concept comes from "the world shines for me" - boundless dream. As long as you dare to pursue and set out, the world will shine for you
in addition to the basic rights and interests of Everbright, UnionPay and MasterCard platinum cards, the co branded card can also enjoy more exclusive rights and interests. For example, if a new user activates free international WiFi for 16 days, he or she can get the first swipe gift (if he or she swipes the card for more than $500, he or she will get the benefit of Jingdong e-card of $500). He or she can also enjoy airport shuttle, airport VIP hall, air delay insurance, travel accident insurance, road rescue, etc
What's more attractive is that cardholders can enjoy 5 times of points by consuming the whole line of Caesar procts, and they can grab 300 yuan of Caesar travel limited exclusive travel voucher by 1 yuan; Designated overseas cooperative merchants can enjoy 88% discount for consumption by card and customized tourism procts; You can also enter the aurora card zone of Caesar's official website and app as a privilege to purchase the specified preferential routes covering 100 countries and regions around the world, and over 10000 kinds of wonderful tourism procts will be put into the aurora card zone
Liu Yuxiao, general manager of Credit Card Center of China Everbright Bank, said: "this cooperation has effectively integrated the high-quality resources of both sides, and will provide cardholders with better daily travel services and the most convenient payment experience. This is an important step taken by Everbright credit card and Kaiser tourism in improving the quality and efficiency of serving the real economy, supporting the development of Inclusive Finance, and boosting the expansion of domestic demand. ".
let's see what others say.