Logo
Encryption

Encryption #

Configuration Entry #

Class name: org.apache.shardingsphere.encrypt.api.config.EncryptRuleConfiguration

Attributes:

NameDataTypeDescriptionDefault Value
tables (+)Collection<EncryptTableRuleConfiguration>Encrypt table rule configurations
encryptors (+)Map<String, ShardingSphereAlgorithmConfiguration>Encrypt algorithm name and configurations
queryWithCipherColumn (?)booleanWhether query with cipher column for data encrypt. User you can use plaintext to query if havetrue

Encrypt Table Rule Configuration #

Class name: org.apache.shardingsphere.encrypt.api.config.rule.EncryptTableRuleConfiguration

Attributes:

NameDataTypeDescription
nameStringTable name
columns (+)Collection<EncryptColumnRuleConfiguration>Encrypt column rule configurations
queryWithCipherColumn (?)booleanThe current table whether query with cipher column for data encrypt.

Encrypt Column Rule Configuration #

Class name: org.apache.shardingsphere.encrypt.api.config.rule.EncryptColumnRuleConfiguration

Attributes:

NameDataTypeDescription
logicColumnStringRequired field. Logic column name.
dataTypeStringLogical column type, optional (required if other encrypted column, auxiliary query column or plain text column types are configured)
cipherColumnStringRequired field. Cipher column name.
cipherDataTypeStringEncrypted column type, optional (required if logical column type is configured)
assistedQueryColumnStringAuxiliary query column name, optional
assistedQueryDataTypeStringAuxiliary query column type, optional (required if auxiliary query column and logical column types are configured)
plainColumnStringName in plain text, optional
plainDataTypeStringPlain text column type, optional (required if plain text column and logical column types are configured)
encryptorNameStringEncryption algorithm name, required

Encrypt Algorithm Configuration #

Class name: org.apache.shardingsphere.infra.config.algorithm.ShardingSphereAlgorithmConfiguration

Attributes:

NameDataTypeDescription
nameStringEncrypt algorithm name
typeStringEncrypt algorithm type
propertiesPropertiesEncrypt algorithm properties

Please refer to Built-in Encrypt Algorithm List for more details about type of algorithm.