Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

feat: Add masking reason display with semantic type icons in SQL query results (#16794)

rebelicee57b9f7e31ba
diff --git a/backend/api/v1/audit.go b/backend/api/v1/audit.go
index 8bbca5fce0..72011fa85f 100644
--- a/backend/api/v1/audit.go
+++ b/backend/api/v1/audit.go
@@ -462,12 +462,11 @@ func redactAdminExecuteResponse(r *v1pb.AdminExecuteResponse) *v1pb.AdminExecute
ColumnNames: result.ColumnNames,
ColumnTypeNames: result.ColumnTypeNames,
Rows: nil, // Redacted
- Masked: result.Masked,
- Sensitive: result.Sensitive,
Error: result.Error,
Latency: result.Latency,
Statement: result.Statement,
DetailedError: result.DetailedError,
+ Masked: redactMaskingReasons(result.Masked), // Redact icon data
})
}
@@ -487,18 +486,40 @@ func redactQueryResponse(r *v1pb.QueryResponse) *v1pb.QueryResponse {
ColumnTypeNames: result.ColumnTypeNames,
Rows: nil, // Redacted
RowsCount: result.RowsCount,
- Masked: result.Masked,
- Sensitive: result.Sensitive,
Error: result.Error,
Latency: result.Latency,
Statement: result.Statement,
DetailedError: result.DetailedError,
AllowExport: result.AllowExport,
+ Masked: redactMaskingReasons(result.Masked), // Redact icon data
})
}
return n
}
+func redactMaskingReasons(reasons []*v1pb.MaskingReason) []*v1pb.MaskingReason {
+ if reasons == nil {
+ return nil
+ }
+ var redacted []*v1pb.MaskingReason
+ for _, reason := range reasons {
+ if reason == nil {
+ redacted = append(redacted, nil)
+ continue
+ }
+ redacted = append(redacted, &v1pb.MaskingReason{
+ SemanticTypeId: reason.SemanticTypeId,
+ SemanticTypeTitle: reason.SemanticTypeTitle,
+ MaskingRuleId: reason.MaskingRuleId,
+ Algorithm: reason.Algorithm,
+ Context: reason.Context,
+ ClassificationLevel: reason.ClassificationLevel,
+ // Omit SemanticTypeIcon to avoid polluting audit logs with base64 data
+ })
+ }
+ return redacted
+}
+
func redactLoginResponse(r *v1pb.LoginResponse) *v1pb.LoginResponse {
if r == nil {
return nil
diff --git a/backend/api/v1/masking_evaluator.go b/backend/api/v1/masking_evaluator.go
index 1db08f40e9..d2468e789b 100644
--- a/backend/api/v1/masking_evaluator.go
+++ b/backend/api/v1/masking_evaluator.go
@@ -1,6 +1,7 @@
package v1
import (
+ "fmt"
"reflect"
"time"
@@ -19,6 +20,17 @@ type maskingLevelEvaluator struct {
semanticTypesMap map[string]*storepb.SemanticTypeSetting_SemanticType
}
+// MaskingEvaluation contains the result of masking evaluation including the reason.
+type MaskingEvaluation struct {
+ SemanticTypeID string
+ SemanticTypeTitle string
+ SemanticTypeIcon string
+ MaskingRuleID string
+ Algorithm string
+ Context string
+ ClassificationLevel string
+}
+
func newEmptyMaskingLevelEvaluator() *maskingLevelEvaluator {
return &maskingLevelEvaluator{
dataClassificationIDMap: make(map[string]*storepb.DataClassificationSetting_DataClassificationConfig),
@@ -70,24 +82,46 @@ func (m *maskingLevelEvaluator) evaluateSemanticTypeOfColumn(
databaseProjectDataClassificationID string,
columnConfig *storepb.ColumnCatalog,
filteredMaskingExceptions []*storepb.MaskingExceptionPolicy_MaskingException,
-) (string, error) {
- semanticTypeID, err := m.evaluateGlobalMaskingLevelOfColumn(databaseMessage, schemaName, tableName, columnName, databaseProjectDataClassificationID, columnConfig)
+) (*MaskingEvaluation, error) {
+ eval, err := m.evaluateGlobalMaskingLevelOfColumn(databaseMessage, schemaName, tableName, columnName, databaseProjectDataClassificationID, columnConfig)
if err != nil {
- return "", errors.Wrapf(err, "failed to evaluate masking level of column")
+ return nil, errors.Wrapf(err, "failed to evaluate masking level of column")
}
- if semanticTypeID == "" {
- semanticTypeID = columnConfig.GetSemanticType()
+
+ if eval == nil || eval.SemanticTypeID == "" {
+ // Check column-level semantic type
+ semanticTypeID := columnConfig.GetSemanticType()
+ if semanticTypeID != "" {
+ semanticType, ok := m.semanticTypesMap[semanticTypeID]
+ if ok {
+ context := ""
+ if schemaName != "" {
+ context = fmt.Sprintf("Column-level semantic type: %s.%s.%s.%s.%s", databaseMessage.InstanceID, databaseMessage.DatabaseName, schemaName, tableName, columnName)
+ } else {
+ context = fmt.Sprintf("Column-level semantic type: %s.%s.%s.%s", databaseMessage.InstanceID, databaseMessage.DatabaseName, tableName, columnName)
+ }
+ algorithmName := getAlgorithmNameFromSemanticType(semanticType)
+ eval = &MaskingEvaluation{
+ SemanticTypeID: semanticTypeID,
+ SemanticTypeTitle: semanticType.Title,
+ SemanticTypeIcon: semanticType.Icon,
+ Algorithm: algorithmName,
+ Context: context,
+ }
+ }
+ }
}
- if semanticTypeID != "" {
+
+ if eval != nil && eval.SemanticTypeID != "" {
pass, err := evaluateExceptionOfColumn(databaseMessage, schemaName, tableName, columnName, filteredMaskingExceptions)
if err != nil {
- return "", err
+ return nil, err
}
if pass {
- return "", nil
+ return nil, nil
}
}
- return semanticTypeID, nil
+ return eval, nil
}
func (m *maskingLevelEvaluator) evaluateGlobalMaskingLevelOfColumn(
@@ -95,7 +129,7 @@ func (m *maskingLevelEvaluator) evaluateGlobalMaskingLevelOfColumn(
schemaName, tableName, columnName string,
databaseProjectDataClassificationID string,
columnConfig *storepb.ColumnCatalog,
-) (string, error) {
+) (*MaskingEvaluation, error) {
dataClassificationConfig := m.getDataClassificationConfig(databaseProjectDataClassificationID)
// If the column has DEFAULT masking level in maskingPolicy or not set yet,
// we will eval the maskingRulePolicy to get the maskingLevel.
@@ -113,13 +147,41 @@ func (m *maskingLevelEvaluator) evaluateGlobalMaskingLevelOfColumn(
}
pass, err := evaluateMaskingRulePolicyCondition(maskingRule.Condition.Expression, maskingRuleAttributes)
if err != nil {
- return "", errors.Wrapf(err, "failed to evaluate masking rule policy condition")
+ return nil, errors.Wrapf(err, "failed to evaluate masking rule policy condition")
}
if pass {
- return maskingRule.GetSemanticType(), nil
+ semanticTypeID := maskingRule.GetSemanticType()
+ semanticType, ok := m.semanticTypesMap[semanticTypeID]
+ if !ok {
+ ruleTitle := ""
+ if maskingRule.Condition != nil && maskingRule.Condition.Title != "" {
+ ruleTitle = maskingRule.Condition.Title
+ }
+ return &MaskingEvaluation{
+ SemanticTypeID: semanticTypeID,
+ MaskingRuleID: maskingRule.Id,
+ Context: fmt.Sprintf("Global masking rule: %s", ruleTitle),
+ ClassificationLevel: classificationLevel,
+ }, nil
+ }
+ ruleTitle := ""
+ if maskingRule.Condition != nil && maskingRule.Condition.Title != "" {
+ ruleTitle = maskingRule.Condition.Title
+ }
+ // Get algorithm name from semantic type
+ algorithmName := getAlgorithmNameFromSemanticType(semanticType)
+ return &MaskingEvaluation{
+ SemanticTypeID: semanticTypeID,
+ SemanticTypeTitle: semanticType.Title,
+ SemanticTypeIcon: semanticType.Icon,
+ MaskingRuleID: maskingRule.Id,
+ Algorithm: algorithmName,
+ Context: fmt.Sprintf("Global masking rule: %s", ruleTitle),
+ ClassificationLevel: classificationLevel,
+ }, nil
}
}
- return "", nil
+ return nil, nil
}
func evaluateExceptionOfColumn(databaseMessage *store.DatabaseMessage, schemaName, tableName, columnName string, filteredMaskingExceptions []*storepb.MaskingExceptionPolicy_MaskingException) (bool, error) {
@@ -198,6 +260,25 @@ func evaluateMaskingExceptionPolicyCondition(expression *expr.Expr, attributes m
return boolVar, nil
}
+func getAlgorithmNameFromSemanticType(semanticType *storepb.SemanticTypeSetting_SemanticType) string {
+ if semanticType == nil || semanticType.Algorithm == nil {
+ return ""
+ }
+
+ switch semanticType.Algorithm.Mask.(type) {
+ case *storepb.Algorithm_FullMask_:
+ return "Full mask"
+ case *storepb.Algorithm_RangeMask_:
+ return "Partial mask"
+ case *storepb.Algorithm_Md5Mask:
+ return "Hash (MD5)"
+ case *storepb.Algorithm_InnerOuterMask_:
+ return "Inner/Outer mask"
+ default:
+ return "Unknown"
+ }
+}
+
func evaluateMaskingRulePolicyCondition(expression string, attributes map[string]any) (bool, error) {
if expression == "" {
return true, nil
@@ -229,6 +310,7 @@ func evaluateMaskingRulePolicyCondition(expression string, attributes map[string
return boolVar, nil
}
+// nolint:unused
func evaluateQueryExportPolicyCondition(expression string, attributes map[string]any) (bool, error) {
if expression == "" {
return true, nil
diff --git a/backend/api/v1/masking_evaluator_test.go b/backend/api/v1/masking_evaluator_test.go
index a9578b1ab4..db30a6a05a 100644
--- a/backend/api/v1/masking_evaluator_test.go
+++ b/backend/api/v1/masking_evaluator_test.go
@@ -79,7 +79,10 @@ func TestEvalMaskingLevelOfColumn(t *testing.T) {
filteredMaskingExceptions []*storepb.MaskingExceptionPolicy_MaskingException
dataClassification *storepb.DataClassificationSetting
- want string
+ want string
+ wantAlgorithm string
+ wantContext string
+ wantClassLevel string
}{
{
description: "Follow The Global Masking Rule",
@@ -103,7 +106,9 @@ func TestEvalMaskingLevelOfColumn(t *testing.T) {
dataClassification: defaultClassification,
databaseProjectDatabaseClassificationID: defaultProjectDatabaseDataClassificationID,
- want: "default",
+ want: "default",
+ wantAlgorithm: "Full mask",
+ wantClassLevel: "S2",
},
{
description: "Respect The Exception",
@@ -150,7 +155,8 @@ func TestEvalMaskingLevelOfColumn(t *testing.T) {
dataClassification: defaultClassification,
databaseProjectDatabaseClassificationID: defaultProjectDatabaseDataClassificationID,
- want: "salary-amount",
+ want: "salary-amount",
+ wantAlgorithm: "Hash (MD5)",
},
}
@@ -160,6 +166,20 @@ func TestEvalMaskingLevelOfColumn(t *testing.T) {
m := newEmptyMaskingLevelEvaluator().withMaskingRulePolicy(tc.maskingRulePolicy).withDataClassificationSetting(tc.dataClassification).withSemanticTypeSetting(defaultSemanticType)
result, err := m.evaluateSemanticTypeOfColumn(tc.databaseMessage, tc.schemaName, tc.tableName, tc.columnName, tc.databaseProjectDatabaseClassificationID, tc.columnCatalog, tc.filteredMaskingExceptions)
a.NoError(err, tc.description)
- a.Equal(tc.want, result, tc.description)
+ if tc.want == "" {
+ a.Nil(result, tc.description)
+ } else {
+ a.NotNil(result, tc.description)
+ a.Equal(tc.want, result.SemanticTypeID, tc.description)
+ if tc.wantAlgorithm != "" {
+ a.Equal(tc.wantAlgorithm, result.Algorithm, tc.description)
+ }
+ if tc.wantContext != "" {
+ a.Equal(tc.wantContext, result.Context, tc.description)
+ }
+ if tc.wantClassLevel != "" {
+ a.Equal(tc.wantClassLevel, result.ClassificationLevel, tc.description)
+ }
+ }
}
}
diff --git a/backend/api/v1/predicate_columns_check.go b/backend/api/v1/predicate_columns_check.go
index 8dd38eb8ed..300d8ddc49 100644
--- a/backend/api/v1/predicate_columns_check.go
+++ b/backend/api/v1/predicate_columns_check.go
@@ -140,11 +140,11 @@ func (s *QueryResultMasker) getSensitiveColumnsForPredicate(
}
func (m *maskingLevelEvaluator) isSensitiveColumn(database *store.DatabaseMessage, column base.ColumnResource, classificationConfigID string, columnConfig *storepb.ColumnCatalog, exception []*storepb.MaskingExceptionPolicy_MaskingException) (bool, error) {
- semanticTypeID, err := m.evaluateSemanticTypeOfColumn(database, column.Schema, column.Table, column.Column, classificationConfigID, columnConfig, exception)
+ evaluation, err := m.evaluateSemanticTypeOfColumn(database, column.Schema, column.Table, column.Column, classificationConfigID, columnConfig, exception)
if err != nil {
return false, errors.Wrapf(err, "failed to evaluate semantic type of column")
}
- return semanticTypeID != "", nil
+ return evaluation != nil && evaluation.SemanticTypeID != "", nil
}
func isPredicateColumnsCheckEnabled(engine storepb.Engine) bool {
diff --git a/backend/api/v1/query_result_masker.go b/backend/api/v1/query_result_masker.go
index f71d295fb0..5f3bf34dd2 100644
--- a/backend/api/v1/query_result_masker.go
+++ b/backend/api/v1/query_result_masker.go
@@ -63,16 +63,34 @@ func (s *QueryResultMasker) MaskResults(ctx context.Context, spans []*parserbase
if results[i].Error != "" && len(results[i].Rows) == 0 {
continue
}
- maskers, err := s.getMaskersForQuerySpan(ctx, m, instance, user, spans[i], action)
+ maskers, reasons, err := s.getMaskersForQuerySpan(ctx, m, instance, user, spans[i], action)
if err != nil {
return errors.Wrapf(err, "failed to get maskers for query span")
}
- doMaskResult(maskers, results[i])
+ doMaskResult(maskers, reasons, results[i])
}
return nil
}
+func getAlgorithmName(m masker.Masker) string {
+ switch m.(type) {
+ case *masker.NoneMasker:
+ return "None"
+ case *masker.FullMasker:
+ return "Full mask"
+ case *masker.RangeMasker, *masker.DefaultRangeMasker:
+ return "Partial mask"
+ case *masker.MD5Masker:
+ return "Hash (MD5)"
+ case *masker.InnerOuterMasker:
+ // Check the actual type by examining the mask result
+ return "Inner/Outer mask"
+ default:
+ return "Unknown"
+ }
+}
+
func buildSemanticTypeToMaskerMap(ctx context.Context, stores *store.Store) (map[string]masker.Masker, error) {
semanticTypeToMasker := map[string]masker.Masker{
"bb.default": masker.NewDefaultFullMasker(),
@@ -87,26 +105,30 @@ func buildSemanticTypeToMaskerMap(ctx context.Context, stores *store.Store) (map
// Skip the built-in default semantic types.
continue
}
- masker, err := getMaskerByMaskingAlgorithmAndLevel(semanticType.GetAlgorithm())
+ m, err := getMaskerByMaskingAlgorithmAndLevel(semanticType.GetAlgorithm())
if err != nil {
return nil, err
}
- semanticTypeToMasker[semanticType.GetId()] = masker
+ // Only add semantic types that have actual masking configured (not NoneMasker)
+ if _, isNoneMasker := m.(*masker.NoneMasker); !isNoneMasker {
+ semanticTypeToMasker[semanticType.GetId()] = m
+ }
}
return semanticTypeToMasker, nil
}
// getMaskersForQuerySpan returns the maskers for the query span.
-func (s *QueryResultMasker) getMaskersForQuerySpan(ctx context.Context, m *maskingLevelEvaluator, instance *store.InstanceMessage, user *store.UserMessage, span *parserbase.QuerySpan, action storepb.MaskingExceptionPolicy_MaskingException_Action) ([]masker.Masker, error) {
+func (s *QueryResultMasker) getMaskersForQuerySpan(ctx context.Context, m *maskingLevelEvaluator, instance *store.InstanceMessage, user *store.UserMessage, span *parserbase.QuerySpan, action storepb.MaskingExceptionPolicy_MaskingException_Action) ([]masker.Masker, []*v1pb.MaskingReason, error) {
if span == nil {
- return nil, nil
+ return nil, nil, nil
}
maskers := make([]masker.Masker, 0, len(span.Results))
+ masked := make([]*v1pb.MaskingReason, 0, len(span.Results))
semanticTypesToMasker, err := buildSemanticTypeToMaskerMap(ctx, s.store)
if err != nil {
- return nil, errors.Wrapf(err, "failed to build semantic type to masker map")
+ return nil, nil, errors.Wrapf(err, "failed to build semantic type to masker map")
}
// Multiple databases may belong to the same project, to reduce the protojson unmarshal cost,
// we store the projectResourceID - maskingExceptionPolicy in a map.
@@ -116,14 +138,16 @@ func (s *QueryResultMasker) getMaskersForQuerySpan(ctx context.Context, m *maski
// Likes constant expression, we use the none masker.
if len(spanResult.SourceColumns) == 0 {
maskers = append(maskers, masker.NewNoneMasker())
+ masked = append(masked, nil)
continue
}
var effectiveMaskers []masker.Masker
+ var effectiveReasons []*MaskingEvaluation
for column := range spanResult.SourceColumns {
- newMasker, err := s.getMaskerForColumnResource(ctx, m, instance, column, maskingExceptionPolicyMap, action, user, semanticTypesToMasker)
+ newMasker, reason, err := s.getMaskerForColumnResource(ctx, m, instance, column, maskingExceptionPolicyMap, action, user, semanticTypesToMasker)
if err != nil {
- return nil, err
+ return nil, nil, err
}
if newMasker == nil {
continue
@@ -132,25 +156,62 @@ func (s *QueryResultMasker) getMaskersForQuerySpan(ctx context.Context, m *maski
continue
}
effectiveMaskers = append(effectiveMaskers, newMasker)
+ if reason != nil {
+ effectiveReasons = append(effectiveReasons, reason)
+ }
}
switch len(effectiveMaskers) {
case 0:
maskers = append(maskers, masker.NewNoneMasker())
+ masked = append(masked, nil)
case 1:
// If there is only one source column, and comes from the expression, we fall back to the default full masker.
if !spanResult.IsPlainField && common.EngineSupportQuerySpanPlainField(instance.Metadata.GetEngine()) {
maskers = append(maskers, masker.NewDefaultFullMasker())
+ // For expression-based columns, add a generic reason
+ if len(effectiveReasons) > 0 {
+ reason := effectiveReasons[0]
+ masked = append(masked, &v1pb.MaskingReason{
+ SemanticTypeId: reason.SemanticTypeID,
+ SemanticTypeTitle: reason.SemanticTypeTitle,
+ SemanticTypeIcon: reason.SemanticTypeIcon,
+ MaskingRuleId: reason.MaskingRuleID,
+ Algorithm: "Full mask",
+ Context: "Expression-based column",
+ ClassificationLevel: reason.ClassificationLevel,
+ })
+ } else {
+ masked = append(masked, nil)
+ }
} else {
maskers = append(maskers, effectiveMaskers[0])
+ if len(effectiveReasons) > 0 {
+ reason := effectiveReasons[0]
+ masked = append(masked, &v1pb.MaskingReason{
+ SemanticTypeId: reason.SemanticTypeID,
+ SemanticTypeTitle: reason.SemanticTypeTitle,
+ SemanticTypeIcon: reason.SemanticTypeIcon,
+ MaskingRuleId: reason.MaskingRuleID,
+ Algorithm: reason.Algorithm,
+ Context: reason.Context,
+ ClassificationLevel: reason.ClassificationLevel,
+ })
+ } else {
+ masked = append(masked, nil)
+ }
}
default:
// If there are more than one source columns, we fall back to the default full masker,
// because we don't know how the data be made up.
maskers = append(maskers, masker.NewDefaultFullMasker())
+ masked = append(masked, &v1pb.MaskingReason{
+ Algorithm: "Full mask",
+ Context: "Multiple source columns",
+ })
}
}
- return maskers, nil
+ return maskers, masked, nil
}
func (s *QueryResultMasker) getMaskerForColumnResource(
@@ -162,38 +223,38 @@ func (s *QueryResultMasker) getMaskerForColumnResource(
action storepb.MaskingExceptionPolicy_MaskingException_Action,
currentPrincipal *store.UserMessage,
semanticTypeToMasker map[string]masker.Masker,
-) (masker.Masker, error) {
+) (masker.Masker, *MaskingEvaluation, error) {
if instance != nil && !common.EngineSupportMasking(instance.Metadata.GetEngine()) {
- return masker.NewNoneMasker(), nil
+ return masker.NewNoneMasker(), nil, nil
}
database, err := s.store.GetDatabaseV2(ctx, &store.FindDatabaseMessage{
InstanceID: &instance.ResourceID,
DatabaseName: &sourceColumn.Database,
})
if err != nil {
- return nil, errors.Wrapf(err, "failed to find database: %q", sourceColumn.Database)
+ return nil, nil, errors.Wrapf(err, "failed to find database: %q", sourceColumn.Database)
}
if database == nil {
- return masker.NewNoneMasker(), nil
+ return masker.NewNoneMasker(), nil, nil
}
project, err := s.store.GetProjectV2(ctx, &store.FindProjectMessage{
ResourceID: &database.ProjectID,
})
if err != nil {
- return nil, errors.Wrapf(err, "failed to find project: %q", database.ProjectID)
+ return nil, nil, errors.Wrapf(err, "failed to find project: %q", database.ProjectID)
}
if project == nil {
- return masker.NewNoneMasker(), nil
+ return masker.NewNoneMasker(), nil, nil
}
meta, config, err := s.getColumnForColumnResource(ctx, instance.ResourceID, &sourceColumn)
if err != nil {
- return nil, errors.Wrapf(err, "failed to get database metadata for column resource: %q", sourceColumn.String())
+ return nil, nil, errors.Wrapf(err, "failed to get database metadata for column resource: %q", sourceColumn.String())
}
// Span and metadata are not the same in real time, so we fall back to none masker.
if meta == nil {
- return masker.NewNoneMasker(), nil
+ return masker.NewNoneMasker(), nil, nil
}
var maskingExceptionPolicy *storepb.MaskingExceptionPolicy
@@ -202,7 +263,7 @@ func (s *QueryResultMasker) getMaskerForColumnResource(
if _, ok := maskingExceptionPolicyMap[database.ProjectID]; !ok {
policy, err := s.store.GetMaskingExceptionPolicyByProject(ctx, project.ResourceID)
if err != nil {
- return nil, errors.Wrapf(err, "failed to find masking exception policy for project %q", project.ResourceID)
+ return nil, nil, errors.Wrapf(err, "failed to find masking exception policy for project %q", project.ResourceID)
}
// It is safe if policy is nil.
maskingExceptionPolicyMap[database.ProjectID] = policy
@@ -227,17 +288,26 @@ func (s *QueryResultMasker) getMaskerForColumnResource(
}
}
- semanticTypeID, err := m.evaluateSemanticTypeOfColumn(database, sourceColumn.Schema, sourceColumn.Table, sourceColumn.Column, project.DataClassificationConfigID, config, maskingExceptionContainsCurrentPrincipal)
+ evaluation, err := m.evaluateSemanticTypeOfColumn(database, sourceColumn.Schema, sourceColumn.Table, sourceColumn.Column, project.DataClassificationConfigID, config, maskingExceptionContainsCurrentPrincipal)
if err != nil {
- return nil, errors.Wrapf(err, "failed to evaluate masking level of database %q, schema %q, table %q, column %q", sourceColumn.Database, sourceColumn.Schema, sourceColumn.Table, sourceColumn.Column)
+ return nil, nil, errors.Wrapf(err, "failed to evaluate masking level of database %q, schema %q, table %q, column %q", sourceColumn.Database, sourceColumn.Schema, sourceColumn.Table, sourceColumn.Column)
}
- result, ok := semanticTypeToMasker[semanticTypeID]
+ if evaluation == nil || evaluation.SemanticTypeID == "" {
+ return masker.NewNoneMasker(), nil, nil
+ }
+
+ result, ok := semanticTypeToMasker[evaluation.SemanticTypeID]
if !ok {
- return masker.NewNoneMasker(), nil
+ // No masker configured for this semantic type, return NoneMasker without evaluation
+ return masker.NewNoneMasker(), nil, nil
}
- return result, nil
+ // Get algorithm name from the masker
+ algorithmName := getAlgorithmName(result)
+ evaluation.Algorithm = algorithmName
+
+ return result, evaluation, nil
}
func (s *QueryResultMasker) getColumnForColumnResource(ctx context.Context, instanceID string, sourceColumn *parserbase.ColumnResource) (*storepb.ColumnMetadata, *storepb.ColumnCatalog, error) {
@@ -322,7 +392,7 @@ func convertRangeMaskSlices(slices []*storepb.Algorithm_RangeMask_Slice) []*mask
return result
}
-func doMaskResult(maskers []masker.Masker, result *v1pb.QueryResult) {
+func doMaskResult(maskers []masker.Masker, reasons []*v1pb.MaskingReason, result *v1pb.QueryResult) {
sensitive := make([]bool, len(result.ColumnNames))
for i := range result.ColumnNames {
if i < len(maskers) {
@@ -350,6 +420,5 @@ func doMaskResult(maskers []masker.Masker, result *v1pb.QueryResult) {
}
}
- result.Sensitive = sensitive
- result.Masked = sensitive
+ result.Masked = reasons
}
diff --git a/backend/tests/sensitive_data_test.go b/backend/tests/sensitive_data_test.go
index 2bb5db34e3..ae0bf00111 100644
--- a/backend/tests/sensitive_data_test.go
+++ b/backend/tests/sensitive_data_test.go
@@ -3,6 +3,7 @@ package tests
import (
"context"
"fmt"
+ "strings"
"testing"
"connectrpc.com/connect"
@@ -18,8 +19,11 @@ var (
maskedData = &v1pb.QueryResult{
ColumnNames: []string{"id", "name", "author"},
ColumnTypeNames: []string{"INT", "VARCHAR", "VARCHAR"},
- Masked: []bool{true, false, true},
- Sensitive: []bool{true, false, true},
+ Masked: []*v1pb.MaskingReason{
+ {SemanticTypeId: "default", Algorithm: "Full mask"},
+ nil,
+ {SemanticTypeId: "default", Algorithm: "Full mask"},
+ },
Rows: []*v1pb.QueryRow{
{
Values: []*v1pb.RowValue{
@@ -254,7 +258,37 @@ func TestSensitiveData(t *testing.T) {
}))
a.NoError(err)
a.Equal(1, len(queryResp.Msg.Results))
- diff := cmp.Diff(maskedData, queryResp.Msg.Results[0], protocmp.Transform(), protocmp.IgnoreMessages(&durationpb.Duration{}))
+
+ // Build expected masked data dynamically with the correct instance name
+ // Extract instance ID from instance.Name (which is in format "instances/instance-id")
+ instanceParts := strings.Split(instance.Name, "/")
+ instanceID := instanceParts[len(instanceParts)-1]
+
+ expectedMaskedData := &v1pb.QueryResult{
+ ColumnNames: []string{"id", "name", "author"},
+ ColumnTypeNames: []string{"INT", "VARCHAR", "VARCHAR"},
+ Masked: []*v1pb.MaskingReason{
+ {
+ SemanticTypeId: "default",
+ Algorithm: "Full mask",
+ Context: fmt.Sprintf("Column-level semantic type: %s.%s.%s.%s", instanceID, databaseName, tableName, "id"),
+ SemanticTypeTitle: "Default",
+ },
+ nil,
+ {
+ SemanticTypeId: "default",
+ Algorithm: "Full mask",
+ Context: fmt.Sprintf("Column-level semantic type: %s.%s.%s.%s", instanceID, databaseName, tableName, "author"),
+ SemanticTypeTitle: "Default",
+ },
+ },
+ Rows: maskedData.Rows,
+ Statement: "SELECT * FROM tech_book",
+ RowsCount: 3,
+ AllowExport: true,
+ }
+
+ diff := cmp.Diff(expectedMaskedData, queryResp.Msg.Results[0], protocmp.Transform(), protocmp.IgnoreMessages(&durationpb.Duration{}))
a.Empty(diff)
// Query origin data.
diff --git a/backend/tests/sql_review_test.go b/backend/tests/sql_review_test.go
index 28b36f1b7f..76c5b1ccbd 100644
--- a/backend/tests/sql_review_test.go
+++ b/backend/tests/sql_review_test.go
@@ -229,8 +229,7 @@ func TestSQLReviewForMySQL(t *testing.T) {
wantQueryResult = &v1pb.QueryResult{
ColumnNames: []string{"count(*)"},
ColumnTypeNames: []string{"BIGINT"},
- Masked: []bool{false},
- Sensitive: []bool{false},
+ Masked: []*v1pb.MaskingReason{nil},
Rows: []*v1pb.QueryRow{
{
Values: []*v1pb.RowValue{
diff --git a/frontend/src/components/SensitiveData/components/IconSelector.vue b/frontend/src/components/SensitiveData/components/IconSelector.vue
new file mode 100644
index 0000000000..c29637e2f5
--- /dev/null
+++ b/frontend/src/components/SensitiveData/components/IconSelector.vue
@@ -0,0 +1,125 @@
+<template>
+ <div class="w-full">
+ <div v-if="!isEditing" class="flex items-center justify-center gap-1">
+ <template v-if="modelValue">
+ <!-- Display uploaded image -->
+ <img :src="modelValue" class="w-6 h-6 object-contain" alt="" />
+ <MiniActionButton v-if="!readonly" @click="startEditing">
+ <PencilIcon class="w-4 h-4" />
+ </MiniActionButton>
+ </template>
+ <MiniActionButton v-else-if="!readonly" @click="startEditing">
+ <PencilIcon class="w-4 h-4" />
+ </MiniActionButton>
+ <span v-else class="text-gray-400">-</span>
+ </div>
+
+ <!-- Edit mode -->
+ <NPopover
+ v-else
+ :show="true"
+ trigger="manual"
+ placement="bottom"
+ @clickoutside="cancelEdit"
+ >
+ <template #trigger>
+ <div class="w-full" />
+ </template>
+ <div class="p-2 space-y-2">
+ <SingleFileSelector
+ class="w-48 h-32"
+ :max-file-size-in-mi-b="2"
+ :support-file-extensions="supportImageExtensions"
+ @on-select="onFileSelect"
+ >
+ <template #default>
+ <div
+ class="w-full h-full flex flex-col items-center justify-center border-2 border-dashed border-gray-300 rounded-md hover:border-gray-400 transition-colors"
+ >
+ <heroicons-outline:upload class="w-8 h-8 text-gray-400" />
+ <span class="text-xs text-gray-500 mt-1">
+ {{ $t("settings.general.workspace.drag-logo") }}
+ </span>
+ <span class="text-xs text-gray-400">
+ {{ supportedFormatsText }}
+ </span>
+ </div>
+ </template>
+ </SingleFileSelector>
+ <div v-if="tempValue" class="mt-2">
+ <img :src="tempValue" class="w-8 h-8 object-contain mx-auto" alt="" />
+ </div>
+ <div class="flex justify-end gap-2">
+ <NButton size="tiny" @click="clearIcon">
+ {{ $t("common.clear") }}
+ </NButton>
+ <NButton size="tiny" @click="cancelEdit">
+ {{ $t("common.cancel") }}
+ </NButton>
+ <NButton size="tiny" type="primary" @click="confirmEdit">
+ {{ $t("common.confirm") }}
+ </NButton>
+ </div>
+ </div>
+ </NPopover>
+ </div>
+</template>
+
+<script setup lang="ts">
+import { PencilIcon } from "lucide-vue-next";
+import { NPopover, NButton } from "naive-ui";
+import { ref, computed } from "vue";
+import SingleFileSelector from "@/components/SingleFileSelector.vue";
+import { MiniActionButton } from "@/components/v2";
+
+const props = defineProps<{
+ modelValue?: string;
+ readonly?: boolean;
+}>();
+
+const emit = defineEmits<{
+ (event: "update:modelValue", value: string): void;
+}>();
+
+const isEditing = ref(false);
+const tempValue = ref("");
+
+const supportImageExtensions = [".jpg", ".jpeg", ".png", ".webp", ".svg"];
+
+const supportedFormatsText = computed(() => {
+ return supportImageExtensions.join(", ") + " (max 2MB)";
+});
+
+const startEditing = () => {
+ if (props.readonly) return;
+ isEditing.value = true;
+ tempValue.value = props.modelValue || "";
+};
+
+const confirmEdit = () => {
+ emit("update:modelValue", tempValue.value);
+ isEditing.value = false;
+};
+
+const cancelEdit = () => {
+ tempValue.value = "";
+ isEditing.value = false;
+};
+
+const clearIcon = () => {
+ tempValue.value = "";
+};
+
+const onFileSelect = async (file: File) => {
+ const fileInBase64 = await convertFileToBase64(file);
+ tempValue.value = fileInBase64;
+};
+
+const convertFileToBase64 = (file: File) =>
+ new Promise<string>((resolve, reject) => {
+ const reader = new FileReader();
+ reader.readAsDataURL(file);
+ reader.onload = () => resolve(reader.result as string);
+ reader.onerror = (error) => reject(error);
+ });
+</script>
diff --git a/frontend/src/components/SensitiveData/components/SemanticTypesTable.vue b/frontend/src/components/SensitiveData/components/SemanticTypesTable.vue
index 389bae9531..e573352119 100644
--- a/frontend/src/components/SensitiveData/components/SemanticTypesTable.vue
+++ b/frontend/src/components/SensitiveData/components/SemanticTypesTable.vue
@@ -43,6 +43,7 @@ import {
type Algorithm,
type SemanticTypeSetting_SemanticType,
} from "@/types/proto-es/v1/setting_service_pb";
+import IconSelector from "./IconSelector.vue";
import MaskingAlgorithmsCreateDrawer from "./MaskingAlgorithmsCreateDrawer.vue";
import { getMaskingType } from "./utils";
@@ -112,6 +113,41 @@ const onAlgorithmUpsert = async (maskingAlgorithm: Algorithm) => {
const columnList = computed(() => {
const columns: DataTableColumn<SemanticItem>[] = [
+ {
+ key: "icon",
+ title: t("settings.sensitive-data.semantic-types.table.icon"),
+ width: 80,
+ align: "center",
+ render: (item, row) => {
+ if (item.mode === "NORMAL") {
+ if (item.item.icon) {
+ return (
+ <div class="flex items-center justify-center">
+ <img
+ src={item.item.icon}
+ class="w-6 h-6 object-contain"
+ alt=""
+ />
+ </div>
+ );
+ }
+ return (
+ <div class="flex items-center justify-center">
+ <span class="text-gray-400">-</span>
+ </div>
+ );
+ }
+ // For edit mode, show IconSelector
+ return (
+ <IconSelector
+ modelValue={item.item.icon || ""}
+ onUpdate:modelValue={(val: string) =>
+ onInput(row, (data) => (data.item.icon = val))
+ }
+ />
+ );
+ },
+ },
{
key: "id",
title: "ID",
diff --git a/frontend/src/locales/en-US.json b/frontend/src/locales/en-US.json
index 775f8df37e..67d72d4a02 100644
--- a/frontend/src/locales/en-US.json
+++ b/frontend/src/locales/en-US.json
@@ -174,6 +174,7 @@
"will-override-current-data": "Will override current data.",
"rollout": "Rollout",
"upload": "Upload",
+ "clear": "Clear",
"added": "Added",
"revoke": "Revoke",
"cannot-undo-this-action": "You cannot undo this action",
@@ -694,6 +695,7 @@
"use-predefined-type": "Use Predefined Type",
"add-from-template": "Add from template",
"table": {
+ "icon": "Icon",
"semantic-type": "Semantic Type",
"description": "Description",
"masking-algorithm": "Masking Algorithm",
@@ -2809,6 +2811,16 @@
"built-in-desc": "Generate sample project and instances"
}
},
+ "masking": {
+ "reason": {
+ "title": "Why is this data masked?",
+ "semantic-type": "Semantic type",
+ "algorithm": "Masking method",
+ "context": "Rule",
+ "classification": "Classification level"
+ },
+ "algorithms": {}
+ },
"landing": {
"quick-link": {
"self": "Quick Link",
diff --git a/frontend/src/locales/es-ES.json b/frontend/src/locales/es-ES.json
index f51198a14d..8841bde415 100644
--- a/frontend/src/locales/es-ES.json
+++ b/frontend/src/locales/es-ES.json
@@ -174,6 +174,7 @@
"will-override-current-data": "Se sobrescribirán los datos actuales.",
"rollout": "Implementar",
"upload": "Subir",
+ "clear": "Limpiar",
"added": "Agregado",
"revoke": "Revocar",
"cannot-undo-this-action": "No se puede deshacer esta acción",
@@ -694,6 +695,7 @@
"use-predefined-type": "Utiliza el Tipo Predefinido",
"add-from-template": "Agregar desde plantilla",
"table": {
+ "icon": "Icono",
"semantic-type": "Tipo Semántico",
"description": "Descripción",
"masking-algorithm": "Algoritmo de enmascaramiento",
@@ -2809,6 +2811,16 @@
"built-in-desc": "Generar proyecto de muestra e instancias"
}
},
+ "masking": {
+ "reason": {
+ "title": "¿Por qué están enmascarados estos datos?",
+ "semantic-type": "Tipo semántico",
+ "algorithm": "Método de enmascaramiento",
+ "context": "Regla",
+ "classification": "Nivel de clasificación"
+ },
+ "algorithms": {}
+ },
"landing": {
"quick-link": {
"self": "Enlace rápido",
diff --git a/frontend/src/locales/ja-JP.json b/frontend/src/locales/ja-JP.json
index 9390149855..caff9b366c 100644
--- a/frontend/src/locales/ja-JP.json
+++ b/frontend/src/locales/ja-JP.json
@@ -174,6 +174,7 @@
"will-override-current-data": "現在のデータは上書きされます。",
"rollout": "リリース",
"upload": "アップロード",
+ "clear": "クリア",
"added": "作成した",
"revoke": "キャンセル",
"cannot-undo-this-action": "この操作は元に戻せません",
@@ -694,6 +695,7 @@
"use-predefined-type": "事前定義されたタイプを使用する",
"add-from-template": "テンプレートから追加",
"table": {
+ "icon": "アイコン",
"semantic-type": "セマンティックタイプ",
"description": "説明",
"masking-algorithm": "マスキングアルゴリズム",
@@ -2809,6 +2811,16 @@
"built-in-desc": "サンプルプロジェクトとインスタンスを生成する"
}
},
+ "masking": {
+ "reason": {
+ "title": "なぜこのデータはマスクされていますか?",
+ "semantic-type": "セマンティックタイプ",
+ "algorithm": "マスキング方法",
+ "context": "ルール",
+ "classification": "分類レベル"
+ },
+ "algorithms": {}
+ },
"landing": {
"quick-link": {
"self": "クイックリンク",
diff --git a/frontend/src/locales/vi-VN.json b/frontend/src/locales/vi-VN.json
index 5f38d73b67..805f1b6c91 100644
--- a/frontend/src/locales/vi-VN.json
+++ b/frontend/src/locales/vi-VN.json
@@ -174,6 +174,7 @@
"will-override-current-data": "Sẽ ghi đè dữ liệu hiện tại.",
"rollout": "Triển khai",
"upload": "Tải lên",
+ "clear": "Xóa",
"added": "Đã thêm",
"revoke": "Thu hồi",
"cannot-undo-this-action": "Bạn không thể hoàn tác hành động này.",
@@ -694,6 +695,7 @@
"use-predefined-type": "Sử dụng Loại định nghĩa trước",
"add-from-template": "Thêm từ mẫu",
"table": {
+ "icon": "Biểu tượng",
"semantic-type": "Loại ngữ nghĩa",
"description": "Mô tả",
"masking-algorithm": "Thuật toán che",
@@ -2809,6 +2811,16 @@
"built-in-desc": "Tạo dự án mẫu và các trường hợp"
}
},
+ "masking": {
+ "reason": {
+ "title": "Tại sao dữ liệu này bị che?",
+ "semantic-type": "Loại ngữ nghĩa",
+ "algorithm": "Phương pháp che dữ liệu",
+ "context": "Quy tắc",
+ "classification": "Mức phân loại"
+ },
+ "algorithms": {}
+ },
"landing": {
"quick-link": {
"self": "Liên kết nhanh",
diff --git a/frontend/src/locales/zh-CN.json b/frontend/src/locales/zh-CN.json
index 4c18185d95..4fb5a9833c 100644
--- a/frontend/src/locales/zh-CN.json
+++ b/frontend/src/locales/zh-CN.json
@@ -174,6 +174,7 @@
"will-override-current-data": "将会覆盖当前数据。",
"rollout": "发布",
"upload": "上传",
+ "clear": "清除",
"added": "已创建",
"revoke": "撤销",
"cannot-undo-this-action": "这个操作无法撤销",
@@ -694,6 +695,7 @@
"use-predefined-type": "使用预定义类型",
"add-from-template": "从模板添加",
"table": {
+ "icon": "图标",
"semantic-type": "语义类型",
"description": "描述",
"masking-algorithm": "脱敏算法",
@@ -2809,6 +2811,16 @@
"built-in-desc": "生成示例项目和实例"
}
},
+ "masking": {
+ "reason": {
+ "title": "为什么这些数据被遮盖?",
+ "semantic-type": "语义类型",
+ "algorithm": "遮盖方法",
+ "context": "规则",
+ "classification": "分类级别"
+ },
+ "algorithms": {}
+ },
"landing": {
"quick-link": {
"self": "快捷访问",
diff --git a/frontend/src/store/modules/sqlEditor/webTerminal.ts b/frontend/src/store/modules/sqlEditor/webTerminal.ts
index 0e7f764080..b6fe0464be 100644
--- a/frontend/src/store/modules/sqlEditor/webTerminal.ts
+++ b/frontend/src/store/modules/sqlEditor/webTerminal.ts
@@ -281,7 +281,7 @@ export const mockAffectedV1Rows0 = (): QueryResult => {
return create(QueryResultSchema, {
columnNames: ["Affected Rows"],
columnTypeNames: ["BIGINT"],
- masked: [false],
+ masked: [],
error: "",
statement: "",
rows: [
diff --git a/frontend/src/types/proto-es/v1/setting_service_pb.d.ts b/frontend/src/types/proto-es/v1/setting_service_pb.d.ts
index 451b1c0824..cbb8d3fdae 100644
--- a/frontend/src/types/proto-es/v1/setting_service_pb.d.ts
+++ b/frontend/src/types/proto-es/v1/setting_service_pb.d.ts
@@ -1033,6 +1033,13 @@ export declare type SemanticTypeSetting_SemanticType = Message<"bytebase.v1.Sema
* @generated from field: bytebase.v1.Algorithm algorithm = 6;
*/
algorithm?: Algorithm;
+
+ /**
+ * icon is the icon for semantic type, it can be emoji or base64 encoded image.
+ *
+ * @generated from field: string icon = 7;
+ */
+ icon: string;
};
/**
diff --git a/frontend/src/types/proto-es/v1/setting_service_pb.js b/frontend/src/types/proto-es/v1/setting_service_pb.js
index 00d82e3e8d..308d892582 100644
--- a/frontend/src/types/proto-es/v1/setting_service_pb.js
+++ b/frontend/src/types/proto-es/v1/setting_service_pb.js
@@ -19,7 +19,7 @@ import { file_v1_issue_service } from "./issue_service_pb";
* Describes the file v1/setting_service.proto.
*/
export const file_v1_setting_service = /*@__PURE__*/
- fileDesc("Chh2MS9zZXR0aW5nX3NlcnZpY2UucHJvdG8SC2J5dGViYXNlLnYxIjwKE0xpc3RTZXR0aW5nc1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W5nc1JlcXVlc3QaIS5ieXRlYmFzZS52MS5MaXN0U2V0dGluZ3NSZXNwb25zZSIv2kEAiuowEGJiLnNldHRpbmdzLmxpc3SQ6jABgtPkkwIOEgwvdjEvc2V0dGluZ3MSfwoKR2V0U2V0dGluZxIeLmJ5dGViYXNlLnYxLkdldFNldHRpbmdSZXF1ZXN0GhQuYnl0ZWJhc2UudjEuU2V0dGluZyI72kEEbmFtZYrqMA9iYi5zZXR0aW5ncy5nZXSQ6jABgtPkkwIXEhUvdjEve25hbWU9c2V0dGluZ3MvKn0SkwEKDVVwZGF0ZVNldHRpbmcSIS5ieXRlYmFzZS52MS5VcGRhdGVTZXR0aW5nUmVxdWVzdBoULmJ5dGViYXNlLnYxLlNldHRpbmciSYrqMA9iYi5zZXR0aW5ncy5zZXSQ6jABmOowAYLT5JMCKDoHc2V0dGluZzIdL3YxL3tzZXR0aW5nLm5hbWU9c2V0dGluZ3MvKn1CNFoyZ2l0aHViLmNvbS9ieXRlYmFzZS9ieXRlYmFzZS9wcm90by9nZW5lcmF0ZWQtZ28vdjFiBnByb3RvMw", [file_google_api_annotations, file_google_api_client, file_google_api_field_behavior, file_google_api_resource, file_google_protobuf_duration, file_google_protobuf_field_mask, file_google_type_expr, file_v1_annotation, file_v1_common, file_v1_database_catalog_service, file_v1_database_service, file_v1_issue_service]);
+ fileDesc("Chh2MS9zZXR0aW5nX3NlcnZpY2UucHJvdG8SC2J5dGViYXNlLnYxIjwKE0xpc3RTZXR0aW5nc1JlcXVlc3QSEQoJcGFnZV9zaXplGAEgASgFEhIKCnBhZ2VfdG9rZW4YAiABKAkiVwoUTGlzdFNldHRpbmdzUmVzcG9uc2USJgoIc2V0dGluZ3MYASADKAsyFC5ieXRlYmFzZS52MS5TZXR0aW5nEhcKD25leHRfcGFnZV90b2tlbhgCIAEoCSJAChFHZXRTZXR0aW5nUmVxdWVzdBIrCgRuYW1lGAEgASgJQh3iQQEC+kEWChRieXRlYmFzZS5jb20vU2V0dGluZyI7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STAhcSFS92MS97bmFtZT1zZXR0aW5ncy8qfRKTAQoNVXBkYXRlU2V0dGluZxIhLmJ5dGViYXNlLnYxLlVwZGF0ZVNldHRpbmdSZXF1ZXN0GhQuYnl0ZWJhc2UudjEuU2V0dGluZyJJiuowD2JiLnNldHRpbmdzLnNldJDqMAGY6jABgtPkkwIoOgdzZXR0aW5nMh0vdjEve3NldHRpbmcubmFtZT1zZXR0aW5ncy8qfUI0WjJnaXRodWIuY29tL2J5dGViYXNlL2J5dGViYXNlL3Byb3RvL2dlbmVyYXRlZC1nby92MWIGcHJvdG8z", [file_google_api_annotations, file_google_api_client, file_google_api_field_behavior, file_google_api_resource, file_google_protobuf_duration, file_google_protobuf_field_mask, file_google_type_expr, file_v1_annotation, file_v1_common, file_v1_database_catalog_service, file_v1_database_service, file_v1_issue_service]);
/**
* Describes the message bytebase.v1.ListSettingsRequest.
diff --git a/frontend/src/types/proto-es/v1/sql_service_pb.d.ts b/frontend/src/types/proto-es/v1/sql_service_pb.d.ts
index 13716eeadf..6a45c7ae84 100644
--- a/frontend/src/types/proto-es/v1/sql_service_pb.d.ts
+++ b/frontend/src/types/proto-es/v1/sql_service_pb.d.ts
@@ -244,20 +244,6 @@ export declare type QueryResult = Message<"bytebase.v1.QueryResult"> & {
*/
rowsCount: bigint;
- /**
- * Columns are masked or not.
- *
- * @generated from field: repeated bool masked = 4;
- */
- masked: boolean[];
-
- /**
- * Columns are sensitive or not.
- *
- * @generated from field: repeated bool sensitive = 5;
- */
- sensitive: boolean[];
-
/**
* The error message if the query failed.
*
@@ -304,6 +290,13 @@ export declare type QueryResult = Message<"bytebase.v1.QueryResult"> & {
* @generated from field: repeated bytebase.v1.QueryResult.Message messages = 12;
*/
messages: QueryResult_Message[];
+
+ /**
+ * Masking reasons for each column (empty for non-masked columns).
+ *
+ * @generated from field: repeated bytebase.v1.MaskingReason masked = 4;
+ */
+ masked: MaskingReason[];
};
/**
@@ -479,6 +472,66 @@ export enum QueryResult_Message_Level {
*/
export declare const QueryResult_Message_LevelSchema: GenEnum<QueryResult_Message_Level>;
+/**
+ * @generated from message bytebase.v1.MaskingReason
+ */
+export declare type MaskingReason = Message<"bytebase.v1.MaskingReason"> & {
+ /**
+ * The semantic type that triggered masking (e.g., "SSN", "email", "phone").
+ *
+ * @generated from field: string semantic_type_id = 1;
+ */
+ semanticTypeId: string;
+
+ /**
+ * Human-readable semantic type title.
+ *
+ * @generated from field: string semantic_type_title = 2;
+ */
+ semanticTypeTitle: string;
+
+ /**
+ * The masking rule ID that matched (if applicable).
+ *
+ * @generated from field: string masking_rule_id = 3;
+ */
+ maskingRuleId: string;
+
+ /**
+ * The masking algorithm used.
+ *
+ * @generated from field: string algorithm = 4;
+ */
+ algorithm: string;
+
+ /**
+ * Additional context (e.g., "Matched global rule: PII Protection").
+ *
+ * @generated from field: string context = 5;
+ */
+ context: string;
+
+ /**
+ * Whether masking was due to classification level.
+ *
+ * @generated from field: string classification_level = 6;
+ */
+ classificationLevel: string;
+
+ /**
+ * Icon associated with the semantic type (if any).
+ *
+ * @generated from field: string semantic_type_icon = 7;
+ */
+ semanticTypeIcon: string;
+};
+
+/**
+ * Describes the message bytebase.v1.MaskingReason.
+ * Use `create(MaskingReasonSchema)` to create a new message.
+ */
+export declare const MaskingReasonSchema: GenMessage<MaskingReason>;
+
/**
* @generated from message bytebase.v1.QueryRow
*/
diff --git a/frontend/src/types/proto-es/v1/sql_service_pb.js b/frontend/src/types/proto-es/v1/sql_service_pb.js
index aac828d483..4975103829 100644
--- a/frontend/src/types/proto-es/v1/sql_service_pb.js
+++ b/frontend/src/types/proto-es/v1/sql_service_pb.js
@@ -16,7 +16,7 @@ import { file_v1_database_service } from "./database_service_pb";
* Describes the file v1/sql_service.proto.
*/
export const file_v1_sql_service = /*@__PURE__*/
- fileDesc("ChR2MS9zcWxfc2VydmljZS5wcm90bxILYnl0ZWJhc2UudjEisQEKE0FkbWluRXhlY3V0ZVJlcXVlc3QSLAoEbmFtZRgBIAEoCUIe4kE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ZS52MS5DaGVja1Jlc3BvbnNlIjKK6jASYmIuZGF0YWJhc2VzLmNoZWNrkOowAYLT5JMCEjoBKiINL3YxL3NxbC9jaGVjaxJgCgZQcmV0dHkSGi5ieXRlYmFzZS52MS5QcmV0dHlSZXF1ZXN0GhsuYnl0ZWJhc2UudjEuUHJldHR5UmVzcG9uc2UiHYDqMAGC0+STAhM6ASoiDi92MS9zcWwvcHJldHR5EoEBCgxEaWZmTWV0YWRhdGESIC5ieXRlYmFzZS52MS5EaWZmTWV0YWRhdGFSZXF1ZXN0GiEuYnl0ZWJhc2UudjEuRGlmZk1ldGFkYXRhUmVzcG9uc2UiLIDqMAGC0+STAiI6ASoiHS92MS9zY2hlbWFEZXNpZ246ZGlmZk1ldGFkYXRhEngKDEFJQ29tcGxldGlvbhIgLmJ5dGViYXNlLnYxLkFJQ29tcGxldGlvblJlcXVlc3QaIS5ieXRlYmFzZS52MS5BSUNvbXBsZXRpb25SZXNwb25zZSIjkOowAoLT5JMCGToBKiIUL3YxL3NxbC9haUNvbXBsZXRpb25CNFoyZ2l0aHViLmNvbS9ieXRlYmFzZS9ieXRlYmFzZS9wcm90by9nZW5lcmF0ZWQtZ28vdjFiBnByb3RvMw", [file_google_api_annotations, file_google_api_field_behavior, file_google_api_resource, file_google_protobuf_duration, file_google_protobuf_struct, file_google_protobuf_timestamp, file_v1_annotation, file_v1_common, file_v1_database_catalog_service, file_v1_database_service]);
+ fileDesc("ChR2MS9zcWxfc2VydmljZS5wcm90bxILYnl0ZWJhc2UudjEisQEKE0FkbWluRXhlY3V0ZVJlcXVlc3QSLAoEbmFtZRgBIAEoCUIe4kEBAvpBFwoVYnl0ZWJhc2UuY29tL0RhdGFiYXNlEhEKCXN0YXRlbWVudBgDIAEoCRINCgVsaW1pdBgEIAEoBRITCgZzY2hlbWEYBiABKAlIAIgBARIWCgljb250YWluZXIYByABKAlIAYgBAUIJCgdfc2NoZW1hQgwKCl9jb250YWluZXJKBAgCEAMiQQoUQWRtaW5FeG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8qfTpleHBvcnQScgoFQ2hlY2sSGS5ieXRlYmFzZS52MS5DaGVja1JlcXVlc3QaGi5ieXRlYmFzZS52MS5DaGVja1Jlc3BvbnNlIjKK6jASYmIuZGF0YWJhc2VzLmNoZWNrkOowAYLT5JMCEjoBKiINL3YxL3NxbC9jaGVjaxJgCgZQcmV0dHkSGi5ieXRlYmFzZS52MS5QcmV0dHlSZXF1ZXN0GhsuYnl0ZWJhc2UudjEuUHJldHR5UmVzcG9uc2UiHYDqMAGC0+STAhM6ASoiDi92MS9zcWwvcHJldHR5EoEBCgxEaWZmTWV0YWRhdGESIC5ieXRlYmFzZS52MS5EaWZmTWV0YWRhdGFSZXF1ZXN0GiEuYnl0ZWJhc2UudjEuRGlmZk1ldGFkYXRhUmVzcG9uc2UiLIDqMAGC0+STAiI6ASoiHS92MS9zY2hlbWFEZXNpZ246ZGlmZk1ldGFkYXRhEngKDEFJQ29tcGxldGlvbhIgLmJ5dGViYXNlLnYxLkFJQ29tcGxldGlvblJlcXVlc3QaIS5ieXRlYmFzZS52MS5BSUNvbXBsZXRpb25SZXNwb25zZSIjkOowAoLT5JMCGToBKiIUL3YxL3NxbC9haUNvbXBsZXRpb25CNFoyZ2l0aHViLmNvbS9ieXRlYmFzZS9ieXRlYmFzZS9wcm90by9nZW5lcmF0ZWQtZ28vdjFiBnByb3RvMw", [file_google_api_annotations, file_google_api_field_behavior, file_google_api_resource, file_google_protobuf_duration, file_google_protobuf_struct, file_google_protobuf_timestamp, file_v1_annotation, file_v1_common, file_v1_database_catalog_service, file_v1_database_service]);
/**
* Describes the message bytebase.v1.AdminExecuteRequest.
@@ -98,46 +98,53 @@ export const QueryResult_Message_LevelSchema = /*@__PURE__*/
export const QueryResult_Message_Level = /*@__PURE__*/
tsEnum(QueryResult_Message_LevelSchema);
+/**
+ * Describes the message bytebase.v1.MaskingReason.
+ * Use `create(MaskingReasonSchema)` to create a new message.
+ */
+export const MaskingReasonSchema = /*@__PURE__*/
+ messageDesc(file_v1_sql_service, 6);
+
/**
* Describes the message bytebase.v1.QueryRow.
* Use `create(QueryRowSchema)` to create a new message.
*/
export const QueryRowSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 6);
+ messageDesc(file_v1_sql_service, 7);
/**
* Describes the message bytebase.v1.RowValue.
* Use `create(RowValueSchema)` to create a new message.
*/
export const RowValueSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 7);
+ messageDesc(file_v1_sql_service, 8);
/**
* Describes the message bytebase.v1.RowValue.Timestamp.
* Use `create(RowValue_TimestampSchema)` to create a new message.
*/
export const RowValue_TimestampSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 7, 0);
+ messageDesc(file_v1_sql_service, 8, 0);
/**
* Describes the message bytebase.v1.RowValue.TimestampTZ.
* Use `create(RowValue_TimestampTZSchema)` to create a new message.
*/
export const RowValue_TimestampTZSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 7, 1);
+ messageDesc(file_v1_sql_service, 8, 1);
/**
* Describes the message bytebase.v1.Advice.
* Use `create(AdviceSchema)` to create a new message.
*/
export const AdviceSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 8);
+ messageDesc(file_v1_sql_service, 9);
/**
* Describes the enum bytebase.v1.Advice.Status.
*/
export const Advice_StatusSchema = /*@__PURE__*/
- enumDesc(file_v1_sql_service, 8, 0);
+ enumDesc(file_v1_sql_service, 9, 0);
/**
* @generated from enum bytebase.v1.Advice.Status
@@ -150,41 +157,41 @@ export const Advice_Status = /*@__PURE__*/
* Use `create(ExportRequestSchema)` to create a new message.
*/
export const ExportRequestSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 9);
+ messageDesc(file_v1_sql_service, 10);
/**
* Describes the message bytebase.v1.ExportResponse.
* Use `create(ExportResponseSchema)` to create a new message.
*/
export const ExportResponseSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 10);
+ messageDesc(file_v1_sql_service, 11);
/**
* Describes the message bytebase.v1.PrettyRequest.
* Use `create(PrettyRequestSchema)` to create a new message.
*/
export const PrettyRequestSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 11);
+ messageDesc(file_v1_sql_service, 12);
/**
* Describes the message bytebase.v1.PrettyResponse.
* Use `create(PrettyResponseSchema)` to create a new message.
*/
export const PrettyResponseSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 12);
+ messageDesc(file_v1_sql_service, 13);
/**
* Describes the message bytebase.v1.CheckRequest.
* Use `create(CheckRequestSchema)` to create a new message.
*/
export const CheckRequestSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 13);
+ messageDesc(file_v1_sql_service, 14);
/**
* Describes the enum bytebase.v1.CheckRequest.ChangeType.
*/
export const CheckRequest_ChangeTypeSchema = /*@__PURE__*/
- enumDesc(file_v1_sql_service, 13, 0);
+ enumDesc(file_v1_sql_service, 14, 0);
/**
* @generated from enum bytebase.v1.CheckRequest.ChangeType
@@ -197,62 +204,62 @@ export const CheckRequest_ChangeType = /*@__PURE__*/
* Use `create(CheckResponseSchema)` to create a new message.
*/
export const CheckResponseSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 14);
+ messageDesc(file_v1_sql_service, 15);
/**
* Describes the message bytebase.v1.ParseMyBatisMapperRequest.
* Use `create(ParseMyBatisMapperRequestSchema)` to create a new message.
*/
export const ParseMyBatisMapperRequestSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 15);
+ messageDesc(file_v1_sql_service, 16);
/**
* Describes the message bytebase.v1.ParseMyBatisMapperResponse.
* Use `create(ParseMyBatisMapperResponseSchema)` to create a new message.
*/
export const ParseMyBatisMapperResponseSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 16);
+ messageDesc(file_v1_sql_service, 17);
/**
* Describes the message bytebase.v1.DiffMetadataRequest.
* Use `create(DiffMetadataRequestSchema)` to create a new message.
*/
export const DiffMetadataRequestSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 17);
+ messageDesc(file_v1_sql_service, 18);
/**
* Describes the message bytebase.v1.DiffMetadataResponse.
* Use `create(DiffMetadataResponseSchema)` to create a new message.
*/
export const DiffMetadataResponseSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 18);
+ messageDesc(file_v1_sql_service, 19);
/**
* Describes the message bytebase.v1.SearchQueryHistoriesRequest.
* Use `create(SearchQueryHistoriesRequestSchema)` to create a new message.
*/
export const SearchQueryHistoriesRequestSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 19);
+ messageDesc(file_v1_sql_service, 20);
/**
* Describes the message bytebase.v1.SearchQueryHistoriesResponse.
* Use `create(SearchQueryHistoriesResponseSchema)` to create a new message.
*/
export const SearchQueryHistoriesResponseSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 20);
+ messageDesc(file_v1_sql_service, 21);
/**
* Describes the message bytebase.v1.QueryHistory.
* Use `create(QueryHistorySchema)` to create a new message.
*/
export const QueryHistorySchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 21);
+ messageDesc(file_v1_sql_service, 22);
/**
* Describes the enum bytebase.v1.QueryHistory.Type.
*/
export const QueryHistory_TypeSchema = /*@__PURE__*/
- enumDesc(file_v1_sql_service, 21, 0);
+ enumDesc(file_v1_sql_service, 22, 0);
/**
* @generated from enum bytebase.v1.QueryHistory.Type
@@ -265,42 +272,42 @@ export const QueryHistory_Type = /*@__PURE__*/
* Use `create(AICompletionRequestSchema)` to create a new message.
*/
export const AICompletionRequestSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 22);
+ messageDesc(file_v1_sql_service, 23);
/**
* Describes the message bytebase.v1.AICompletionRequest.Message.
* Use `create(AICompletionRequest_MessageSchema)` to create a new message.
*/
export const AICompletionRequest_MessageSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 22, 0);
+ messageDesc(file_v1_sql_service, 23, 0);
/**
* Describes the message bytebase.v1.AICompletionResponse.
* Use `create(AICompletionResponseSchema)` to create a new message.
*/
export const AICompletionResponseSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 23);
+ messageDesc(file_v1_sql_service, 24);
/**
* Describes the message bytebase.v1.AICompletionResponse.Candidate.
* Use `create(AICompletionResponse_CandidateSchema)` to create a new message.
*/
export const AICompletionResponse_CandidateSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 23, 0);
+ messageDesc(file_v1_sql_service, 24, 0);
/**
* Describes the message bytebase.v1.AICompletionResponse.Candidate.Content.
* Use `create(AICompletionResponse_Candidate_ContentSchema)` to create a new message.
*/
export const AICompletionResponse_Candidate_ContentSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 23, 0, 0);
+ messageDesc(file_v1_sql_service, 24, 0, 0);
/**
* Describes the message bytebase.v1.AICompletionResponse.Candidate.Content.Part.
* Use `create(AICompletionResponse_Candidate_Content_PartSchema)` to create a new message.
*/
export const AICompletionResponse_Candidate_Content_PartSchema = /*@__PURE__*/
- messageDesc(file_v1_sql_service, 23, 0, 0, 0);
+ messageDesc(file_v1_sql_service, 24, 0, 0, 0);
/**
* @generated from service bytebase.v1.SQLService
diff --git a/frontend/src/views/sql-editor/EditorCommon/ResultView/DataBlock.vue b/frontend/src/views/sql-editor/EditorCommon/ResultView/DataBlock.vue
index d15c674c6d..1647b20269 100644
--- a/frontend/src/views/sql-editor/EditorCommon/ResultView/DataBlock.vue
+++ b/frontend/src/views/sql-editor/EditorCommon/ResultView/DataBlock.vue
@@ -19,15 +19,14 @@
>
<div class="min-w-[7rem] text-left flex items-center font-medium">
{{ header.column.columnDef.header }}
- <SensitiveDataIcon
- v-if="isSensitiveColumn(header.index)"
+ <MaskingReasonPopover
+ v-if="getMaskingReason && getMaskingReason(header.index)"
+ :reason="getMaskingReason(header.index)"
class="ml-0.5 shrink-0"
/>
- <FeatureBadge
- v-else-if="isColumnMissingSensitive(header.index)"
- :feature="PlanFeature.FEATURE_DATA_MASKING"
+ <SensitiveDataIcon
+ v-else-if="isSensitiveColumn(header.index)"
class="ml-0.5 shrink-0"
- :instance="database.instanceResource"
/>
:
</div>
@@ -57,11 +56,9 @@
import type { Table } from "@tanstack/vue-table";
import { NScrollbar } from "naive-ui";
import { computed, watch, ref } from "vue";
-import { FeatureBadge } from "@/components/FeatureGuard";
-import { useConnectionOfCurrentSQLEditorTab } from "@/store";
import type { QueryRow, RowValue } from "@/types/proto-es/v1/sql_service_pb";
-import { PlanFeature } from "@/types/proto-es/v1/subscription_service_pb";
import TableCell from "./DataTable/TableCell.vue";
+import MaskingReasonPopover from "./DataTable/common/MaskingReasonPopover.vue";
import SensitiveDataIcon from "./DataTable/common/SensitiveDataIcon.vue";
import { getColumnType } from "./DataTable/common/utils";
import { useSQLResultViewContext } from "./context";
@@ -71,11 +68,10 @@ const props = defineProps<{
setIndex: number;
offset: number;
isSensitiveColumn: (index: number) => boolean;
- isColumnMissingSensitive: (index: number) => boolean;
+ getMaskingReason?: (index: number) => any;
}>();
const { keyword } = useSQLResultViewContext();
-const { database } = useConnectionOfCurrentSQLEditorTab();
const scrollbarRef = ref<InstanceType<typeof NScrollbar>>();
const rows = computed(() => props.table.getRowModel().rows);
diff --git a/frontend/src/views/sql-editor/EditorCommon/ResultView/DataTable/DataTable.vue b/frontend/src/views/sql-editor/EditorCommon/ResultView/DataTable/DataTable.vue
index 7575b27bcd..e98e624274 100644
--- a/frontend/src/views/sql-editor/EditorCommon/ResultView/DataTable/DataTable.vue
+++ b/frontend/src/views/sql-editor/EditorCommon/ResultView/DataTable/DataTable.vue
@@ -40,15 +40,14 @@
<br v-else class="min-h-[1rem] inline-flex" />
</span>
- <SensitiveDataIcon
- v-if="isSensitiveColumn(header.index)"
+ <MaskingReasonPopover
+ v-if="getMaskingReason && getMaskingReason(header.index)"
+ :reason="getMaskingReason(header.index)"
class="ml-0.5 shrink-0"
/>
- <FeatureBadge
- v-else-if="isColumnMissingSensitive(header.index)"
- :feature="PlanFeature.FEATURE_DATA_MASKING"
+ <SensitiveDataIcon
+ v-else-if="isSensitiveColumn(header.index)"
class="ml-0.5 shrink-0"
- :instance="database.instanceResource"
/>
<ColumnSortedIcon
@@ -141,13 +140,10 @@
import type { Table } from "@tanstack/vue-table";
import { NEmpty } from "naive-ui";
import { computed, nextTick, onMounted, ref, watch } from "vue";
-import { FeatureBadge } from "@/components/FeatureGuard";
-import { useConnectionOfCurrentSQLEditorTab } from "@/store";
import {
type QueryRow,
type RowValue,
} from "@/types/proto-es/v1/sql_service_pb";
-import { PlanFeature } from "@/types/proto-es/v1/subscription_service_pb";
import { useSQLResultViewContext } from "../context";
import TableCell from "./TableCell.vue";
import {
@@ -157,6 +153,7 @@ import {
} from "./binary-format-store";
import BinaryFormatButton from "./common/BinaryFormatButton.vue";
import ColumnSortedIcon from "./common/ColumnSortedIcon.vue";
+import MaskingReasonPopover from "./common/MaskingReasonPopover.vue";
import SensitiveDataIcon from "./common/SensitiveDataIcon.vue";
import { useSelectionContext } from "./common/selection-logic";
import { getColumnType } from "./common/utils";
@@ -167,7 +164,7 @@ const props = defineProps<{
setIndex: number;
offset: number;
isSensitiveColumn: (index: number) => boolean;
- isColumnMissingSensitive: (index: number) => boolean;
+ getMaskingReason?: (index: number) => any;
maxHeight?: number;
}>();
@@ -190,7 +187,6 @@ const tableResize = useTableColumnWidthLogic({
const { getBinaryFormat, setBinaryFormat } = useBinaryFormatContext();
const { keyword } = useSQLResultViewContext();
-const { database } = useConnectionOfCurrentSQLEditorTab();
const rows = computed(() => props.table.getRowModel().rows);
const columns = computed(() => props.table.getFlatHeaders());
diff --git a/frontend/src/views/sql-editor/EditorCommon/ResultView/DataTable/common/MaskingReasonPopover.vue b/frontend/src/views/sql-editor/EditorCommon/ResultView/DataTable/common/MaskingReasonPopover.vue
new file mode 100644
index 0000000000..8e13b101d9
--- /dev/null
+++ b/frontend/src/views/sql-editor/EditorCommon/ResultView/DataTable/common/MaskingReasonPopover.vue
@@ -0,0 +1,86 @@
+<template>
+ <NPopover trigger="hover" :delay="100">
+ <template #trigger>
+ <div class="inline-flex items-center gap-0.5">
+ <!-- Show semantic type icon if available -->
+ <img
+ v-if="props.reason.semanticTypeIcon"
+ :src="props.reason.semanticTypeIcon"
+ class="w-3 h-3 object-contain"
+ alt=""
+ />
+ <heroicons:eye-slash
+ class="w-3 h-3 cursor-pointer text-gray-500 hover:text-gray-700"
+ @click="handleClick"
+ />
+ </div>
+ </template>
+ <div class="space-y-2 max-w-sm">
+ <div class="font-medium flex items-center gap-2">
+ <img
+ v-if="props.reason.semanticTypeIcon"
+ :src="props.reason.semanticTypeIcon"
+ class="w-4 h-4 object-contain"
+ alt=""
+ />
+ {{ $t("masking.reason.title") }}
+ </div>
+
+ <div v-if="props.reason.semanticTypeTitle" class="text-sm">
+ <span class="text-gray-500"
+ >{{ $t("masking.reason.semantic-type") }}:</span
+ >
+ <span class="ml-1">{{ props.reason.semanticTypeTitle }}</span>
+ </div>
+
+ <div v-if="props.reason.algorithm" class="text-sm">
+ <span class="text-gray-500">{{ $t("masking.reason.algorithm") }}:</span>
+ <span class="ml-1">{{ formatAlgorithm(props.reason.algorithm) }}</span>
+ </div>
+
+ <div v-if="props.reason.context" class="text-sm">
+ <span class="text-gray-500">{{ $t("masking.reason.context") }}:</span>
+ <span class="ml-1">{{ props.reason.context }}</span>
+ </div>
+
+ <div v-if="props.reason.classificationLevel" class="text-sm">
+ <span class="text-gray-500"
+ >{{ $t("masking.reason.classification") }}:</span
+ >
+ <span class="ml-1">{{ props.reason.classificationLevel }}</span>
+ </div>
+ </div>
+ </NPopover>
+</template>
+
+<script setup lang="ts">
+import { NPopover } from "naive-ui";
+import { useI18n } from "vue-i18n";
+import type { MaskingReason } from "@/types/proto-es/v1/sql_service_pb";
+
+const props = defineProps<{
+ reason: MaskingReason;
+}>();
+
+const emit = defineEmits<{
+ (event: "click"): void;
+}>();
+
+const { t } = useI18n();
+
+const formatAlgorithm = (algorithm: string): string => {
+ const algorithmKey = algorithm.toLowerCase().replace(/\s+/g, "-");
+ const key = `masking.algorithms.${algorithmKey}`;
+ // Check if translation exists
+ const translated = t(key);
+ if (translated === key) {
+ // If no translation found, return original
+ return algorithm;
+ }
+ return translated;
+};
+
+const handleClick = () => {
+ emit("click");
+};
+</script>
diff --git a/frontend/src/views/sql-editor/EditorCommon/ResultView/SingleResultViewV1.vue b/frontend/src/views/sql-editor/EditorCommon/ResultView/SingleResultViewV1.vue
index a64dd6db99..2ead13b774 100644
--- a/frontend/src/views/sql-editor/EditorCommon/ResultView/SingleResultViewV1.vue
+++ b/frontend/src/views/sql-editor/EditorCommon/ResultView/SingleResultViewV1.vue
@@ -128,7 +128,7 @@
:set-index="setIndex"
:offset="pageIndex * pageSize"
:is-sensitive-column="isSensitiveColumn"
- :is-column-missing-sensitive="isColumnMissingSensitive"
+ :get-masking-reason="getMaskingReason"
/>
<DataTable
v-else
@@ -136,7 +136,7 @@
:set-index="setIndex"
:offset="pageIndex * pageSize"
:is-sensitive-column="isSensitiveColumn"
- :is-column-missing-sensitive="isColumnMissingSensitive"
+ :get-masking-reason="getMaskingReason"
/>
</div>
@@ -421,16 +421,28 @@ const data = computed(() => {
});
const isSensitiveColumn = (columnIndex: number): boolean => {
- return props.result.masked[columnIndex] ?? false;
-};
-
-const isColumnMissingSensitive = (columnIndex: number): boolean => {
+ const maskingReason = props.result.masked?.[columnIndex];
+ // Check if maskingReason exists and has actual content (not empty object)
return (
- (props.result.sensitive[columnIndex] ?? false) &&
- !isSensitiveColumn(columnIndex)
+ maskingReason !== null &&
+ maskingReason !== undefined &&
+ maskingReason.semanticTypeId !== undefined &&
+ maskingReason.semanticTypeId !== ""
);
};
+const getMaskingReason = (columnIndex: number) => {
+ if (!props.result.masked || columnIndex >= props.result.masked.length) {
+ return undefined;
+ }
+ const reason = props.result.masked[columnIndex];
+ // Return undefined for empty masking reasons
+ if (!reason || !reason.semanticTypeId) {
+ return undefined;
+ }
+ return reason;
+};
+
const table = useVueTable<QueryRow>({
get data() {
return data.value;
diff --git a/proto/gen/grpc-doc/openapi.yaml b/proto/gen/grpc-doc/openapi.yaml
index f27a265f78..90280d7991 100644
--- a/proto/gen/grpc-doc/openapi.yaml
+++ b/proto/gen/grpc-doc/openapi.yaml
@@ -11308,6 +11308,30 @@ components:
LogoutRequest:
type: object
properties: {}
+ MaskingReason:
+ type: object
+ properties:
+ semanticTypeId:
+ type: string
+ description: The semantic type that triggered masking (e.g., "SSN", "email", "phone").
+ semanticTypeTitle:
+ type: string
+ description: Human-readable semantic type title.
+ maskingRuleId:
+ type: string
+ description: The masking rule ID that matched (if applicable).
+ algorithm:
+ type: string
+ description: The masking algorithm used.
+ context:
+ type: string
+ description: 'Additional context (e.g., "Matched global rule: PII Protection").'
+ classificationLevel:
+ type: string
+ description: Whether masking was due to classification level.
+ semanticTypeIcon:
+ type: string
+ description: Icon associated with the semantic type (if any).
OAuth2IdentityProviderConfig:
type: object
properties:
@@ -12024,16 +12048,6 @@ components:
description: Rows of the query result.
rowsCount:
type: string
- masked:
- type: array
- items:
- type: boolean
- description: Columns are masked or not.
- sensitive:
- type: array
- items:
- type: boolean
- description: Columns are sensitive or not.
error:
type: string
description: The error message if the query failed.
@@ -12056,6 +12070,11 @@ components:
description: |-
Informational or debug messages returned by the database engine during query execution.
Examples include PostgreSQL's RAISE NOTICE, MSSQL's PRINT, or Oracle's DBMS_OUTPUT.PUT_LINE.
+ masked:
+ type: array
+ items:
+ $ref: '#/components/schemas/MaskingReason'
+ description: Masking reasons for each column (empty for non-masked columns).
QueryResult_Message:
type: object
properties:
@@ -13259,6 +13278,9 @@ components:
description: the description of the semantic type, it can be empty.
algorithm:
$ref: '#/components/schemas/Algorithm'
+ icon:
+ type: string
+ description: icon is the icon for semantic type, it can be emoji or base64 encoded image.
SetIamPolicyRequest:
required:
- resource
diff --git a/proto/gen/grpc-doc/store/README.md b/proto/gen/grpc-doc/store/README.md
index 5b4f0566cf..010aee3fcd 100644
--- a/proto/gen/grpc-doc/store/README.md
+++ b/proto/gen/grpc-doc/store/README.md
@@ -4446,6 +4446,7 @@ RestrictIssueCreationForSQLReviewPolicy is the policy configuration for restrict
| title | [string](#string) | | the title of the semantic type, it should not be empty. |
| description | [string](#string) | | the description of the semantic type, it can be empty. |
| algorithm | [Algorithm](#bytebase-store-Algorithm) | | |
+| icon | [string](#string) | | icon is the icon for semantic type, it can be emoji or base64 encoded image. |
diff --git a/proto/gen/grpc-doc/store/index.html b/proto/gen/grpc-doc/store/index.html
index 149753f023..e0191238fd 100644
--- a/proto/gen/grpc-doc/store/index.html
+++ b/proto/gen/grpc-doc/store/index.html
@@ -11548,6 +11548,13 @@ The default value is -1, means no limit. </p></td>
<td><p> </p></td>
</tr>
+ <tr>
+ <td>icon</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>icon is the icon for semantic type, it can be emoji or base64 encoded image. </p></td>
+ </tr>
+
</tbody>
</table>
diff --git a/proto/gen/grpc-doc/v1/README.md b/proto/gen/grpc-doc/v1/README.md
index 8a566ecbb2..e491b53e67 100644
--- a/proto/gen/grpc-doc/v1/README.md
+++ b/proto/gen/grpc-doc/v1/README.md
@@ -504,6 +504,7 @@
- [DiffMetadataResponse](#bytebase-v1-DiffMetadataResponse)
- [ExportRequest](#bytebase-v1-ExportRequest)
- [ExportResponse](#bytebase-v1-ExportResponse)
+ - [MaskingReason](#bytebase-v1-MaskingReason)
- [ParseMyBatisMapperRequest](#bytebase-v1-ParseMyBatisMapperRequest)
- [ParseMyBatisMapperResponse](#bytebase-v1-ParseMyBatisMapperResponse)
- [PrettyRequest](#bytebase-v1-PrettyRequest)
@@ -4558,6 +4559,7 @@ When paginating, all other parameters provided to `ListSettings` must match the
| title | [string](#string) | | the title of the semantic type, it should not be empty. |
| description | [string](#string) | | the description of the semantic type, it can be empty. |
| algorithm | [Algorithm](#bytebase-v1-Algorithm) | | |
+| icon | [string](#string) | | icon is the icon for semantic type, it can be emoji or base64 encoded image. |
@@ -8347,6 +8349,27 @@ ISSUE_CREATE represents creating an issue. |
+<a name="bytebase-v1-MaskingReason"></a>
+
+### MaskingReason
+
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| semantic_type_id | [string](#string) | | The semantic type that triggered masking (e.g., &#34;SSN&#34;, &#34;email&#34;, &#34;phone&#34;). |
+| semantic_type_title | [string](#string) | | Human-readable semantic type title. |
+| masking_rule_id | [string](#string) | | The masking rule ID that matched (if applicable). |
+| algorithm | [string](#string) | | The masking algorithm used. |
+| context | [string](#string) | | Additional context (e.g., &#34;Matched global rule: PII Protection&#34;). |
+| classification_level | [string](#string) | | Whether masking was due to classification level. |
+| semantic_type_icon | [string](#string) | | Icon associated with the semantic type (if any). |
+
+
+
+
+
+
<a name="bytebase-v1-ParseMyBatisMapperRequest"></a>
### ParseMyBatisMapperRequest
@@ -8496,14 +8519,13 @@ ISSUE_CREATE represents creating an issue. |
| column_type_names | [string](#string) | repeated | Column types of the query result. The types come from the Golang SQL driver. |
| rows | [QueryRow](#bytebase-v1-QueryRow) | repeated | Rows of the query result. |
| rows_count | [int64](#int64) | | |
-| masked | [bool](#bool) | repeated | Columns are masked or not. |
-| sensitive | [bool](#bool) | repeated | Columns are sensitive or not. |
| error | [string](#string) | | The error message if the query failed. |
| latency | [google.protobuf.Duration](#google-protobuf-Duration) | | The time it takes to execute the query. |
| statement | [string](#string) | | The query statement for the result. |
| postgres_error | [QueryResult.PostgresError](#bytebase-v1-QueryResult-PostgresError) | | |
| allow_export | [bool](#bool) | | The query result is allowed to be exported or not. |
| messages | [QueryResult.Message](#bytebase-v1-QueryResult-Message) | repeated | Informational or debug messages returned by the database engine during query execution. Examples include PostgreSQL&#39;s RAISE NOTICE, MSSQL&#39;s PRINT, or Oracle&#39;s DBMS_OUTPUT.PUT_LINE. |
+| masked | [MaskingReason](#bytebase-v1-MaskingReason) | repeated | Masking reasons for each column (empty for non-masked columns). |
diff --git a/proto/gen/grpc-doc/v1/index.html b/proto/gen/grpc-doc/v1/index.html
index e83669ffa6..8598cde28a 100644
--- a/proto/gen/grpc-doc/v1/index.html
+++ b/proto/gen/grpc-doc/v1/index.html
@@ -2105,6 +2105,10 @@
<a href="#bytebase.v1.ExportResponse"><span class="badge">M</span>ExportResponse</a>
</li>
+ <li>
+ <a href="#bytebase.v1.MaskingReason"><span class="badge">M</span>MaskingReason</a>
+ </li>
+
<li>
<a href="#bytebase.v1.ParseMyBatisMapperRequest"><span class="badge">M</span>ParseMyBatisMapperRequest</a>
</li>
@@ -13271,6 +13275,13 @@ The default value is -1. </p></td>
<td><p> </p></td>
</tr>
+ <tr>
+ <td>icon</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>icon is the icon for semantic type, it can be emoji or base64 encoded image. </p></td>
+ </tr>
+
</tbody>
</table>
@@ -23212,6 +23223,72 @@ data source. </p></td>
+ <h3 id="bytebase.v1.MaskingReason">MaskingReason</h3>
+ <p></p>
+
+
+ <table class="field-table">
+ <thead>
+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>
+ </thead>
+ <tbody>
+
+ <tr>
+ <td>semantic_type_id</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>The semantic type that triggered masking (e.g., &#34;SSN&#34;, &#34;email&#34;, &#34;phone&#34;). </p></td>
+ </tr>
+
+ <tr>
+ <td>semantic_type_title</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>Human-readable semantic type title. </p></td>
+ </tr>
+
+ <tr>
+ <td>masking_rule_id</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>The masking rule ID that matched (if applicable). </p></td>
+ </tr>
+
+ <tr>
+ <td>algorithm</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>The masking algorithm used. </p></td>
+ </tr>
+
+ <tr>
+ <td>context</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>Additional context (e.g., &#34;Matched global rule: PII Protection&#34;). </p></td>
+ </tr>
+
+ <tr>
+ <td>classification_level</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>Whether masking was due to classification level. </p></td>
+ </tr>
+
+ <tr>
+ <td>semantic_type_icon</td>
+ <td><a href="#string">string</a></td>
+ <td></td>
+ <td><p>Icon associated with the semantic type (if any). </p></td>
+ </tr>
+
+ </tbody>
+ </table>
+
+
+
+
+
<h3 id="bytebase.v1.ParseMyBatisMapperRequest">ParseMyBatisMapperRequest</h3>
<p></p>
@@ -23573,20 +23650,6 @@ The types come from the Golang SQL driver. </p></td>
<td><p> </p></td>
</tr>
- <tr>
- <td>masked</td>
- <td><a href="#bool">bool</a></td>
- <td>repeated</td>
- <td><p>Columns are masked or not. </p></td>
- </tr>
-
- <tr>
- <td>sensitive</td>
- <td><a href="#bool">bool</a></td>
- <td>repeated</td>
- <td><p>Columns are sensitive or not. </p></td>
- </tr>
-
<tr>
<td>error</td>
<td><a href="#string">string</a></td>
@@ -23630,6 +23693,13 @@ The types come from the Golang SQL driver. </p></td>
Examples include PostgreSQL&#39;s RAISE NOTICE, MSSQL&#39;s PRINT, or Oracle&#39;s DBMS_OUTPUT.PUT_LINE. </p></td>
</tr>
+ <tr>
+ <td>masked</td>
+ <td><a href="#bytebase.v1.MaskingReason">MaskingReason</a></td>
+ <td>repeated</td>
+ <td><p>Masking reasons for each column (empty for non-masked columns). </p></td>
+ </tr>
+
</tbody>
</table>
diff --git a/proto/generated-go/store/setting.pb.go b/proto/generated-go/store/setting.pb.go
index 97d4eaf22d..70779e331a 100644
--- a/proto/generated-go/store/setting.pb.go
+++ b/proto/generated-go/store/setting.pb.go
@@ -1718,8 +1718,10 @@ type SemanticTypeSetting_SemanticType struct {
// the title of the semantic type, it should not be empty.
Title string `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty"`
// the description of the semantic type, it can be empty.
- Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
- Algorithm *Algorithm `protobuf:"bytes,6,opt,name=algorithm,proto3" json:"algorithm,omitempty"`
+ Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
+ Algorithm *Algorithm `protobuf:"bytes,6,opt,name=algorithm,proto3" json:"algorithm,omitempty"`
+ // icon is the icon for semantic type, it can be emoji or base64 encoded image.
+ Icon string `protobuf:"bytes,7,opt,name=icon,proto3" json:"icon,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
@@ -1782,6 +1784,13 @@ func (x *SemanticTypeSetting_SemanticType) GetAlgorithm() *Algorithm {
return nil
}
+func (x *SemanticTypeSetting_SemanticType) GetIcon() string {
+ if x != nil {
+ return x.Icon
+ }
+ return ""
+}
+
type Algorithm_FullMask struct {
state protoimpl.MessageState `protogen:"open.v1"`
// substitution is the string used to replace the original value, the
@@ -2507,14 +2516,15 @@ const file_store_setting_proto_rawDesc = "" +
"\t_level_id\x1a\x98\x01\n" +
"\x13ClassificationEntry\x12\x10\n" +
"\x03key\x18\x01 \x01(\tR\x03key\x12k\n" +
- "\x05value\x18\x02 \x01(\v2U.bytebase.store.DataClassificationSetting.DataClassificationConfig.DataClassificationR\x05value:\x028\x01\"\xef\x01\n" +
+ "\x05value\x18\x02 \x01(\v2U.bytebase.store.DataClassificationSetting.DataClassificationConfig.DataClassificationR\x05value:\x028\x01\"\x83\x02\n" +
"\x13SemanticTypeSetting\x12F\n" +
- "\x05types\x18\x01 \x03(\v20.bytebase.store.SemanticTypeSetting.SemanticTypeR\x05types\x1a\x8f\x01\n" +
+ "\x05types\x18\x01 \x03(\v20.bytebase.store.SemanticTypeSetting.SemanticTypeR\x05types\x1a\xa3\x01\n" +
"\fSemanticType\x12\x0e\n" +
"\x02id\x18\x01 \x01(\tR\x02id\x12\x14\n" +
"\x05title\x18\x02 \x01(\tR\x05title\x12 \n" +
"\vdescription\x18\x03 \x01(\tR\vdescription\x127\n" +
- "\talgorithm\x18\x06 \x01(\v2\x19.bytebase.store.AlgorithmR\talgorithm\"\xa0\x06\n" +
+ "\talgorithm\x18\x06 \x01(\v2\x19.bytebase.store.AlgorithmR\talgorithm\x12\x12\n" +
+ "\x04icon\x18\a \x01(\tR\x04icon\"\xa0\x06\n" +
"\tAlgorithm\x12A\n" +
"\tfull_mask\x18\x05 \x01(\v2\".bytebase.store.Algorithm.FullMaskH\x00R\bfullMask\x12D\n" +
"\n" +
diff --git a/proto/generated-go/v1/setting_service.pb.go b/proto/generated-go/v1/setting_service.pb.go
index f02cc267ea..fc1d90ed37 100644
--- a/proto/generated-go/v1/setting_service.pb.go
+++ b/proto/generated-go/v1/setting_service.pb.go
@@ -2613,8 +2613,10 @@ type SemanticTypeSetting_SemanticType struct {
// the title of the semantic type, it should not be empty.
Title string `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty"`
// the description of the semantic type, it can be empty.
- Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
- Algorithm *Algorithm `protobuf:"bytes,6,opt,name=algorithm,proto3" json:"algorithm,omitempty"`
+ Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
+ Algorithm *Algorithm `protobuf:"bytes,6,opt,name=algorithm,proto3" json:"algorithm,omitempty"`
+ // icon is the icon for semantic type, it can be emoji or base64 encoded image.
+ Icon string `protobuf:"bytes,7,opt,name=icon,proto3" json:"icon,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
@@ -2677,6 +2679,13 @@ func (x *SemanticTypeSetting_SemanticType) GetAlgorithm() *Algorithm {
return nil
}
+func (x *SemanticTypeSetting_SemanticType) GetIcon() string {
+ if x != nil {
+ return x.Icon
+ }
+ return ""
+}
+
type Algorithm_FullMask struct {
state protoimpl.MessageState `protogen:"open.v1"`
// substitution is the string used to replace the original value, the
@@ -3191,14 +3200,15 @@ const file_v1_setting_service_proto_rawDesc = "" +
"\t_level_id\x1a\x95\x01\n" +
"\x13ClassificationEntry\x12\x10\n" +
"\x03key\x18\x01 \x01(\tR\x03key\x12h\n" +
- "\x05value\x18\x02 \x01(\v2R.bytebase.v1.DataClassificationSetting.DataClassificationConfig.DataClassificationR\x05value:\x028\x01\"\xe9\x01\n" +
+ "\x05value\x18\x02 \x01(\v2R.bytebase.v1.DataClassificationSetting.DataClassificationConfig.DataClassificationR\x05value:\x028\x01\"\xfd\x01\n" +
"\x13SemanticTypeSetting\x12C\n" +
- "\x05types\x18\x01 \x03(\v2-.bytebase.v1.SemanticTypeSetting.SemanticTypeR\x05types\x1a\x8c\x01\n" +
+ "\x05types\x18\x01 \x03(\v2-.bytebase.v1.SemanticTypeSetting.SemanticTypeR\x05types\x1a\xa0\x01\n" +
"\fSemanticType\x12\x0e\n" +
"\x02id\x18\x01 \x01(\tR\x02id\x12\x14\n" +
"\x05title\x18\x02 \x01(\tR\x05title\x12 \n" +
"\vdescription\x18\x03 \x01(\tR\vdescription\x124\n" +
- "\talgorithm\x18\x06 \x01(\v2\x16.bytebase.v1.AlgorithmR\talgorithm\"\x8e\x06\n" +
+ "\talgorithm\x18\x06 \x01(\v2\x16.bytebase.v1.AlgorithmR\talgorithm\x12\x12\n" +
+ "\x04icon\x18\a \x01(\tR\x04icon\"\x8e\x06\n" +
"\tAlgorithm\x12>\n" +
"\tfull_mask\x18\x05 \x01(\v2\x1f.bytebase.v1.Algorithm.FullMaskH\x00R\bfullMask\x12A\n" +
"\n" +
diff --git a/proto/generated-go/v1/sql_service.pb.go b/proto/generated-go/v1/sql_service.pb.go
index 48a080996e..b5ab695a3e 100644
--- a/proto/generated-go/v1/sql_service.pb.go
+++ b/proto/generated-go/v1/sql_service.pb.go
@@ -187,7 +187,7 @@ func (x Advice_Status) Number() protoreflect.EnumNumber {
// Deprecated: Use Advice_Status.Descriptor instead.
func (Advice_Status) EnumDescriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{8, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{9, 0}
}
type CheckRequest_ChangeType int32
@@ -242,7 +242,7 @@ func (x CheckRequest_ChangeType) Number() protoreflect.EnumNumber {
// Deprecated: Use CheckRequest_ChangeType.Descriptor instead.
func (CheckRequest_ChangeType) EnumDescriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{13, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{14, 0}
}
type QueryHistory_Type int32
@@ -291,7 +291,7 @@ func (x QueryHistory_Type) Number() protoreflect.EnumNumber {
// Deprecated: Use QueryHistory_Type.Descriptor instead.
func (QueryHistory_Type) EnumDescriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{21, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{22, 0}
}
type AdminExecuteRequest struct {
@@ -635,10 +635,6 @@ type QueryResult struct {
// Rows of the query result.
Rows []*QueryRow `protobuf:"bytes,3,rep,name=rows,proto3" json:"rows,omitempty"`
RowsCount int64 `protobuf:"varint,10,opt,name=rows_count,json=rowsCount,proto3" json:"rows_count,omitempty"`
- // Columns are masked or not.
- Masked []bool `protobuf:"varint,4,rep,packed,name=masked,proto3" json:"masked,omitempty"`
- // Columns are sensitive or not.
- Sensitive []bool `protobuf:"varint,5,rep,packed,name=sensitive,proto3" json:"sensitive,omitempty"`
// The error message if the query failed.
Error string `protobuf:"bytes,6,opt,name=error,proto3" json:"error,omitempty"`
// The time it takes to execute the query.
@@ -653,7 +649,9 @@ type QueryResult struct {
AllowExport bool `protobuf:"varint,11,opt,name=allow_export,json=allowExport,proto3" json:"allow_export,omitempty"`
// Informational or debug messages returned by the database engine during query execution.
// Examples include PostgreSQL's RAISE NOTICE, MSSQL's PRINT, or Oracle's DBMS_OUTPUT.PUT_LINE.
- Messages []*QueryResult_Message `protobuf:"bytes,12,rep,name=messages,proto3" json:"messages,omitempty"`
+ Messages []*QueryResult_Message `protobuf:"bytes,12,rep,name=messages,proto3" json:"messages,omitempty"`
+ // Masking reasons for each column (empty for non-masked columns).
+ Masked []*MaskingReason `protobuf:"bytes,4,rep,name=masked,proto3" json:"masked,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
@@ -716,20 +714,6 @@ func (x *QueryResult) GetRowsCount() int64 {
return 0
}
-func (x *QueryResult) GetMasked() []bool {
- if x != nil {
- return x.Masked
- }
- return nil
-}
-
-func (x *QueryResult) GetSensitive() []bool {
- if x != nil {
- return x.Sensitive
- }
- return nil
-}
-
func (x *QueryResult) GetError() string {
if x != nil {
return x.Error
@@ -781,6 +765,13 @@ func (x *QueryResult) GetMessages() []*QueryResult_Message {
return nil
}
+func (x *QueryResult) GetMasked() []*MaskingReason {
+ if x != nil {
+ return x.Masked
+ }
+ return nil
+}
+
type isQueryResult_DetailedError interface {
isQueryResult_DetailedError()
}
@@ -791,6 +782,105 @@ type QueryResult_PostgresError_ struct {
func (*QueryResult_PostgresError_) isQueryResult_DetailedError() {}
+type MaskingReason struct {
+ state protoimpl.MessageState `protogen:"open.v1"`
+ // The semantic type that triggered masking (e.g., "SSN", "email", "phone").
+ SemanticTypeId string `protobuf:"bytes,1,opt,name=semantic_type_id,json=semanticTypeId,proto3" json:"semantic_type_id,omitempty"`
+ // Human-readable semantic type title.
+ SemanticTypeTitle string `protobuf:"bytes,2,opt,name=semantic_type_title,json=semanticTypeTitle,proto3" json:"semantic_type_title,omitempty"`
+ // The masking rule ID that matched (if applicable).
+ MaskingRuleId string `protobuf:"bytes,3,opt,name=masking_rule_id,json=maskingRuleId,proto3" json:"masking_rule_id,omitempty"`
+ // The masking algorithm used.
+ Algorithm string `protobuf:"bytes,4,opt,name=algorithm,proto3" json:"algorithm,omitempty"`
+ // Additional context (e.g., "Matched global rule: PII Protection").
+ Context string `protobuf:"bytes,5,opt,name=context,proto3" json:"context,omitempty"`
+ // Whether masking was due to classification level.
+ ClassificationLevel string `protobuf:"bytes,6,opt,name=classification_level,json=classificationLevel,proto3" json:"classification_level,omitempty"`
+ // Icon associated with the semantic type (if any).
+ SemanticTypeIcon string `protobuf:"bytes,7,opt,name=semantic_type_icon,json=semanticTypeIcon,proto3" json:"semantic_type_icon,omitempty"`
+ unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
+}
+
+func (x *MaskingReason) Reset() {
+ *x = MaskingReason{}
+ mi := &file_v1_sql_service_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+}
+
+func (x *MaskingReason) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*MaskingReason) ProtoMessage() {}
+
+func (x *MaskingReason) ProtoReflect() protoreflect.Message {
+ mi := &file_v1_sql_service_proto_msgTypes[6]
+ if x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use MaskingReason.ProtoReflect.Descriptor instead.
+func (*MaskingReason) Descriptor() ([]byte, []int) {
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{6}
+}
+
+func (x *MaskingReason) GetSemanticTypeId() string {
+ if x != nil {
+ return x.SemanticTypeId
+ }
+ return ""
+}
+
+func (x *MaskingReason) GetSemanticTypeTitle() string {
+ if x != nil {
+ return x.SemanticTypeTitle
+ }
+ return ""
+}
+
+func (x *MaskingReason) GetMaskingRuleId() string {
+ if x != nil {
+ return x.MaskingRuleId
+ }
+ return ""
+}
+
+func (x *MaskingReason) GetAlgorithm() string {
+ if x != nil {
+ return x.Algorithm
+ }
+ return ""
+}
+
+func (x *MaskingReason) GetContext() string {
+ if x != nil {
+ return x.Context
+ }
+ return ""
+}
+
+func (x *MaskingReason) GetClassificationLevel() string {
+ if x != nil {
+ return x.ClassificationLevel
+ }
+ return ""
+}
+
+func (x *MaskingReason) GetSemanticTypeIcon() string {
+ if x != nil {
+ return x.SemanticTypeIcon
+ }
+ return ""
+}
+
type QueryRow struct {
state protoimpl.MessageState `protogen:"open.v1"`
// Row values of the query result.
@@ -801,7 +891,7 @@ type QueryRow struct {
func (x *QueryRow) Reset() {
*x = QueryRow{}
- mi := &file_v1_sql_service_proto_msgTypes[6]
+ mi := &file_v1_sql_service_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -813,7 +903,7 @@ func (x *QueryRow) String() string {
func (*QueryRow) ProtoMessage() {}
func (x *QueryRow) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[6]
+ mi := &file_v1_sql_service_proto_msgTypes[7]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -826,7 +916,7 @@ func (x *QueryRow) ProtoReflect() protoreflect.Message {
// Deprecated: Use QueryRow.ProtoReflect.Descriptor instead.
func (*QueryRow) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{6}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{7}
}
func (x *QueryRow) GetValues() []*RowValue {
@@ -860,7 +950,7 @@ type RowValue struct {
func (x *RowValue) Reset() {
*x = RowValue{}
- mi := &file_v1_sql_service_proto_msgTypes[7]
+ mi := &file_v1_sql_service_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -872,7 +962,7 @@ func (x *RowValue) String() string {
func (*RowValue) ProtoMessage() {}
func (x *RowValue) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[7]
+ mi := &file_v1_sql_service_proto_msgTypes[8]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -885,7 +975,7 @@ func (x *RowValue) ProtoReflect() protoreflect.Message {
// Deprecated: Use RowValue.ProtoReflect.Descriptor instead.
func (*RowValue) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{7}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{8}
}
func (x *RowValue) GetKind() isRowValue_Kind {
@@ -1121,7 +1211,7 @@ type Advice struct {
func (x *Advice) Reset() {
*x = Advice{}
- mi := &file_v1_sql_service_proto_msgTypes[8]
+ mi := &file_v1_sql_service_proto_msgTypes[9]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1133,7 +1223,7 @@ func (x *Advice) String() string {
func (*Advice) ProtoMessage() {}
func (x *Advice) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[8]
+ mi := &file_v1_sql_service_proto_msgTypes[9]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1146,7 +1236,7 @@ func (x *Advice) ProtoReflect() protoreflect.Message {
// Deprecated: Use Advice.ProtoReflect.Descriptor instead.
func (*Advice) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{8}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{9}
}
func (x *Advice) GetStatus() Advice_Status {
@@ -1219,7 +1309,7 @@ type ExportRequest struct {
func (x *ExportRequest) Reset() {
*x = ExportRequest{}
- mi := &file_v1_sql_service_proto_msgTypes[9]
+ mi := &file_v1_sql_service_proto_msgTypes[10]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1231,7 +1321,7 @@ func (x *ExportRequest) String() string {
func (*ExportRequest) ProtoMessage() {}
func (x *ExportRequest) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[9]
+ mi := &file_v1_sql_service_proto_msgTypes[10]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1244,7 +1334,7 @@ func (x *ExportRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use ExportRequest.ProtoReflect.Descriptor instead.
func (*ExportRequest) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{9}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{10}
}
func (x *ExportRequest) GetName() string {
@@ -1306,7 +1396,7 @@ type ExportResponse struct {
func (x *ExportResponse) Reset() {
*x = ExportResponse{}
- mi := &file_v1_sql_service_proto_msgTypes[10]
+ mi := &file_v1_sql_service_proto_msgTypes[11]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1318,7 +1408,7 @@ func (x *ExportResponse) String() string {
func (*ExportResponse) ProtoMessage() {}
func (x *ExportResponse) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[10]
+ mi := &file_v1_sql_service_proto_msgTypes[11]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1331,7 +1421,7 @@ func (x *ExportResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use ExportResponse.ProtoReflect.Descriptor instead.
func (*ExportResponse) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{10}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{11}
}
func (x *ExportResponse) GetContent() []byte {
@@ -1357,7 +1447,7 @@ type PrettyRequest struct {
func (x *PrettyRequest) Reset() {
*x = PrettyRequest{}
- mi := &file_v1_sql_service_proto_msgTypes[11]
+ mi := &file_v1_sql_service_proto_msgTypes[12]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1369,7 +1459,7 @@ func (x *PrettyRequest) String() string {
func (*PrettyRequest) ProtoMessage() {}
func (x *PrettyRequest) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[11]
+ mi := &file_v1_sql_service_proto_msgTypes[12]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1382,7 +1472,7 @@ func (x *PrettyRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use PrettyRequest.ProtoReflect.Descriptor instead.
func (*PrettyRequest) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{11}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{12}
}
func (x *PrettyRequest) GetEngine() Engine {
@@ -1418,7 +1508,7 @@ type PrettyResponse struct {
func (x *PrettyResponse) Reset() {
*x = PrettyResponse{}
- mi := &file_v1_sql_service_proto_msgTypes[12]
+ mi := &file_v1_sql_service_proto_msgTypes[13]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1430,7 +1520,7 @@ func (x *PrettyResponse) String() string {
func (*PrettyResponse) ProtoMessage() {}
func (x *PrettyResponse) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[12]
+ mi := &file_v1_sql_service_proto_msgTypes[13]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1443,7 +1533,7 @@ func (x *PrettyResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use PrettyResponse.ProtoReflect.Descriptor instead.
func (*PrettyResponse) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{12}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{13}
}
func (x *PrettyResponse) GetCurrentSchema() string {
@@ -1473,7 +1563,7 @@ type CheckRequest struct {
func (x *CheckRequest) Reset() {
*x = CheckRequest{}
- mi := &file_v1_sql_service_proto_msgTypes[13]
+ mi := &file_v1_sql_service_proto_msgTypes[14]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1485,7 +1575,7 @@ func (x *CheckRequest) String() string {
func (*CheckRequest) ProtoMessage() {}
func (x *CheckRequest) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[13]
+ mi := &file_v1_sql_service_proto_msgTypes[14]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1498,7 +1588,7 @@ func (x *CheckRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use CheckRequest.ProtoReflect.Descriptor instead.
func (*CheckRequest) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{13}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{14}
}
func (x *CheckRequest) GetName() string {
@@ -1533,7 +1623,7 @@ type CheckResponse struct {
func (x *CheckResponse) Reset() {
*x = CheckResponse{}
- mi := &file_v1_sql_service_proto_msgTypes[14]
+ mi := &file_v1_sql_service_proto_msgTypes[15]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1545,7 +1635,7 @@ func (x *CheckResponse) String() string {
func (*CheckResponse) ProtoMessage() {}
func (x *CheckResponse) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[14]
+ mi := &file_v1_sql_service_proto_msgTypes[15]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1558,7 +1648,7 @@ func (x *CheckResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use CheckResponse.ProtoReflect.Descriptor instead.
func (*CheckResponse) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{14}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{15}
}
func (x *CheckResponse) GetAdvices() []*Advice {
@@ -1584,7 +1674,7 @@ type ParseMyBatisMapperRequest struct {
func (x *ParseMyBatisMapperRequest) Reset() {
*x = ParseMyBatisMapperRequest{}
- mi := &file_v1_sql_service_proto_msgTypes[15]
+ mi := &file_v1_sql_service_proto_msgTypes[16]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1596,7 +1686,7 @@ func (x *ParseMyBatisMapperRequest) String() string {
func (*ParseMyBatisMapperRequest) ProtoMessage() {}
func (x *ParseMyBatisMapperRequest) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[15]
+ mi := &file_v1_sql_service_proto_msgTypes[16]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1609,7 +1699,7 @@ func (x *ParseMyBatisMapperRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use ParseMyBatisMapperRequest.ProtoReflect.Descriptor instead.
func (*ParseMyBatisMapperRequest) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{15}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{16}
}
func (x *ParseMyBatisMapperRequest) GetContent() []byte {
@@ -1628,7 +1718,7 @@ type ParseMyBatisMapperResponse struct {
func (x *ParseMyBatisMapperResponse) Reset() {
*x = ParseMyBatisMapperResponse{}
- mi := &file_v1_sql_service_proto_msgTypes[16]
+ mi := &file_v1_sql_service_proto_msgTypes[17]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1640,7 +1730,7 @@ func (x *ParseMyBatisMapperResponse) String() string {
func (*ParseMyBatisMapperResponse) ProtoMessage() {}
func (x *ParseMyBatisMapperResponse) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[16]
+ mi := &file_v1_sql_service_proto_msgTypes[17]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1653,7 +1743,7 @@ func (x *ParseMyBatisMapperResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use ParseMyBatisMapperResponse.ProtoReflect.Descriptor instead.
func (*ParseMyBatisMapperResponse) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{16}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{17}
}
func (x *ParseMyBatisMapperResponse) GetStatements() []string {
@@ -1682,7 +1772,7 @@ type DiffMetadataRequest struct {
func (x *DiffMetadataRequest) Reset() {
*x = DiffMetadataRequest{}
- mi := &file_v1_sql_service_proto_msgTypes[17]
+ mi := &file_v1_sql_service_proto_msgTypes[18]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1694,7 +1784,7 @@ func (x *DiffMetadataRequest) String() string {
func (*DiffMetadataRequest) ProtoMessage() {}
func (x *DiffMetadataRequest) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[17]
+ mi := &file_v1_sql_service_proto_msgTypes[18]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1707,7 +1797,7 @@ func (x *DiffMetadataRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use DiffMetadataRequest.ProtoReflect.Descriptor instead.
func (*DiffMetadataRequest) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{17}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{18}
}
func (x *DiffMetadataRequest) GetSourceMetadata() *DatabaseMetadata {
@@ -1762,7 +1852,7 @@ type DiffMetadataResponse struct {
func (x *DiffMetadataResponse) Reset() {
*x = DiffMetadataResponse{}
- mi := &file_v1_sql_service_proto_msgTypes[18]
+ mi := &file_v1_sql_service_proto_msgTypes[19]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1774,7 +1864,7 @@ func (x *DiffMetadataResponse) String() string {
func (*DiffMetadataResponse) ProtoMessage() {}
func (x *DiffMetadataResponse) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[18]
+ mi := &file_v1_sql_service_proto_msgTypes[19]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1787,7 +1877,7 @@ func (x *DiffMetadataResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use DiffMetadataResponse.ProtoReflect.Descriptor instead.
func (*DiffMetadataResponse) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{18}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{19}
}
func (x *DiffMetadataResponse) GetDiff() string {
@@ -1832,7 +1922,7 @@ type SearchQueryHistoriesRequest struct {
func (x *SearchQueryHistoriesRequest) Reset() {
*x = SearchQueryHistoriesRequest{}
- mi := &file_v1_sql_service_proto_msgTypes[19]
+ mi := &file_v1_sql_service_proto_msgTypes[20]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1844,7 +1934,7 @@ func (x *SearchQueryHistoriesRequest) String() string {
func (*SearchQueryHistoriesRequest) ProtoMessage() {}
func (x *SearchQueryHistoriesRequest) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[19]
+ mi := &file_v1_sql_service_proto_msgTypes[20]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1857,7 +1947,7 @@ func (x *SearchQueryHistoriesRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use SearchQueryHistoriesRequest.ProtoReflect.Descriptor instead.
func (*SearchQueryHistoriesRequest) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{19}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{20}
}
func (x *SearchQueryHistoriesRequest) GetPageSize() int32 {
@@ -1895,7 +1985,7 @@ type SearchQueryHistoriesResponse struct {
func (x *SearchQueryHistoriesResponse) Reset() {
*x = SearchQueryHistoriesResponse{}
- mi := &file_v1_sql_service_proto_msgTypes[20]
+ mi := &file_v1_sql_service_proto_msgTypes[21]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1907,7 +1997,7 @@ func (x *SearchQueryHistoriesResponse) String() string {
func (*SearchQueryHistoriesResponse) ProtoMessage() {}
func (x *SearchQueryHistoriesResponse) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[20]
+ mi := &file_v1_sql_service_proto_msgTypes[21]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1920,7 +2010,7 @@ func (x *SearchQueryHistoriesResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use SearchQueryHistoriesResponse.ProtoReflect.Descriptor instead.
func (*SearchQueryHistoriesResponse) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{20}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{21}
}
func (x *SearchQueryHistoriesResponse) GetQueryHistories() []*QueryHistory {
@@ -1957,7 +2047,7 @@ type QueryHistory struct {
func (x *QueryHistory) Reset() {
*x = QueryHistory{}
- mi := &file_v1_sql_service_proto_msgTypes[21]
+ mi := &file_v1_sql_service_proto_msgTypes[22]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -1969,7 +2059,7 @@ func (x *QueryHistory) String() string {
func (*QueryHistory) ProtoMessage() {}
func (x *QueryHistory) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[21]
+ mi := &file_v1_sql_service_proto_msgTypes[22]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -1982,7 +2072,7 @@ func (x *QueryHistory) ProtoReflect() protoreflect.Message {
// Deprecated: Use QueryHistory.ProtoReflect.Descriptor instead.
func (*QueryHistory) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{21}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{22}
}
func (x *QueryHistory) GetName() string {
@@ -2050,7 +2140,7 @@ type AICompletionRequest struct {
func (x *AICompletionRequest) Reset() {
*x = AICompletionRequest{}
- mi := &file_v1_sql_service_proto_msgTypes[22]
+ mi := &file_v1_sql_service_proto_msgTypes[23]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2062,7 +2152,7 @@ func (x *AICompletionRequest) String() string {
func (*AICompletionRequest) ProtoMessage() {}
func (x *AICompletionRequest) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[22]
+ mi := &file_v1_sql_service_proto_msgTypes[23]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2075,7 +2165,7 @@ func (x *AICompletionRequest) ProtoReflect() protoreflect.Message {
// Deprecated: Use AICompletionRequest.ProtoReflect.Descriptor instead.
func (*AICompletionRequest) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{22}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{23}
}
func (x *AICompletionRequest) GetMessages() []*AICompletionRequest_Message {
@@ -2096,7 +2186,7 @@ type AICompletionResponse struct {
func (x *AICompletionResponse) Reset() {
*x = AICompletionResponse{}
- mi := &file_v1_sql_service_proto_msgTypes[23]
+ mi := &file_v1_sql_service_proto_msgTypes[24]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2108,7 +2198,7 @@ func (x *AICompletionResponse) String() string {
func (*AICompletionResponse) ProtoMessage() {}
func (x *AICompletionResponse) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[23]
+ mi := &file_v1_sql_service_proto_msgTypes[24]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2121,7 +2211,7 @@ func (x *AICompletionResponse) ProtoReflect() protoreflect.Message {
// Deprecated: Use AICompletionResponse.ProtoReflect.Descriptor instead.
func (*AICompletionResponse) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{23}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{24}
}
func (x *AICompletionResponse) GetCandidates() []*AICompletionResponse_Candidate {
@@ -2158,7 +2248,7 @@ type QueryResult_PostgresError struct {
func (x *QueryResult_PostgresError) Reset() {
*x = QueryResult_PostgresError{}
- mi := &file_v1_sql_service_proto_msgTypes[24]
+ mi := &file_v1_sql_service_proto_msgTypes[25]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2170,7 +2260,7 @@ func (x *QueryResult_PostgresError) String() string {
func (*QueryResult_PostgresError) ProtoMessage() {}
func (x *QueryResult_PostgresError) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[24]
+ mi := &file_v1_sql_service_proto_msgTypes[25]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2315,7 +2405,7 @@ type QueryResult_Message struct {
func (x *QueryResult_Message) Reset() {
*x = QueryResult_Message{}
- mi := &file_v1_sql_service_proto_msgTypes[25]
+ mi := &file_v1_sql_service_proto_msgTypes[26]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2327,7 +2417,7 @@ func (x *QueryResult_Message) String() string {
func (*QueryResult_Message) ProtoMessage() {}
func (x *QueryResult_Message) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[25]
+ mi := &file_v1_sql_service_proto_msgTypes[26]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2368,7 +2458,7 @@ type RowValue_Timestamp struct {
func (x *RowValue_Timestamp) Reset() {
*x = RowValue_Timestamp{}
- mi := &file_v1_sql_service_proto_msgTypes[26]
+ mi := &file_v1_sql_service_proto_msgTypes[27]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2380,7 +2470,7 @@ func (x *RowValue_Timestamp) String() string {
func (*RowValue_Timestamp) ProtoMessage() {}
func (x *RowValue_Timestamp) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[26]
+ mi := &file_v1_sql_service_proto_msgTypes[27]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2393,7 +2483,7 @@ func (x *RowValue_Timestamp) ProtoReflect() protoreflect.Message {
// Deprecated: Use RowValue_Timestamp.ProtoReflect.Descriptor instead.
func (*RowValue_Timestamp) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{7, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{8, 0}
}
func (x *RowValue_Timestamp) GetGoogleTimestamp() *timestamppb.Timestamp {
@@ -2429,7 +2519,7 @@ type RowValue_TimestampTZ struct {
func (x *RowValue_TimestampTZ) Reset() {
*x = RowValue_TimestampTZ{}
- mi := &file_v1_sql_service_proto_msgTypes[27]
+ mi := &file_v1_sql_service_proto_msgTypes[28]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2441,7 +2531,7 @@ func (x *RowValue_TimestampTZ) String() string {
func (*RowValue_TimestampTZ) ProtoMessage() {}
func (x *RowValue_TimestampTZ) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[27]
+ mi := &file_v1_sql_service_proto_msgTypes[28]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2454,7 +2544,7 @@ func (x *RowValue_TimestampTZ) ProtoReflect() protoreflect.Message {
// Deprecated: Use RowValue_TimestampTZ.ProtoReflect.Descriptor instead.
func (*RowValue_TimestampTZ) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{7, 1}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{8, 1}
}
func (x *RowValue_TimestampTZ) GetGoogleTimestamp() *timestamppb.Timestamp {
@@ -2495,7 +2585,7 @@ type AICompletionRequest_Message struct {
func (x *AICompletionRequest_Message) Reset() {
*x = AICompletionRequest_Message{}
- mi := &file_v1_sql_service_proto_msgTypes[28]
+ mi := &file_v1_sql_service_proto_msgTypes[29]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2507,7 +2597,7 @@ func (x *AICompletionRequest_Message) String() string {
func (*AICompletionRequest_Message) ProtoMessage() {}
func (x *AICompletionRequest_Message) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[28]
+ mi := &file_v1_sql_service_proto_msgTypes[29]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2520,7 +2610,7 @@ func (x *AICompletionRequest_Message) ProtoReflect() protoreflect.Message {
// Deprecated: Use AICompletionRequest_Message.ProtoReflect.Descriptor instead.
func (*AICompletionRequest_Message) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{22, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{23, 0}
}
func (x *AICompletionRequest_Message) GetRole() string {
@@ -2546,7 +2636,7 @@ type AICompletionResponse_Candidate struct {
func (x *AICompletionResponse_Candidate) Reset() {
*x = AICompletionResponse_Candidate{}
- mi := &file_v1_sql_service_proto_msgTypes[29]
+ mi := &file_v1_sql_service_proto_msgTypes[30]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2558,7 +2648,7 @@ func (x *AICompletionResponse_Candidate) String() string {
func (*AICompletionResponse_Candidate) ProtoMessage() {}
func (x *AICompletionResponse_Candidate) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[29]
+ mi := &file_v1_sql_service_proto_msgTypes[30]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2571,7 +2661,7 @@ func (x *AICompletionResponse_Candidate) ProtoReflect() protoreflect.Message {
// Deprecated: Use AICompletionResponse_Candidate.ProtoReflect.Descriptor instead.
func (*AICompletionResponse_Candidate) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{23, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{24, 0}
}
func (x *AICompletionResponse_Candidate) GetContent() *AICompletionResponse_Candidate_Content {
@@ -2591,7 +2681,7 @@ type AICompletionResponse_Candidate_Content struct {
func (x *AICompletionResponse_Candidate_Content) Reset() {
*x = AICompletionResponse_Candidate_Content{}
- mi := &file_v1_sql_service_proto_msgTypes[30]
+ mi := &file_v1_sql_service_proto_msgTypes[31]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2603,7 +2693,7 @@ func (x *AICompletionResponse_Candidate_Content) String() string {
func (*AICompletionResponse_Candidate_Content) ProtoMessage() {}
func (x *AICompletionResponse_Candidate_Content) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[30]
+ mi := &file_v1_sql_service_proto_msgTypes[31]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2616,7 +2706,7 @@ func (x *AICompletionResponse_Candidate_Content) ProtoReflect() protoreflect.Mes
// Deprecated: Use AICompletionResponse_Candidate_Content.ProtoReflect.Descriptor instead.
func (*AICompletionResponse_Candidate_Content) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{23, 0, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{24, 0, 0}
}
func (x *AICompletionResponse_Candidate_Content) GetParts() []*AICompletionResponse_Candidate_Content_Part {
@@ -2635,7 +2725,7 @@ type AICompletionResponse_Candidate_Content_Part struct {
func (x *AICompletionResponse_Candidate_Content_Part) Reset() {
*x = AICompletionResponse_Candidate_Content_Part{}
- mi := &file_v1_sql_service_proto_msgTypes[31]
+ mi := &file_v1_sql_service_proto_msgTypes[32]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
@@ -2647,7 +2737,7 @@ func (x *AICompletionResponse_Candidate_Content_Part) String() string {
func (*AICompletionResponse_Candidate_Content_Part) ProtoMessage() {}
func (x *AICompletionResponse_Candidate_Content_Part) ProtoReflect() protoreflect.Message {
- mi := &file_v1_sql_service_proto_msgTypes[31]
+ mi := &file_v1_sql_service_proto_msgTypes[32]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
@@ -2660,7 +2750,7 @@ func (x *AICompletionResponse_Candidate_Content_Part) ProtoReflect() protoreflec
// Deprecated: Use AICompletionResponse_Candidate_Content_Part.ProtoReflect.Descriptor instead.
func (*AICompletionResponse_Candidate_Content_Part) Descriptor() ([]byte, []int) {
- return file_v1_sql_service_proto_rawDescGZIP(), []int{23, 0, 0, 0}
+ return file_v1_sql_service_proto_rawDescGZIP(), []int{24, 0, 0, 0}
}
func (x *AICompletionResponse_Candidate_Content_Part) GetText() string {
@@ -2708,22 +2798,21 @@ const file_v1_sql_service_proto_rawDesc = "" +
"\x12RedisRunCommandsOn\x12%\n" +
"!REDIS_RUN_COMMANDS_ON_UNSPECIFIED\x10\x00\x12\x0f\n" +
"\vSINGLE_NODE\x10\x01\x12\r\n" +
- "\tALL_NODES\x10\x02\"\xd3\t\n" +
+ "\tALL_NODES\x10\x02\"\xd1\t\n" +
"\vQueryResult\x12!\n" +
"\fcolumn_names\x18\x01 \x03(\tR\vcolumnNames\x12*\n" +
"\x11column_type_names\x18\x02 \x03(\tR\x0fcolumnTypeNames\x12)\n" +
"\x04rows\x18\x03 \x03(\v2\x15.bytebase.v1.QueryRowR\x04rows\x12\x1d\n" +
"\n" +
"rows_count\x18\n" +
- " \x01(\x03R\trowsCount\x12\x16\n" +
- "\x06masked\x18\x04 \x03(\bR\x06masked\x12\x1c\n" +
- "\tsensitive\x18\x05 \x03(\bR\tsensitive\x12\x14\n" +
+ " \x01(\x03R\trowsCount\x12\x14\n" +
"\x05error\x18\x06 \x01(\tR\x05error\x123\n" +
"\alatency\x18\a \x01(\v2\x19.google.protobuf.DurationR\alatency\x12\x1c\n" +
"\tstatement\x18\b \x01(\tR\tstatement\x12O\n" +
"\x0epostgres_error\x18\t \x01(\v2&.bytebase.v1.QueryResult.PostgresErrorH\x00R\rpostgresError\x12!\n" +
"\fallow_export\x18\v \x01(\bR\vallowExport\x12<\n" +
- "\bmessages\x18\f \x03(\v2 .bytebase.v1.QueryResult.MessageR\bmessages\x1a\xfd\x03\n" +
+ "\bmessages\x18\f \x03(\v2 .bytebase.v1.QueryResult.MessageR\bmessages\x122\n" +
+ "\x06masked\x18\x04 \x03(\v2\x1a.bytebase.v1.MaskingReasonR\x06masked\x1a\xfd\x03\n" +
"\rPostgresError\x12\x1a\n" +
"\bseverity\x18\x01 \x01(\tR\bseverity\x12\x12\n" +
"\x04code\x18\x02 \x01(\tR\x04code\x12\x18\n" +
@@ -2758,7 +2847,15 @@ const file_v1_sql_service_proto_rawDesc = "" +
"\n" +
"\x06NOTICE\x10\x05\x12\r\n" +
"\tEXCEPTION\x10\x06B\x10\n" +
- "\x0edetailed_error\"9\n" +
+ "\x0edetailed_error\"\xaa\x02\n" +
+ "\rMaskingReason\x12(\n" +
+ "\x10semantic_type_id\x18\x01 \x01(\tR\x0esemanticTypeId\x12.\n" +
+ "\x13semantic_type_title\x18\x02 \x01(\tR\x11semanticTypeTitle\x12&\n" +
+ "\x0fmasking_rule_id\x18\x03 \x01(\tR\rmaskingRuleId\x12\x1c\n" +
+ "\talgorithm\x18\x04 \x01(\tR\talgorithm\x12\x18\n" +
+ "\acontext\x18\x05 \x01(\tR\acontext\x121\n" +
+ "\x14classification_level\x18\x06 \x01(\tR\x13classificationLevel\x12,\n" +
+ "\x12semantic_type_icon\x18\a \x01(\tR\x10semanticTypeIcon\"9\n" +
"\bQueryRow\x12-\n" +
"\x06values\x18\x01 \x03(\v2\x15.bytebase.v1.RowValueR\x06values\"\xf9\x06\n" +
"\bRowValue\x12;\n" +
@@ -2917,7 +3014,7 @@ func file_v1_sql_service_proto_rawDescGZIP() []byte {
}
var file_v1_sql_service_proto_enumTypes = make([]protoimpl.EnumInfo, 5)
-var file_v1_sql_service_proto_msgTypes = make([]protoimpl.MessageInfo, 32)
+var file_v1_sql_service_proto_msgTypes = make([]protoimpl.MessageInfo, 33)
var file_v1_sql_service_proto_goTypes = []any{
(QueryOption_RedisRunCommandsOn)(0), // 0: bytebase.v1.QueryOption.RedisRunCommandsOn
(QueryResult_Message_Level)(0), // 1: bytebase.v1.QueryResult.Message.Level
@@ -2930,100 +3027,102 @@ var file_v1_sql_service_proto_goTypes = []any{
(*QueryResponse)(nil), // 8: bytebase.v1.QueryResponse
(*QueryOption)(nil), // 9: bytebase.v1.QueryOption
(*QueryResult)(nil), // 10: bytebase.v1.QueryResult
- (*QueryRow)(nil), // 11: bytebase.v1.QueryRow
- (*RowValue)(nil), // 12: bytebase.v1.RowValue
- (*Advice)(nil), // 13: bytebase.v1.Advice
- (*ExportRequest)(nil), // 14: bytebase.v1.ExportRequest
- (*ExportResponse)(nil), // 15: bytebase.v1.ExportResponse
- (*PrettyRequest)(nil), // 16: bytebase.v1.PrettyRequest
- (*PrettyResponse)(nil), // 17: bytebase.v1.PrettyResponse
- (*CheckRequest)(nil), // 18: bytebase.v1.CheckRequest
- (*CheckResponse)(nil), // 19: bytebase.v1.CheckResponse
- (*ParseMyBatisMapperRequest)(nil), // 20: bytebase.v1.ParseMyBatisMapperRequest
- (*ParseMyBatisMapperResponse)(nil), // 21: bytebase.v1.ParseMyBatisMapperResponse
- (*DiffMetadataRequest)(nil), // 22: bytebase.v1.DiffMetadataRequest
- (*DiffMetadataResponse)(nil), // 23: bytebase.v1.DiffMetadataResponse
- (*SearchQueryHistoriesRequest)(nil), // 24: bytebase.v1.SearchQueryHistoriesRequest
- (*SearchQueryHistoriesResponse)(nil), // 25: bytebase.v1.SearchQueryHistoriesResponse
- (*QueryHistory)(nil), // 26: bytebase.v1.QueryHistory
- (*AICompletionRequest)(nil), // 27: bytebase.v1.AICompletionRequest
- (*AICompletionResponse)(nil), // 28: bytebase.v1.AICompletionResponse
- (*QueryResult_PostgresError)(nil), // 29: bytebase.v1.QueryResult.PostgresError
- (*QueryResult_Message)(nil), // 30: bytebase.v1.QueryResult.Message
- (*RowValue_Timestamp)(nil), // 31: bytebase.v1.RowValue.Timestamp
- (*RowValue_TimestampTZ)(nil), // 32: bytebase.v1.RowValue.TimestampTZ
- (*AICompletionRequest_Message)(nil), // 33: bytebase.v1.AICompletionRequest.Message
- (*AICompletionResponse_Candidate)(nil), // 34: bytebase.v1.AICompletionResponse.Candidate
- (*AICompletionResponse_Candidate_Content)(nil), // 35: bytebase.v1.AICompletionResponse.Candidate.Content
- (*AICompletionResponse_Candidate_Content_Part)(nil), // 36: bytebase.v1.AICompletionResponse.Candidate.Content.Part
- (*durationpb.Duration)(nil), // 37: google.protobuf.Duration
- (structpb.NullValue)(0), // 38: google.protobuf.NullValue
- (*structpb.Value)(nil), // 39: google.protobuf.Value
- (*Position)(nil), // 40: bytebase.v1.Position
- (ExportFormat)(0), // 41: bytebase.v1.ExportFormat
- (Engine)(0), // 42: bytebase.v1.Engine
- (*DatabaseMetadata)(nil), // 43: bytebase.v1.DatabaseMetadata
- (*DatabaseCatalog)(nil), // 44: bytebase.v1.DatabaseCatalog
- (*timestamppb.Timestamp)(nil), // 45: google.protobuf.Timestamp
+ (*MaskingReason)(nil), // 11: bytebase.v1.MaskingReason
+ (*QueryRow)(nil), // 12: bytebase.v1.QueryRow
+ (*RowValue)(nil), // 13: bytebase.v1.RowValue
+ (*Advice)(nil), // 14: bytebase.v1.Advice
+ (*ExportRequest)(nil), // 15: bytebase.v1.ExportRequest
+ (*ExportResponse)(nil), // 16: bytebase.v1.ExportResponse
+ (*PrettyRequest)(nil), // 17: bytebase.v1.PrettyRequest
+ (*PrettyResponse)(nil), // 18: bytebase.v1.PrettyResponse
+ (*CheckRequest)(nil), // 19: bytebase.v1.CheckRequest
+ (*CheckResponse)(nil), // 20: bytebase.v1.CheckResponse
+ (*ParseMyBatisMapperRequest)(nil), // 21: bytebase.v1.ParseMyBatisMapperRequest
+ (*ParseMyBatisMapperResponse)(nil), // 22: bytebase.v1.ParseMyBatisMapperResponse
+ (*DiffMetadataRequest)(nil), // 23: bytebase.v1.DiffMetadataRequest
+ (*DiffMetadataResponse)(nil), // 24: bytebase.v1.DiffMetadataResponse
+ (*SearchQueryHistoriesRequest)(nil), // 25: bytebase.v1.SearchQueryHistoriesRequest
+ (*SearchQueryHistoriesResponse)(nil), // 26: bytebase.v1.SearchQueryHistoriesResponse
+ (*QueryHistory)(nil), // 27: bytebase.v1.QueryHistory
+ (*AICompletionRequest)(nil), // 28: bytebase.v1.AICompletionRequest
+ (*AICompletionResponse)(nil), // 29: bytebase.v1.AICompletionResponse
+ (*QueryResult_PostgresError)(nil), // 30: bytebase.v1.QueryResult.PostgresError
+ (*QueryResult_Message)(nil), // 31: bytebase.v1.QueryResult.Message
+ (*RowValue_Timestamp)(nil), // 32: bytebase.v1.RowValue.Timestamp
+ (*RowValue_TimestampTZ)(nil), // 33: bytebase.v1.RowValue.TimestampTZ
+ (*AICompletionRequest_Message)(nil), // 34: bytebase.v1.AICompletionRequest.Message
+ (*AICompletionResponse_Candidate)(nil), // 35: bytebase.v1.AICompletionResponse.Candidate
+ (*AICompletionResponse_Candidate_Content)(nil), // 36: bytebase.v1.AICompletionResponse.Candidate.Content
+ (*AICompletionResponse_Candidate_Content_Part)(nil), // 37: bytebase.v1.AICompletionResponse.Candidate.Content.Part
+ (*durationpb.Duration)(nil), // 38: google.protobuf.Duration
+ (structpb.NullValue)(0), // 39: google.protobuf.NullValue
+ (*structpb.Value)(nil), // 40: google.protobuf.Value
+ (*Position)(nil), // 41: bytebase.v1.Position
+ (ExportFormat)(0), // 42: bytebase.v1.ExportFormat
+ (Engine)(0), // 43: bytebase.v1.Engine
+ (*DatabaseMetadata)(nil), // 44: bytebase.v1.DatabaseMetadata
+ (*DatabaseCatalog)(nil), // 45: bytebase.v1.DatabaseCatalog
+ (*timestamppb.Timestamp)(nil), // 46: google.protobuf.Timestamp
}
var file_v1_sql_service_proto_depIdxs = []int32{
10, // 0: bytebase.v1.AdminExecuteResponse.results:type_name -> bytebase.v1.QueryResult
9, // 1: bytebase.v1.QueryRequest.query_option:type_name -> bytebase.v1.QueryOption
10, // 2: bytebase.v1.QueryResponse.results:type_name -> bytebase.v1.QueryResult
0, // 3: bytebase.v1.QueryOption.redis_run_commands_on:type_name -> bytebase.v1.QueryOption.RedisRunCommandsOn
- 11, // 4: bytebase.v1.QueryResult.rows:type_name -> bytebase.v1.QueryRow
- 37, // 5: bytebase.v1.QueryResult.latency:type_name -> google.protobuf.Duration
- 29, // 6: bytebase.v1.QueryResult.postgres_error:type_name -> bytebase.v1.QueryResult.PostgresError
- 30, // 7: bytebase.v1.QueryResult.messages:type_name -> bytebase.v1.QueryResult.Message
- 12, // 8: bytebase.v1.QueryRow.values:type_name -> bytebase.v1.RowValue
- 38, // 9: bytebase.v1.RowValue.null_value:type_name -> google.protobuf.NullValue
- 39, // 10: bytebase.v1.RowValue.value_value:type_name -> google.protobuf.Value
- 31, // 11: bytebase.v1.RowValue.timestamp_value:type_name -> bytebase.v1.RowValue.Timestamp
- 32, // 12: bytebase.v1.RowValue.timestamp_tz_value:type_name -> bytebase.v1.RowValue.TimestampTZ
- 2, // 13: bytebase.v1.Advice.status:type_name -> bytebase.v1.Advice.Status
- 40, // 14: bytebase.v1.Advice.start_position:type_name -> bytebase.v1.Position
- 40, // 15: bytebase.v1.Advice.end_position:type_name -> bytebase.v1.Position
- 41, // 16: bytebase.v1.ExportRequest.format:type_name -> bytebase.v1.ExportFormat
- 42, // 17: bytebase.v1.PrettyRequest.engine:type_name -> bytebase.v1.Engine
- 3, // 18: bytebase.v1.CheckRequest.change_type:type_name -> bytebase.v1.CheckRequest.ChangeType
- 13, // 19: bytebase.v1.CheckResponse.advices:type_name -> bytebase.v1.Advice
- 43, // 20: bytebase.v1.DiffMetadataRequest.source_metadata:type_name -> bytebase.v1.DatabaseMetadata
- 43, // 21: bytebase.v1.DiffMetadataRequest.target_metadata:type_name -> bytebase.v1.DatabaseMetadata
- 44, // 22: bytebase.v1.DiffMetadataRequest.source_catalog:type_name -> bytebase.v1.DatabaseCatalog
- 44, // 23: bytebase.v1.DiffMetadataRequest.target_catalog:type_name -> bytebase.v1.DatabaseCatalog
- 42, // 24: bytebase.v1.DiffMetadataRequest.engine:type_name -> bytebase.v1.Engine
- 26, // 25: bytebase.v1.SearchQueryHistoriesResponse.query_histories:type_name -> bytebase.v1.QueryHistory
- 45, // 26: bytebase.v1.QueryHistory.create_time:type_name -> google.protobuf.Timestamp
- 37, // 27: bytebase.v1.QueryHistory.duration:type_name -> google.protobuf.Duration
- 4, // 28: bytebase.v1.QueryHistory.type:type_name -> bytebase.v1.QueryHistory.Type
- 33, // 29: bytebase.v1.AICompletionRequest.messages:type_name -> bytebase.v1.AICompletionRequest.Message
- 34, // 30: bytebase.v1.AICompletionResponse.candidates:type_name -> bytebase.v1.AICompletionResponse.Candidate
- 1, // 31: bytebase.v1.QueryResult.Message.level:type_name -> bytebase.v1.QueryResult.Message.Level
- 45, // 32: bytebase.v1.RowValue.Timestamp.google_timestamp:type_name -> google.protobuf.Timestamp
- 45, // 33: bytebase.v1.RowValue.TimestampTZ.google_timestamp:type_name -> google.protobuf.Timestamp
- 35, // 34: bytebase.v1.AICompletionResponse.Candidate.content:type_name -> bytebase.v1.AICompletionResponse.Candidate.Content
- 36, // 35: bytebase.v1.AICompletionResponse.Candidate.Content.parts:type_name -> bytebase.v1.AICompletionResponse.Candidate.Content.Part
- 7, // 36: bytebase.v1.SQLService.Query:input_type -> bytebase.v1.QueryRequest
- 5, // 37: bytebase.v1.SQLService.AdminExecute:input_type -> bytebase.v1.AdminExecuteRequest
- 24, // 38: bytebase.v1.SQLService.SearchQueryHistories:input_type -> bytebase.v1.SearchQueryHistoriesRequest
- 14, // 39: bytebase.v1.SQLService.Export:input_type -> bytebase.v1.ExportRequest
- 18, // 40: bytebase.v1.SQLService.Check:input_type -> bytebase.v1.CheckRequest
- 16, // 41: bytebase.v1.SQLService.Pretty:input_type -> bytebase.v1.PrettyRequest
- 22, // 42: bytebase.v1.SQLService.DiffMetadata:input_type -> bytebase.v1.DiffMetadataRequest
- 27, // 43: bytebase.v1.SQLService.AICompletion:input_type -> bytebase.v1.AICompletionRequest
- 8, // 44: bytebase.v1.SQLService.Query:output_type -> bytebase.v1.QueryResponse
- 6, // 45: bytebase.v1.SQLService.AdminExecute:output_type -> bytebase.v1.AdminExecuteResponse
- 25, // 46: bytebase.v1.SQLService.SearchQueryHistories:output_type -> bytebase.v1.SearchQueryHistoriesResponse
- 15, // 47: bytebase.v1.SQLService.Export:output_type -> bytebase.v1.ExportResponse
- 19, // 48: bytebase.v1.SQLService.Check:output_type -> bytebase.v1.CheckResponse
- 17, // 49: bytebase.v1.SQLService.Pretty:output_type -> bytebase.v1.PrettyResponse
- 23, // 50: bytebase.v1.SQLService.DiffMetadata:output_type -> bytebase.v1.DiffMetadataResponse
- 28, // 51: bytebase.v1.SQLService.AICompletion:output_type -> bytebase.v1.AICompletionResponse
- 44, // [44:52] is the sub-list for method output_type
- 36, // [36:44] is the sub-list for method input_type
- 36, // [36:36] is the sub-list for extension type_name
- 36, // [36:36] is the sub-list for extension extendee
- 0, // [0:36] is the sub-list for field type_name
+ 12, // 4: bytebase.v1.QueryResult.rows:type_name -> bytebase.v1.QueryRow
+ 38, // 5: bytebase.v1.QueryResult.latency:type_name -> google.protobuf.Duration
+ 30, // 6: bytebase.v1.QueryResult.postgres_error:type_name -> bytebase.v1.QueryResult.PostgresError
+ 31, // 7: bytebase.v1.QueryResult.messages:type_name -> bytebase.v1.QueryResult.Message
+ 11, // 8: bytebase.v1.QueryResult.masked:type_name -> bytebase.v1.MaskingReason
+ 13, // 9: bytebase.v1.QueryRow.values:type_name -> bytebase.v1.RowValue
+ 39, // 10: bytebase.v1.RowValue.null_value:type_name -> google.protobuf.NullValue
+ 40, // 11: bytebase.v1.RowValue.value_value:type_name -> google.protobuf.Value
+ 32, // 12: bytebase.v1.RowValue.timestamp_value:type_name -> bytebase.v1.RowValue.Timestamp
+ 33, // 13: bytebase.v1.RowValue.timestamp_tz_value:type_name -> bytebase.v1.RowValue.TimestampTZ
+ 2, // 14: bytebase.v1.Advice.status:type_name -> bytebase.v1.Advice.Status
+ 41, // 15: bytebase.v1.Advice.start_position:type_name -> bytebase.v1.Position
+ 41, // 16: bytebase.v1.Advice.end_position:type_name -> bytebase.v1.Position
+ 42, // 17: bytebase.v1.ExportRequest.format:type_name -> bytebase.v1.ExportFormat
+ 43, // 18: bytebase.v1.PrettyRequest.engine:type_name -> bytebase.v1.Engine
+ 3, // 19: bytebase.v1.CheckRequest.change_type:type_name -> bytebase.v1.CheckRequest.ChangeType
+ 14, // 20: bytebase.v1.CheckResponse.advices:type_name -> bytebase.v1.Advice
+ 44, // 21: bytebase.v1.DiffMetadataRequest.source_metadata:type_name -> bytebase.v1.DatabaseMetadata
+ 44, // 22: bytebase.v1.DiffMetadataRequest.target_metadata:type_name -> bytebase.v1.DatabaseMetadata
+ 45, // 23: bytebase.v1.DiffMetadataRequest.source_catalog:type_name -> bytebase.v1.DatabaseCatalog
+ 45, // 24: bytebase.v1.DiffMetadataRequest.target_catalog:type_name -> bytebase.v1.DatabaseCatalog
+ 43, // 25: bytebase.v1.DiffMetadataRequest.engine:type_name -> bytebase.v1.Engine
+ 27, // 26: bytebase.v1.SearchQueryHistoriesResponse.query_histories:type_name -> bytebase.v1.QueryHistory
+ 46, // 27: bytebase.v1.QueryHistory.create_time:type_name -> google.protobuf.Timestamp
+ 38, // 28: bytebase.v1.QueryHistory.duration:type_name -> google.protobuf.Duration
+ 4, // 29: bytebase.v1.QueryHistory.type:type_name -> bytebase.v1.QueryHistory.Type
+ 34, // 30: bytebase.v1.AICompletionRequest.messages:type_name -> bytebase.v1.AICompletionRequest.Message
+ 35, // 31: bytebase.v1.AICompletionResponse.candidates:type_name -> bytebase.v1.AICompletionResponse.Candidate
+ 1, // 32: bytebase.v1.QueryResult.Message.level:type_name -> bytebase.v1.QueryResult.Message.Level
+ 46, // 33: bytebase.v1.RowValue.Timestamp.google_timestamp:type_name -> google.protobuf.Timestamp
+ 46, // 34: bytebase.v1.RowValue.TimestampTZ.google_timestamp:type_name -> google.protobuf.Timestamp
+ 36, // 35: bytebase.v1.AICompletionResponse.Candidate.content:type_name -> bytebase.v1.AICompletionResponse.Candidate.Content
+ 37, // 36: bytebase.v1.AICompletionResponse.Candidate.Content.parts:type_name -> bytebase.v1.AICompletionResponse.Candidate.Content.Part
+ 7, // 37: bytebase.v1.SQLService.Query:input_type -> bytebase.v1.QueryRequest
+ 5, // 38: bytebase.v1.SQLService.AdminExecute:input_type -> bytebase.v1.AdminExecuteRequest
+ 25, // 39: bytebase.v1.SQLService.SearchQueryHistories:input_type -> bytebase.v1.SearchQueryHistoriesRequest
+ 15, // 40: bytebase.v1.SQLService.Export:input_type -> bytebase.v1.ExportRequest
+ 19, // 41: bytebase.v1.SQLService.Check:input_type -> bytebase.v1.CheckRequest
+ 17, // 42: bytebase.v1.SQLService.Pretty:input_type -> bytebase.v1.PrettyRequest
+ 23, // 43: bytebase.v1.SQLService.DiffMetadata:input_type -> bytebase.v1.DiffMetadataRequest
+ 28, // 44: bytebase.v1.SQLService.AICompletion:input_type -> bytebase.v1.AICompletionRequest
+ 8, // 45: bytebase.v1.SQLService.Query:output_type -> bytebase.v1.QueryResponse
+ 6, // 46: bytebase.v1.SQLService.AdminExecute:output_type -> bytebase.v1.AdminExecuteResponse
+ 26, // 47: bytebase.v1.SQLService.SearchQueryHistories:output_type -> bytebase.v1.SearchQueryHistoriesResponse
+ 16, // 48: bytebase.v1.SQLService.Export:output_type -> bytebase.v1.ExportResponse
+ 20, // 49: bytebase.v1.SQLService.Check:output_type -> bytebase.v1.CheckResponse
+ 18, // 50: bytebase.v1.SQLService.Pretty:output_type -> bytebase.v1.PrettyResponse
+ 24, // 51: bytebase.v1.SQLService.DiffMetadata:output_type -> bytebase.v1.DiffMetadataResponse
+ 29, // 52: bytebase.v1.SQLService.AICompletion:output_type -> bytebase.v1.AICompletionResponse
+ 45, // [45:53] is the sub-list for method output_type
+ 37, // [37:45] is the sub-list for method input_type
+ 37, // [37:37] is the sub-list for extension type_name
+ 37, // [37:37] is the sub-list for extension extendee
+ 0, // [0:37] is the sub-list for field type_name
}
func init() { file_v1_sql_service_proto_init() }
@@ -3040,7 +3139,7 @@ func file_v1_sql_service_proto_init() {
file_v1_sql_service_proto_msgTypes[5].OneofWrappers = []any{
(*QueryResult_PostgresError_)(nil),
}
- file_v1_sql_service_proto_msgTypes[7].OneofWrappers = []any{
+ file_v1_sql_service_proto_msgTypes[8].OneofWrappers = []any{
(*RowValue_NullValue)(nil),
(*RowValue_BoolValue)(nil),
(*RowValue_BytesValue)(nil),
@@ -3055,14 +3154,14 @@ func file_v1_sql_service_proto_init() {
(*RowValue_TimestampValue)(nil),
(*RowValue_TimestampTzValue)(nil),
}
- file_v1_sql_service_proto_msgTypes[21].OneofWrappers = []any{}
+ file_v1_sql_service_proto_msgTypes[22].OneofWrappers = []any{}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: unsafe.Slice(unsafe.StringData(file_v1_sql_service_proto_rawDesc), len(file_v1_sql_service_proto_rawDesc)),
NumEnums: 5,
- NumMessages: 32,
+ NumMessages: 33,
NumExtensions: 0,
NumServices: 1,
},
diff --git a/proto/store/store/setting.proto b/proto/store/store/setting.proto
index 91798a0de9..c1f338724c 100644
--- a/proto/store/store/setting.proto
+++ b/proto/store/store/setting.proto
@@ -180,6 +180,9 @@ message SemanticTypeSetting {
string description = 3;
Algorithm algorithm = 6;
+
+ // icon is the icon for semantic type, it can be emoji or base64 encoded image.
+ string icon = 7;
}
repeated SemanticType types = 1;
diff --git a/proto/v1/v1/setting_service.proto b/proto/v1/v1/setting_service.proto
index 0e0f46bce2..6790ff6223 100644
--- a/proto/v1/v1/setting_service.proto
+++ b/proto/v1/v1/setting_service.proto
@@ -349,6 +349,9 @@ message SemanticTypeSetting {
string description = 3;
Algorithm algorithm = 6;
+
+ // icon is the icon for semantic type, it can be emoji or base64 encoded image.
+ string icon = 7;
}
repeated SemanticType types = 1;
diff --git a/proto/v1/v1/sql_service.proto b/proto/v1/v1/sql_service.proto
index bd3189baaa..26ca51d9c0 100644
--- a/proto/v1/v1/sql_service.proto
+++ b/proto/v1/v1/sql_service.proto
@@ -210,12 +210,6 @@ message QueryResult {
int64 rows_count = 10;
- // Columns are masked or not.
- repeated bool masked = 4;
-
- // Columns are sensitive or not.
- repeated bool sensitive = 5;
-
// The error message if the query failed.
string error = 6;
@@ -273,6 +267,32 @@ message QueryResult {
// Informational or debug messages returned by the database engine during query execution.
// Examples include PostgreSQL's RAISE NOTICE, MSSQL's PRINT, or Oracle's DBMS_OUTPUT.PUT_LINE.
repeated Message messages = 12;
+
+ // Masking reasons for each column (empty for non-masked columns).
+ repeated MaskingReason masked = 4;
+}
+
+message MaskingReason {
+ // The semantic type that triggered masking (e.g., "SSN", "email", "phone").
+ string semantic_type_id = 1;
+
+ // Human-readable semantic type title.
+ string semantic_type_title = 2;
+
+ // The masking rule ID that matched (if applicable).
+ string masking_rule_id = 3;
+
+ // The masking algorithm used.
+ string algorithm = 4;
+
+ // Additional context (e.g., "Matched global rule: PII Protection").
+ string context = 5;
+
+ // Whether masking was due to classification level.
+ string classification_level = 6;
+
+ // Icon associated with the semantic type (if any).
+ string semantic_type_icon = 7;
}
message QueryRow {