Sending Network: Reconstructing TCP/IP for Web3 Communication Infrastructure

IntermediateApr 23, 2024
This article showcases Sending Labs' development of a decentralized communication protocol stack designed to overhaul the traditional TCP/IP model, tackling its centralization flaws prevalent in the Web2 era. The revamped protocol allows for peer-to-peer communication via wallet addresses, boosting security, privacy, and giving users increased control. It promises an unlimited provision of IP addresses, cuts out the need for centralized CAs, and integrates essential protocols such as DNS into the blockchain. The protocol also promotes setting up personal routers to foster a decentralized physical infrastructure and imbues network communication devices with financial characteristics that tie directly to blockchain accounts. Detailed strategies for decentralizing the network, transport, application, and physical layers are explored.
Sending Network: Reconstructing TCP/IP for Web3 Communication Infrastructure

Sending Labs is at the forefront of crafting a decentralized communication protocol stack that directly confronts the inherent centralization issues of TCP/IP. This initiative supports wallet-based peer-to-peer communication, fundamentally transforming internet infrastructure to significantly elevate security, privacy, and user empowerment.

Overview of Web2’s TCP/IP Protocol Stack

In the Web2 era, communication, computing and storage together form the cornerstone of the Internet. Among them, the TCP/IP protocol stack is the most basic and broad form of network communication. It runs through all levels and provides a unified communication framework and standard for all levels from the physical layer to the application layer. Almost all Web2 applications rely directly or indirectly on this system. Therefore, the TCP/IP protocol stack has become the standardized basis for Internet communication.

Problems with TCP/IP Protocol in the Web2 Era

With the evolution of Internet technology, the TCP/IP protocol stack has begun to reveal some structural problems. These flaws lurk in our daily web usage. The impact of these issues can be concretely demonstrated using the example of two users communicating via a chat app. Suppose user A sends a message to user B. The message is first split into several data packets and then transmitted to user B through multiple servers on the Internet.

  • At the application layer, when users access the application website, they need to rely on DNS to resolve the service address. If the DNS is contaminated or attacked, users may mistakenly access a malicious server, resulting in privacy leaks or data tampering.
  • At the transport layer, if the Certificate Authority (CA) that the SSL/TLS protocol relies on is attacked or loses its trust, communications between users may be eavesdropped or tampered with by a third party. For example, if a user’s messages are transmitted through an unsecured channel, hackers may intercept these packets or even forge bad information. At the same time, reliance on these centralized CAs brings trust risks.
  • At the network layer, because the IP addresses of application services are controlled and allocated by a few organizations, the limited nature of IP addresses and the problem of centralized allocation lead to resource control rights being mostly concentrated in the hands of a few countries and organizations, which not only results in unfair distribution , also makes the entire network architecture vulnerable to the threat of centralized control.

The inherent centralization of TCP/IP leads to deep-seated issues that cannot be resolved with simple fixes. A radical technological overhaul is necessary to achieve complete decentralization of the protocol stack, which is crucial for addressing these fundamental problems. Sending Labs is at the forefront of this transformation, working on a decentralized communication protocol stack. This new model will reinvent TCP/IP by enabling direct peer-to-peer communication through wallet addresses, revolutionizing internet infrastructure and greatly improving security, privacy, privacy and enhancing user control.

Building a New Communication Standard in the Web3 Era: Rebuilding the TCP/IP Protocol Stack

In the Web3 era, we need to reconstruct the TCP/IP protocol stack to solve the problems in the current system. The Web3 version of the TCP/IP protocol stack will have the following characteristics: First, it ensures an unlimited supply of IP addresses and avoids the monopoly of resources by a few countries or organizations; second, it transfers the trust authentication of the transport layer to a decentralized mechanism based on the blockchain. No longer rely on a single CA certification agency; thirdly, transfer key protocols such as DNS to the blockchain to get rid of dependence on traditional DNS service providers; in addition, encourage the public to set up their own routers to build decentralized physical layer infrastructure; Finally, the network communication terminal is given financial attributes so that it is directly related to the blockchain account system and naturally supports financial functions.

With the help of this new protocol stack, the way of surfing the Internet will be greatly changed in the future: users open a browser, enter the ENS domain name, and the browser parses the corresponding address through the blockchain and initiates a connection request. Before the connection is established, the system uses the terminal’s digital signature and blockchain-based DID system authentication to confirm the identities of both communicating parties before establishing the connection. During this process, all data is processed through a huge physical routing system to ensure that the data is transmitted from one end to the other. When it comes to payment, because the communication terminal has financial attributes, users can pay directly to the corresponding wallet address of ENS, avoiding the risk of phishing fraud and ensuring safe and reliable payment. Whether it is social networking, e-commerce or other applications, they will inherit the security and decentralization features of the network layer and transport layer.

Next, we will introduce in detail how to implement these decentralized features at the network layer, transport layer, application layer and physical layer.

Network Layer

The design of the network layer needs to meet four core requirements: first, IP addresses must be sufficient to ensure that the area code of the address is distributed fairly globally; second, the IP address must have financial attributes and can be directly associated with the blockchain account; third, in Before completely transitioning to the Web3 network, maintain compatibility with IPv4/IPv6; fourth, ensure the decentralization of domain name resolution. For this reason, we have two main address types: unicast addresses and anycast addresses including:

  • Unicast address: It is unique and deterministic. It is composed of several IDs such as network segment ID, subnet ID, host ID, and network card ID. It can uniquely determine a network card device in the network. Perform fast routing based on the ID prefixes of network segments and subnets to reduce the complexity of the routing table.
  • Anycast address: Corresponding to the wallet address, multiple unicast addresses can be bound to achieve efficient data transmission. This design not only optimizes the routing efficiency of the network, but also greatly improves the supply capacity of IP addresses. When the sender initiates a connection request to an anycast address, the router sends the packet to the nearest unicast address bound to the anycast address based on the routing distance. Because the services provided by all unicast addresses bound to the anycast address are the same, the sender can satisfy its communication needs by communicating with any unicast address.

Unicast addresses achieve fast routing through address prefixes, and their length can be designed to exceed 160-bit wallet addresses, which can theoretically be supplied unlimitedly. Anycast address is equivalent to a wallet address, which gives financial attributes to the IP address.

So how to implement unicast address allocation in a decentralized manner? In the Web2 era, IP addresses are assigned by central authorities. In Web3, these addresses are allocated through smart contracts. The smart contract generates various network segment ID License NFTs based on the network size and authorizes operators to manage specific subnets. Operators holding network segment IDs can subdivide subnets and sell them to lower-level operators or end users. Operators operate router nodes to process data traffic, achieve profitability, and ensure fair and decentralized distribution of IP addresses.

Domain name resolution - DNS protocol, although it is defined at the application layer in Web3, logically it is more like a protocol for naming network transmission terminals at the network layer. We regard it here as a network layer protocol, which can be Reused by other application layer protocols. DNS should be an on-chain resolution protocol in Web3, and the implementation should be something like ENS. The on-chain contract defines the corresponding relationship between the domain name and the wallet-address, thereby realizing the dependence on the DNS domain name organization and eliminating the dependence on the center, thereby avoiding the DNS pollution problem.

In order to ensure that the network can operate normally and solve the cold start problem before it is fully scaled, we need to make the network compatible with existing IPv4/IPv6. When a router cannot find the destination address in its directly connected network, it will encapsulate the data into IPv4/IPv6 packets and send them to routers on other subnets. The receiving router parses these packets and continues routing within the subnet until the destination address is found. This process is similar to the early stages of IPv6 achieving compatibility through tunnels in the IPv4 network.

In addition, the router is also responsible for intranet penetration. When data needs to enter the intranet through the IPv4 gateway, the public network routing device will forward these connections. These devices act as reverse proxies for the intranet, allowing data to safely enter the intranet address through the tunnel.

In order to realize these network layer transformations, corresponding improvements must be made at the physical layer and transport layer. The physical layer requires sufficient router equipment, and at the same time encourages end users, fiber service providers or current ISP operators to purchase these equipment to form a network effect and gradually replace the existing IP network. At the transport layer, we need further improvements to verify the binding of anycast and unicast addresses and ensure the security and unforgeability of communications.

Transport Layer

While ensuring safe data transmission, the transport layer removes trust in the CA and eliminates the need to rely on any centralized organization for the security certification process.

Typically, ensuring the security of Internet connections (such as websites using HTTPS) relies on SSL/TLS protocols, which rely on CA authorities to verify the authenticity of the websites visited. We hope to adopt on-chain-based DID documents to maintain security while eliminating dependence on centralized entities.

This mutual authentication process is performed by accessing the DID document on the chain. Since the anycast addresses of both parties are already registered on the blockchain and linked to their wallet addresses, the DNS services required by traditional CAs are no longer needed. Once the DID document and wallet address are found and associated, and the corresponding party provides a valid signature, you can confirm that the entity you are communicating with is the legal owner of the identifier.

In this way, a wallet-to-wallet connection is established, allowing convenient data transmission through sockets. Similar to how SSL/TLS operates in a specific socket environment, this system provides a new option for these connections.

Socket Example

We have proposed some ways to reconstruct the network layer and transport layer, the following socket code is an example. Each level addresses its specific challenges. On this basis, because the wallet address has financial functions - a function that ordinary IP addresses do not have - we can use the socket code to establish a connection and then send transaction instructions through it.

Therefore, this new TCP/IP technology stack integrates the features of SSL/TLS, IP routing and financial transactions. Below is a short sample code.

Application Layer

There are many application layer protocols in the TCP/IP protocol stack. Common ones include HTTP(S), XMPP, SMTP, POP3, FTP, SIP, RTMP, CDN, etc. These protocols have traditionally relied on centralized servers, such as XMPP for instant messaging servers and SMTP for mail servers. However, in the Web3 era, decentralized network nodes will replace traditional central servers, and application layer protocols no longer care about the application server. In addition to defining the data packet format on the transport layer/network layer, these protocols are based on the decentralized network infrastructure of the network layer, allowing the network layer to provide a solid decentralized network for various applications. Base.

Among all application layer protocols, HTTPS, XMPP, SMTP, etc. are the most common, and they form the basis of our daily social activities. Under the architecture of Web3, we developed the first application example - a decentralized instant messaging social application protocol using a protocol similar to XMPP. In this protocol, users use their wallet addresses as social accounts to conduct end-to-end encrypted chats, establish private or public chat groups, send voice and video messages, and even make audio and video calls. These reuse the secure communication capabilities of the transport layer and the extensive node network of the network layer, using the wallet address as a new network identity.

