Author Topic: Problem with UAC in Windows 7  (Read 11448 times)

Scorpio47

  • Newbie
  • *
  • Posts: 41
Problem with UAC in Windows 7
« on: October 05, 2011, 02:22:05 pm »
Buon giorno, Umberto:

I have enmcountered a new poblem on my Windows 7 Ultimate PC with FSX and LSZH, KJFK and KLAX installed and working just fine, as long as I start FSX as administrator.

However, I have now installed the addon from Robert Cezar "Its Your Plane". Should you not know it, it is a flight assistant working with speech recognition and it requires the User Access Control setting to be OFF in order to work.

I now have a conflict between this setting necessary for IYP and the requirement to start FSX as administrator, because with the UAC set to OFF I do not get the window any longer where I have to input the admin password and so FSX starts without that and the buildings in the FSDT sceneries are gone again.

Would you know of a way to get both to run? That would mean a setting where UAC is OFF but I still get prompted for the admin password when starting FSX?

Thank you for your help!
Ciao
Juergen

P.S.
I have found out that all runs fine if I log in to my administrator account. UAC is still OFF, but both programs run flawlessly.
Question: is there a way to start a particular program, i.e. FSX, as administrator from a normal user account with the UAC st to OFF? I have not found anything on that so far....
« Last Edit: October 05, 2011, 04:08:22 pm by Scorpio47 »

virtuali

  • Administrator
  • Hero Member
  • *****
  • Posts: 51229
    • VIRTUALI Sagl
Re: Problem with UAC in Windows 7
« Reply #1 on: October 05, 2011, 05:16:12 pm »
You should first ask to the developer of that addon, why it requires UAC to be off.

The most likely case, is that product is trying to write something in the FSX folder, which is usually under C:\Program Files (x86), which is a folder that even programs launched by Admin user can't normally write, unless you run them As Administrator, which is not possible with a limited account user with UAC off.

A proper Vista/Win7 product should never write into the folder were the main program (FSX or its own folder) is installed but, instead, use the correct roaming folder, usually under %APPDATA%, which is what FSX itself does and which is what we do too, since we only write under %APPDATA%\Virtuali in case we need to write something.

So, the "requires UAC off" maybe it's just an issue of permissions.

This might be fixed in these two ways:

- Reinstall FSX in a folder *you* created, for example C:\FSX. This is STRONGLY suggested, you'll never have any issues with non-Vista/Win7 aware products ever, if you follow this rule.

- If you don't want to reinstall FSX, you can add your user name to the permission list on the FSX folder:

Go to the FSX root folder, which should be C:\Program Files (x86)\Microsoft\Microsoft Games, right click on the "Flight Simulator X" folder, select "Properties" -> "Security" tab -> Edit -> Add... -> type your Windows username -> OK -> select Allow checkbox for Full control -> OK or Apply.

Scorpio47

  • Newbie
  • *
  • Posts: 41
Re: Problem with UAC in Windows 7
« Reply #2 on: October 06, 2011, 10:46:50 am »
Grazie mille, Umberto:

I have followed your suggestion with respect to permissions for my FSX directory, but it was already there and with full access rights. I have also tried various settings in the local policies settings with secpol.msc to disable and enable the prompts, but it seems that the UAC setting overwrites all of this, as the only setting that makes a difference is the UAC setting.

I could live with the UAC disabled, but the problem is then, that FSX is started without inputting the administrator password and that means that the buildings will not be shown at the various airports and they do not show up in the add-on menu of FSX.

If there is a way to start FSX as administrator with UAC set to OFF, this might be the solution.

If all else fails I might have to re-install FSX in a non-standard directory as you suggested and hope for the best. But you will understand that this radical solution is not at the top of my priority list ;)

Thank you for your patience and support,
Have a great day
Juergen

virtuali

  • Administrator
  • Hero Member
  • *****
  • Posts: 51229
    • VIRTUALI Sagl
Re: Problem with UAC in Windows 7
« Reply #3 on: October 06, 2011, 02:03:55 pm »
I have followed your suggestion with respect to permissions for my FSX directory, but it was already there and with full access rights. I have also tried various settings in the local policies settings with secpol.msc to disable and enable the prompts, but it seems that the UAC setting overwrites all of this, as the only setting that makes a difference is the UAC setting.

