471,315 Members | 1,448 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,315 software developers and data experts.

invisible service

hello

I would like to create a service that stays hidden from the user (the
idea is to stop the user from killing the service, so the client
specified to hide it)
I thought to create my service as a thread, passing
SERVICE_WIN32_SHARE_PROCESS instead of own process
but it is still creating it's own proccess.. anybody knows why that happens?

I'm installing the service using the win32 api (DLL imports..)

thanks
marcel
Jan 4 '06 #1
6 1712
"Marcel Serour" <ma****@kttf.net> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
hello

I would like to create a service that stays hidden from the user (the idea
is to stop the user from killing the service, so the client specified to
hide it)
I thought to create my service as a thread, passing
SERVICE_WIN32_SHARE_PROCESS instead of own process
but it is still creating it's own proccess.. anybody knows why that
happens?

I'm installing the service using the win32 api (DLL imports..)

thanks
marcel


Are you:

1) trying to make the process indistinguishable from any other process so
the user won;t notice it's there?

2) trying to make the process unkillable by the user?

3) trying to make the service unstoppable by the user via the MMC?

4) something else?

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk
Jan 4 '06 #2

"Richard Blewett [DevelopMentor]" <richard at nospam dotnetconsult dot co
dot uk> wrote in message news:u3****************@TK2MSFTNGP12.phx.gbl...
"Marcel Serour" <ma****@kttf.net> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
hello

I would like to create a service that stays hidden from the user (the
idea is to stop the user from killing the service, so the client
specified to hide it)
I thought to create my service as a thread, passing
SERVICE_WIN32_SHARE_PROCESS instead of own process
but it is still creating it's own proccess.. anybody knows why that
happens?

I'm installing the service using the win32 api (DLL imports..)

thanks
marcel


Are you:

1) trying to make the process indistinguishable from any other process so
the user won;t notice it's there?

2) trying to make the process unkillable by the user?

3) trying to make the service unstoppable by the user via the MMC?

4) something else?

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk


You forgot the fifth question Richard:

Are you:
5) Working for Sony-BMG?

=)

- Michael S
Jan 4 '06 #3
Richard Blewett [DevelopMentor] wrote:
"Marcel Serour" <ma****@kttf.net> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
hello

I would like to create a service that stays hidden from the user (the idea
is to stop the user from killing the service, so the client specified to
hide it)
I thought to create my service as a thread, passing
SERVICE_WIN32_SHARE_PROCESS instead of own process
but it is still creating it's own proccess.. anybody knows why that
happens?

I'm installing the service using the win32 api (DLL imports..)

thanks
marcel

Are you:

1) trying to make the process indistinguishable from any other process so
the user won;t notice it's there?

2) trying to make the process unkillable by the user?

3) trying to make the service unstoppable by the user via the MMC?

4) something else?

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk


I think the answer would be 2, but the client specified to do it by
doing 1 so my answer is 1
Jan 4 '06 #4
"Marcel Serour" <ma****@kttf.net> wrote in message
news:el*************@TK2MSFTNGP09.phx.gbl...
Richard Blewett [DevelopMentor] wrote:
"Marcel Serour" <ma****@kttf.net> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
hello

I would like to create a service that stays hidden from the user (the
idea is to stop the user from killing the service, so the client
specified to hide it)
I thought to create my service as a thread, passing
SERVICE_WIN32_SHARE_PROCESS instead of own process
but it is still creating it's own proccess.. anybody knows why that
happens?

I'm installing the service using the win32 api (DLL imports..)

thanks
marcel

Are you:

1) trying to make the process indistinguishable from any other process so
the user won;t notice it's there?

2) trying to make the process unkillable by the user?

3) trying to make the service unstoppable by the user via the MMC?

4) something else?

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk


I think the answer would be 2, but the client specified to do it by doing
1 so my answer is 1


The only way to do 2 is to make sure the user doesn't have permissions to do
this buy making sure they don;t run as admin and run the service under a
different account.

