Classic ASP Error 405 - asp-classic

I have several development sites on my wix XP laptop (all classic asp). Doe anyone know why i need to type localhost/site/default.asp (i keep getting a 405 error on iis 5.1) and not just localhost/site

You need to add "Default.asp" as a default document. From this page ...
With iis 4.0 and iis 5.0 the change is
performed as follows:
Start the Internet Service Manager (Start - Programs - Administrative
Tools - Internet Services Manager).
Expand the computer and select the web site.
Right click on it and select Properties.
Select the documents tab.
Check the Enable default document box and click Add to add a new default
name. The order of the search can be
changed by clicking the up and down
arrows.
Click Apply and then OK.
Per comment ... okay, check your script map settings, per this article.

Sounds like you need to configure your default document type in IIS to be default.asp.

First off we need to clear up the web site thing. You only have one web site, the default web site. (It is possible to munge the metabase on XP to create multiple web sites but IIS 5.1 will only serve one of them, the others will have to be stopped).
You have multiple applications which are virtual directories under a common default website.
Have you checked that Default.asp is in the list of default documents for the application not the website? In IIS manager open properties dialog on each applications virtual directory and check the config there.
If you have then you've got a strange one on your hands. At this point I would always advise checking permissions. Does the application allow anonymous access, if so does the anonymous user have access to the folder and files?
This might seem strange advice since accessing the default.asp directly works but in my experience when the configuration looks good and should work but isn't 90% of the time its the result of permissions not correctly set up.

A 405 http response status code means "Method Not Allowed". The Wikipedia article List of HTTP Status Codes has this definition for the error:
A request was made of a resource using
a request method not supported by that
resource; for example, using GET on
a form which requires data to be
presented via POST, or using PUT on a
read-only resource.

You can try the third XP PRO IIS Admin, which can add more than one site to the IIS 5.1, you can switch the site with no difficulty.

Related

How does /reports redirect to the SQL server reporting page

I'm working on creating a report page for an ASP.NET project, the url to that page is
'localhost/reports'
But for some reason, the SQL Server reporting page is turned on and now there is a url conflict.
So my url now redirects me to the following url:
'localhost/Reports/Pages/Folder.aspx'
It seems the behavior of '/reports' is overwritten by the SQL Report Service site. I would like to know how to turn on/off the db service(report browsing) site manually or by DDL change
You can turn of the entire reporting service in the SQL Server Configuration Manager or you can go to the Reporting Services Configuration Manager and change the Report Manager URL to point to a different location. The default is /Reports.
If you look under "Internet Information Services (IIS) Management", I usually just search for it from start menu, you will see an app pool for reporting services/SSRS with a Reports entry under it. You will probably also see an entry under Default Website. Unfortunately different versions of IIS manager will look different. If you find the "Reports" entry under the Websites/Sites entry, and right click you may have a Properties or Manage Virtual Directory option. Basically IIS handles routing requests to different web applications. So each web application that wants to handle a certain base URL must be configured here. Often times this is done without your knowledge through a deployment or install process, but for more complex setups you might modify IIS directly.
Basically you have a situation where your app and SSRS both have a path in IIS that responds to /reports/. As JodyT answered, the correct solution is to modify the Reporting Manager URL(which likely in turn modifies IIS). I wouldn't be surprised if you had to reboot or run IISReset to get this change picked up. It's hard to say sometimes, but hopefully not.
Change Configuration for SSRS.
Follow these Step:
Open Reporting Services Configuration Manager
Click on Reporting Manager URL
In virtual Directory Change Folder Name 'Reports' to 'Reports2'
Click Apply
Now Check website

Remove NEGOTIATE from WindowsAuthentication in IIS

I have a site running in IIS 7.5 that is accessed using a DNS alias different from the actual server name. In IE 8, integrated authentication is failing, but in Firefox and Chrome everything works fine. (IE presents a credential challenge a few times, then displays a 401.1 error page.)
I have figured out that this is due to IE using Kerberos (aka "Negotiate") over NTLM, and Kerberos requires registering a Service Principal Name (using SETSPN) so that the mismatch between the DNS name and the server name is properly handled.
My web site, however, doesn't need impersonation--it is enough to have delegation. So instead of messing with SetSPN, I would just like to remove "Negotiate" from the list of WindowsAuthentication methods in IIS.
I have searched for quite some time to find out how to do this in IIS. I have played with many appcmd commands--but I just can't find online examples, or figure out how by reading MSDN documentation or using appcmd /? to make appcmd commands apply only to a particular application within a site rather than to the entire web server. A few search-hours later over two days, and at least 3 dozen web pages visited, I am still coming up fruitless.
How in tarnation do I get this done--it seems like it should be so easy!
Open the Configuration Editor in IIS. It comes with IIS 7.5, or you can download the IIS administration pack for IIS 7.0. Navigate to the scope you want to affect (server, site, or application) and then open the icon:
.
Change the Section to system.webServer/security/authentication/windowsAuthentication:
Click on the providers item, and then click Edit Items on the right. Select the "Negotiate" item and click "Remove":
Close the dialog and click Apply in the Actions pane on the right.
Your problem is solved! No more Kerberos/negotiate!
Note: you can also click Generate Script in the actions pane to display the code that will make the change in either C#, javascript, or with appcmd from the command line.
For reference, here is the appcmd statement to do the job without using the Configuration Editor.
appcmd.exe set config "Virtual/path/to/application" -section:system.webServer/security/authentication/windowsAuthentication /-"providers.[value='Negotiate']" /commit:apphost

IIS 7 Windows Server 2008 / CSS file not loading within aspx

