Does it fail on installation?
And as Sascha said that after pressing of the install button user will be 
prompted to enter a username and password, but you should be sure that you 
specified Impersonate="no" property on deferred custom actions which require 
admin rights.

-----Original Message-----
From: Sascha Beaumont [mailto:sascha.beaum...@gmail.com] 
Sent: Friday, February 12, 2010 4:00 AM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] Admin check in Win 2008?

Without MSIUSEREALADMINDETECTION set the user can run the MSI, but
they can't install the application. Once they press the 'Install'
button (with the UAC Shield) they'll be prompted to enter a username
and password to continue. With MSIUSEREALADMINDETECTION set to 1 then
the message will display.

As you shouldn't be modifying the system outside of the
InstallExecuteSequence anyway I can't see how this would be a problem?

Here's the code I'm using below, as the condition all looks OK I've
included the Package element - I don't know if the settings there
would have any effect on the behaviour?

        <Package Description="!(loc.Package_Description) $(var.version)"
           Comments="!(loc.Package_Comments)"
           Manufacturer="!(loc.ManufacturerName)"
           InstallerVersion="301"
           Compressed="yes"
           InstallPrivileges="elevated"
           InstallScope="perMachine"
           Platform="$(var.ProcessorArchitecture)" />

        <Condition Message="!(loc.LaunchCondition_AdminPrivs)">
                <![CDATA[Installed OR Privileged]]>
        </Condition>

On Fri, Feb 12, 2010 at 6:56 AM, Tabmow <tabmo...@gmail.com> wrote:
>
>  Hi all,
>    I previously used (in Win 2003) this check to ensure that only a user
> with admin privileges could run our msi:
>
>  <Condition Message="You need to be an administrator to install this
> product.">
>      Privileged
>  </Condition>
>
> and that worked fine.  However, we've moved to Windows 2008 R2 and now that
> check doesn't seem to do anything in a non-admin user attempts to run ->
> everyone is allowed to run the MSI now.
> I poked around google and this group, and i do see posts like this one:
> http://n2.nabble.com/Admin-Check-in-VISTA-OS-td707200.html#a707200
>
> that mention to use MSIUSEREALADMINDETECTION, which i've done (set it to 1),
> but then this still doesn't seem to do what I want (which is prevent
> non-admin from running MSI).
>
> I've tried this in InstallExecuteSequence:
>
> <Custom Action='IsPrivileged' Before='LaunchConditions'>
>        Not AdminUser
> </Custom>
>
> and also used "Not Privilege" there instead too with no luck.    What am I
> missing?  Any ideas or suggestions would be great.
>
> Thanks.
>
> --
> View this message in context: 
> http://n2.nabble.com/Admin-check-in-Win-2008-tp4557002p4557002.html
> Sent from the wix-users mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
> SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
> Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
> http://p.sf.net/sfu/solaris-dev2dev
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
>

------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
</pre>
<BR style="font-size:4px;">
<a href = "http://www.sdl.com";><img src="http://www.sdl.com/images/email 
logo_150dpi-01.png" alt="www.sdl.com" border="0"/></a>
<BR>
<font face="arial"  size="2" "><a href = "http://www.sdl.com"; 
style="color:005740; font-weight: bold">www.sdl.com</a>
<BR>
<BR>
<font face="arial"  size="1" color="#736F6E">
<b>SDL PLC confidential, all rights reserved.</b>
If you are not the intended recipient of this mail SDL requests and requires 
that you delete it without acting upon or copying any of its contents, and we 
further request that you advise us.<BR>
SDL PLC is a public limited company registered in England and Wales.  
Registered number: 02675207.<BR>
Registered address: Globe House, Clivemont Road, Maidenhead, Berkshire SL6 7DY, 
UK.
</font>

------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to