Solved

UAC and Runtime Themes

Posted on 2014-09-23
5
429 Views
Last Modified: 2014-09-24
Hi,

My Application Setup (App_Setup.exe) displayed the UAC Shield because it contains the word 'Setup'.
I do not want to elevate the App_Setup.exe.
I came across 'Enable Runtime Themes'and With this set the UAC shield goes off,
and my Setup program is not elevated and my task is accomplished.

Question
Why this behaviour as themes have nothing to do with Security ?
Will the behaviour be consistent across all windows/delphi versions ?

I use Delphi Xe2 currently and soon moving to Xe6. Also tested on WinXP/win7/win8.

Regards
Allan
0
Comment
Question by:Allan_Fernandes
  • 3
  • 2
5 Comments
 
LVL 26

Expert Comment

by:Sinisa Vuk
ID: 40339151
According to this articles:
uac-five-most-common-install-failure-scenarios-and-workarounds
Understanding and Configuring User Account Control in Windows Vista
... if you set proper manifest into exe (setup exe at least) - then you will not have problems any more.
It is not Delphi related, but exe build old way (not using manifest file).
Use Inno setup and you will not have a problem with that.

...and when ms is in question .... nothing is certain.
0
 

Author Comment

by:Allan_Fernandes
ID: 40340768
I do not want to elevate the App_Setup.exe so I cannot use Manifest. Elevating changes the user, I want my application to run under same user as I work on Outlook.pst. What I want to know is
Why this behaviour as themes have nothing to do with Security ?
Will the behaviour be consistent across all windows/delphi versions ?
0
 
LVL 26

Accepted Solution

by:
Sinisa Vuk earned 500 total points
ID: 40340890
Theming certainly adds manifest into exe - because manifest switch from old comctl (v5) to newer (v6).
http://msdn.microsoft.com/en-us/library/windows/desktop/bb773175%28v=vs.85%29.aspx
As a result when manifest is in exe - Security check is fine. Again, it is not Delphi related - because MS windows request those. Will be in future some changes....does not depent on Delphi (Embarcadero) but Ms first. Adding manifest to your exe is very simple and one time job - like including this line after you build own manifest: {$R MyMan.RES}
http://delphi.about.com/library/bluc/text/uc111601a.htm
- description of manifest file:
http://msdn.microsoft.com/en-us/library/aa374191%28VS.85%29.aspx
Adding this manifest will trigger theming too.
0
 

Author Comment

by:Allan_Fernandes
ID: 40341768
Thanks for all the assistance. Added AsInvoker in custom manifest instead of requireadministrator and that works fine.
0
 
LVL 26

Expert Comment

by:Sinisa Vuk
ID: 40342509
yes, requireadministrator force application to be run as administrator
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The use of stolen credentials is a hot commodity this year allowing threat actors to move laterally within the network in order to avoid breach detection.
Sometimes drives fill up and we don't know why.  If you don't understand the best way to use the tools available, you may end up being stumped as to why your drive says it's not full when you have no space left!  Here's how you can find out...
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now