Custom Filesystem with Merkle Tree Integrity

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Filesystems on computing devices are vulnerable to unauthorized changes, and existing solutions do not efficiently share filesystem contents while minimizing resource usage.

Innovation Solution

A custom filesystem that creates a single metadata file containing all filesystem metadata, storing actual files in a content-addressed store, and enables fs-verity to generate a Merkle tree, making the filesystem and its contents fully cryptographically sealed and immutable.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If traditional filesystem structures are used, then ease of operation and sharing are improved, but security against unauthorized changes deteriorates

Engineering Contradiction:
ImprovesecurityVSAvoidfilesystem structure
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The filesystem is segmented into two distinct components: a metadata file containing directory structure and file information, and a content-addressed store containing actual file data. This segmentation allows the metadata to be verified independently through cryptographic hashing while maintaining efficient content sharing through the content-addressed store.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

A cryptographic hash function acts as an intermediary between the filesystem metadata and the content-addressed store. The hash function generates Merkle tree hashes that verify metadata integrity without exposing the actual file contents, enabling security verification while maintaining operational simplicity.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Ease of operation

If filesystem contents are shared across multiple devices, then ease of operation is improved, but resource usage increases

Engineering Contradiction:
ImprovesharingVSAvoidresource usage
Core Design Contradiction:
Ease of operationVSQuantity of substance

Solution Approach 1:

The content-addressed store serves multiple functions simultaneously: it stores file contents, enables deduplication across shared files, and provides cryptographic verification through content hashing. This multi-functionality allows efficient sharing without duplicating resources.

Inventive Principle:
Principle #6Universality (Multi-functionality)

Solution Approach 2:

The system changes the parameter of content identification from traditional path-based addressing to hash-based addressing. This parameter change enables the same content to be referenced by its unique hash value across different devices and filesystems, automatically eliminating duplicates and reducing resource usage.

Inventive Principle:
Principle #35Parameter changes

3Reliability

If cryptographic verification is implemented, then security is improved, but processing time increases

Engineering Contradiction:
Improveintegrity verificationVSAvoidverification time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

Merkle tree hashes are pre-computed and stored in the metadata file during filesystem creation. This preliminary action allows verification to proceed by simply comparing pre-computed hashes against newly computed hashes, rather than performing full cryptographic verification of all file contents each time.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

Instead of verifying the actual file contents through cryptographic hashing during operation, the system uses copied hash values stored in the Merkle tree. This copying approach maintains security verification while minimizing processing time during filesystem operations.

Inventive Principle:
Principle #26Copying

Data Source

PatentUS12321479B2Using a custom filesystem to secure the contents of a filesystem
Publication Date: 2025.06.03 RED HAT LLC
  • US12321479B2 patent drawing
  • US12321479B2 patent drawing
  • US12321479B2 patent drawing

AI summary

A computing device executing a kernel-based operating system creates a content-addressed object store containing files of a filesystem. The computing device generates a metadata file that describes characteristics of the files of the filesystem that are in the content-addressed object store. The computing device, in a kernel of the operating system, generates a Merkle tree of the metadata file and a Merkle tree of the content-addressed object store. The Merkle trees contain hashes of blocks of the metadata file and hashes of blocks of the files in the content-addressed object store. The computing device, in the kernel, verifies that a digest corresponding to the metadata file matches an expected digest for the metadata file and that digests corresponding to the files in the content-addressed object store match expected digests for the files in the content-addressed object store. The computing device mounts the metadata file to a location in the filesystem.