Page 1 of 1

hide from Task manager or Anti-Kill

PostPosted: Fri Apr 13, 2012 5:27 pm
by qawsedstation
I need to hide from Task manager or Anti-Kill my Application on BCB 6 C++
Please Help me... I need my Application not terminate... :P

Re: hide from Task manager or Anti-Kill

PostPosted: Sat Apr 14, 2012 9:16 am
by 2ffat
Sounds like you want to create a service instead of an app? Is that correct?

Re: hide from Task manager or Anti-Kill

PostPosted: Sat Apr 14, 2012 9:34 am
by Lena
Code: Select all
__fastcall TForm2::TForm2(TComponent* Owner)
   : TForm(Owner)
{
 Visible = false;
 Application->ShowMainForm = false;
}


?

Re: hide from Task manager or Anti-Kill

PostPosted: Sat Apr 14, 2012 9:37 am
by qawsedstation
not exactly ... I need an VCL application that will not close ever from the user.
or may be closed by task manager but reopens automatically or hide from task manager
Can you help me?

Re: hide from Task manager or Anti-Kill

PostPosted: Sat Apr 14, 2012 9:44 am
by qawsedstation
Lena wrote:__fastcall TForm2::TForm2(TComponent* Owner)
   : TForm(Owner)
{
Visible = false;
Application->ShowMainForm = false;
}


this code is very well, is not visible from Tab "Applications" but from task manager on the tab of "processes" is visible. and i can terminate the application from this.

Re: hide from Task manager or Anti-Kill

PostPosted: Sat Apr 14, 2012 9:49 am
by qawsedstation
if you have code in non-VCL please send me too 8)

Re: hide from Task manager or Anti-Kill

PostPosted: Mon Apr 16, 2012 8:37 pm
by rlebeau
qawsedstation wrote:I need an VCL application that will not close ever from the user.


The user has final say over what runs on their machine. If they don't want your app running, they are free to kill it. You should not be trying to prevent that. To change that, you would have to run the app under a different user account that the user does not have permissions to.

qawsedstation wrote:or may be closed by task manager but reopens automatically or hide from task manager


To hide from Task Manager, you would basically have to write a rootkit, which is bound to trigger security/antivirus alerts.

A killed app cannot auto-restart itself. You would need to create and run a separate process that monitors the main process that you want to restart. But then the user can always kill the watchdog process first, so it is a kin of catch-22.

On Windows 2000 and later, at least, a service can register itself with the SCM via ChangeServiceConfig2(SERVICE_CONFIG_FAILURE_ACTIONS) to indicate that it wants to be auto-restarted if it dies unexpectedly.