Article View: borland.public.cppbuilder.nativeapi
Article #16125Re: Troubles with services
From: Stefano Bonifazi
Date: Sat, 31 May 2003 20:17
Date: Sat, 31 May 2003 20:17
28 lines
2425 bytes
2425 bytes
> 2) detemine if the user is already currently logged in, grab its security > tokens, and adjust the tokens of your own calling thread to impersonate the > user. Well I know the logged in user (only one and administrator), but I don't have any idea about how to grab his security tokens or whatever I need to access his HKEY_CURRENT_USER registry root key ;( > > When no user is logged in yet, any access to HKCU is going to go to > HKEY_USERS\.DEFAULT since the current user's key has not been loaded yet. > But there is a logged user, and the HKCU is not his one! > The LocalSystem account has full access to the entire machine. If, on the > other hand, you configured the service to run under a specific user account, > then the service is restricted to whatever the user account is restricted > to. My service has NULL lpServiceStartName and pPassword, and in Microsoft SCM program under the voice connection it say Local System !! Sorry so many troubles:-( Stefano B.
Technical Details
Message-ID:
<3ed90dd0@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-08!sn-xit-09!supernews.com!64.152.100.70.MISMATCH!sjc70.webusenet.com!news.webusenet.com!feedwest.aleron.net!aleron.net!news.linkpendium.com!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<3ed1e176@newsgroups.borland.com> <3ed28fd7$1@newsgroups.borland.com> <3ed3a8c4@newsgroups.borland.com> <3ed3b644$4@newsgroups.borland.com> <3ed46301@newsgroups.borland.com> <3ed4eda2$1@newsgroups.borland.com> <3ed5d3fa@newsgroups.borland.com> <3ed65152$1@newsgroups.borland.com> <3ed711ab$1@newsgroups.borland.com> <3ed7865e$3@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,2bef8d34fe764e59 X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2003-05-31 13:21:15 PST Reply-To: "Stefano Bonifazi" <stefboombastic@libero.it> From: "Stefano Bonifazi" <stefboombastic@libero.it> Newsgroups: borland.public.cppbuilder.nativeapi References: <3ed1e176@newsgroups.borland.com> <3ed28fd7$1@newsgroups.borland.com> <3ed3a8c4@newsgroups.borland.com> <3ed3b644$4@newsgroups.borland.com> <3ed46301@newsgroups.borland.com> <3ed4eda2$1@newsgroups.borland.com> <3ed5d3fa@newsgroups.borland.com> <3ed65152$1@newsgroups.borland.com> <3ed711ab$1@newsgroups.borland.com> <3ed7865e$3@newsgroups.borland.com> Subject: Re: Troubles with services Date: Sat, 31 May 2003 22:17:19 +0200 Lines: 30 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 NNTP-Posting-Host: 151.24.137.95 Message-ID: <3ed90dd0@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1054412240 151.24.137.95 (31 May 2003 13:17:20 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-08!sn-xit-09!supernews.com!64.152.100.70.MISMATCH!sjc70.webusenet.com!news.webusenet.com!feedwest.aleron.net!aleron.net!news.linkpendium.com!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail