Question

I have built a windows service which runs a self hosted SignalR service.

I start the webApp thus: WebApp.Start("http://*:1111")

to get this to start I have to provide my service with an Admin logOn. But that seems a bit too much of a privilege.

I Tried using NETWORK SERVICE but that got access denied error.

What is the minimum privilege required to start my WebApp for the URL provided. Or Must I run my service with Admin privileges?

Was it helpful?

Solution

You probably want to use netsh.exe (found in c:\Windows\System32) to allow a specified non-admin user to listen for http requests on port 1111.

The syntax for the command is as follows:

netsh http add urlacl url=http://*:1111/ user=DOMAIN\user

http://msdn.microsoft.com/en-us/library/windows/desktop/cc307223(v=vs.85).aspx

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top