Running this code as a regular user throws HttpListenerException (access denied). Snippet runs ok as an administator
class Program
{
static void Main(string[] args)
{
HttpListener listener = new HttpListener();
listener.Prefixes.Add("http://myip:8080/app/");
listener.Start();
//.... and so on
}
}
i went ahead and added the uri using netsh (netsh http show lists the uri)
netsh http add urlacl url=http://+:8080/app user=domain\user
still getting the same error. Adding ACLs did work for other projects (they didn't use HttpListener though). I tried multiple port/application name combinations, nothing works.
Any ideas what might be the cause?
Running .Net 3.5 SP1 on Vista