Skip to content

Commit

Permalink
ExtendedTools smbios
Browse files Browse the repository at this point in the history
  • Loading branch information
jxy-s committed Jan 8, 2025
1 parent ca1c443 commit eb80e07
Show file tree
Hide file tree
Showing 8 changed files with 941 additions and 3 deletions.
8 changes: 6 additions & 2 deletions SystemInformer/SystemInformer.def
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ EXPORTS
PhShellOpenKey
PhShellOpenKey2
PhShellProcessHacker
PhShowChooseProcessDialog
PhShowChooseProcessDialog
PhShowHandleObjectProperties1
PhShowHandleObjectProperties2
PhShowIconNotification
Expand All @@ -176,7 +176,7 @@ EXPORTS
PhWordMatchStringRef
PhWritePhTextHeader
PhaChoiceDialog
PhaGetProcessKnownCommandLine
PhaGetProcessKnownCommandLine

; plugin
PhEnumeratePlugins
Expand Down Expand Up @@ -501,6 +501,10 @@ EXPORTS
PhfWaitForEvent
PhfWaitForRundownProtection

; phfirmware
PhEnumSMBIOS
PhGetSMBIOSString

; phnative
PhAdjustPrivilege
PhConnectPipe
Expand Down
13 changes: 13 additions & 0 deletions plugins/ExtendedTools/ExtendedTools.rc
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,15 @@ BEGIN
CONTROL "",IDC_LIST,"SysListView32",LVS_REPORT | LVS_SHOWSELALWAYS | LVS_SHAREIMAGELISTS | LVS_ALIGNLEFT | WS_BORDER | WS_TABSTOP,7,7,246,246
END

IDD_SMBIOS DIALOGEX 0, 0, 309, 265
STYLE DS_SETFONT | DS_FIXEDSYS | WS_MINIMIZEBOX | WS_MAXIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME
EXSTYLE WS_EX_APPWINDOW
CAPTION "SMBIOS"
FONT 8, "MS Shell Dlg", 400, 0, 0x1
BEGIN
CONTROL "",IDC_SMBIOS_INFO,"SysListView32",LVS_REPORT | LVS_SHOWSELALWAYS | LVS_ALIGNLEFT | WS_TABSTOP,0,0,309,265
END


/////////////////////////////////////////////////////////////////////////////
//
Expand Down Expand Up @@ -725,6 +734,10 @@ BEGIN
IDD_OBJWINSTA, DIALOG
BEGIN
END

IDD_DEVICE_INTERFACES, DIALOG
BEGIN
END
END
#endif // APSTUDIO_INVOKED

Expand Down
1 change: 1 addition & 0 deletions plugins/ExtendedTools/ExtendedTools.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@
<ClCompile Include="PresentMon\TraceConsumer.cpp" />
<ClCompile Include="PresentMon\TraceSession.cpp" />
<ClCompile Include="reparse.c" />
<ClCompile Include="smbios.c" />
<ClCompile Include="svcext.c" />
<ClCompile Include="tpm.c" />
<ClCompile Include="tpm_editor.c" />
Expand Down
3 changes: 3 additions & 0 deletions plugins/ExtendedTools/ExtendedTools.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,9 @@
<ClCompile Include="tpm_editor.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="smbios.c">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="resource.h">
Expand Down
10 changes: 10 additions & 0 deletions plugins/ExtendedTools/exttools.h
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ extern BOOLEAN EtEnableAvxSupport;
#define SETTING_NAME_TPM_WINDOW_POSITION (PLUGIN_NAME L".TpmWindowPosition")
#define SETTING_NAME_TPM_WINDOW_SIZE (PLUGIN_NAME L".TpmWindowSize")
#define SETTING_NAME_TPM_LISTVIEW_COLUMNS (PLUGIN_NAME L".TpmListViewColumns")
#define SETTING_NAME_SMBIOS_WINDOW_POSITION (PLUGIN_NAME L".SMBIOSWindowPosition")
#define SETTING_NAME_SMBIOS_WINDOW_SIZE (PLUGIN_NAME L".SMBIOSWindowSize")
#define SETTING_NAME_SMBIOS_INFO_COLUMNS (PLUGIN_NAME L".SMBIOSListViewColumns")
#define SETTING_NAME_SMBIOS_SHOW_UNDEFINED_TYPES (PLUGIN_NAME L".SMBIOSShowUndefinedTypes")

