From 8b3411a1b5dee3701c82df87a060726f7bc70051 Mon Sep 17 00:00:00 2001 From: DavidXanatos <3890945+DavidXanatos@users.noreply.github.com> Date: Mon, 30 Sep 2024 14:18:08 +0200 Subject: [PATCH] 1.14.10 --- CHANGELOG.md | 3 + SandboxiePlus/SandMan/Forms/ExtractDialog.ui | 71 ++++++++++--------- SandboxiePlus/SandMan/Views/SbieView.cpp | 4 +- .../SandMan/Windows/ExtractDialog.cpp | 2 + SandboxiePlus/SandMan/Windows/ExtractDialog.h | 2 + 5 files changed, 49 insertions(+), 33 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 534ea6c6..69b26e6b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,9 @@ This project adheres to [Semantic Versioning](http://semver.org/). ## [1.14.10 / 5.69.10] - 2024-09- +### Added +- added Ability to import encrypted archive files directly [#4255](https://github.com/sandboxie-plus/Sandboxie/issues/4255) + ### Fixed - fixed issue with sandbox path entry combo boxes - fixed Proxy for GetRawInputDeviceInfoW() causes a buffer overflow [#4267](https://github.com/sandboxie-plus/Sandboxie/issues/4267) (thanks marti4d) diff --git a/SandboxiePlus/SandMan/Forms/ExtractDialog.ui b/SandboxiePlus/SandMan/Forms/ExtractDialog.ui index 25b447c3..f4f73e85 100644 --- a/SandboxiePlus/SandMan/Forms/ExtractDialog.ui +++ b/SandboxiePlus/SandMan/Forms/ExtractDialog.ui @@ -16,26 +16,6 @@ - - - - - - - Import Sandbox from an archive - - - true - - - - - - - Import Sandbox Name - - - @@ -43,18 +23,8 @@ - - - - Qt::Vertical - - - - 20 - 40 - - - + + @@ -70,6 +40,43 @@ + + + + Import Sandbox Name + + + + + + + Export Sandbox from an archive + + + true + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + Import without encryption + + + diff --git a/SandboxiePlus/SandMan/Views/SbieView.cpp b/SandboxiePlus/SandMan/Views/SbieView.cpp index 7bc997e8..f5a91894 100644 --- a/SandboxiePlus/SandMan/Views/SbieView.cpp +++ b/SandboxiePlus/SandMan/Views/SbieView.cpp @@ -1074,6 +1074,8 @@ QString CSbieView::ImportSandbox() QString Name = NameEx.first; CExtractDialog optWnd(Name, this); + if(!Password.isEmpty()) + optWnd.ShowNoCrypt(); if (!theGUI->SafeExec(&optWnd) == 1) return ""; Name = optWnd.GetName(); @@ -1090,7 +1092,7 @@ QString CSbieView::ImportSandbox() if (!BoxRoot.isEmpty()) pBox->SetFileRoot(BoxRoot); - if (!Password.isEmpty()) { + if (!Password.isEmpty() && !optWnd.IsNoCrypt()) { Status = pBoxEx->ImBoxCreate(ImageSize / 1024, Password); if (!Status.IsError()) Status = pBoxEx->ImBoxMount(Password, true, true); diff --git a/SandboxiePlus/SandMan/Windows/ExtractDialog.cpp b/SandboxiePlus/SandMan/Windows/ExtractDialog.cpp index c862ce92..d5d5e4e8 100644 --- a/SandboxiePlus/SandMan/Windows/ExtractDialog.cpp +++ b/SandboxiePlus/SandMan/Windows/ExtractDialog.cpp @@ -41,6 +41,8 @@ CExtractDialog::CExtractDialog(const QString& Name, QWidget *parent) ui.cmbRoot->setCurrentText(FilePath.replace("/", "\\")); }); + ui.chkNoCrypt->setVisible(false); + connect(ui.buttonBox, SIGNAL(accepted()), SLOT(OnAccept())); connect(ui.buttonBox, SIGNAL(rejected()), SLOT(reject())); diff --git a/SandboxiePlus/SandMan/Windows/ExtractDialog.h b/SandboxiePlus/SandMan/Windows/ExtractDialog.h index 53f437ac..ee34d4b9 100644 --- a/SandboxiePlus/SandMan/Windows/ExtractDialog.h +++ b/SandboxiePlus/SandMan/Windows/ExtractDialog.h @@ -14,6 +14,8 @@ public: QString GetName() const { return ui.txtName->text(); } QString GetRoot() const; + void ShowNoCrypt() const { ui.chkNoCrypt->setVisible(true); } + bool IsNoCrypt() const { return ui.chkNoCrypt->isChecked(); } private slots: void OnAccept();