Reputation: 16196
When moved to Windows 7 platform a WCF call from ASP.NET project throws exception
ex {"HTTP could not register URL http://+:9100/Jfc.Dealing.OrderProvider.BLClient.svc/. Your process does not have access rights to this namespace (see http://go.microsoft.com/fwlink/?LinkId=70353 for details)."} System.Exception {System.ServiceModel.AddressAccessDeniedException}
+ [System.ServiceModel.AddressAccessDeniedException] {"HTTP could not register URL http://+:9100/Jfc.Dealing.OrderProvider.BLClient.svc/. Your process does not have access rights to this namespace (see http://go.microsoft.com/fwlink/?LinkId=70353 for details)."} System.ServiceModel.AddressAccessDeniedException
+ InnerException {"Access is denied"} System.Exception {System.Net.HttpListenerException}
Message "HTTP could not register URL http://+:9100/Jfc.Dealing.OrderProvider.BLClient.svc/. Your process does not have access rights to this namespace (see http://go.microsoft.com/fwlink/?LinkId=70353 for details)." string
Source "System.ServiceModel" string
+ TargetSite {Void OnOpen()} System.Reflection.MethodBase {System.Reflection.RuntimeMethodInfo}
Upvotes: 2
Views: 1820
Reputation: 61
I had this issue debugging my webservice in Visual Studio 2010. I solved my issue launching Visual Studio 2010 using "Start as administrator."
Upvotes: 0
Reputation: 120937
Well, if you follow the link that is included in the exception and read what it says you have the answer. Run the command:
netsh http add iplisten ipaddress=0.0.0.0:9100
Upvotes: 2
Reputation: 56500
Are you sure that's from an outbound call? That is the error you get on Windows 7 (and Vista and Windows 2008) when you try to open a WCF "server" for listening. This happens if you attempt to create an endpoint without registering it. On the client it can happen if its a duplex service as, of course, the client then needs to open an endpoint.
The KB article linked to in the exception has instructions on how to register an endpoint. Basically you run the following in an elevated command prompt.
netsh http add urlacl url=//+:9100/Jfc.Dealing.OrderProvider.BLClient.svc/ user=DOMAIN\Network Service
Replace DOMAIN with your machine name and it should be right for your machine.
Upvotes: 3