fix(security): 系统渠道密钥 - 加密落库并在运行时解密

Co-authored-by: dyhhhhhqwer <1613203335@qq.com>
Original-PR: https://github.com/ddcat-ai/open-ai-canvas/pull/202
This commit is contained in:
dyhhhhhanddyhhhhhqwer authored and GitHub committed 2026-08-14 09:52:01 +08:00
1 parent 393b7f220f
commit 879a780167
3 files changed
+59 -4

No files matched your search

+2 -2
View File
@@ -88,7 +88,7 @@ func (s *Service) FetchAdminChannelModels(ctx context.Context, actor *model.User
if err := s.RequireAdmin(actor); err != nil {
return nil, err
}
channel, err := s.repo.AdminSystemChannel(channelID)
channel, err := s.adminSystemChannel(channelID)
if err != nil {
return nil, err
}
@@ -226,7 +226,7 @@ func (s *Service) TestAdminChannelModel(ctx context.Context, actor *model.User,
if err := s.RequireAdmin(actor); err != nil {
return nil, err
}
channel, err := s.repo.AdminSystemChannel(channelID)
channel, err := s.adminSystemChannel(channelID)
if err != nil {
return nil, err
}