Maybe you have not fully understood my reply: the whole point of changing the permission settings to your FSX folder, was to enable you turn UAC back ON!

It's likely that, with the FSX folder permissions set to include your username in its folder (and, be sure permissions are set recursively to FSX folder AND its subfolders too), that addon that requires UAC off, might work as well with UAC on.

Quote
If all else fails I might have to re-install FSX in a non-standard directory

This won't change anything: installing FSX in a folder you create, is exactly the same as correctly set permissions to the FSX folder to include your own user name. Provided you set the permissions to "Full control" and you applied them to the FSX root folder AND its subfolders too.
« Last Edit: October 06, 2011, 02:05:43 pm by virtuali »

Scorpio47

  • Newbie
  • *
  • Posts: 41
Re: Problem with UAC in Windows 7
« Reply #4 on: October 07, 2011, 11:14:56 am »
It is very possible that I have not fully understood your reply. My FSX directory with all subdirs has full rights for all users, the admin account and my normal user account are listed as well and have full rights.
Nevertheless, it seems that these settings do NOT overwrite the general UAC settings or modify them, because the only setting that makes a difference is the UAC setting.
If this is disabled, IYP runs without any problem, but I cannot start FSX as administrator and therefore do not get the buildings in my sceneries to work.
If I set this to any other setting, I am prompted for the admin password to start FSX and get the buildings to show up, but the IYP program runs into an error when it tries to start and connect to the speech recognition engine.

That is why the developer of IYP now thinks it might be a localization problem, as the only other user of his program who has this problem is someone from Europe like me. The Americans do not have the problem at all.....

Perhaps this will give you some idea on where to look further..

Thank you and have a great weekend!
Ciao
Juergen

virtuali

  • Administrator
  • Hero Member
  • *****
  • Posts: 51229
    • VIRTUALI Sagl
Re: Problem with UAC in Windows 7
« Reply #5 on: October 07, 2011, 11:22:42 am »
Nevertheless, it seems that these settings do NOT overwrite the general UAC settings or modify them, because the only setting that makes a difference is the UAC setting.

They do, but if the problem of IYP was related to FILE PERMISSIONS to write to the FSX folder, which is what creates 90% of issues with addons not entirely compatible with Vista/Win7.

However, it's possible that, either IYP needs to write in *other* folders, which are still under the C:\Program Files folder (= no permission to write by default), in that case you need to add your user to that folder too, OR it's a different thing altogether.

If the program author says it that it affects only European (non-English, maybe?) users, it's possible he's hard-coded program paths which are different by language ? For example, under the Italian version of Windows 7, the "C:\Program Files" folder is called "C:\Programmi" and this creates lots of issues with installers and products that, instead of correctly *asking* to Windows HOW the "C:\Program Files" folder is named, have the English version of the path hardcoded somewhere.

Scorpio47

  • Newbie
  • *
  • Posts: 41
Re: Problem with UAC in Windows 7
« Reply #6 on: October 07, 2011, 06:37:02 pm »
Hello Umberto,

thank you very much for this explanation which helps me to understand a little bit better how Windows works...

It seems that the problem is related to the speech recognition engine combined with localization (linguistic) settings. In my case I found a preinstalled Windows 7 Home version in German on my PC and I immediately upgraded to Ultimate using a version I had bought already earlier in Gibraltar. I then set the country to United States for date and time formats, decimal point etc, and I also changed the language for thr speech recognition from German to English (U.S.).
With these settings there is NO problem when UAC is disabled, but I receive the following error message, when UAC is enabled at any level:

