GBASE Financial Application Guide 7 | Data Security and High Availability

Published on 2024-06-21

To help financial institutions select the right distributed analytical database products and promote best practices for deploying such databases in the financial industry, GBASE, under the guidance of the Beijing Fintech Industry Alliance, has compiled the GBase 8a Financial Application Guide. This Guide provides an in-depth look at the entire deployment process of a distributed analytical database—from selection planning and development design standards to data security, high availability, and operations optimization—and shares representative deployment cases of GBase 8a MPP Cluster at national policy banks and large state-owned commercial banks.

GBASE will be releasing a series of articles to share and interpret the Guide content, hoping to provide financial users with practical insights for database selection and to empower the efficient implementation and high-quality development of technology‑driven finance. This article is the seventh in the series and introduces data security and high availability.

 

1. Data Security

Among all industries, the financial sector demands the highest level of data security. GBase 8a provides comprehensive security measures throughout the entire data lifecycle: from authentication of data sources during data ingestion, to encryption during data transmission and at rest, to encrypted connections and privilege checks when users access data, to in-database data masking, and finally to data delivery to users, fully protecting data security and privacy.

Overview of GBase 8a security features.

Figure 1 – Overview of GBase 8a Security Features

1. Data Masking

When user data contains sensitive words or information that should appear masked to unauthorized viewers, dynamic data masking can be employed.

Dynamic data masking does not actually alter the underlying stored data. It works by using masking functions to add masking attributes to the fields that require protection, set masks for sensitive information, and use privilege controls to determine whether to expose the original data to users making queries.

The supported masking functions are listed in Table 1.

Table 1 – Data Masking Functions

2. Transparent Data Encryption

By default, GBase 8a stores data on disk in non-encrypted form. For scenarios that require encrypted storage, the Transparent Data Encryption feature can be used to encrypt data before it is written to disk.

Transparent Data Encryption in GBase 8a operates at the instance level. A single key certificate is created for the entire instance, and data in all tables or columns tagged with encryption keywords is automatically encrypted and decrypted in the background. Supported encryption algorithms include AES and SM4.

Data encryption functionality and principles.

Figure 2 – Overview of Data Encryption

GBase 8a also provides built-in encryption and decryption functions for temporary, small-scale data encryption/decryption within business SQL:
AES_ENCRYPT(str,key_str), ENCRYPT(str[,salt]), MD5(str), SHA1(str), SHA(str), to_base64(str)

3. User and Privilege Management

The GBase 8a MPP Cluster privilege management system enforces security for all connections, queries, and other operations based on access control lists. It authenticates users connecting to a GBase 8a MPP Cluster instance and determines their privileges, ensuring that users can perform only permitted actions. When a user connects to the server, their identity is determined by both the originating host and the specified username. After a successful connection, when a command is issued, the privilege system decides whether to grant execution permission based on the user's identity and the type of command.

GBase 8a privileges fall into five categories: database object operations, data operations, execution of stored procedures and user-defined functions, data viewing, and database (including user) administration.

 

2. Cluster High Availability

Beyond securing data access and transmission, data security also includes data protection—using backups, remote disaster recovery, and other methods to safeguard data.

1. Data High Availability – Replica Configuration

During GBase 8a cluster installation, the number of replicas for user data storage can be configured—1, 2, or 3 replicas. More replicas mean higher data security but also greater disk space requirements.

2. Data High Availability – Backup and Recovery

The GBase 8a MPP Cluster backup and recovery tool (gcrcman) supports full and incremental backup and recovery at the cluster, database, and table levels.

Since user data in a GBase 8a cluster is already protected by 1 or 2 replicas for data integrity and business continuity, it is generally not advisable to use the backup tool to back up all user data locally (on cluster nodes). However, the gcrcman tool is recommended in the following scenarios:

• For certain critical tables in the GBase 8a cluster, it is recommended to back them up using gcrcman;

• Historical data in the GBase 8a cluster can be backed up to file systems such as HDFS or S3 using gcrcman.

3. Data High Availability – Connection High Availability

When applications connect to a GBase 8a cluster using GBase APIs or the gccli tool, they can specify multiple Gcluster node IPs to achieve connection high availability, avoiding single-point performance bottlenecks and single points of failure.

4. Cluster Active-Active (Same Data Center) – GBase 8a Virtual Cluster Mirroring

Cluster active-active is used to seamlessly switch services to another cluster when one cluster becomes unavailable due to a failure. Active-active within the same data center is implemented through virtual cluster mirroring technology, with the two clusters located close to each other, typically in the same server room or building.

Virtual cluster mirroring has the following features:

Flexible mirroring configuration: supports mirroring at the database and table levels;

Real-time data synchronization: changes to mirrored databases or tables are synchronized in real time on both sides. All tables under a mirrored database are automatically mirrored. All functions, stored procedures, and views under the database are also created synchronously on the target side;

5. Cluster Active-Active (Same City/Remote Disaster Recovery) – GBase 8a Inter-Cluster Synchronization Tool

Cluster active-active for remote disaster recovery is implemented using the inter-cluster synchronization tool (GVR), which is suitable for long-distance remote disaster recovery.

The inter-cluster synchronization tool enables full and incremental data synchronization between two physically identical clusters through binary synchronization of underlying data files. It allows the construction of a disaster recovery architecture between two physical clusters.

6. Two-site/Three-center Disaster Recovery

This architecture is typically used in scenarios where local real-time synchronization improves service capacity, while remote asynchronous synchronization ensures data security.

By combining virtual cluster mirroring technology and the GVR tool, two Virtual Clusters (VCs) in the primary data center mirror each other, enhancing both service capabilities and data security. The standby cluster VC at the remote data center further strengthens disaster recovery and data protection capabilities.