I've found out several topics related to this issue yet I couldn't find an answer which worked for my problem, which is following:
I moved my Asp.Net 4.0 site to a new server (IIS 7, Windows Server 2008). The server side is working fine but the CSS style sheet is not loading.
When I use firebug, I see the following on the part where css should be loaded
404 - File or directory not found.
The resource you are looking for might have been removed, had its name changed, or is temporarily unavailable.
Despite this message,I can display the content of the css (in text) on the web (such as ../Styles/button.css ..etc)
I have tried some solutions such as staticFile handler mapping on IIS or adding ASP roles on server manager (through control panel).
Any help would be appreciated
Kind regards
The articles/topics that you have found is talking about the same thing as Uali's answer, which is correct, but it doesn't always solve everyone's problem. The problem is also not about your css per se.
Before proceeding, make sure that you have enabled Static Content as the other answer instructed.
Then do these steps in the IIS Manager window with your virtual directory selected.
Open Handler Mappings.
Click Add Managed Handler in the Actions Panel located in the right.
In the request path field, type: *.css
In the type textbox, enter: System.Web.StaticFileHandler
In the name textbox, type in any descriptive name you want such as css fix.
Click OK.
Update:
I also forgot to say that you can do the same thing for .jpg, .png, .gif or any other file types if necessary.
Please Make sure Your IIS 'Static Content' is enabled.
Do to This follow these steps:
Open Control Panel
Click Programs
Click Turn windows features on or off in Programs and Features.
Open Internet Information services -> World Wide Web Service ->Common HTTP Features
Make sure Static Content is checked, Mark checked if it
is not.
Hopefully it will help you.
The process of enabling Static Content on Windows 7 is different from that on Windows Server 2008.
To install the Static Content feature on Windows Server 2008 and Windows Server 2008 R2, follow these steps:
a. Open Server Manager, and then expand Roles.
b. Right-click Web Server (IIS), and then click Add Role Services.
c. Under Web Server, click to select the "Static Content" check box.
d. Click Next to complete the installation.
Here is the complete step by step guide for both situation for reference.
http://support.microsoft.com/kb/2196177

How to set up a asp.net application on IIS

I've copied a whole folder which keeps a website inside from a web server to another computer.From the original server I can easily run the web application. Now I need to know what exactly I have to do in order to be able to run the application on the second computer too. I think there are some special considerations with IIS. What and how do I have to set up in IIS?
Follow these steps.
create a new site from left menu By right clicking and add new website.
Give physical path to that folder
Map with the site url
Give permissions to Directory as (like everyone)
Set up the default page if (index page is not present in the directory)
Set framework which ever you are using.
Install the IIS Windows component for whatever version of Windows you're using.
Create a new site in IIS
Point this new site to your web root
Configure DNS for the site (maybe using your hosts file)
There are some considerations to make depending on which version of IIS you are using. It would be helpful to know if you are using 6 or 7.
If you are under 7, you need to copy the site to your IIS directory (typically wwwroot) and then setup the basic settings in IIS by choosing your application pool and such. Application pools are typically (but not always) setup by .Net Framework. You may need to setup your default page and set it as an application. There are many blogs and sites out there that will tell you how to setup this basic functionality but are specific to your application.
For configuring IIS
1. Firstly, in Programs and features go to Turn on and off windows features...in that tick everything under IIS..go to sub folder and tick everything everywhere
Go to Internet Explorer> Setting> Internet Options> Advanced> untick Show friendly http error messages option
Go to IIS manager
a. In default application pool> advanced settings > Set true enable 32-bit program option
b. Go to Asp> setting> expand debugging properties> there will an option of error messages some 2nd last or last option that would be false...set it to true..apply changes
Run vbscript and asp only in Internet Explorer (edge 10 in developer options for pop ups)

Obscure IIS7 ISAPI Filter problem

I am currently trying to migrate a legacy ASP application from Windows Server 2000 and IIS5 on to Windows Server 2008 and IIS7. The authentication for this application uses an ISAPI filter. Both the application and the ISAPI filter work in the new environment except for one problem. The application in question is set up to be the root application (as in you access it by going to http://hostname/application.asp). If I access it by the stated URL, it asks for my authentication details, the ISAPI filter gets passed the correct login details and then does its thing. Then I added a default document to IIS7 to point to application.asp. Now if I access the application by going to http://hostname, the ISAPI filter gets passed the wrong login details. The ISAPI filter implements this method:
DWORD CMyISAPIFilter::OnAuthentication(CHttpFilterContext* pCtxt, PHTTP_FILTER_AUTHENT pAuthent)
In it, the pAuthent object gets passed in by IIS when it calls the ISAPI filter and has the pszUser property which normally holds the value entered in the authentication dialog. In my case (when accessing the website by using the default document entry), the pszUser property holds the value of the Windows account that is running the application pool instead. Just to make things clear, the ISAPI filter gets passed the correct value if I type in the application.asp part.
I'm quite stumped at this problem and have no clue as to how to solve it. To make matters workse I can't really rebuild/modify the ISAPI filter and am quite the beginner when it comes to IIS administration.
I have also found that authentication works if IIS does not have the Default Document feature installed. Without this feature the default document does not work (naturally) but authentication does. It's only after I add the Default Document feature that authentication breaks.
Thanks for your help!
Sounds like the web site is configured to use integrated security on the root level. Make sure you remove the checkmark from the Integrated Windows Authentication checkbox in the Directory Security-Tab.
The Node "Web Sites" can be configured as well. So make sure you don't miss that one ;-)
EDIT: Damn i can't upload a picture. Would make it easier for you to find the setting.

Resources