PDA

View Full Version : Question about execution level



NewsArchive
01-13-2011, 12:49 AM
I have execution level set to highest available. Users who have installed
in the last couple of days seem to be having a problem
with there user administrator setting being downgraded. In other words
under users it shows them as administrators.
Other programs however report them as not administrator.

A reboot has usually solved this but not in one case. Is there a chance
this is being caused by the installation. This also,
happened on my machine after running the installation.

Most users are installing from a station to a network drive. 7.3.3166

Should I be using something besides highest available

Can this be caused by setup builder or is this just an coincidence.

Gary

NewsArchive
01-13-2011, 12:50 AM
Gary,

> Should I be using something besides highest available

Unless necessary use AsInvoker.

--
Lee White

RPM Report Viewer.: http://www.cwaddons.com/products/rpm/
RPM Review........: http://www.clarionmag.com/cmag/v11/v11n06rpm.html
Report Faxing.....: http://www.cwaddons.com/products/afe/
---Enroll Today---: http://CWaddons.com

Enhanced Reporting: http://www.cpcs-inc.com

NewsArchive
01-13-2011, 12:51 AM
> I have execution level set to highest available. Users who have installed
> in the last couple of days seem to be having a problem
> with there user administrator setting being downgraded. In other words
> under users it shows them as administrators.
> Other programs however report them as not administrator.

Welcome to Vista and Windows!

To short circuit a common exploit that hackers have used for years (namely
where everyone made their account an "Administrator") Vista and Windows 7
change the way a user executes a program.

Having an "Administrator" account on the machine gives you the rights to do
Administrator level things (such as install a program).

In order to install a program, the installer has to run elevated, so that
is "Gary the Administrator".

However when you RUN the program the next time, then "Gary the
Administrator" becomes "Gary the User".

That is why it is important that your program use CSIDL locations for the
data, doesn't try to write ANY file under the Program Files folder and does
not attempt to write to the HKLM Registry. Any attempt to do this causes
the writes to be "Virtualized" by Windows - then all hell breaks loose<g>.

It is also a reason that you should NOT provide an offer to run the program
at the end of the install (on Vista/Windows 7) unless it is with the
special option in SetupBuilder that allows you to run an application
non-elevated.

Otherwise even if you are using CSIDL locations, your data will go to the
CSIDL location for "Gary the Administrator", not "Gary the User". Then
when "Gary the User" runs your program (non elevated), he will not see data
created by the application when it was in "Gary the Administrator" mode.

That is why we wrote the ProPath templates for Clarion users. It makes it
easy to put the data files (as well as INI or writeable program files) in
the correct per user locations.


> Should I be using something besides highest available

As Lee said, use "As Involker" unless your program is doing something
special that requires elevation.


> Can this be caused by setup builder or is this just an coincidence.

Not a SetupBuilder problem - just the way modern OS's work.

:-)

Charles


--
-------------------------------------------------------------------------------------------------------
Charles Edmonds
www.clarionproseries.com - "Get ProPath, make your Clarion programs ready
for Windows 7 and Vista!"
www.ezchangelog.com - "Free ChangeLog software to manage your projects!"
www.setupcast.com - "A revolutionary new publishing system for software
developers - enhanced for SetupBuilder users!"
www.pagesnip.com - "Print and Save the Web, just the way you want it!"
www.clarionproseries.com - "Serious tools for Clarion Developers"
www.ezround.com - "Round Corner HTML tables with matching Banners, Buttons
and Forms - Now with PNG support!
www.lansrad.com - "Intelligent Solutions for Universal Problems"
www.fotokiss.com - "World's Best Auction Photo Editor"
-------------------------------------------------------------------------------------------------------

NewsArchive
01-14-2011, 12:42 AM
"Highest Available" is a weirdo.
It means you ask the operating system for whatever you may have beyond
standard user credentials, but you're not an administrator.
One often-cited use for such a level would be for a backup program, which
could operate if the user had "server operator" or "backup operator" group
membership but wasn't an administrator.

If your app gets installed on anything later than XP or Server 2003, it
really needs "requireAdministrator" for the installation program. The app
itself should do fine "asInvoker" if you've followed the rules as to where
your app is allowed to write to the hard disk and the Registry.

If this stuff isn't familiar to you, you might read the sections "Windows
SIDs and Tokens" and "And Then... Vista and the 'Split' Token" sections of
the "Learning SetupBuilder Part I" help file.

Jane

NewsArchive
01-14-2011, 12:43 AM
Thanks everyone this really helps. and Charles I am using propath. But I
still have some files we write to in the windows folder. I am now working
on removing them.

Thanks

Gary Hoffman

NewsArchive
01-14-2011, 12:44 AM
> Thanks everyone this really helps. and Charles I am using propath. But I
> still have some files we write to in the windows folder. I am now working
> on removing them.

Glad your making progress Gary.

If you get stuck on getting some template to play well with ProPath, drop
me an E-mail. In most cases even a template that does not support a
variable for the INI name can be re-routed to the correct location with a
single line of ProPath code.

:-)

Charles


--
-------------------------------------------------------------------------------------------------------
Charles Edmonds
www.clarionproseries.com - "Get ProPath, make your Clarion programs ready
for Windows 7 and Vista!"
www.ezchangelog.com - "Free ChangeLog software to manage your projects!"
www.setupcast.com - "A revolutionary new publishing system for software
developers - enhanced for SetupBuilder users!"
www.pagesnip.com - "Print and Save the Web, just the way you want it!"
www.clarionproseries.com - "Serious tools for Clarion Developers"
www.ezround.com - "Round Corner HTML tables with matching Banners, Buttons
and Forms - Now with PNG support!
www.lansrad.com - "Intelligent Solutions for Universal Problems"
www.fotokiss.com - "World's Best Auction Photo Editor"
-------------------------------------------------------------------------------------------------------