From 641fe352dadb75dd9d82976c4fd17cb5338d26a9 Mon Sep 17 00:00:00 2001 From: HFO4 <912394456@qq.com> Date: Sun, 25 Apr 2021 16:06:22 +0800 Subject: [PATCH 1/2] Fix: user encryption setting will now overwrite the default one in gomail (#869 #857 #723 #545) --- assets | 2 +- pkg/email/smtp.go | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/assets b/assets index 08a301d..997b733 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit 08a301d53a39d0a67a2714caef9866c1eeaa4ee3 +Subproject commit 997b73312aad0fd8caae91cd1fde386701ce37c0 diff --git a/pkg/email/smtp.go b/pkg/email/smtp.go index 9b77cd9..02376d7 100644 --- a/pkg/email/smtp.go +++ b/pkg/email/smtp.go @@ -77,11 +77,12 @@ func (client *SMTP) Init() { d := mail.NewDialer(client.Config.Host, client.Config.Port, client.Config.User, client.Config.Password) d.Timeout = time.Duration(client.Config.Keepalive+5) * time.Second client.chOpen = true - // 是否启用 SSL + d.SSL = false if client.Config.Encryption { d.SSL = true } + d.StartTLSPolicy = mail.OpportunisticStartTLS var s mail.SendCloser var err error From 8659bdcf777847a5744054baffe478a19b38ef22 Mon Sep 17 00:00:00 2001 From: HFO4 <912394456@qq.com> Date: Tue, 11 May 2021 21:52:55 +0800 Subject: [PATCH 2/2] Fix: unable to read file from UPYUN (#472, #472, #836) --- pkg/filesystem/driver/upyun/handler.go | 3 --- 1 file changed, 3 deletions(-) diff --git a/pkg/filesystem/driver/upyun/handler.go b/pkg/filesystem/driver/upyun/handler.go index 30fafa5..4431bc6 100644 --- a/pkg/filesystem/driver/upyun/handler.go +++ b/pkg/filesystem/driver/upyun/handler.go @@ -105,9 +105,6 @@ func (handler Driver) List(ctx context.Context, base string, recursive bool) ([] // Get 获取文件 func (handler Driver) Get(ctx context.Context, path string) (response.RSCloser, error) { - // 给文件名加上随机参数以强制拉取 - path = fmt.Sprintf("%s?v=%d", path, time.Now().UnixNano()) - // 获取文件源地址 downloadURL, err := handler.Source( ctx,