'link/window general'에 해당되는 글 71건
- 2018.01.23 Gadgets have been discontinued.
- 2018.01.22 How to get the edition information of Windows
- 2018.01.16 Using ShellExecute or ShellExecuteEx instead of using CreateProcess when an executable is marked as "requiredAdministrator"
- 2018.01.04 Usage Notes WS_EX_CONTROLPARENT
- 2018.01.03 Winlogon Automatic Restart Sign-On (ARSO)
- 2016.05.20 Understanding and Working in Protected Mode Internet Explorer - Allowing Drag and Drop Operations in your Application
- 2016.03.04 Using ON_UPDATE_COMMAND_UI in dialog window
- 2016.02.16 Dual Code Signing
- 2015.09.17 Managing BHO by GPO
- 2015.08.04 registry value redirection
Gadgets have been discontinued.

Recently, I was researching how to get an edition of Windows, so I checked the registry value of each Windows(XP - Windows 10). Suddenly, I was curious to know about whether Windows 10 supports Gadgets when I saw the Gadgets on Windows Vista. Then, I've found the link below
How to get the edition information of Windows

- GetProductionInfo API
- note: minimum support : Windows Vista / Windows Server 2008
- link
- prodspec.ini
- location: %systemroot%\system32\prodspec.ini
- example
- [Product Specification]
- Product=Windows XP Professional
- note: This file is only existed in Windows XP.
- link
- EditionID (REG_SZ)
- location: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion
- note: This registry value is not exist in Windows XP.
Using ShellExecute or ShellExecuteEx instead of using CreateProcess when an executable is marked as "requiredAdministrator"

An executable that is marked as "requireAdministrator" in its manifest cannot be started from a non-elevated process using CreateProcess(). Instead, ERROR_ELEVATION_REQUIRED will be returned. ShellExecute() or ShellExecuteEx() must be used instead. If an HWND is not supplied, then the dialog will show up as a blinking item in the taskbar.
When embedding a dialog inside another, make sure you don’t accidentally create duplicate control IDshttps://blogs.msdn.microsoft.com/oldnewthing/20120620-00/?p=7333
Winlogon Automatic Restart Sign-On (ARSO)

- What is ARSO?
- It makes a device will automatically sign-in the last interactive user after Windows Update restarts the system.
- We can decide to use this function or not by GPO or other options.
- link
- But after Win 10 RS3 1709 build 16251, this function has been extended to regular reboots and shutdowns.
Understanding and Working in Protected Mode Internet Explorer - Allowing Drag and Drop Operations in your Application

Using ON_UPDATE_COMMAND_UI in dialog window

CAUSE
When a drop-down menu is displayed, the WM_INITMENUPOPUP message is sent prior to displaying the menu items. The MFCCFrameWnd::OnInitMenuPopup function iterates through the menu items and calls the update command UI handler for the item, if there is one. The appearance of each menu item is updated to reflect its state (enabled/disabled, checked/unchecked).
The update UI mechanism doesn't work for a dialog box-based application because CDialog has no OnInitMenuPopup handler and it uses CWnd's default handler, which does not call update command UI handlers for menu items.
Dual Code Signing Instructions with SHA1 & SHA256 hashing Algorithm
Signing Tool:
Step 1: Sign the Primary Signature with SHA1 Algorithm
The following syntax signs the file using a certificate stored in your Personal certificate store
With TimeStamp:
signtool.exe sign /a /s MY /n "Common name" /fd sha1 /t http://timestamp.verisign.com/scripts/timstamp.dll /v "<file to be signed>" |
Step 2: Append the Secondary Signature with SHA256 Algorithm
Once the application file been signed with SHA1 algorithm in Step 1 , follow the steps below to append the secondary signature with SHA256 algorithm to the same application file.
The following syntax signs the file using a certificate stored in your Personal certificate store
With TimeStamp:
signtool.exe sign /a /s MY /n "Common name" /as /fd sha256 /tr http://timestamp.geotrust.com/tsa /v "<file to be signed>" |
Windows 7
https://technet.microsoft.com/ko-kr/library/security/2949927.aspx
registry value redirection
- %ProgramFiles% => %ProgramFiles(x86)%
- %commonprogramfiles% => %commonprogramfiles(x86)%
https://msdn.microsoft.com/en-us/library/aa384232(VS.85).aspx