views:

139

answers:

1

Hello everyone,

I am using Windows Vista and I find something strange,

  1. I programatically invoke IE to open IE to access some local html page, the current user belongs to administrator group;

  2. I programatically invoke IE with RunAs parameter, and let IE to access access some local html page, the current user belongs to administrator group;

I find (1) and (2) sometimes have different results (page content), especially when there is ActiveX or Silverlight plug-in in the local page.

My confusion is, if the current user belongs to Administrator Group, it should not matter whether we use RunAs parameter. Why still different with and without RunAs parameter even current user belongs to administrator group?

thanks in advance, George

+1  A: 

Even when the user is in the Administators group, they won't be able to undertake privileged operations without an application requesting elevation via a UAC prompt.

Hence the availability of the right-click, "run as administrator" context menu item.

Here is some documentation on UAC from Microsoft. It contains the following:

After an administrator logs on, the full administrator access token is not invoked until the user attempts to perform an administrative task.

An administrative task is defined as a task that requires elevation (indicated by a Vista "shield" over the icon for the application).

However, I am not sure how you might programatically invoke Internet Explorer "pre"-elevated, nor if this is the proper solution to your problem.

tomfanning
Thanks tomfanning, 1. in my case I find it is always different when access local pages from IE, which contains ActiveX or Silverlight. In this context, what "privileged operations" may be? 2. Appreciate if you could recommend some documents about "Even when the user is in the Administators group, they won't be able to undertake privileged operations" -- I do not know this point before and I am very interested to learn. :-)
George2
Added more detail for you.
tomfanning
Nice stuff, I have marked your reply as answered.
George2