Files
backend/internal/config/encryption.go

15 lines
402 B
Go
Raw Permalink Normal View History

package config
// EncryptionConfig 消息加密配置
type EncryptionConfig struct {
// Enabled 是否启用消息加密
Enabled bool `mapstructure:"enabled"`
// Key 加密密钥32字节AES-256
// 生产环境应通过环境变量 APP_ENCRYPTION_KEY 设置
Key string `mapstructure:"key"`
// KeyVersion 密钥版本,用于密钥轮换
KeyVersion int `mapstructure:"key_version"`
}