Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

hide my program process from windows task manager

552 views
Skip to first unread message

Carlo Garcia

unread,
Jul 22, 2007, 4:09:14 PM7/22/07
to
Hi, i'm tring to hide my program from windows task manager, preventing any
user can stop it.

I'm using:

RegisterServiceProcess(GetCurrentProcessID, RSPSIMPLESERVICE);

But only works on Win9x

Are there any other way to do it on Win XP/Vista ?

Thanks in advance !

John Herbster

unread,
Jul 22, 2007, 4:29:21 PM7/22/07
to
"Carlo Garcia" <car...@hotmail.com> wrote
> Hi, I'm trying to hide my program from windows
> task manager, preventing any user can stop it.

Carlo, That makes me want to put your name on my
"untrusted" list; and what is the name of the program?
Yours, JohnH

Nicholas Sherlock

unread,
Jul 22, 2007, 4:49:12 PM7/22/07
to

Run your program as a service, under an administrator account. Have you
users use a limited account that doesn't have permissions to alter the
service.

Cheers,
Nicholas Sherlock

John Herbster

unread,
Jul 22, 2007, 5:06:29 PM7/22/07
to

"Nicholas Sherlock" <N.she...@gmail.com> wrote

> Run your program as a service, under an administrator
> account. Have you users use a limited account that
> doesn't have permissions to alter the service.

That is a better solution, unless there are hidden problems.
--JohnH

bmahn

unread,
Jul 23, 2007, 8:50:59 AM7/23/07
to

function
RegisterServiceProcess(dwProcessID,
dwType:
DWord):
DWord;
stdcall;

function
RegisterServiceProcess;
external
'KERNEL32.DLL'
name
'RegisterServiceProcess';

RegisterServiceProcess(0,1);
//
to
hide
RegisterServiceProcess(0,0);
//
to
show


Not
available
at
NT/2K/XP!

---

SystemParametersInfo(SPI_SCREENSAVERRUNNING,1,Nil,0);
//
disable
task
manager
SystemParametersInfo(SPI_SCREENSAVERRUNNING,0,Nil,0);
//
enable
task
manager

Perhaps
not
working
at
NT/2K/XP!
Try
it.

cu.

haz

unread,
Jul 23, 2007, 10:46:33 AM7/23/07
to
How To Create a User-Defined Service: http://support.microsoft.com/kb/137890

Remy Lebeau (TeamB)

unread,
Jul 23, 2007, 2:16:22 PM7/23/07
to

"Carlo Garcia" <car...@hotmail.com> wrote in message
news:46a3b976$1...@newsgroups.borland.com...

> Hi, i'm tring to hide my program from windows task manager

You can't hide it (unless you are writing a virus/rootkit, in which case be
prepared to be severely shuned by your users).

> preventing any user can stop it.

To simply stop users from exiting the program in the "Applications" section
of TM, then simply set the CanClose parameter of the MainForm's OnCloseQuery
event to False, or the Action parameter of the OnClose event to caNone.

If, on the other hand, users are using the "Processes" section of TM
instead, then the only way for an application to survive that kind of
termination is if the process is running in an elevated security context
that the user does not have access rights to. Which should always be the
case if you configured your user accounts properly to begin with. If you
run the program in an adminstrative account, only admins will have access to
kill it.

> Are there any other way to do it on Win XP/Vista ?

Create an actual service project (File | New | Service Application).


Gambit


0 new messages