Data
Transfer
Protocol
Ergonomic network programming in any language.

Synopsis

The Data Transfer Protocol is designed to be a flexible, often asynchronous and event-based solution to all things involving low-level networking. I learned from experience that establishing higher-level socket interaction is a pain in just about any language, so I went about writing easy-to-use networking APIs for as many languages as I could.

Tailored to the language

The design of the protocol is made to fit the design of the language in which it is implemented. This means that the usage of the implementation will differ between languages, but the overall capabilities will not be hindered, and will reflect that of the language itself.

Language-specific features

The implementations themselves will not necessarily be compatible with one another. For example, you would encounter errors attempting to connect a client in the JavaScript implementation to a server in the Go implementation. This is because each individual language's implementation differs greatly, in order to support features that make the most sense in the language (e.g. language-specific serialization).

Batteries included

Batteries are included with DTP. Most implementations support dynamic or generic type parameters (depending on the language) for sending and receiving data, as well as data serialization and information security. In implementations that come with information security, each message sent over a network interface is encrypted with AES. Key exchanges are performed using RSA.

Implementation comparison

Below is a set of examples in different languages. Note that although the examples may appear very different from each other, they all do roughly the same thing.

Server

                
              

Server

                
              

Client

                
              

Client

                
              

Implementations

Additional details about specific implementations can be found below. Please note the following:

  • A status of "Complete" indicates that the implementation in question is functional, but may still have undiscovered issues or additional features planned.
  • The "Secure" column indicates whether an implementation comes with information security included.
Language Status Secure Repository
C Complete Yes cdtp
C++ Complete Yes cppdtp
C# Complete Yes CSDTP
Java Complete Yes JDTP
JavaScript/TypeScript Complete Yes dtp.js
Python Complete Yes dtppy
Go Complete Yes godtp
Rust Complete Yes rustdtp

For any and all inquiries regarding the Data Transfer Protocol, feel free to contact me at wkhallen@gmail.com.