VOID EtLoadSettings(
VOID
Expand Down Expand Up @@ -1742,4 +1746,10 @@ VOID EtShowTpmEditDialog(
_In_ TPM_NV_INDEX Index
);

// smbios

VOID EtShowSMBIOSDialog(
_In_ HWND ParentWindowHandle
);

#endif
12 changes: 12 additions & 0 deletions plugins/ExtendedTools/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,11 @@ VOID NTAPI MenuItemCallback(
EtShowPipeEnumDialog(menuItem->OwnerWindow);
}
break;
case ID_SMBIOS:
{
EtShowSMBIOSDialog(menuItem->OwnerWindow);
}
break;
case ID_FIRMWARE:
{
EtShowFirmwareDialog(menuItem->OwnerWindow);
Expand Down Expand Up @@ -244,6 +249,9 @@ VOID NTAPI MainMenuInitializingCallback(

PhInsertEMenuItem(systemMenu, PhPluginCreateEMenuItem(PluginInstance, 0, ID_POOL_TABLE, L"Poo&l Table", NULL), ULONG_MAX);
PhInsertEMenuItem(systemMenu, PhPluginCreateEMenuItem(PluginInstance, 0, ID_OBJMGR, L"&Object Manager", NULL), ULONG_MAX);
#ifdef DEBUG // WIP(jxy-s)
PhInsertEMenuItem(systemMenu, PhPluginCreateEMenuItem(PluginInstance, 0, ID_SMBIOS, L"SM&BIOS", NULL), ULONG_MAX);
#endif
PhInsertEMenuItem(systemMenu, bootMenuItem = PhPluginCreateEMenuItem(PluginInstance, 0, ID_FIRMWARE, L"Firm&ware Table", NULL), ULONG_MAX);
PhInsertEMenuItem(systemMenu, tpmMenuItem = PhPluginCreateEMenuItem(PluginInstance, 0, ID_TPM, L"&Trusted Platform Module", NULL), ULONG_MAX);
PhInsertEMenuItem(systemMenu, PhPluginCreateEMenuItem(PluginInstance, 0, ID_PIPE_ENUM, L"&Named Pipes", NULL), ULONG_MAX);
Expand Down Expand Up @@ -1338,6 +1346,10 @@ LOGICAL DllMain(
{ IntegerPairSettingType, SETTING_NAME_TPM_WINDOW_POSITION, L"0,0" },
{ ScalableIntegerPairSettingType, SETTING_NAME_TPM_WINDOW_SIZE, L"@96|490,340" },
{ StringSettingType, SETTING_NAME_TPM_LISTVIEW_COLUMNS, L"" },
{ IntegerPairSettingType, SETTING_NAME_SMBIOS_WINDOW_POSITION, L"0,0" },
{ ScalableIntegerPairSettingType, SETTING_NAME_SMBIOS_WINDOW_SIZE, L"@96|490,340" },
{ StringSettingType, SETTING_NAME_SMBIOS_INFO_COLUMNS, L"" },
{ IntegerSettingType, SETTING_NAME_SMBIOS_SHOW_UNDEFINED_TYPES, L"0" },
};

PluginInstance = PhRegisterPlugin(PLUGIN_NAME, Instance, &info);
Expand Down
5 changes: 4 additions & 1 deletion plugins/ExtendedTools/resource.h
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@
#define IDI_UNKNOWN 4012
#define IDC_OBJMGR_LIST 4013
#define IDC_OBJMGR_TREE 4014
#define ID_SMBIOS 5000
#define ID_FIRMWARE 5001
#define IDD_FIRMWARE 5002
#define IDD_FIRMWARE_EDITVAR 5003
Expand All @@ -171,6 +172,8 @@
#define IDC_FIRMWARE_BYTESPERROW 5008
#define IDC_FIRMWARE_BOOT_LIST 5009
#define IDC_FIRMWARE_BOOT_REFRESH 5010
#define IDD_SMBIOS 5011
#define IDC_SMBIOS_INFO 5012
#define ID_PIPE_ENUM 6000
#define IDD_PIPEDIALOG 6001
#define IDC_ATOMLIST 6002
Expand Down Expand Up @@ -208,7 +211,7 @@


// Next default values for new objects
//
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 172
Expand Down
Loading

0 comments on commit eb80e07

Please sign in to comment.