IIS 7 and Above
HTTP Error 405.0 - Method Not Allowed
Last post Mar 23, 2013 01:44 PM by prasok
Jan 27, 2009 03:08 PM|will1968|LINK
IIS 7.0 Problem
Jan 27, 2009 09:05 PM|ServerIntellect_BH|LINK
The error message indidicates the Handler Mapping for the extension you are trying to access is restricting the Verbs it is allowed to process.
In IIS, go to the site and click on its Handler Mappings section. Locate the handler for the file you are trying to access, appears to be .cgi according to the screenshot. Right Click on it and select Edit. Click the Request Restrictions button and review
the Verbs tab.
IIS -> Sites -> DOMAIN.COM -> Handler Mappings -> Edit the CGI handler handling your requests -> Request Restrictions -> Verbs tab.
This is were IIS limits which Verbs the handler is allowed to handle. Either add the appropriate verb, or set it to All verbs for testing.
Hope this helps!
Jan 27, 2009 09:26 PM|will1968|LINK
I have set it to all verbs and have given read, script and execute permissions. It has not made the slightest bit of difference.
It is hosted on discountasp.net if that helps. I have been modifying iis 7.0 using the IIS Manager console (nice bit of kit..if only I could get this to work!).
I have assumed the handler I should be modifying is CgiModule.
Thank you for the reply.
Jul 31, 2009 11:35 AM|Tapani Talvitie|LINK
I have a similar problem with this kind of configuration:
IIS 7.0 / Windows Vista / IIS site having default IIS configuration, including Handler Mappings
/default.aspx contains form that sends it to "/postreceiver"
/postreceiver/default.aspx receives the post.
if the post is made to "/postreveicer/default.aspx" all goes just fine. But when posting to "/postreceiver" I get HTTP error 405.0, though it should reply as it does when making GET to "/postreceiver".
I tried to tweak the Handler Mappings with no result. It seems that the factory default StaticFile first handles the request. For some reason the DefaultDocumentModule doesn't allow POST to get through to PageHandlerFactory-Integrated / PageHandlerFactory-ISAPI-2.0
handlers as it should like it does with GET.
Note: The StaticFile mapping Verbs are set to Allow All but I also tried specified GET,POST with no results. Also I tried to change the Access from Read to Script, with no results either.
My work-around now to this issue is to call "/postreveicer/default.aspx" but it would be nicer to use a shorter uri.
Jul 31, 2009 04:29 PM|anilr|LINK
If you do a POST to /postreceiver/ (note the trailing /), you should not see the problem - the reason why you cannot POST to /postreceiver is that we cannot just transfer control to /postreceiver/default.aspx on the server side as any relative links generated
by that page would be incorrect on the client (because the new url is at a different level), so we have to first redirect the client to /postreceiver/ which is fine for GETs, but for POSTs, most clients when redirected will drop the POST body and just do a
GET so it does not work.
Aug 03, 2009 05:13 AM|Tapani Talvitie|LINK
Tried it and it works. Thanks for clearing this out!
May 27, 2010 08:55 PM|hano3|LINK
i am having a similar isue how can i over come it error info above
Mar 23, 2013 01:44 PM|prasok|LINK
I had faced this issue , please check this link
it resolved my issue.