Safe file sharing with OnionShare
Share and Share Alike
In order to make the file on my laptop public, I would need to forward traffic from my broadband router to the correct port (TCP port 9050) on my laptop and then fine tune my local firewall to allow inbound access. Instead, I'll use a local Tor Browser installation to simulate the user experience from outside my local network.
The main benefits of using Tor Browser are two-fold. First, the Internet provider that you use (and indeed anybody eavesdropping on the local network) will have DNS lookups hidden from them, along with the traffic you send and receive.
Second, any person or business running an online service will not see your Internet provider's IP Address and will instead just see a connection from the Tor network. That means you should be completely anonymous, unless you identify yourself to an online service by logging in.
Tor Browser also does an excellent job of circumventing eavesdropping technology and prevents what is known as fingerprinting. Having a standard browser configuration across all users means that your online ID is far less identifiable. You might be surprised what using other browsers will reveal about you: hardware architecture, browser version, configurations, and other details that could potentially be useful to an attacker.
Tor Browser also deletes all browsing history automatically. Cookies are dropped too after each session and deleted after the browser is closed or the New Identity functionality is requested.
Accessing the Link
See the box entitled "Tor Browser Launcher" for some notes on Tor Browser launcher. Once my configuration is up and running, I can use it to visit that lengthy .onion
URL I created for file-sharing. You'll need to enter the private key (Figure 6).
Tor Browser Launcher
The Tor Browser launcher is intended to make Tor Browser easier to install and use on Linux systems. I had mixed results with installing via the Tor Browser launcher. I couldn't find a friendly mirror to download the package (I could have gone to the Tor website but wanted to see if I could install it through an apt package).
Instead, I opted to install it as a Flatpak. If you don't have Flatpak installed on your system, you'll need to install it before you can try this approach. Once you're set up for Flatpak, install the Tor Browser launcher with:
$ flatpak install flathub com.github.micahflee.torbrowser-launcher -y
The process took about 10 minutes for me. Once the installation is complete, you can use the Super keyboard key to search for the installed Tor Browser package. You might see two purple Tor icons – just click the one that doesn't mention the launcher, and you should see a quick installation following a much more rapid download.
After you start Tor Browser, you should navigate to the menu on the far right side at the top, scroll down, and click Help. From there, click About Tor Browser, which should install any updates automatically.
This installation route for the Tor Browser used quite a lot of disk space, but Tor Browser is such an excellent addition to your online security that the space is well worth it.

After I enter the private key, I see that onions.txt
is waiting for download (Figure 7).

Success! I can now use OnionShare to fire up a local web server and share files with the highest levels of anonymity.
More, More, More
Hosting a website with OnionShare is similar to file sharing. As you can see in Figure 8, the first step is to add a file. Listing 1 shows a simple HTML file I created called index.html
.
Listing 1
Simple HTML File
<HTML> <BODY> <CENTER><H1>Secret Website</H1></CENTER> </BODY> </HTML>

Figure 9 shows some of the options available for hosting web pages in OnionShare. Advanced settings include the ability to schedule the website availability for specific times of the day.

Clicking the big, green Start sharing button brings you to the view you see in Figure 10, which, you will notice, is very similar to Figure 4.

The secret key is the same format as before, and when I visit the specified URL and paste the key into Tor Browser, I get the HTML page defined in Listing 1 (Figure 11).

OnionShare also provides an option for anonymous chat. Figure 12 shows the chat service running in my Tor Browser.

« Previous 1 2 3 Next »
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.

News
-
Linux Hits an Important Milestone
If you pay attention to the news in the Linux-sphere, you've probably heard that the open source operating system recently crashed through a ceiling no one thought possible.
-
Plasma Bigscreen Returns
A developer discovered that the Plasma Bigscreen feature had been sitting untouched, so he decided to do something about it.
-
CachyOS Now Lets Users Choose Their Shell
Imagine getting the opportunity to select which shell you want during the installation of your favorite Linux distribution. That's now a thing.
-
Wayland 1.24 Released with Fixes and New Features
Wayland continues to move forward, while X11 slowly vanishes into the shadows, and the latest release includes plenty of improvements.
-
Bugs Found in sudo
Two critical flaws allow users to gain access to root privileges.
-
Fedora Continues 32-Bit Support
In a move that should come as a relief to some portions of the Linux community, Fedora will continue supporting 32-bit architecture.
-
Linux Kernel 6.17 Drops bcachefs
After a clash over some late fixes and disagreements between bcachefs's lead developer and Linus Torvalds, bachefs is out.
-
ONLYOFFICE v9 Embraces AI
Like nearly all office suites on the market (except LibreOffice), ONLYOFFICE has decided to go the AI route.
-
Two Local Privilege Escalation Flaws Discovered in Linux
Qualys researchers have discovered two local privilege escalation vulnerabilities that allow hackers to gain root privileges on major Linux distributions.
-
New TUXEDO InfinityBook Pro Powered by AMD Ryzen AI 300
The TUXEDO InfinityBook Pro 14 Gen10 offers serious power that is ready for your business, development, or entertainment needs.