Towards Search on Encrypted Graph Data

Andreas Kasten, Ansgar Scherp, Frederik Armknecht, Matthias Krause

Abstract

As graph-based data increasingly migrates to cloud environments, maintaining privacy while preserving searchability remains a significant challenge. This paper introduces a two-layered encryption scheme for RDF triples that allows for direct SPARQL querying on encrypted data without server-side decryption. The approach utilizes a unique combining function to generate encryption and decryption keys based on triple patterns, enabling fine-grained access control and preventing structural information leakage. Experimental results using the Berlin SPARQL Benchmark (BSBM) indicate that the system scales linearly with dataset size, providing a viable path for secure, offline graph data management.

Introduction

The rise of the Semantic Web and the adoption of graph-based data formats like RDF have led to the proliferation of sensitive datasets in medical, financial, and social domains. Moving this data to untrusted cloud servers necessitates robust encryption. However, traditional encryption methods often require full decryption for searching, which compromises privacy. Existing searchable encryption techniques frequently suffer from high interactivity requirements, information leakage regarding graph topology, or a lack of fine-grained access control (e.g., restricting a user to specific predicates).

Methodology

The proposed system addresses these limitations through a two-layered encryption architecture:

  1. The Basic Layer: In SPARQL, a triple pattern consists of a Subject, Predicate, and Object, each of which can be either "bound" (a specific value) or "unbound" (a variable). This results in $2^3 = 8$ possible binding combinations. The system encrypts every triple in the database eight times—once for each possible query view.
  2. The Refinement Layer: This layer allows data owners to issue "Query Keys" that include "Restriction Patterns." For example, an owner can grant a key that only permits searches where the Predicate is a specific type, keeping the rest of the graph hidden.
Figure 1: Workflow for triple encryption, query key generation, and query execution.

The cryptographic core relies on a combining function using RSA-style modular exponentiation and SHA-256. Encryption keys ($k_t$) are derived from a "Basic Key" and the bound parts of a triple. Conversely, decryption keys are generated from a "Query Key" and the user's query pattern. Successful decryption occurs only if the query parameters match the underlying triple data; otherwise, the result is gibberish.

Table 1: Generation of encryption keys and ciphertexts for various triple binding patterns.

This mechanism also enables an "Early Exit" strategy for complex JOIN queries. By executing mandatory ASK patterns first, the system can terminate searches early if conditions are not met, significantly saving computational resources on large datasets.

Evaluation and Results

Performance was assessed using the Berlin SPARQL Benchmark (BSBM) on synthetic datasets ranging from 50,000 to 200,000 triples. Key findings include:

  • Linear Scalability: Both encryption and query times scale linearly with the number of triples. Doubling the dataset size results in a roughly proportional increase in processing time.
  • Encryption Overhead: Encrypting 50,000 triples took approximately 56 minutes. While significant, this is a one-time cost for the data owner.
  • Query Performance: Evaluating a single triple pattern on a dataset of 100,000 triples takes about 950ms.
  • Security: The system successfully prevents untrusted servers from learning graph topology or object frequencies, as no structural indices are leaked.

Conclusion

The system provides a secure, offline method for querying encrypted RDF data without compromising privacy or leaking graph structure. While storage overhead (due to the 8x encryption) and computational costs are higher than plaintext alternatives, the approach offers a significant advancement in fine-grained searchable encryption. Future work will focus on optimizing the combining function for "Big Data" scales and expanding support for the full SPARQL 1.1 specification.

Summary updated

BibTeX
@inproceedings{kasten2013towards,
  author = {Andreas Kasten and Ansgar Scherp and Frederik Armknecht and Matthias Krause},
  title = {{Towards Search on Encrypted Graph Data}},
  booktitle = {PrivOn@ISWC},
  year = {2013},
}
Figure