***********************CUT**************************
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.ComponentModel.Win32Exception: Access is denied
   at System.Diagnostics.ProcessManager.OpenProcess(Int32 processId, Int32 access, Boolean throwIfExited)
   at System.Diagnostics.Process.GetProcessHandle(Int32 access, Boolean throwIfExited)
   at System.Diagnostics.Process.set_ProcessorAffinity(IntPtr value)
   at ItsYourPlane.MainForm.MainForm_Load(Object sender, EventArgs e)
   at System.Windows.Forms.Form.OnLoad(EventArgs e)
   at System.Windows.Forms.Form.OnCreateControl()
   at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
   at System.Windows.Forms.Control.CreateControl()
   at System.Windows.Forms.Control.WmShowWindow(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ContainerControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WmShowWindow(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5446 (Win7SP1GDR.050727-5400)
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
ItsYourPlane
    Assembly Version: 4.1.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///C:/Users/JHV/AppData/Local/Apps/2.0/OJEC440B.90Y/CE9H0WA5.N9D/itsy..tion_9ececbceebb75e21_0004.0001_d906b92e505233f8/ItsYourPlane.exe
----------------------------------------
Microsoft.VisualBasic
    Assembly Version: 8.0.0.0
    Win32 Version: 8.0.50727.5420 (Win7SP1.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/Microsoft.VisualBasic/8.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualBasic.dll
----------------------------------------
System
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5447 (Win7SP1GDR.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Windows.Forms
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5446 (Win7SP1GDR.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System.Runtime.Remoting
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Runtime.Remoting/2.0.0.0__b77a5c561934e089/System.Runtime.Remoting.dll
----------------------------------------
System.Configuration
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Xml
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
Interop.SpeechLib
    Assembly Version: 5.0.0.0
    Win32 Version: 5.0.0.0
    CodeBase: file:///C:/Users/JHV/AppData/Local/Apps/2.0/OJEC440B.90Y/CE9H0WA5.N9D/itsy..tion_9ececbceebb75e21_0004.0001_d906b92e505233f8/Interop.SpeechLib.DLL
----------------------------------------
System.Deployment
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5420 (Win7SP1.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/System.Deployment/2.0.0.0__b03f5f7f11d50a3a/System.Deployment.dll
----------------------------------------
FSUIPCEX
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///C:/Users/JHV/AppData/Local/Apps/2.0/OJEC440B.90Y/CE9H0WA5.N9D/itsy..tion_9ececbceebb75e21_0004.0001_d906b92e505233f8/FSUIPCEX.DLL
----------------------------------------
FSUIPCClient
    Assembly Version: 1.1.2397.13
    Win32 Version: 1.1.2397.13
    CodeBase: file:///C:/Users/JHV/AppData/Local/Apps/2.0/OJEC440B.90Y/CE9H0WA5.N9D/itsy..tion_9ececbceebb75e21_0004.0001_d906b92e505233f8/FSUIPCClient.DLL
----------------------------------------

************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.

For example:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.
*******************************CUT**********************

Perhaps with this extensive eror message you will be able to find a solution....

If, on the other hand, it would be possible to run the cuatl.exe file without starting FSX as administrator and get the buildings at the three airports I have to show up, that would also solve the problem, I think I could live with UAC disabled all the time,,, but prefer to have it ON.

Thank you, grazie, gracias and Danke!
Ciao
Jürgen

virtuali

  • Administrator
  • Hero Member
  • *****
  • Posts: 51229
    • VIRTUALI Sagl
Re: Problem with UAC in Windows 7
« Reply #7 on: October 07, 2011, 06:55:18 pm »
That error report would surely help if I had the source code of the program, so you should post it to the ItsYourPlane developer, since he should know for sure what the program was doing when it crashed, the most interesting line is probably this one:

at System.Diagnostics.ProcessManager.OpenProcess(Int32 processId, Int32 access, Boolean throwIfExited)

It's a long shot but, you might try this:

Give "Everyone" or a more specific user like "Authenicated Users" the right to debug programs.

You will find it here:

Open Group Policy...
Start | Type: gpedit.msc | OK |

Navigate to
Computer Configuration\Windows Settings\Security Settings\Local Policies\User Rights Assignment\Debug programs


Scorpio47

  • Newbie
  • *
  • Posts: 41
Re: Problem with UAC in Windows 7
« Reply #8 on: October 08, 2011, 11:28:13 am »
Buon giorno Umberto:

Heureka, my problem is now solved and it was with your help that Robert Cezar could determine the culprit, because you spotted the line in the error report which lead to the solution:
There is a setting in the IYP program called "Unify Affinity" and after switching this off all works fine now with UAC enabled!
(I do not know what that does, but I still think it had to do with access rights...)

I can now start FSX as administrator and all buildings are there, I can start the voice recognition engine and get the virtual co-pilot to help me fly the plane through voice commands... You made me a happy virtual pilot again!

THANK YOU, GRACIAS A TI, MILLE GRAZIE, DANKESChÖN, SPASIBO, XIEXIE etc.

Have a great weekend and take care,
Cheers
Jürgen

Scorpio47

  • Newbie
  • *
  • Posts: 41
Re: Problem with UAC in Windows 7
« Reply #9 on: October 11, 2011, 10:25:51 am »
Hello Umberto,

while we were able to spot and solve my problem with the UAC settings I now have another question related to this conflict:

As you will remember I log on to Windows 7 as normal user (JHV) and have set FSX to ask for the administrator password when I start it (start as administrator) in order to make couatl and the sceneries work properly.

However, when I now create a flight file or use IYP to send me flight files for their VA flights, these files do not show up when I want to load a flight!
I have found out, that thea do not get stored in the personal FSX directory of the user JHV (...\Users\JHV\My Documents\Flight Simulator X Files\) but in that of the user admin!!!, i.e (...\Users\admin\My Documents\Flight Simulator X Files\).

Is there a way to tell FSX to use one particular directory to store all flight files and also to load them from there?

As it is now, files are stored for user admin, but when loading the program looks for files in the normal user´s directory, strange and not really consequent... It should be one or the other, I think...

I would be very grateful if you can help me with that, even if it is not directly related to the products you support.

THANK YOU and have a great day!
Jürgen

virtuali

  • Administrator
  • Hero Member
  • *****
  • Posts: 51229
    • VIRTUALI Sagl
Re: Problem with UAC in Windows 7
« Reply #10 on: October 11, 2011, 10:42:27 am »
Is there a way to tell FSX to use one particular directory to store all flight files and also to load them from there?

I don't know if it's possible but, in general, running FSX with a limited rights account, is not a very good idea, you are getting into a lot of troubles, as your posts indicates.

It's best if you just run FSX with admin user.

Scorpio47

  • Newbie
  • *
  • Posts: 41
Re: Problem with UAC in Windows 7
« Reply #11 on: October 11, 2011, 11:06:50 am »
Thank you Umberto for your quick reply.

Are you suggesting that I not only start FSX as admin, but also log on with an administrator account?
Will that not open many doors for malware attacks if I am connected to the internet, for example when flying online?

Would it be a good idea then to give my "normal user" JHV administrator rights?

Please let me know the best way in our opinion to deal with this situation.

THANK YOU and GRAZIE
Jürgen

EDIT:
I have in the meantime changed the account type of JHV from normal to administrator account, but after rebooting and logging on as JHV and starting FSX (with the window to ask for authorisation coming up but no password necessary this time), the couatl engine is NOT loaded and the buildings in the sceneries are NOT there.... Do I have to reinstall the manager in this account?
« Last Edit: October 11, 2011, 11:25:12 am by Scorpio47 »

virtuali

  • Administrator
  • Hero Member
  • *****
  • Posts: 51229
    • VIRTUALI Sagl
Re: Problem with UAC in Windows 7
« Reply #12 on: October 11, 2011, 11:31:10 am »
the couatl engine is NOT loaded and the buildings in the sceneries are NOT there.... Do I have to reinstall the manager in this account?

Yes, of course.

Scorpio47

  • Newbie
  • *
  • Posts: 41
Re: Problem with UAC in Windows 7
« Reply #13 on: October 11, 2011, 11:54:59 am »
Thank you, Umberto!

It works fine now!

My only concern ist security when logged on with administrator rights.... :(

virtuali

  • Administrator
  • Hero Member
  • *****
  • Posts: 51229
    • VIRTUALI Sagl
Re: Problem with UAC in Windows 7
« Reply #14 on: October 11, 2011, 12:48:02 pm »
My only concern ist security when logged on with administrator rights....

It's not really a problem. In fact, it's *more* dangerous to run a program "As Administor" when being a standard user, than run it normally, being an administrator because, under Vista/Windows 7, even if you *are* an administrator, programs you run normally don't run with admin permissions, while if you are a standard user and select "run as administrator", they run with full privileges.

And, in any case, if you are worried catching malware when connected to the internet, it's best to use an antivirus or firewall