diff --git a/Changelog.md b/Changelog.md
index 765c3fd4..5cc6c3fe 100644
--- a/Changelog.md
+++ b/Changelog.md
@@ -19,6 +19,9 @@ Changelog [format](http://keepachangelog.com/en/1.0.0/)
* GODT-834 Info about tags in BUILDS.md and link to Import-Export page in README.md.
* GODT-777 Support Apple Mail MBOX export format.
+### Removed
+* GODT-766 Remove GUI popup for IMAP TLS error.
+
### Fixed
* GODT-677 Windows IE: global import settings not fit in window.
* GODT-794 Congo fails to update to Danube
diff --git a/go.mod b/go.mod
index b87e9134..385b1e1f 100644
--- a/go.mod
+++ b/go.mod
@@ -75,7 +75,7 @@ require (
replace (
github.com/docker/docker-credential-helpers => github.com/ProtonMail/docker-credential-helpers v1.1.0
- github.com/emersion/go-imap => github.com/ProtonMail/go-imap v0.0.0-20201016095853-a7520cc904d3
+ github.com/emersion/go-imap => github.com/ProtonMail/go-imap v0.0.0-20201102134601-418cd74e9474
github.com/emersion/go-smtp => github.com/ProtonMail/go-smtp v0.0.0-20181206232543-8261df20d309
github.com/jameskeane/bcrypt => github.com/ProtonMail/bcrypt v0.0.0-20170924085257-7509ea014998
golang.org/x/crypto => github.com/ProtonMail/crypto v0.0.0-20200818122824-ed5d25e28db8
diff --git a/go.sum b/go.sum
index 81c08404..74f0fb75 100644
--- a/go.sum
+++ b/go.sum
@@ -15,8 +15,8 @@ github.com/ProtonMail/go-apple-mobileconfig v0.0.0-20160701194735-7ea9927a11f6 h
github.com/ProtonMail/go-apple-mobileconfig v0.0.0-20160701194735-7ea9927a11f6/go.mod h1:EtDfBMIDWmVe4viZCuBTEfe3OIIo0ghbpOaAZVO+hVg=
github.com/ProtonMail/go-autostart v0.0.0-20181114175602-c5272053443a h1:fXK2KsfnkBV9Nh+9SKzHchYjuE9s0vI20JG1mbtEAcc=
github.com/ProtonMail/go-autostart v0.0.0-20181114175602-c5272053443a/go.mod h1:oTGdE7/DlWIr23G0IKW3OXK9wZ5Hw1GGiaJFccTvZi4=
-github.com/ProtonMail/go-imap v0.0.0-20201016095853-a7520cc904d3 h1:Jvv9t3rSg/ID3Fh+uYsxgmvNI9fYnlab4vtBsbPtmq8=
-github.com/ProtonMail/go-imap v0.0.0-20201016095853-a7520cc904d3/go.mod h1:yKASt+C3ZiDAiCSssxg9caIckWF/JG7ZQTO7GAmvicU=
+github.com/ProtonMail/go-imap v0.0.0-20201102134601-418cd74e9474 h1:D0RwDtkBw0Gt7hmbb1ivdEulplJAwu1i2jzh4HM45fo=
+github.com/ProtonMail/go-imap v0.0.0-20201102134601-418cd74e9474/go.mod h1:yKASt+C3ZiDAiCSssxg9caIckWF/JG7ZQTO7GAmvicU=
github.com/ProtonMail/go-imap-id v0.0.0-20190926060100-f94a56b9ecde h1:5koQozTDELymYOyFbQ/VSubexAEXzDR8qGM5mO8GRdw=
github.com/ProtonMail/go-imap-id v0.0.0-20190926060100-f94a56b9ecde/go.mod h1:795VPXcRUIQ9JyMNHP4el582VokQfippgjkQP3Gk0r0=
github.com/ProtonMail/go-mime v0.0.0-20190923161245-9b5a4261663a h1:W6RrgN/sTxg1msqzFFb+G80MFmpjMw61IU+slm+wln4=
diff --git a/internal/events/events.go b/internal/events/events.go
index f4c8411c..773b61a6 100644
--- a/internal/events/events.go
+++ b/internal/events/events.go
@@ -40,7 +40,6 @@ const (
NoActiveKeyForRecipientEvent = "noActiveKeyForRecipient"
UpgradeApplicationEvent = "upgradeApplication"
TLSCertIssue = "tlsCertPinningIssue"
- IMAPTLSBadCert = "imapTLSBadCert"
// LogoutEventTimeout is the minimum time to permit between logout events being sent.
LogoutEventTimeout = 3 * time.Minute
diff --git a/internal/frontend/qml/Gui.qml b/internal/frontend/qml/Gui.qml
index 82b2743e..cd9d187a 100644
--- a/internal/frontend/qml/Gui.qml
+++ b/internal/frontend/qml/Gui.qml
@@ -237,13 +237,6 @@ Item {
winMain.tlsBarState="notOK"
}
- onShowIMAPCertTroubleshoot : {
- go.notifyBubble(1, qsTr(
- "Bridge was unable to establish a connection with your Email client.
Learn more
",
- "notification message"
- ))
- }
-
}
diff --git a/internal/frontend/qml/tst_Gui.qml b/internal/frontend/qml/tst_Gui.qml
index 464cad92..6edc2a8f 100644
--- a/internal/frontend/qml/tst_Gui.qml
+++ b/internal/frontend/qml/tst_Gui.qml
@@ -122,7 +122,6 @@ Window {
ListElement { title: "Minimize this" }
ListElement { title: "SendAlertPopup" }
ListElement { title: "TLSCertError" }
- ListElement { title: "IMAPCertError" }
}
ListView {
@@ -209,9 +208,6 @@ Window {
case "TLSCertError" :
go.showCertIssue()
break;
- case "IMAPCertError" :
- go.showIMAPCertTroubleshoot()
- break;
default :
console.log("Not implemented " + data)
}
@@ -314,7 +310,6 @@ Window {
signal failedAutostartCode(string code)
signal showCertIssue()
- signal showIMAPCertTroubleshoot()
signal updateFinished(bool hasError)
diff --git a/internal/frontend/qt-common/account_model.go b/internal/frontend/qt-common/account_model.go
index 87d32746..27d4f8ea 100644
--- a/internal/frontend/qt-common/account_model.go
+++ b/internal/frontend/qt-common/account_model.go
@@ -21,6 +21,7 @@ package qtcommon
import (
"fmt"
+
"github.com/therecipe/qt/core"
)
diff --git a/internal/frontend/qt/frontend.go b/internal/frontend/qt/frontend.go
index 0093d10e..f1c20cb9 100644
--- a/internal/frontend/qt/frontend.go
+++ b/internal/frontend/qt/frontend.go
@@ -40,17 +40,17 @@ import (
"github.com/ProtonMail/proton-bridge/internal/bridge"
"github.com/ProtonMail/proton-bridge/internal/events"
"github.com/ProtonMail/proton-bridge/internal/frontend/autoconfig"
- "github.com/ProtonMail/proton-bridge/internal/frontend/qt-common"
+ qtcommon "github.com/ProtonMail/proton-bridge/internal/frontend/qt-common"
"github.com/ProtonMail/proton-bridge/internal/frontend/types"
"github.com/ProtonMail/proton-bridge/internal/preferences"
"github.com/ProtonMail/proton-bridge/internal/updates"
"github.com/ProtonMail/proton-bridge/pkg/config"
- "github.com/ProtonMail/proton-bridge/pkg/ports"
- "github.com/ProtonMail/proton-bridge/pkg/useragent"
"github.com/ProtonMail/proton-bridge/pkg/listener"
"github.com/ProtonMail/proton-bridge/pkg/pmapi"
- "github.com/sirupsen/logrus"
+ "github.com/ProtonMail/proton-bridge/pkg/ports"
+ "github.com/ProtonMail/proton-bridge/pkg/useragent"
"github.com/kardianos/osext"
+ "github.com/sirupsen/logrus"
"github.com/skratchdot/open-golang/open"
"github.com/therecipe/qt/core"
"github.com/therecipe/qt/gui"
@@ -187,7 +187,6 @@ func (s *FrontendQt) watchEvents() {
updateApplicationCh := s.getEventChannel(events.UpgradeApplicationEvent)
newUserCh := s.getEventChannel(events.UserRefreshEvent)
certIssue := s.getEventChannel(events.TLSCertIssue)
- imapCertIssue := s.getEventChannel(events.IMAPTLSBadCert)
for {
select {
case errorDetails := <-errorCh:
@@ -227,8 +226,6 @@ func (s *FrontendQt) watchEvents() {
s.Qml.LoadAccounts()
case <-certIssue:
s.Qml.ShowCertIssue()
- case <-imapCertIssue:
- s.Qml.ShowIMAPCertTroubleshoot()
}
}
}
diff --git a/internal/frontend/qt/ui.go b/internal/frontend/qt/ui.go
index 30cffc26..76818132 100644
--- a/internal/frontend/qt/ui.go
+++ b/internal/frontend/qt/ui.go
@@ -135,7 +135,6 @@ type GoQMLInterface struct {
_ func(x, y float32) `slot:"saveOutgoingNoEncPopupCoord"`
_ func(recipient string) `signal:"showNoActiveKeyForRecipient"`
_ func() `signal:"showCertIssue"`
- _ func() `signal:"ShowIMAPCertTroubleshoot"`
_ func() `slot:"startUpdate"`
_ func(hasError bool) `signal:"updateFinished"`
diff --git a/internal/imap/backend.go b/internal/imap/backend.go
index 237df196..5a8063cf 100644
--- a/internal/imap/backend.go
+++ b/internal/imap/backend.go
@@ -28,7 +28,6 @@ import (
"github.com/ProtonMail/proton-bridge/pkg/listener"
"github.com/emersion/go-imap"
goIMAPBackend "github.com/emersion/go-imap/backend"
- "github.com/sirupsen/logrus"
)
type panicHandler interface {
@@ -198,11 +197,3 @@ func (ib *imapBackend) monitorDisconnectedUsers() {
ib.deleteUser(address)
}
}
-
-func (ib *imapBackend) upgradeError(err error) {
- logrus.WithError(err).Error("IMAP connection couldn't be upgraded to TLS during STARTTLS")
-
- if strings.Contains(err.Error(), "remote error: tls: bad certificate") {
- ib.eventListener.Emit(events.IMAPTLSBadCert, err.Error())
- }
-}
diff --git a/internal/imap/server.go b/internal/imap/server.go
index 937872c3..0628d77e 100644
--- a/internal/imap/server.go
+++ b/internal/imap/server.go
@@ -58,7 +58,6 @@ func NewIMAPServer(debugClient, debugServer bool, port int, tls *tls.Config, ima
s.AllowInsecureAuth = true
s.ErrorLog = newServerErrorLogger("server-imap")
s.AutoLogout = 30 * time.Minute
- s.UpgradeError = imapBackend.upgradeError
serverID := imapid.ID{
imapid.FieldName: "ProtonMail Bridge",
diff --git a/internal/store/mocks/mocks.go b/internal/store/mocks/mocks.go
index 467863be..8fd5c2d6 100644
--- a/internal/store/mocks/mocks.go
+++ b/internal/store/mocks/mocks.go
@@ -5,9 +5,10 @@
package mocks
import (
+ reflect "reflect"
+
pmapi "github.com/ProtonMail/proton-bridge/pkg/pmapi"
gomock "github.com/golang/mock/gomock"
- reflect "reflect"
)
// MockPanicHandler is a mock of PanicHandler interface
diff --git a/internal/store/mocks/utils_mocks.go b/internal/store/mocks/utils_mocks.go
index 3f43bb43..940bf172 100644
--- a/internal/store/mocks/utils_mocks.go
+++ b/internal/store/mocks/utils_mocks.go
@@ -5,9 +5,10 @@
package mocks
import (
- gomock "github.com/golang/mock/gomock"
reflect "reflect"
time "time"
+
+ gomock "github.com/golang/mock/gomock"
)
// MockListener is a mock of Listener interface
diff --git a/internal/transfer/mocks/mocks.go b/internal/transfer/mocks/mocks.go
index bc18f2b7..560303bf 100644
--- a/internal/transfer/mocks/mocks.go
+++ b/internal/transfer/mocks/mocks.go
@@ -5,9 +5,10 @@
package mocks
import (
+ reflect "reflect"
+
pmapi "github.com/ProtonMail/proton-bridge/pkg/pmapi"
gomock "github.com/golang/mock/gomock"
- reflect "reflect"
)
// MockPanicHandler is a mock of PanicHandler interface
diff --git a/internal/users/mocks/mocks.go b/internal/users/mocks/mocks.go
index 524d3273..dd087706 100644
--- a/internal/users/mocks/mocks.go
+++ b/internal/users/mocks/mocks.go
@@ -5,11 +5,12 @@
package mocks
import (
+ reflect "reflect"
+
store "github.com/ProtonMail/proton-bridge/internal/store"
credentials "github.com/ProtonMail/proton-bridge/internal/users/credentials"
pmapi "github.com/ProtonMail/proton-bridge/pkg/pmapi"
gomock "github.com/golang/mock/gomock"
- reflect "reflect"
)
// MockConfiger is a mock of Configer interface