rollback 4049

This commit is contained in:
DavidXanatos 2024-07-13 15:39:14 +02:00
parent a23f7ca605
commit 17965f4f89
6 changed files with 213 additions and 243 deletions

View File

@ -8,7 +8,6 @@ This project adheres to [Semantic Versioning](http://semver.org/).
- added UI options for "ForceRestartAll" and "UseCreateToken" in OptionWindow
- added an optional context menu option to make folder/file forced quickly
- You can also use "Sandman.exe /add_force program_path" to do it
- added option "Improve3DGameRate" to enhance 3D games' FPS

View File

@ -215,20 +215,6 @@ _FX BOOLEAN Syscall_Init_List(void)
LIST disabled_hooks;
Syscall_LoadHookMap(L"DisableWinNtHook", &disabled_hooks);
if (Conf_Get_Boolean(NULL, L"Improve3DGameRate", 0, FALSE)) {
PATTERN* pat = Pattern_Create(Driver_Pool, L"WaitForSingleObject", FALSE, 0);
if (pat)
List_Insert_After(&disabled_hooks, NULL, pat);
pat = Pattern_Create(Driver_Pool, L"ReleaseSemaphore", FALSE, 0);
if (pat)
List_Insert_After(&disabled_hooks, NULL, pat);
pat = Pattern_Create(Driver_Pool, L"SetEvent", FALSE, 0);
if (pat)
List_Insert_After(&disabled_hooks, NULL, pat);
pat = Pattern_Create(Driver_Pool, L"ClearEvent", FALSE, 0);
if (pat)
List_Insert_After(&disabled_hooks, NULL, pat);
}
LIST approved_syscalls;
Syscall_LoadHookMap(L"ApproveWinNtSysCall", &approved_syscalls);

View File

@ -1951,228 +1951,225 @@ Unlike the preview channel, it does not include untested, potentially breaking,
<item row="0" column="0">
<widget class="QTabWidget" name="tabsAdvanced">
<property name="currentIndex">
<number>0</number>
<number>1</number>
</property>
<widget class="QWidget" name="tabSandbox">
<attribute name="title">
<string>Sandboxie Config</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_18">
<layout class="QGridLayout" name="gridLayout_20">
<item row="0" column="0">
<widget class="QLabel" name="lblBoxRoot">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
<kerning>true</kerning>
</font>
</property>
<property name="text">
<string>Sandbox default</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Default sandbox:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QComboBox" name="cmbDefault"/>
</item>
<item row="1" column="5">
<widget class="QCheckBox" name="chkAutoRoot">
<property name="text">
<string>Portable root folder</string>
</property>
</widget>
</item>
<item row="2" column="0" colspan="2">
<widget class="QLabel" name="label_15">
<property name="text">
<string>Sandbox &lt;a href=&quot;sbie://docs/filerootpath&quot;&gt;file system root&lt;/a&gt;: </string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="2" colspan="2">
<widget class="QLineEdit" name="fileRoot"/>
</item>
<item row="2" column="6">
<widget class="QPushButton" name="btnBrowse">
<property name="maximumSize">
<size>
<width>23</width>
<height>16777215</height>
</size>
</property>
<property name="text">
<string>...</string>
</property>
</widget>
</item>
<item row="3" column="0" colspan="2">
<widget class="QLabel" name="label_16">
<property name="text">
<string>Sandbox &lt;a href=&quot;sbie://docs/keyrootpath&quot;&gt;registry root&lt;/a&gt;: </string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="3" column="2" colspan="2">
<widget class="QLineEdit" name="regRoot"/>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_17">
<property name="text">
<string>Sandbox &lt;a href=&quot;sbie://docs/ipcrootpath&quot;&gt;ipc root&lt;/a&gt;: </string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="4" column="2" colspan="2">
<widget class="QLineEdit" name="ipcRoot"/>
</item>
<item row="5" column="0" colspan="2">
<widget class="QLabel" name="lblBoxFeatures">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
<kerning>true</kerning>
</font>
</property>
<property name="text">
<string>Sandboxing features</string>
</property>
</widget>
</item>
<item row="5" column="2">
<spacer name="horizontalSpacer_12">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>108</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="6" column="1" colspan="4">
<widget class="QCheckBox" name="chkWFP">
<property name="text">
<string>Use Windows Filtering Platform to restrict network access</string>
</property>
</widget>
</item>
<item row="7" column="1" colspan="3">
<widget class="QCheckBox" name="chkObjCb">
<property name="text">
<string>Activate Kernel Mode Object Filtering</string>
</property>
</widget>
</item>
<item row="8" column="1" colspan="5">
<widget class="QCheckBox" name="chkWin32k">
<property name="text">
<string>Hook selected Win32k system calls to enable GPU acceleration (experimental)</string>
</property>
</widget>
</item>
<item row="9" column="1" colspan="3">
<widget class="QCheckBox" name="chkSbieLogon">
<property name="text">
<string>Use a Sandboxie login instead of an anonymous token</string>
</property>
</widget>
</item>
<item row="10" column="1" colspan="4">
<widget class="QCheckBox" name="chkSbieAll">
<property name="text">
<string>Add &quot;Sandboxie\All Sandboxes&quot; group to the sandboxed token (experimental)</string>
</property>
</widget>
</item>
<item row="11" column="1" colspan="4">
<widget class="QCheckBox" name="chkImproveGame">
<property name="text">
<string>Enhance the 3D gaming experience by releasing some system calls.</string>
</property>
</widget>
</item>
<item row="12" column="1">
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>108</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="12" column="2">
<spacer name="verticalSpacer_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>139</height>
</size>
</property>
</spacer>
</item>
<item row="12" column="3">
<spacer name="horizontalSpacer_15">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>107</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="12" column="4">
<spacer name="horizontalSpacer_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>108</width>
<height>20</height>
</size>
</property>
</spacer>
<layout class="QGridLayout" name="gridLayout_18">
<item row="11" column="4">
<spacer name="horizontalSpacer_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="11" column="2">
<spacer name="verticalSpacer_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item row="3" column="0" colspan="2">
<widget class="QLabel" name="label_16">
<property name="text">
<string>Sandbox &lt;a href=&quot;sbie://docs/keyrootpath&quot;&gt;registry root&lt;/a&gt;: </string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="lblBoxRoot">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
<kerning>true</kerning>
</font>
</property>
<property name="text">
<string>Sandbox default</string>
</property>
</widget>
</item>
<item row="1" column="2" colspan="2">
<widget class="QComboBox" name="cmbDefault"/>
</item>
<item row="4" column="2" colspan="5">
<widget class="QLineEdit" name="ipcRoot"/>
</item>
<item row="2" column="0" colspan="2">
<widget class="QLabel" name="label_15">
<property name="text">
<string>Sandbox &lt;a href=&quot;sbie://docs/filerootpath&quot;&gt;file system root&lt;/a&gt;: </string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="5" column="2">
<spacer name="horizontalSpacer_12">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="0" colspan="2">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Default sandbox:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="7" column="1" colspan="6">
<widget class="QCheckBox" name="chkObjCb">
<property name="text">
<string>Activate Kernel Mode Object Filtering</string>
</property>
</widget>
</item>
<item row="5" column="0" colspan="2">
<widget class="QLabel" name="lblBoxFeatures">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
<kerning>true</kerning>
</font>
</property>
<property name="text">
<string>Sandboxing features</string>
</property>
</widget>
</item>
<item row="11" column="3">
<spacer name="horizontalSpacer_15">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="8" column="1" colspan="6">
<widget class="QCheckBox" name="chkWin32k">
<property name="text">
<string>Hook selected Win32k system calls to enable GPU acceleration (experimental)</string>
</property>
</widget>
</item>
<item row="9" column="1" colspan="6">
<widget class="QCheckBox" name="chkSbieLogon">
<property name="text">
<string>Use a Sandboxie login instead of an anonymous token</string>
</property>
</widget>
</item>
<item row="2" column="2" colspan="5">
<widget class="QLineEdit" name="fileRoot"/>
</item>
<item row="1" column="5" colspan="2">
<widget class="QCheckBox" name="chkAutoRoot">
<property name="text">
<string>Portable root folder</string>
</property>
</widget>
</item>
<item row="4" column="0" colspan="2">
<widget class="QLabel" name="label_17">
<property name="text">
<string>Sandbox &lt;a href=&quot;sbie://docs/ipcrootpath&quot;&gt;ipc root&lt;/a&gt;: </string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="11" column="1">
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="3" column="2" colspan="5">
<widget class="QLineEdit" name="regRoot"/>
</item>
<item row="2" column="7">
<widget class="QPushButton" name="btnBrowse">
<property name="maximumSize">
<size>
<width>23</width>
<height>16777215</height>
</size>
</property>
<property name="text">
<string>...</string>
</property>
</widget>
</item>
<item row="6" column="1" colspan="6">
<widget class="QCheckBox" name="chkWFP">
<property name="text">
<string>Use Windows Filtering Platform to restrict network access</string>
</property>
</widget>
</item>
<item row="10" column="1" colspan="6">
<widget class="QCheckBox" name="chkSbieAll">
<property name="text">
<string>Add &quot;Sandboxie\All Sandboxes&quot; group to the sandboxed token (experimental)</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>

View File

@ -427,7 +427,6 @@ CSettingsWindow::CSettingsWindow(QWidget* parent)
connect(ui.chkWin32k, SIGNAL(stateChanged(int)), this, SLOT(OnGeneralChanged()));
connect(ui.chkSbieLogon, SIGNAL(stateChanged(int)), this, SLOT(OnGeneralChanged()));
connect(ui.chkSbieAll, SIGNAL(stateChanged(int)), this, SLOT(OnGeneralChanged()));
connect(ui.chkImproveGame, SIGNAL(stateChanged(int)), this, SLOT(OnGeneralChanged()));
m_GeneralChanged = false;
connect(ui.chkWatchConfig, SIGNAL(stateChanged(int)), this, SLOT(OnOptChanged())); // not sbie ini
@ -1012,7 +1011,6 @@ void CSettingsWindow::LoadSettings()
ui.chkWin32k->setChecked(theAPI->GetGlobalSettings()->GetBool("EnableWin32kHooks", true));
ui.chkSbieLogon->setChecked(theAPI->GetGlobalSettings()->GetBool("SandboxieLogon", false));
ui.chkSbieAll->setChecked(theAPI->GetGlobalSettings()->GetBool("SandboxieAllGroup", false));
ui.chkImproveGame->setChecked(theAPI->GetGlobalSettings()->GetBool("Improve3DGameRate", false));
ui.chkAdminOnly->setChecked(theAPI->GetGlobalSettings()->GetBool("EditAdminOnly", false));
ui.chkAdminOnly->setEnabled(IsAdminUser());
@ -1065,7 +1063,6 @@ void CSettingsWindow::LoadSettings()
ui.chkWin32k->setEnabled(false);
ui.chkSbieLogon->setEnabled(false);
ui.chkSbieAll->setEnabled(false);
ui.chkImproveGame->setEnabled(false);
ui.regRoot->setEnabled(false);
ui.ipcRoot->setEnabled(false);
ui.chkRamDisk->setEnabled(false);
@ -1716,7 +1713,6 @@ void CSettingsWindow::SaveSettings()
WriteAdvancedCheck(ui.chkWin32k, "EnableWin32kHooks", "", "n");
WriteAdvancedCheck(ui.chkSbieLogon, "SandboxieLogon", "y", "");
WriteAdvancedCheck(ui.chkSbieAll, "SandboxieAllGroup", "y", "");
WriteAdvancedCheck(ui.chkImproveGame, "Improve3DGameRate", "y", "");
if (m_FeaturesChanged) {
m_FeaturesChanged = false;

View File

@ -135,8 +135,6 @@ bool CSetupWizard::ShowWizard(int iOldLevel)
{
if (wizard.field("editAdminOnly").toBool())
theAPI->GetGlobalSettings()->SetText("EditAdminOnly", "y");
if (wizard.field("improveGame").toBool())
theAPI->GetGlobalSettings()->SetText("Improve3DGameRate", "y");
}
theConf->SetValue("Options/WizardLevel", SETUP_LVL_CURRENT);
@ -532,11 +530,6 @@ CShellPage::CShellPage(QWidget *parent)
layout->addWidget(m_pEditOnlyAdmin);
registerField("editAdminOnly", m_pEditOnlyAdmin);
m_pImproveGame = new QCheckBox(tr("Enhance the 3D gaming experience by releasing some system calls."));
m_pImproveGame->setChecked(false);
layout->addWidget(m_pImproveGame);
registerField("improveGame", m_pImproveGame);
setLayout(layout);
}

View File

@ -123,7 +123,6 @@ private:
QCheckBox *m_pContecxtMenu;
QCheckBox *m_pBrowserIcon;
QCheckBox* m_pEditOnlyAdmin;
QCheckBox* m_pImproveGame;
};
//////////////////////////////////////////////////////////////////////////////////////////