In addition to the XMPP-like instant messaging protocols we provide, the application layer also has a large number of application scenarios, such as:

  • Web applications based on HTTP and HTTPS: Developers can simply deploy their website in a network based on wallet address/ENS domain name, enjoy high-speed access brought by bandwidth sharing provided by the network, while ensuring application censorship resistance and secure access. .
  • Mail applications such as SMTP/POP3: Relying on this network, decentralized mail systems will become easy. When you need to send an email to an ENS domain name owner, your application only needs to find the node corresponding to the ENS address through network layer addressing, upload the email, and the recipient can download the email from the node.
  • Application of CDN resource distribution protocol: Relying on this network, developers can distribute their data to nodes in major router devices or data centers. The huge node network built based on the incentive mechanism will allow nodes to be spread almost all over the world, in-depth In every home, the vast node network allows the CDN protocol to efficiently utilize idle bandwidth resources, allowing developers and users to enjoy a higher-speed application experience.
  • Application of streaming media protocols such as SIP/RTMP/WebRTC: Relying on extensive node resource and idle bandwidth sharing, streaming media applications can realize distributed storage and caching of streaming media content to accelerate access and improve the access speed and fluency of streaming media.
  • Application of file transfer and access protocols such as FTP: Through a huge node network, combined with the web3 decentralized storage project, the network can actively cache the content resources of projects such as IPFS/Arweave, accelerate frequently accessed content, and improve the activity and application of the project scope.
  • Application of VPN protocols such as OpenVPN: VPN applications can rationally utilize the IP resources shared by routing devices, greatly expand the IP resource range of applications, and provide the most basic IP and bandwidth resources for VPN.
  • Message queue protocols such as Kafka and RabitMQ: Message queues are application layer protocols widely used in distributed and cluster applications. A large number of applications require them to implement communication between application modules or processes. In the web3 era, these applications can rely on an extensive node network and use these nodes as natural message queue carriers to provide shared, high-speed message queue services for a wide range of applications.

Physical Layer

The core idea of ​​the physical layer is to promote decentralized routers through incentives so that they can be widely adopted by households and ultimately generate network effects. These routers enable users to utilize unused home bandwidth to increase overall network capacity. By integrating with our network layer protocols, these devices enhance data caching and acceleration capabilities to benefit decentralized applications within the ecosystem. These devices optimize bandwidth usage and allow users to earn revenue from their bandwidth contributions.

In the initial stage, we can establish a transmission link directly to the communication terminal through an IPv4 tunnel based on IPv4 architecture. As nodes become more popular, we will further attract more optical fiber service providers to join through incentives to achieve complete interconnection of our hardware network at the physical layer.

Conclusion

The impact of rebuilding the TCP/IP protocol stack will go far beyond technical changes. By integrating wallet address-based routing, domain name resolution, and authentication directly into the Internet’s core protocols, we are actively building the foundation of a decentralized web. Taking decentralized instant messaging communication as our initial application layer protocol, a decentralized ecosystem integrating messaging, financial transactions and digital asset management will be formed in the future. This shift is expected to significantly improve online privacy, security and freedom, marking a key step towards achieving an open internet.

As previously mentioned, SendingNetwork has launched a decentralized messaging protocol as the first application layer protocol in our decentralized protocol stack. Users can use their wallet address to send end-to-end encrypted messages, participate in private or public chats, and make voice and video calls. The network is composed of the following three roles:

  • Edge node: Responsible for forwarding, relaying messages and submitting proof of work.
  • WatchDog node: Send random challenge messages to the Edge node to detect its running status.
  • Guardian node: Verify the proof of work of the Edge node and evaluate its service quality such as stability based on WatchDog’s challenge results.

The network uses Proof of Relay as the proof of work for message relay, and uses Proof of Availability to evaluate node service quality. Currently, we have opened the first phase of the test network, in which Edge nodes can earn points through message forwarding. Next, we will gradually add WatchDog and Guardian roles to the network to ensure that the network can operate stably in a decentralized environment.

We invite developers and users to join this messaging network and help Web3 users interconnect between different applications through this cross-platform protocol. At the same time, we also invite more like-minded friends to join us to witness the transformation of TCP/IP, truly realize the interconnection of the Web3 ecosystem, create a more secure, private and decentralized online world, and reshape the digital future Communications infrastructure.

Disclaimer:

  1. This article is reprinted from [Chaincatcher], All copyrights belong to the original author [行业速递]. If there are objections to this reprint, please contact the Gate Learn team, and they will handle it promptly.
  2. Liability Disclaimer: The views and opinions expressed in this article are solely those of the author and do not constitute any investment advice.
  3. Translations of the article into other languages are done by the Gate Learn team. Unless mentioned, copying, distributing, or plagiarizing the translated articles is prohibited.
Start Now
Sign up and get a
$100
Voucher!
Create Account