current position:Home>IPFs series - combination of IPFs and blockchain

IPFs series - combination of IPFs and blockchain

2022-02-03 05:29:52 Brick moving leader

IPFS It is a decentralized file storage protocol , Based on this protocol, a file storage network can be realized by decentralization .

Combined with blockchain

  • take IPFS Used as an object server

    • The chain can record IPFS Returned after storage on cid
  • Use chain for IPFS Access control

    • visit IPFS need CA Certificate issued

    • Chain maintenance CRL

  • Use chain for IPFS Video charges for

    • The account system and payment system are put on the chain

    • Put the video file ipfs On

  • Use chain for IPFS File transactions

    • The seller is ipfs On Upload A small sample of the document

    • Smart contract realizes document exchange

    • Add the name of the file when it is on the shelf , describe , Price , The seller's public key , Sample link

    • Add the buyer's public key after the buyer places an order , Deduct money to the exchange

    • The seller uses its own private key and the buyer's public key to authenticate the file ECDH + AES encryption , Upload to IPFS

    • The seller adds a file link to the contract , Close the deal , Collect money

    • Buyer from IPFS Download files on , Use your private key and the seller's public key to decrypt (ECDH + AES), Enjoying !

    • The process is basically as above , There may be a risk of cheating money , Rules can be added to make it more perfect

And EOS combination

 Insert picture description here

according to EOS Introduction to the white paper ,EOS There will be a built-in IPFS Standard file system .IPFS And EOS The combination of can realize many useful application scenarios , Here are the introduction .

1. Block data storage

EOS The volume of transactions is very large , and 0.5s Will produce a block of data . If all the data is recorded on the main chain , Then there will be a huge amount of data . adopt IPFS It can greatly reduce the data storage cost of the main chain itself .

2. Front end page storage

DApp When users access the front end, they need a static page Distribution Service , For example, auction an encrypted cat on Ethereum , Its front-end files are currently centralized . By putting these front-end programs or website front-end based on IPFS File storage on , Can achieve Web Decentralization and low cost of services . As you can imagine , Future in EOS There will be no need to buy ECs to develop applications on , You don't have to think about what kind of host you need 、 what CPU、 How much memory and hard disk , And what system to install 、 How to start Apache,DApp Developers only need to deploy the front-end code to IPFS, Deploy the smart contract of back-end business logic to EOS Just on the chain , And as long as the mortgage EOS Tokens, , All this is free .

3. Media content storage

If we want to EOS Make a similar YouTube Of DApp, Then we can put the account system and payment system in EOS On the chain , Put all front-end pages and video files into IPFS On . Through this architecture , The model of the whole payment system is very easy to implement , We can foresee this DApp The service should come soon .

4. File transactions

In the Internet age, all documents are transmitted in the form of reproduction , This actually reduces the value of the document itself , In addition, piracy is rampant . If we pass EOS Realize a file transaction DApp, Then all documents can be passed through IPFS Storage , And encrypt with a key , The property right transfer on the chain can be realized by modifying the key , In order to achieve the purpose of document transaction . Ultimately, blockchain will bring value to the Internet era .

Past highlights :
Blockchain Knowledge Series
Cryptography series
Consensus series
Public chain research series
Ethereum series
EOS series
Smart contract series
Token series

copyright notice
author[Brick moving leader],Please bring the original link to reprint, thank you.

Random recommended