bitcoin
Bitcoin (BTC) $63,497.00 2.23%
ethereum
Ethereum (ETH) $1,894.76 2.37%
tether
Tether (USDT) $0.998964 0.01%
bnb
BNB (BNB) $567.29 1.10%
usd-coin
USDC (USDC) $0.999863 0.00%
xrp
XRP (XRP) $1.06 3.52%
solana
Solana (SOL) $73.60 3.17%
tron
TRON (TRX) $0.324112 1.30%
figure-heloc
Figure Heloc (FIGR_HELOC) $1.02 2.31%
staked-ether
Lido Staked Ether (STETH) $2,265.05 3.46%

An inquiry was conducted to ascertain the presence of images within the Bitcoin blockchain, as discussions surrounding arbitrary data and content have become increasingly prominent. This investigation not only highlights a burgeoning niche art scene but also illustrates a broader movement against non-monetary transactions on the Bitcoin network. Observers on either side of the argument often liken the blockchain to a canvas marred with graffiti.

To evaluate these claims, the author undertook a rigorous investigation: Do images actually exist on the blockchain? Furthermore, what implications might this have for Bitcoin users seeking to operate their own full nodes and enhance their financial autonomy?

The methodology employed was straightforward. A new hard drive was procured for blockchain storage, and classic image recovery software was utilized to extract potential images from the data, specifically designed to recover raw image files.

The chosen software was PhotoRec, an open-source image recovery tool that has been operational for over 20 years. This utility is engineered to identify image files within raw data and is frequently utilized to recover lost wallet.dat files from the early days of Bitcoin, prior to the advent of the seed word format.

Syncing the Complete Bitcoin Node

For the purpose of storing the complete Bitcoin blockchain, a 4-terabyte hard drive was purchased at a cost of a few hundred dollars. Following the installation of the latest version of Bitcoin Core, the synchronization of the blockchain commenced. This process, which involves downloading and verifying the integrity of all transactions in Bitcoin history, required approximately 72 hours, during which the Bitcoin Core software operated autonomously in the background.

Utilizing a powerful gaming computer, the primary bottleneck affecting the synchronization time was determined to be the hard drive’s read and write speeds. Notably, the indexing of the unspent transaction output set (UTXO) proved to be a particularly slow aspect of the process. As users sync the blockchain, each unspent transaction value, or positive balance, is organized into the UTXO set, with values being removed upon spending and new addresses being incorporated as satoshis are transferred.

Estimates indicated that indexing the UTXO on the hard drive could extend the process to three weeks. Therefore, to expedite the synchronization, the implementation of RAM for indexing was suggested, followed by a transfer of the data back to the hard drive. Although the entire procedure took three days, had a solid-state drive (SSD) been utilized, the complete synchronization could have been achieved within approximately one day, as SSDs are significantly faster than traditional hard drives, albeit at a premium cost of about four times more.

Once the blockchain was fully downloaded and validated, the UTXO index was migrated from RAM back to the disk, and the Bitcoin software was launched; the blockchain was entirely synced, and the wallet was prepared for use. The subsequent step involved the recovery of images residing on the blockchain.

Image Recovery on the Blockchain Using PhotoRec

With the complete Bitcoin blockchain stored on the hard drive, Bitcoin Core was disabled, and PhotoRec 7.2 was executed on the drive. The standard PhotoRec process is designed to search for image formats including jpg, png, gif, tif, bmp, ico, psd, and raw. The imaging recovery operation lasted over 11 hours and ultimately resulted in… (drum roll)… no findings.

Despite analyzing over a terabyte of blockchain data and half a day of scanning, no meaningful images were discovered. The PhotoRec wiki provides a basic example of its functionality: “PhotoRec identifies a JPEG file when a block begins with: 0xff, 0xd8, 0xff, 0xe0, 0xff, 0xd8, 0xff, 0xe1, or 0xff, 0xd8, 0xff, 0xfe.” Essentially, the program examines the disk data for byte sequences indicative of image files.

Although the program exhibited instances of false positives, saving 8 ICOs and 4 identical PNG files that yielded no visible images, the conclusion remains that no substantive images were found.

Exploring the Absence of JPEGs: XOR Obfuscation Techniques

This outcome raises an intriguing question: how can it be that discussions about NFTs and the embedding of image data on the Bitcoin blockchain have proliferated, while no images are found? It appears that the risks associated with arbitrary data have been known and addressed within Bitcoin Core development circles for an extended period, dating back to as early as 2011. A technique known as XOR, a basic data obfuscation method, is utilized to scramble blockchain data when it is stored on hard drives.

The fundamental principle underlying computer communication involves binary representations of data (0s and 1s). In essence, XOR compares two bits and produces a result of 1 if they differ or 0 if they are identical. In the context of Bitcoin, XOR compares each bit of blockchain data against a randomly generated key established during the initial setup, resulting in data that holds no discernible meaning for alternative programs. However, when the Bitcoin software is executed, it possesses the necessary key to decrypt and utilize that data. Furthermore, XOR’s efficiency ensures that it does not significantly affect overall performance. An example can be seen in the transformation of the Bitcoin genesis block before and after XOR application.

Currently, XOR is implemented across both blockchain data and the UTXO set. Discussions regarding XOR began in 2014 when some anti-virus software misidentified blockchain data as potentially harmful code. This misclassification led to the quarantining of blocks, which in turn corrupted the blockchain data and rendered synchronization impossible. By late 2015, XOR was integrated within UTXO set data at rest, and by 2024, it was extended to encompass all blockchain data.

Consequently, the XOR process ensures that arbitrary data cannot be identified or extracted from the blockchain without intentional circumvention, a procedure unnecessary for typical monetary transactions involving Bitcoin. The Bitcoin Core software maintains a straightforward database delineating the location of each scrambled block, facilitating the retrieval and unscrambling of data efficiently. Syncing Bitcoin in an unscrambled manner requires a custom process akin to syncing from scratch, which essentially involves rewriting the entire terabyte of data in an alternative sequence. For users desiring the primary privacy and security benefits of running a Bitcoin node, there is little incentive to undertake such an operation. Thus, for the vast majority of copies of the Bitcoin blockchain data existing on the devices of Bitcoin users worldwide, there is effectively no identifiable arbitrary data or images. This revelation may be surprising; individuals are encouraged to conduct their own PhotoRec tests on their respective nodes.

Source link

Leave a Comment

I accept the Terms and Conditions and the Privacy Policy

bitcoin
Bitcoin (BTC) $63,497.00 2.23%
ethereum
Ethereum (ETH) $1,894.76 2.37%
tether
Tether (USDT) $0.998964 0.01%
bnb
BNB (BNB) $567.29 1.10%
usd-coin
USDC (USDC) $0.999863 0.00%
xrp
XRP (XRP) $1.06 3.52%
solana
Solana (SOL) $73.60 3.17%
tron
TRON (TRX) $0.324112 1.30%
figure-heloc
Figure Heloc (FIGR_HELOC) $1.02 2.31%
staked-ether
Lido Staked Ether (STETH) $2,265.05 3.46%