Web Connection
wc.dll trying to download
Gravatar is a globally recognized avatar based on your email address. wc.dll trying to download
  Nicholas St Jon
  All
  Apr 1, 2020 @ 03:25pm

Bringing up a new server and thought I had all the setup done including the Map Handler for ISAPI-dll (it is enabled) but the wc.dll is still trying to download instead of firing. Have duplicated everything on new server but I'm apparently missing something. What can I check? Nicholas St Jon

Gravatar is a globally recognized avatar based on your email address. re: wc.dll trying to download
  Rick Strahl
  Nicholas St Jon
  Apr 2, 2020 @ 02:13am

First: You probably shouldn't be using wc.dll in your URLs as IIS doesn't make that easy (and hasn't for some time). You really should be using script maps (ie. wc.wc that are mapped to a handler like wc.dll or the WebConnectionModule.dll).

You can get the DLL links to work but it takes some extra steps. If I recall you need to:

  • Map the DLL to ISAPI Module in the IIS Handlers for the site/virtual
  • Add permissions for the dll extension to Read/Script/Execute (the last is important)
  • Make sure that your copy of wc.dll is added to the allowed ISAPI extensions

More info on IIS configuration here (although there are no specific steps for your scenario since that's been discouraged for 20 years now 😃)

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: wc.dll trying to download
  Nicholas St Jon
  Rick Strahl
  Apr 2, 2020 @ 01:11pm

We've updated everything we know of and I ran the Intall-IIS_Features.ps1. This is a 2019 Server, does anyone know of perhaps a security change that would cause this problem. We've also set a scriptmap but it doesn't seem to "find the page". Thanks in advance, Nicholas

Gravatar is a globally recognized avatar based on your email address. re: wc.dll trying to download
  Rick Strahl
  Nicholas St Jon
  Apr 2, 2020 @ 04:17pm

Like I said - .dll is restricted in IIS by default as it's an executable and not recommended to be used to directly. So none of the default configuration will make that work.

I don't remember all the details on how to get that to work. I think you have to explicitly have .dll mapped and then make sure that the ISAPI execution is allowed on that.

If you want to avoid this in the future I would suggest you invest the time to replace your .dll links with scriptmapped .wc (or whatever your app uses) links instead. It's basically a search and replace excercise for your code and HTML templates. So basically every url becomes wc.wc instead of wc.dll you can then map .wc as script and that will work out of the box because it's not an executable. If necessary you can even set up a UrlRewrite rule that automatically forwards all wc.dll requests to wc.wc.

+++ Rick ---

© 1996-2024