For 1 you could use svchost.exe to host your service, then the user will
only see another copy of svchost.exe in their process list. I assume we are
talking about normal users here and not skilled developers, etc who could
quite easily download process explorer from sysinternals and find out the
command line that started the service.

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk
Jan 5 '06 #5
Richard Blewett [DevelopMentor] wrote:
"Marcel Serour" <ma****@kttf.net> wrote in message
news:el*************@TK2MSFTNGP09.phx.gbl...
Richard Blewett [DevelopMentor] wrote:
"Marcel Serour" <ma****@kttf.net> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl. ..
hello

I would like to create a service that stays hidden from the user (the
idea is to stop the user from killing the service, so the client
specified to hide it)
I thought to create my service as a thread, passing
SERVICE_WIN32_SHARE_PROCESS instead of own process
but it is still creating it's own proccess.. anybody knows why that
happens?

I'm installing the service using the win32 api (DLL imports..)

thanks
marcel
Are you:

1) trying to make the process indistinguishable from any other process so
the user won;t notice it's there?

2) trying to make the process unkillable by the user?

3) trying to make the service unstoppable by the user via the MMC?

4) something else?

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk


I think the answer would be 2, but the client specified to do it by doing
1 so my answer is 1

The only way to do 2 is to make sure the user doesn't have permissions to do
this buy making sure they don;t run as admin and run the service under a
different account.

For 1 you could use svchost.exe to host your service, then the user will
only see another copy of svchost.exe in their process list. I assume we are
talking about normal users here and not skilled developers, etc who could
quite easily download process explorer from sysinternals and find out the
command line that started the service.

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk

yes, I'm talking about normal users, not skiled developers..

so, how could I use svhost.exe to host it?

marcel
Jan 5 '06 #6
You can't use the Framework classes to build "svchost" hosted services. The
Framework provides it's own host (it creates an executable) to host multiple
services, however, no-one stops you from calling your service .exe
svchost.exe.
If you want to build services that must be hosted in svchosts.exe, you'll
have to build DLL's and use the native Win32 Service API. Please refer to
the Platform SDK for more info.

Willy.

"Marcel Serour" <ma****@kttf.net> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Richard Blewett [DevelopMentor] wrote:
"Marcel Serour" <ma****@kttf.net> wrote in message
news:el*************@TK2MSFTNGP09.phx.gbl...
Richard Blewett [DevelopMentor] wrote:

"Marcel Serour" <ma****@kttf.net> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl.. .
>hello
>
>I would like to create a service that stays hidden from the user (the
>idea is to stop the user from killing the service, so the client
>specified to hide it)
>I thought to create my service as a thread, passing
>SERVICE_WIN32_SHARE_PROCESS instead of own process
>but it is still creating it's own proccess.. anybody knows why that
>happens?
>
>I'm installing the service using the win32 api (DLL imports..)
>
>thanks
>marcel
Are you:

1) trying to make the process indistinguishable from any other process
so the user won;t notice it's there?

2) trying to make the process unkillable by the user?

3) trying to make the service unstoppable by the user via the MMC?

4) something else?

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk

I think the answer would be 2, but the client specified to do it by doing
1 so my answer is 1

The only way to do 2 is to make sure the user doesn't have permissions to
do this buy making sure they don;t run as admin and run the service under
a different account.

For 1 you could use svchost.exe to host your service, then the user will
only see another copy of svchost.exe in their process list. I assume we
are talking about normal users here and not skilled developers, etc who
could quite easily download process explorer from sysinternals and find
out the command line that started the service.

Regards

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk

yes, I'm talking about normal users, not skiled developers..

so, how could I use svhost.exe to host it?

marcel

Jan 5 '06 #7

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Juha Suni | last post: by
41 posts views Thread by Mr. x | last post: by
67 posts views Thread by Sandy.Pittendrigh | last post: by
3 posts views Thread by Jose_Csharp | last post: by
4 posts views Thread by Hugh | last post: by
1 post views Thread by beihotmailanmelden | last post: by
5 posts views Thread by my.shabby.sheep | last post: by
reply views Thread by rosydwin | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.