Inspiration
AirTransit explores a small command-line interaction for sharing a file between computers: send a file, pass along a short code, and receive it elsewhere. An external storage service removes the need for a direct connection between the two devices.
The project is also a useful example of why a simple user interface should have an equally clear explanation of where the file goes. An HTTPS upload and a short code do not, by themselves, create private or anonymous file transfer.
What it does
The Python CLI offers send and receive commands. Sending checks that the source is a file and enforces a local size limit of 200 MiB. It uploads the file to Catbox over HTTPS, displays the returned download URL and derives a short code from that URL’s final path component.
Receiving a short code constructs a Catbox download URL and writes the returned bytes to a local file. If that destination already exists, the CLI asks before overwriting it. The current implementation also accepts complete HTTP or HTTPS download URLs.
After an upload, the CLI also attempts to request a terminal QR rendering from a separate service. This sends the download URL to that QR service. The QR output is a convenience feature, not an additional access-control mechanism.
How it is built
The core is one Python script using the standard library. The upload path builds a multipart request with the file bytes and sends it with urllib. The download path reads the response and writes it to disk. No separate Python package installation is needed for that script’s imports.
Both paths currently hold the file in memory. The upload path also constructs a multipart payload containing those bytes. This is understandable for a small prototype, but it is not a streaming design and the upload size check is not a general memory-safety guarantee.
After obtaining the script from the public repository, its direct entry point is:
python3 transfer.py
This displays the available commands without uploading a file. A real send operation transfers the selected file to the external host. Only files suitable for that sharing model should be used.
Challenges and limitations
The external file host is part of the trust boundary. The reviewed code does not implement recipient authentication, client-side encryption or a deletion guarantee. It also cannot promise that the host will be reachable on every network. Network policies and service availability remain outside the CLI’s control.
The short code is a convenient reference to a download URL, not proof of a recipient’s identity. Because the QR rendering uses another service, the link is also disclosed beyond the storage provider. A fuller product would need to make that behavior visible before upload.
Implemented accomplishments
The public source contains complete send and receive paths, a missing-file check, the upload size check, a destination-overwrite prompt and terminal output for the returned link. A local check with mocked HTTP responses exercised multipart upload construction and short-code download without sending files to an external service. That check does not establish live host availability or end-to-end privacy.
Engineering lessons
A product’s transfer model matters more than whether its interface feels direct. Here, the devices exchange a reference to a hosted file. Describing that architecture plainly makes the tool easier to assess and helps avoid security claims its code does not support.
Failure handling also needs more detail as the tool grows. An unreachable host, a malformed response, an invalid destination and a user cancelling an overwrite are different outcomes. They should remain distinguishable in a dependable CLI.
What is next
Proposed improvements include local QR generation, HTTPS-only URL validation, streaming transfers, explicit timeouts and exit codes, and clearer storage and retention information. Client-side encryption with a separately shared key would require a specific design and must not be implied by the current version.
Built with and source
Python 3, urllib, HTTPS, multipart form data and the Catbox upload API.
This description was prepared with AI assistance from the linked source code. It describes a prototype and its implementation boundaries.
Built With
- catbox
- command-line
- https
- python
- urllib
Log in or sign up for Devpost to join the conversation.