Hack #3: Mining Cryptocurrency (namely Monero Coin) Using Tails OS
Even with the bottleneck created by using the Tor network, I have found that Tails OS can mine various cryptocurrencies faster than other Linux distributions. This is probably because cryptocurrency mining does not require high Internet bandwidth; even slow Internet connections will do. The main constraint of mining cryptocurrency on Tails OS is the processing power of the computer. The smaller the operating system, the fewer resources the operating system uses, allowing more power to be devoted to actually hashing a mining algorithm.
Most cryptocurrencies can no longer be mined efficiently on computers. This is because the hashing rates required to competitively solve the hash algorithm are too high to compete with dedicated mining machines (called application-specific integrated circuits, or ASICs). To understand this requires a detailed discussion of how proof-of-work cryptocurrency algorithms operate, but the simplest explanation is that cryptocurrency networks (like Bitcoin) keep track of all transactions on a ledger. Unlike a bank ledger, which is kept in one place (the bank server), the Bitcoin ledger is copied to all nodes on the Bitcoin network. The ledger details what amount of Bitcoin is owned by which Bitcoin addresses. When Bitcoin is transferred from address to address in a transaction, the ledger is updated. Consensus is achieved because the ledger is stored on a blockchain based on a hash algorithm. A hash algorithm is a mathematical formula developed by cryptologists that takes an arbitrarily long input and transforms that input into a unique output of a fixed length (called a hash). Mining for Bitcoin requires verifying transactions as genuine by brute-force guessing inputs that will generate a "valid" output needed to add a transaction to the blockchain. Here, "valid" means that the output value satisfies the requirements set and adjusted automatically by the Bitcoin network. The Bitcoin network can make finding a valid output more or less difficult based on how many people are competing to find a valid value. As the computing resources available to the Bitcoin network steadily increase, the difficulty also increases, and thus the computing power required to find a valid value goes up in turn. The reward for finding a valid value is, of course, a Bitcoin payout from the network. The reward decreases over time.
<SIDE NOTE> Intuitively, one might worry that because an infinitely long input into the algorithm always results in the same length (finite) output, there must be multiple inputs that generate the same output. This is true and referred to as a "collision." However, in practice, the likelihood of finding a collision is vanishingly small. The number of possible outputs from the Bitcoin algorithm (SHA-256) is 2^256. How big is that number? The number of atoms in the observable universe is estimated to be between 10^78 and 10^82, which is several orders of magnitude smaller than 2^256. So while there are an infinite number of inputs and a finite number of outputs, the finiteness of the outputs is still far too large to deliberately create collisions. If you were able to deliberately produce collisions in the SHA-256 hashing algorithm, you would likely win the Turing Award as it would represent a monumental cryptographic breakthrough. </END SIDE NOTE>
There is an important exception to the oft-stated "rule" that you can no longer mine cryptocurrency on a computer. That exception is Monero Coin. Monero Coin can be mined on a computer because the hash algorithm, RandomX, is (1) optimized for computations that work better on computer CPUs, (2) relies heavily on RAM, which dedicated mining machines do not have in large supply, and (3) changes its internal computations constantly to evade ASIC manufacturers' attempts to create optimized hardware. Because Monero Coin can be mined fairly efficiently (provided your computer is relatively powerful), I decided to compare Tails OS to a standard Debian distribution for mining Monero Coin.
In my experience, Tails OS is slightly (2-3%) more efficient than a standard Debian distribution for mining Monero Coin. Coupled with the ease and speed with which Tails OS can be installed on a USB thumb drive, Tails OS can perhaps be justifiably used for Monero Coin mining operations. However, I suspect (but have not tested) that other lightweight Linux distributions might do just as well as Tails OS without consuming the precious resources of the Tor network.
Here is how I have mined Monero relatively efficiently in Tails OS using fairly powerful computers:
(1) Boot the computer into Tails OS and enable persistent storage and an administrative password. Connect to the Internet and configure a Tor connection like normal.
(2) Open the "Root Terminal" app (located in the "System Tools" tab of the Applications menu) and type and enter the following command:
(If you cannot view the text of the command below, you can download a PDF version of this guide here. The password to open the PDF file is "aboutwes.com").