Microsoft Windows Vista Community Forums - Vistaheads
Recommended Download



Welcome to the Microsoft Windows Vista Community Forums - Vistaheads, YOUR Largest Resource for Windows Vista related information.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so , join our community today!

If you have any problems with the registration process or your account login, please contact us.

Driver Scanner

UAC blocks windows messages

microsoft.public.windows.vista.security






Speedup My PC
Reply
  #1 (permalink)  
Old 05-30-2007
Martin
 

Posts: n/a
UAC blocks windows messages

We have a system that is comprised of 3 executables. They're all about
controlling displays.
1) Service.exe -- A service (running as local system)
2) Main.exe --The main app which is run as as local system too, but
within the interactive user's Session and attached to the user's
input desktop.
3) UI.exe -- A UI executable which runs under the interactive user's
account.

Service launches Main.
Main launches UI, using CreateProcessAsUser(), getting the
QueryUserToken().

UI.exe tries to broadcast WM_DISPLAYCHANGE at certain points which
needs to be heard by Main.exe.
But Main.exe's listening window & thread do not receive that message
if control-panel's UAC is checked on.
(BTW: On XP & win2k all is fine, and also on Vista when UAC=Off.)

Strangely calling ChangeDisplaySettingsEx() in the UI will
successfully cause WM_DISPLAYCHANGE to be heard by main.exe

Using Spy I can see that, for example, the frame of Notepad.exe does
receive the WM_DISPLAYCHANGE message, even though the window-procedure
in Main.exe does not.

I've tried using SendMessage, PostMessage, SendNotifyMessage, all
aimed at HWND_BROADCAST. All suffer the above problem under UAC.
I can add more details on how the processes are created if needs be.

Any suggestions of what's going on, and how I can fix it?
Thanks for any advice. I've been looking at this for a week now.

Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 05-31-2007
Martin
 

Posts: n/a
Re: UAC blocks windows messages
On 30 May, 17:56, Martin <MNVP...@googlemail.com> wrote:

I'll begin to answer my own question, for the benefit of anyone else
baffled by this.

It seems that UIPI (User Interface Privilege Isolation) is the cause.
In summary: a lower privilege process cant send windows-messages to
higher privilege processes.

Its defined in the document: "WindowsVistaUACDevReqs.doc", which can
be downloaded from a link on:
http://technet.microsoft.com/en-us/w.../aa905108.aspx

I'd still like any advice on a possible fix.
Is it possible to have the higher privilege process (Main.exe) that
launches the lower privilege process (UI.exe) open up a deliberate
chink in this UIPI armor?

Reply With Quote
  #3 (permalink)  
Old 05-31-2007
Martin
 

Posts: n/a
Re: UAC blocks windows messages
OK, I got there in the end. :-)
Sorry for the noise.
The answer appears to be call ChangeWindowMessageFilter().

Reply With Quote
  #4 (permalink)  
Old 05-31-2007
Jimmy Brush
 

Posts: n/a
Re: UAC blocks windows messages
On 31 May 2007 04:56:28 -0700, Martin <MNVPyle@googlemail.com> wrote:

>OK, I got there in the end. :-)
>Sorry for the noise.
>The answer appears to be call ChangeWindowMessageFilter().


You may already know this, but running interactive programs on the
user's desktop running as system is considered a bad thing, even with
Vista's new security.

I'm sure you have a reason for doing so, but it would be better from a
security perspective if all the privileged code was running in your
service, and the only programs running on the users desktop was
running in the context of their user account.

- JB
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Windows Defender Blocks Programs Which Have Been Uninstalled. MrSlartybartfast microsoft.public.windows.vista.performance maintenance 6 05-12-2007 02:29
UAC blocks IE add-on Frank Berzau microsoft.public.windows.vista.security 4 04-01-2007 14:03
UAC blocks startup program =?Utf-8?B?R2FsZXg2Mg==?= microsoft.public.windows.vista.security 1 03-28-2007 17:02
Windows Mail blocks email as phishing email joled@rcn.com microsoft.public.windows.vista.security 2 03-28-2007 01:54
China Blocks LiveJournal Steve General Technology News 0 03-05-2007 23:27




All times are GMT +1. The time now is 01:22.




Driver Scanner - Free Scan Now

Vistaheads.com is part of the Heads Network. See also XPHeads.com , Win7Heads.com and Win8Heads.com.


Design by Vjacheslav Trushkin for phpBBStyles.com.
Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.6.0 RC 2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120