In our last community update, we, the Shift Team, announced our intention to release onto the testnet by the conclusion of Q3, a publicly accessible version of our flagship dApp, Phantom, capable of providing a blockchain-enabled, decentralized storage and hosting solution. In addition, we also promised to prepare a glimpse of what is to come, by granting to all interested parties the opportunity to experiment with the technology we are developing. In keeping with that promise, thanks to the efforts of community member/delegate Mx, we are happy to be able to present a video tutorial that covers all you’ll need to know in order to upload data and host web content on the Shift storage cluster.
This is an incredibly important moment, as it represents our first open-invitation for the public to take part in the testing phase of Phantom, the provision of which is our primary goal in the cryptocurrency space. While the integration of blockchain governance remains an ongoing process, this video demonstrates how, in the space of just a few minutes, compatible website resources* may be uploaded and published, as well as a domain name pointed to their IPNS hash for online distribution. This means you too, can upload one of the world’s first decentralized websites accessible with real, top-level domains, and available to users on regular browsers, without plugins.
Though it must be noted that the Shift Team’s testing protocol, due to our policy of only gradually rolling out cluster storage capacity, does not currently guarantee the retention of data uploaded to the servers permanently, the release of this video nevertheless provides an excellent opportunity to become familiar with the principles underpinning our IPFS/IPNS infrastructure. In order to support users of our testnet services, especially those who encounter Shift for the first time through this video, we would therefore like to provide a synopsis of the components that empower Phantom to carry out such complex functions, in an outwardly simple manner.
The Mechanics of Phantom
The Shift wallet is the user’s window into the blockchain and allows for the creation of a private Shift testnet account through the generation of a secure passphrase. Currently, Phantom is only accessible using our testnet web wallet, with the Nano desktop wallet to be supported in subsequent versions. The testnet wallet, while offering additional functionalities, is, in the context of the video, used only as a means of account creation and for the purpose of opening the Phantom dApp. Though the dApp will offer token utilities in the future, Shift will be launching these onto the testnet mainchain by the completion of Q3, enabling the full integration of the IPFS storage cluster with our decentralized governance empowered blockchain technology. You can learn more about these token utilities in our previous news post: https://www.shiftproject.com/news/news-item/8.
Opened from within the testnet wallet, the Phantom dApp is more than just Shift’s custom-built IPFS file manager, it is the technology that unites many of Shift’s innovations within a single package. Presently, Phantom’s UI consists of three tabs, though only two are relevant to this video. The functionalities of Phantom and these two tabs are discussed below:
- With the IPFS File Manager, Shift has built a UI where users can easily store and access their files and website/web resources held on the project’s peer-to-peer storage cluster. In order to remove barriers to adoption that have, thus far, impeded the transition to the Web 3.0, this is intended to be an extremely user-friendly process. A drag and drop interface and easily comprehensible, hierarchical file structure combine to make working with Phantom an incredibly intuitive experience.The Phantom File Manager contains an IPFS Indicator. Found in the top-left of the user interface, the IPFS Indicator icon displays whether the wallet is correctly connected to the storage cluster. If the indicator shows green, it means you’re currently connected and good to go. When green, it will also show the number of connected peers in the cluster.The cluster itself is a swarm of storage nodes that dynamically replicates data across the network in order to provide a plurality of available sources at the point at which data is requested (thus granting robust and censorship-resistant hosting properties). At a later stage, the Shift Project intends to facilitate the ability of anyone to join this network and, using their own server(s), provide storage to the cluster for which they will be compensated in Shift tokens.
Using the pin function informs the cluster’s nodes that data must not be removed by their automated garbage collectors, ensuring that it remains accessible as long as the user desires. By default, pinned data has a replication factor of three, being maintained across three different locations on the network. Unlike HTTP, that is unable to automatically detect when a connection between a user and content located on a server has been severed, IPFS identifies when communication is interrupted and uses a content-based hash to make sure another peer re-establishes the connection necessary to serve the pinned data.
The file manager also has a publish function that generates the mutable IPNS hash that is able to point to data stored on multiple nodes. While content served by an IPNS hash is uncensorable, hashes are not particularly user-friendly. To establish a smooth transition between the old web (HTTP/DNS) and the new (IPFS/IPNS), Phantom combines the best of both worlds within its very own DNS wizard: real top-level domains (pretty URLs) and a content-based, peer-to-peer infrastructure.
- Phantom’s DNS wizard creates the information necessary to ensure that a domain can be linked to an IPNS hash, allowing it to point simultaneously to all the nodes that a Shift user tasks with storing/serving their data or web content. You may ask yourself, why would Shift combine DNS with IPFS/IPNS? It seems illogical to obscure the benefits of an IPFS network’s peer-to-peer infrastructure and hash-based nature behind a cloak of DNS compatibility. However, one of the obstacles in the way of IPFS adoption is that it represents a fundamental change in the structure of the Web.Shift’s goal is to increase the rate of adoption of IPFS technology (and thus its potential for success) while development continues on a decentralized variant of the Domain Name System that includes the ability to point IPNS hashes to pretty URLs without the possibility of domain blocking. For this purpose, we’ve built Jenga, Shift’s very own, custom-built DNS monitor.Jenga is responsible for actively inspecting nodes in the cluster to ensure that they are correctly storing pinned content. This is an ongoing process in which an internal list of healthy nodes that are ready to serve content is maintained, with the DNS nodes kept constantly and automatically updated with this vital information. This makes your uploaded content resistant against DDoS attacks without sacrificing your pre-existing URL.
The problem with DNS is that it does not know when a peer is offline and unable to serve content. So, usually, when the single connection to the serving peer is lost, your access to the content will not be automatically re-established (you’ll instead receive a ‘404 page not found’ page). With an IPNS hash, if a single peer is unable to serve content, IPFS is able to ensure that another peer will serve it instead. This is possible because IPFS knows when content is down and a node cannot be reached, and uses the mutable IPNS hash to point to other peers in the cluster that host it. Thus, Jenga allows Phantom to bridge the old web (HTTP/DNS) with the new (IPFS/IPNS), by facilitating: real top-level domains, regular browsers without any third-party plugins and a content-based, peer-to-peer infrastructure.
Within the video, Mx uses this information to create the DNS records required to link his IPNS hash (and, by extension, his website) to his personal domain name. This friendly URL, while sacrificing a degree of censorship resistance by associating his site with a DNS that could feasibly be centrally blocked, does not miss out on the raft of other benefits provided by hosting content on the Shift ecosystem, such as the ability to thwart DDoS attacks and a fallback system always in place to prevent the negative repercussions of server downtime.
We hope that our community is as excited as we are to be entering this new phase in Shift’s development. We truly believe that transparency and decentralization, in blockchain and in the projects that employ it, contributes to the realization of better technology. We would, therefore, like to request your feedback on your experiences experimenting with Phantom, so that together we can build a better, more user-friendly dApp, ready for mass-adoption. Participate in the conversation by joining us in our project’s Ryver group.
The Shift Team
*IPFS does not natively offer a solution for the hosting of dynamic website content. Shift has solved this problem by creating a decentralized and IPFS-compatible content management system (CMS), named Hydra, that uses JSON files to pull and push such data.