I suspect you're misunderstanding something, assuming I understand your
point 4. Neither AdminUser nor Privileged will cause your CA to run
elevated. They're typically used as LaunchConditions, and they also
happen to be unreliable in Vista in the UI sequence. To get your CA to
run elevated in the UI sequence you need to launch it with elevated
privilege, and an elevated bootstrapper can do that, and that in turn
requires an administrator account to do the launching. Bottom line, you
must supply an admin account somewhere. At the risk of stating the
obvious, this is not a scenario in which a standard user can cause
elevated code to run during an install.
Phil Wilson
________________________________
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Chuck
Sent: Monday, April 02, 2007 9:51 AM
To: wix-users@lists.sourceforge.net
Subject: Re: [WiX-users] CA with elevated privileges under Vista!
Phil,
Thanx for your response.
1. Yes, "early in the installation process" does mean in the UI
sequence...I know that this is not a recommended way to execute elevated
CAs but I have a task that must be done prior to displaying a custom
dialog that requires it.
2. I stuffed the manifest into the dll to ensure that all of my bases
were covered...I haven't done a lot of work with them in the past and I
figured that what you said would be true but just wanted to make sure I
hadn't missed it if it was needed.
3. The setup.exe is asking for an Admin password if I am running the
install as a "Standard" user...and it is asking for the OK to go ahead
and run if I am logged on as an Admin user.
4. I've tried using both AdminUser and Privileged properties and neither
of them causes the CA to run as admin!
Any other thoughts on how I can get this CA to run as an Administrator?
Thanx
Chuck
> A couple or four things:=20
> 1) Does "early in the installation process" mean in the UI
sequence?=20
> 2) Manifests target executables, not Dlls - they run with the level of
> the exe that loads them.=20
> 3) If the setup.exe isn't asking for elevation via Cancel/Allow but is
> asking for an admin account, then it means you're not an administrator
> but you need to be. Someone has to provide admin credentials, either
you
> elevated to admin or somebody "over the shoulder" on your behalf.=20
> 4) AdminUser is unreliable under Vista. =20
> =20
>
http://blogs.msdn.com/rflaming/archive/2006/09/21/uac-in-msi-notes-the-a
> dminuser-mistake.aspx =20
> Phil Wilson=20
Chuck wrote:
I have the following situation:
I am creating an MSI in which I need to run a CA early in the
installation process, the DA is in a C dll. The CA "Requires" Admin
access under Vista. I am wrapping the msi in a setup.exe boot strapper
that has a manifest with requestedExecutionLevel
level="requireAdministrator". In my WIX project I have a condition for
AdminUser and in the package I have InstallPrivileges set to elevated.
The dll has requireAdministrator in its manifest.
The problem that I'm having is that the code that I'm executing
in my CA fails to execute correctly. I extracted the code and compiled
it into an exe with the same manifest as above. When I run the exe the
code completes correctly!
In both cases I am getting prompted for an Admin
password...which would lead one to think that the installer is running
as an Admin user...but the CA fails.
Any thoughts on this would be greatly appreciated.
Thanx
Chuck
--
Chuck Hatt
Magic Kite Software Ltd <http://www.magickite.com>
Makers of Sourcerer: managing the risks in your software development.
Phone: 250.383.8175
Cell: 250.889.0119
email: [EMAIL PROTECTED]
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users