Thread: Services and Pipes

  1. #1
    Banned nickname_changed's Avatar
    Join Date
    Feb 2003
    Location
    Australia
    Posts
    986

    Services and Pipes

    Hey,

    I've been working on an application that runs as an NT service. It opens a pipe with _popen(), and then is supposed to read in from the pipe and send the information over the network.

    However the code I used for creating the pipe does not work. It runs perfectly fine when run as a normal console app, but NOT when run as a service.

    The service does run properly (It's not just a normal executable that I told to run as a service or anything, but has a ServiceMain function and so on).

    I have not been able to figure out why the program failes to open pipes. Then I read an article at http://www.microsoft.com/msj/0398/service2.aspx
    "The System account is a special account known only locally to your machine. This means that this account cannot be used to access network resources relying on NT LAN Manager (NTLM) authentication. These resources include file shares, named pipes, the registry, and access to a remote computer's eventlog or Service Control Manager."

    Does that mean that my service cannot use pipes created by _popen()? That seems to make sense because thats whats been happening to me.

    But thats for the localsystem account, so I told my program to run as Administrator when the service was started. That didn't work either.

    If anyone has any idea what I must do to allow my program to use pipes I would really really appreciate it
    Last edited by nickname_changed; 07-16-2003 at 06:48 AM.

Popular pages Recent additions subscribe to a feed