FAQ Database Discussion Community


IIS rewrite rule to redirect https to http not working

asp.net,iis,url-rewriting,web-config
There's lots of questions here about redirecting http to https so I figured it would be easy to reverse the process. However, everything I've tried hasn't worked. I'm trying to combine the rule with my canonical host name rule (it's the first rule, at the top of the rewrite rules):...

How to check weblogs in IIS

iis,iis-7,server,windows-server-2008,windows-server-2008-r2
My application is deployed on IIS 7. I want to check the number of failures as my logic is getting failed at some point and getting errors.Is there any general weblogs in IIS.I can only see system errors in the event logs. Is there any web logs?

Malicious code hidden in image

image,iis,asp-classic,virus
I've come across a dodgy file upload on our server. It is an image and the MIME TYPE checks out, though on the server it was also uploaded with the extension .asp and .cer. On the surface its a photo some weird chinese symbols and the letters asp, though I...

SQL Server Native Client 11 ADO connection string for MS SQL Server 2014 with integrated login

sql-server,iis,asp-classic,database-connection,ado
I'm currently trying to migrate a working web solution from an environment on IIS 7.5 and MS SQL Server 2008 R2 (both on Windows Server 2008 R2 x64) to IIS 8.5 and MS SQL Server 2014 (both on Windows Server 2012 R2). I can't quite get my ADODB connectionstring working...

Application keep Alive in Shared Hosting , No Access to IIS Manager [closed]

c#,asp.net,iis,web-config
I am using GoDaddy's shared hosting. My website usually takes time to load everytime when i open it after sometime. I came to know that Asp.net websites starts again after some time-out. Then i came to know that we can Keep Alive our websites via IIS Manager. But i do...

IIS Rewrite URL to remove duplicate query strings

iis,url-rewriting
Is it possible to rewrite/redirect a url such as this: http://example.com?id=123&id=123 To instead be: http://example.com?id=123 The actual reason for doing this is a bug in code, but a URL rewrite/redirect would be a quick workaround....

Does copying a file cause it to lock

c#,asp.net,vb.net,iis
On web server, I have an ASP.NET website with error.txt inside it. This file always gets written to. And it is in the bin folder. Should I be concerned if: I go to web server and open the bin folder Go to web server and open the error.txt My C#...

USBHIDDRIVER works in Visual Studio debug mode but not when deployed to IIS

web-services,iis,wcf-security,hid,windows-security
I'm using USBHIDDRIVER to access a scale connected to our local workstation. Everything works fine when I run the WCF in Visual Studio 2012 Debug. But once I attempt to run the service in IIS it doesn't seem to recognize the USBHIDDRIVER. I have a test service in the WCF...

IIS not handling WebApi requests asynchonously

c#,asp.net,iis,asp.net-web-api
I have this endpoint defined in ApiController: public async Task<IHttpActionResult> GetAsync() { await Task.Delay(1000); return Ok("getasync"); } I'm running Apache Benchmark to run 50 concurrent requests on it like this: ab -c50 -n50 http://localhost/api/hello/getasync Requests completed in IIS: 5050ms Requests completed in IISExpress: 1080ms It seems that on IIS these...

Adding site Binding programatically IIS 7.5

c#,iis
I am trying to add site binding programatically. Here is my code: using (ServerManager manager = ServerManager.OpenRemote("serverName")) { manager.Sites["siteName"].Bindings.Add(string.Format("*:{1}:{0}.localhost", clientCode, port), "http"); manager.CommitChanges(); } I am getting the following Error. How do I get around this? UnAuthorizedException: Retrieving the COM class factory for remote component with CLSID {} from machine...

Salt IIS configuration fails

iis,salt-stack,salt-contrib
I am trying to configure IIS on Windows 2012R2 x64 via salt. I downloaded and linked salt-contrib. Now when I run: salt-call --local iis.apppool_list I am getting the following error [Error 2] The system cannot find the file specified But when I am running salt-call --local cmd.run "C:\Windows\system32\inetsrv\appcmd.exe list APPPOOL"...

Web.config - Custom error pages not working

asp.net,.net,iis
I have tried the following (and also tried with the commented-out uncommented instead) but only get an error: The resource you are looking for has been removed, had its name changed, or is temporarily unavailable. In the web.config of a published website project: <system.webServer> <httpErrors errorMode="Custom" existingResponse="Replace"> <remove statusCode="404"/> <!--<error...

How to display the physical path of a web application using appcmd.exe?

iis,iis-7,iis-7.5,appcmd
Please, observe: PS C:\Dayforce\DayforceRTQA\150520_747\SharpTop> $a C:\Program Files\IIS Express\appcmd.exe PS C:\Dayforce\DayforceRTQA\150520_747\SharpTop> &$a list app "MyDayforce/" /text:* APP path:"/" APP.NAME:"MyDayforce/" APPPOOL.NAME:"Clr4IntegratedAppPool" SITE.NAME:"MyDayforce" [application] path:"/" applicationPool:"Clr4IntegratedAppPool" enabledProtocols:"http" serviceAutoStartEnabled:"false" serviceAutoStartProvider:"" preloadEnabled:"false" [virtualDirectoryDefaults] path:"" physicalPath:""...

IIS Express 8 - Max allowed length

c#,asp.net,iis,visual-studio-2013,iis-express
In case the below is too long, my question is whether IIS Express 8 in Visual Studio 2013 obeys the maxAllowedContentLength attribute or if it has some overriding value that prevents large requests When debugging some webapi calls against Visual Studio 2013, I'm receiving this error: Maximum request length exceeded....

Bonobo Git Server Configruation: HTTP Error 500.19 - Internal Server Error at line 71

iis,windows-server,windows-server-2012-r2,iis-8.5,bonobo
I have tried to configure Bonobo Git Server. I have followed the included instructions, and after trying to visit the server for the first time, I get the following error: There is a similar question; however, it gives an error at one line prior and the solution the author answered...

Publish will not push adovbs.inc to target File System destination (classic asp and IIS 7.5)

iis,asp-classic,iis-7.5,publish,server-side-includes
I have a classic ASP site on my Visual Studio 2012 development machine and I have noticed a strange behavior with Publish. A file called adovbs.inc exists in a folder called debug within the root of the site. Quite a few files on the (development) site reference this without problem...

IIS and Windows authentication not allowing error pages

asp.net,iis,web-config,windows-authentication,global-asax
I have been trying this from last two days. I am not getting whats the problem. I searched the web but didn't find any solution. i tried all the settings of IIS like "Moving negotiate down, disable other authentication" but doesn't work. SO here is my problem: I have a...

Replace a word using IIS URL Rewrite

iis,url-rewriting
I am using the IIS Rewrite module with my web.config, and would like to rewrite certain requests by replacing a word in the URL. Example: http://domain.com/windows to be http://domain.com/WINDOWSSoftware I'm aware that a URL with query string parameters can be rewritten using for example below rule <rules> <rule name="Rewrite to...

Azure virtual machine cost and pricing questions

iis,asp.net-mvc-5,sql-server-2014,azure-virtual-machine
I have an A-Series, A0 at $18.22 ($0.025/hr) Azure Virtual Machine setup. How much is the cost to update software in the virtual machine. For example, if I wish to do a Windows Update from the Virtual Machine's Control Panel, is there any cost associated with this? If I wish...

AccountDomainSID is the same for all users accessing ASP.Net MVC site

asp.net,asp.net-mvc,iis
The site is under ApplicationPoolIdentity in IIS7.5, we are using Windows Authentication. When running this code, AccoundDomainSID is the same for all users accessing the site, not unique. Are there any IIS settings that need to be configured for this to work properly? string SID = new WindowsIdentity(WindowsIdentity.GetCurrent().Token).Owner.Value; Is there...

Run WCF WebService on IIS ,HTTP Error 404.0 - Not Found

c#,asp.net,web-services,wcf,iis
I have a WCF WebService that uses JSON format. I can run it in Visual Studio 2013 properly but when i publish it to IIS to run by my machine local ip and a specific port (192.168.1.6:8005) to access it from local network by this address : http://192.168.1.6:8005/Service1.svc/checkLogin?username=2&password=2&code=1 it is...

Conflict when running IIS and WCF application listening on the same port (443)

c#,asp.net,wcf,iis
I'm in the process of doing a server migration, and I've come across an issue when trying to host a WCF application and IIS at the same time using the same IP address and port. (this works perfectly on our other server) The new server is a Windows 2012 R2...

Location of system.webServer within web.config

asp.net,iis
I am struggling to find a definitive schema guide to web.config for an ASP.NET 4.51 WebForms project. With the various web configs I am seeing both of the below and I want to know of both are right, or what the exact difference is. Is the parent for system.webServer the...

URL Rewrite causing redirect loop

.net,iis,iis-7,web-config,iis-8
An issue has been frustrating me today in setting up a URL Rewrite in an old .Net Webforms website (EDIT: It is a Web Site project, not a Web Application project, if that is making a difference). The site I'm working on is linked to a lot, all linking to...

WCF WebFaultException details not sent to client

c#,asp.net,.net,wcf,iis
Ok, so.. I have a WCF service that throws a WebFaultException<Error>(Error, HttpStatusCode.BadRequest) where Error is my custom, serializable object. This all works as expected when I host the service on my local machine, and on GoDaddy's (as seen here: link removed). But when hosted with Arvixe all I receive is...

IIS cannot write file if called from remote, only from the server

c#,.net,iis,file-permissions
I am running a web api on a IIS on Windows Server 2012 R2. The application has a controller, that on a get request will write to a file on a network share. If I access the site from a browser on the server it works fine, however if I...

TFS 2013: HTTP code 503: Service Unavailable

iis,tfs
All of a sudden, our TFS server down. When I checked in IIS, http://localhost:8080/tfs is giving 503 service error. Below application pools are getting stopped automatically, even though I manually made them start in IIS manager. Microsoft Team Foundation Server Application Pool, Microsoft Team Foundation Server Proxy Application Pool Please...

How to deploy a single solution with multiple projects?

asp.net,angularjs,iis,asp.net-web-api
I have developed a well-decoupled website using WebAPI and AngularJS as follows: SOLUTION |—— WEB.API Project |—— Website pages Project '—— Other projects related to functionalities This setup is on my own computer. Now I'm here wanting to deploy to my web server (iis 7.5, privately owned, WebDeploy installed). It...

published reports don't work - Database logon failed Error

c#,iis,visual-studio-2013,crystal-reports,db2
I am developing a simple web app that has 3 reports created on VS 2013, for some reason those reports run fine from developer mode, but when I publish the website they give me "Database logon failed" Error. What could be causing this? VS is installed on the same server...

How to publish ASP.Net website to remote machine?

asp.net,iis
I am trying to publish the ASP.Net site in IIS to a remote machine. Presently I am publishing the site local file system and copying that folder to remote machine using mstsc tool. Is there any way I can directly publish to remote machine?...

404 - File or directory not found

c#,asp.net,.net,iis,dotnetnuke
I am very new in DNN and using very first time; I have an application developed in DotNetNuke which I need to deploy on server. Server has IIS6 and application has DotNetNuke 6.2.01610 After deploying site, I get error as 404 - File or directory not found; There is already...

Request.QueryString empty if 'Form' is one of the keys

asp.net,iis
The following query string results in Request.QueryString being empty: http://intranetsite/form.apsx?InstanceID=123&Form=App.SomeForm As soon as I change it to http://intranetsite/form.apsx?InstanceID=123&Forms=App.SomeForm Request.QueryString is populated with two key value pairs (InstanceID - 123 and Forms - App.SomeForm). I am using IIS 8 on a win2k12 server. I think that this worked under IIS 7...

Is it possible to share session between different PHP versions?

php,apache,symfony2,session,iis
I am starting an old app refactoring, I will rebuild some functionality from spaghetti code to MVC (Symfony). Plan was I will set up new IIS app, using subdomain. Now, old app is running PHP 5.3 which can't be upgraded. New app will be running on PHP 5.6. Only thing...

DataContext.Executequery login failed

c#,sql-server,linq,iis,linq-to-sql
I use Linq to sql and have the following statement: myDataContext ctx = new myDataContext(); string query = "select * from myTable"; var mycollection = ctx.ExecuteQuery<t_entity>(query).ToList(); This code works well with my domain user but not with the user running the IIS application pool which has lower privileges. It is...

How to tell whether my ASP.NET app is 32bit in a 32bit IIS worker process

c#,asp.net,asp.net-mvc,iis
I need to ensure that my ASP.NET MVC app: was built in 32-bit mode is running in an IIS worker process which is in 32-bit mode (i.e. it's on a 32-bit machine, or it's running in WOW64 on a 64-bit machine) I need to check programmatically, as I'm on shared...

What does IIS do with MVC projects

asp.net-mvc,iis
IIS seems to be an application that listens for incoming connections, parses the data sent there as HTTP requests, and maps request urls to directories based on a site an application and a virtual directory, and then does something based on the file present (or not present) on that location....

Two websites in same ASP.NET solution

asp.net,angularjs,iis,url-rewriting
I have two websites (index.html files) in the same asp.net solution. I have two domains that I want to direct to the correct html file. This is an angularjs application so I have only one html file per site. I want all requests for any resources at http://site1.myhostname.com/ to return...

jQuery or AngularJS Ajax “POST” request to server using code below however do not sending param data to server.

javascript,jquery,ajax,angularjs,iis
"POST" request to server using code below however do not sending param data to server. I tried jQuery Way and var request = $.ajax({ url: baseUrl, type:'post', data: 'userId=userabcd&passwd=abcd1234', }); request.done(function( msg ) { console.log(msg); }); request.fail(function( jqXHR, textStatus ) { alert( "Request failed: " + textStatus ); }); AngularJS...

Can't open localhost in Project Spartan in Windows 10 preview

iis,browser,windows-10,microsoft-edge
I installed Windows 10 preview and installed IIS. Open "http://localhost" in Project Spartan can't connect. IE has no problem. What's the problem?...

IIS + ASP.NET + Multiple sessions each minute with random session id

asp.net,session,iis
My IIS is starting a new session each minute with different session id as you can see below: 2015-05-24 02:05:48,284 WARN [5gs1h5biysgaovwgxclzoa53 - ] Session_Start (): 24-05-2015 02:05:48, ID=5gs1h5biysgaovwgxclzoa53 2015-05-24 02:06:48,289 WARN [i2cw11dcyc444agufblzqw3t - ] Session_Start (): 24-05-2015 02:06:48, ID=i2cw11dcyc444agufblzqw3t 2015-05-24 02:07:48,290 WARN [x4d2dqekamnmbqtwcb1xugzv - ] Session_Start (): 24-05-2015 02:07:48,...

Adding a sub-application to an existing IIS application programmatically

c#,asp.net,.net,iis
I am using the System.Web.Administration assembly. Using this I am able to create websites with applications and virtual directories. And the applications are able to have virtual directories. But there doesn't seem to be an exposed way to create an application inside of an existing application. A Site has an...

Allow console application to access Windows Authenticated web app

c#,asp.net,asp.net-mvc,iis,asp.net-web-api
I have a MVC web application which uses Windows Authentication. So we do things like System.Web.HttpContext.Current.User.Identity.Name Now there is a console app I'm writing that would be run as part of a batch job. All this console app needs to do is call an ActionResult in the main web app...

ColdFusion Builder 3 vs. Dreamweaver & local and remote paths

eclipse,iis,coldfusion,development-environment
I can't wrap my head around how I'm supposed to use ColdFusion Builder 3 (akin to Eclipse). Up until this point, I've been using Dreamweaver 5, which is getting 'long-in-the-tooth', and I wanted to give CF Builder a try. So, in Dreamweaver, it's pretty simple: you setup connections to servers...

Cannot start Website in IIS - W3SVC running

asp.net,iis
I am trying to start a Website in IIS but it doesn't get started and gives me following error: The World Wide Web Publishing Service (W3SVC) is stopped. Websites cannot be started unless the World Wide Web Publishing Service is running. How can I resolve it? I donot even know...

File upload web api 2.0 error after deployment on IIS 8.5

c#,iis,file-upload,asp.net-web-api2
The below code works very well on development environment VS 2012, the images are saved to App_Data. When I deployed the same on Win 8.1, IIS 8.5, the App_Data was missing. I manually create the folder and set the properties as given in http://hintdesk.com/tutorial-publish-asp-net-web-api-in-iis-8-5-and-windows-8-1/. I am seeing strange behavior as...

node.js iisnode https 500 HRESULT 0x6d subStatus 1013

node.js,iis,socket.io,iisnode
I'm currently working on a realtime chat with socket.io and node.js. On my development machine everything works fine. I can call my socket.io-server on port 888. The same port is free and reachable on my production server. I can't figure out why IIS raises an 500 error. Has anyone an...

IIS Url Rewrite rule HTTP to HTTPS AND add WWW

c#,.net,iis,url-rewriting,web-config
I have a website that I want to be only used with the WWW sub-domain and via HTTPS. I had an URL rewrite working for adding WWW. But now I also want to force a HTTP to HTTPS redirect. Just forcing HTTPS works as well, but when I can't really...

Web API Sync Calls Best Practice

c#,iis,.net-4.5,web-api
Probably this question has already been made, but I never found a definitive answer. Let's say that I have a Web API 2.0 Application hosted on IIS. I think I understand that best practice (to prevent deadlocks on client) is always use async methods from the GUI event to the...

IIS URL rewrite rule for https and containing path

iis,url-rewrite-module
I'm trying to figure out a url rewrite rule to rewrite http requests into https only when a specific path is accessed like below. I've tried quite a few things that in the test pattern seem as though they should work but it never does. url accessed: http://example.com/books/test.css I need...

Why web API return 404 when deploy to IIS

asp.net,asp.net-mvc,iis,asp.net-web-api
Windows Server 2012 R2, IIS, VS2013 I have implement a ASP.NET web api, when I debug in VS2013, it can open IE, and I can call my web api correctly. http://localhost:42508/api/log/111 I have use "publish" in VS2013, and deploy all files to D:\api_publish. Now, I set up IIS, and under...

Angular-UI-Router and IIS publishing

angularjs,iis,routing,angular-ui-router
I'm attempting to get Angular ui-route to work once deployed on IIS7 but even with URL rewrites setup in the web.config its still not working as perfectly as it does in IIS express. The 404 state is always intercepted by IIS and displays 404 - File or directory not found....

Routing problems in ASP.NET Web API if deployed in IIS as child application

c#,asp.net,iis,visual-studio-2013,asp.net-web-api
I have a solution in VS2013 with multiple ASP.NET Web applications. I have added an ASP.NET WebAPI project in the same solution. After I deployed the WebAPI as a child application in IIS I got the following error: Multiple types were found that match the controller named 'Account'. This can...

Recycling app pool each time something is published

.net,iis,lucene,umbraco,application-pool
I'm working on an Umbraco site where I have custom sections, and therefore use the application.config and trees.config files. I have a problem where every time I publish something, the app pool recycles with the following message: w3wp.exe Information: 0 : _shutDownMessage=CONFIG change HostingEnvironment initiated shutdown CONFIG change HostingEnvironment caused...

SSL certificate is not installing

iis,ssl,https
I'm facing an issue in installing SSL certificate in IIS and below are the step before I got the certificate from my CA. Generated a private key file using OpenSSL with: "openssl genrsa -out key_name.key 2048" command. Generated .csr file with: "openssl req -out CSR.csr -key key_name.key -new -sha256" command....

“%” character causing issues in IIS URL rewrite regex

regex,asp.net-mvc,iis,url-rewriting
I'm replatforming an online shop, and part of that process is writing 301 redirects for old links customers may have bookmarked to hit their new addresses. All of them work apart from the ones in which the old address contains the % character. It seems to somehow be interfering with...

How IE setting affect authorization

asp.net,iis
I have a Webform app written in asp.net 4.5 and trying to understand how IE plays a role for authentication. So far my search has not provided a solid answer I know webconfig setting override iis setting. But assume we set the authorization mode to anonymous in both of iis...

IIS 6 Allow anonymous access by default

asp.net,iis,website,iis-6
I have automated builds the will create IIS websites for me using FinalBuilder scripts. The problem is that in FinalBuilder there is no option to set 'allow anonymous access' to true on creation of the website, so I am forced to go into IIS manager and change this manually. In...

Wordpress on IIS with shared wp-content

php,wordpress,iis,permissions
I've been trying to install Wordpress on IIS and everything went smoothly with a standard installation and an handler mapping for php-cgi. Since I have a public server (A) and a private shared server (B), I need to have a WP installation on server A with a shared database and...

If I use targetFramework=“4.5” why are my pages still served in 4.0?

asp.net,iis
My Web Application is targeting framework 4.5 and runs perfectly on the local IIS, but when I publish the the server (Windows Server 2012, IIS 8.0), I see that the webpage is still rendered as 4.0, which is a problem because web.optimization only works on 4.5. I made sure that...

How do you declare or use variables in web.config

iis,web-config
Because our web application is using both Entityframework and System.Data.SqlClient, we need to have 2 . This is very error prone, as you need to make you update both with the same data. So i wonder if its posible to add variables to the web.config xml? <connectionStrings> <add name="Server" value="sql2014"...

Hosting a WCF service using net.tcp binding in IIS 7 (unreachable from outside)

c#,.net,wcf,iis,tcp
I have developped a WCF duplex service and a Windows Winforms client communicating togeteher via a net.tcp duplex binding. Both do communicate and work fine on my LAN, the WCF service beeing hosted on a IIS 7 on a Windows 8 workstation. I then tried to host the WCF service...

IIS and Yii2 pretty URL

.htaccess,iis,web-config,yii2
What is the .htaccess equivalent for IIS to enable pretty URLs in Yii2 on IIS. Indeed, I don't know what could I do with web.conf to allow those URLs.

IIS Authorization Not Working During WebRequest to Itself

c#,asp.net-mvc-4,iis
I'm having a problem when trying to get an authenticated response in MVC4 on IIS when making a call to itself using the current users credentials. I'm using the code below. It simply creates a request back to the local server using the port its on to return a given...

How to remove the :port number from the end of an IIS URL?

url,iis,port
In IIS, I noticed when you use the default ports (80 for http and 443 for https) the port number doesn't display at the end of the URL in your browser. However, if you use a different port it will display. Example: Default port generates link: http://www.example.com Custom port generates...

Windows client damage authorization header (Kerberos) => IIS 400 (Bad Request)

.net,windows,iis,kerberos
We are facing strange behavior on about 5% of Windows (7 Pro and XP Pro, both 32 and 64 bits) client computers. These computers gets randomly error from IIS server - 400 Bad request. We are using Windows domain and these clients are trying to authorize to IIS via Kerberos....

WebApiConfig.Register Clears routes defined by RouteConfig.RegisterRoutes apon deployment

asp.net-mvc,asp.net-mvc-4,iis,asp.net-mvc-routing,asp.net-web-api-routing
I'm on struggle street here, When I try to add API controllers it seems to destroy all my MVC base routes and area routes. On my application start I call protected void Application_Start() { AreaRegistration.RegisterAllAreas(); WebApiConfig.Register(GlobalConfiguration.Configuration); //FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); RouteConfig.RegisterRoutes(RouteTable.Routes); Util.RazorDebuggingSetup(); BundleConfig.RegisterBundles(BundleTable.Bundles); } using System.Web.Mvc; An example of an area config: namespace...

Set the Enable Parent Paths = True of ASP Application in IIS for all available websites by Power shell Script

powershell,iis
I am trying to update Enable Parent Paths = True of ASP Application in IIS for all available websites by Power Shell Script. Below is my power shell script which I tried but it works for Specific Website only. Set-WebConfigurationProperty ` -PSPath MACHINE/WEBROOT/APPHOST ` -Location 'Default Web Site' ` -Filter...

get-website/get-webapplication associated directory

powershell,iis
If I wanted to find the directory associated with an IIS site or application, how would I do that? I cannot seem to find anything on any properties of objects from Get-Website and Get-WebApplication that allow me to do so....

Appcmd Syntax for Arrays in Powershell

powershell,iis
I'm trying to run the following to set the handler mappings for each of our websites using appcmd in powershell: $websites = Get-ChildItem IIS:\Sites foreach ($Site in $WebSites) { C:\Windows\system32\inetsrv\appcmd set config "$site" /section:handlers -accessPolicy:"Read,Script,Execute"} However I'm getting this error message for each site as it iterates through them: ERROR...

CakePHP 3.0 IIS web.config

php,cakephp,iis,iis-7.5,cakephp-3.0
All of my urls for images and css or being rendered with app prepended /app/favicon.ico /app/img/logo.png /app/css/styles.css The content of the pages is rendering fine, just not the images and css. My web.config looks like this, but doesn't seem to be helping these urls. Thus they are all resulting in...

How to track 500 errors on WebSockets (ws://)

c#,asp.net,iis,websocket
I'm trying to play around with WebSockets on IIS 8.5. I started off with a couple of very basic C# classes from a lesson: using Microsoft.Web.WebSockets; using System.Web; public class ChatHttpHandler : IHttpHandler { public void ProcessRequest(HttpContext context) { if (context.IsWebSocketRequest) context.AcceptWebSocketRequest(new WebSocketChatHandler()); } public bool IsReusable { get {...

Location header with IDN characters broken when hosted in IIS

asp.net,iis,asp.net-web-api
For some POST calls in our API we point the response Location header to the created resource. The Location header can contain a URL with IDN characters (e.g. http://résponse.com) When hosting the API in IIS, IIS changes the Location header to http://résponse.com/ There is definitely something wrong in the encoding...

Azure web app not passing https scheme to java web application

java,azure,iis,ssl,azure-web-sites
I am trying to enforce https on an Azure java web app running on tomcat 1.7. (The application wa created using the portal) I have added the below web.config to the site/wwwroot directory. This is correctly redirecting the non http calls via https, but inside the application the request appears...

abcpdf and XULRunner failure or temp browser profile directory error

.net,iis,windows-server,xulrunner,abcpdf
I can't seem to figure out this error message while upgrading to the newest version of ABCPDF, 10.0.1.0. Does the error message give any clues? It happens in spurts and restarting the app pool is the only way to fix it right away. WebSupergoo.ABCpdf10.Internal.PDFException: Failed to add HTML: Gecko engine...

AvailableVirtualMemory on IIS and Console application

asp.net,iis,memory,console-application
I'm having problems to get the real value of AvailableVirtualMemory in IIS and a Console application, as detailed below: When i run these commands on a Console application: Console.WriteLine(String.Format("Memoria virtual total: {0}MB", My.Computer.Info.TotalVirtualMemory / 1024 / 1024)) Console.WriteLine(String.Format("Memoria virtual disponible: {0}MB", CDec(My.Computer.Info.AvailableVirtualMemory / 1024 / 1024))) The Console shows me...

Maximum value for IIS .NET Compilation Batch Time-out

iis,pre-compilation
What is the maximum value for the IIS -> .NET Compilation -> Batch -> time-out ? i need to set it to maximum in order to avoid compilation cannot be completed within the time-out period, the compiler reverts to single-compilation mode for the current page....

HTTP to HTTPS Redirect - IIS 8.5 not working properly

redirect,iis,iis-8.5
I've read a number of posts here on SO as well as on the 'net (IIS blogs, etc.). I'm trying to force all connections going from domain.com to www.domain.com and at the same time forcing the request from HTTP to HTTPS. I'm using this set of rules and rewrites but...

Running SonarQube on internal Web Server

web-services,iis,sonarqube,sonarqube-5.0
I am trying to make Sonarqube working on a virtual machine, IP 192.168.0.150, running on a production server (Win Server 2012 R2). I need also to access it from the Internet. Thus, I created a new website in IIS on the Physical server enabling the reverse proxy and redirecting everything...

DokuWiki Installation on Windows server 2003 using IIS problems

php,iis,permissions,windows-server-2003,dokuwiki
I am trying to install DokuWiki on a windows 2003 server and using IIS 7.2 and PHP 5. I have gone on to IIS and created a virtual directory that points to where I extracted DokuWiki, I have set up all the permissions for that folder ensuring that it has...

IIS High CPU Usage in Visual Studio 2013

iis,visual-studio-2013,iis-express
When we use Visual Studio 2013 for web development, we experience the following issues while debugging: Web application takes a very long time to load Client scripts take a long time to load CPU usage by the IIS worker process increases enormously while debugging the application Changing to a local...

Chrome now treating IP address of localhost same as somesite.localhost

google-chrome,iis,localhost,vagrant,hosts
For a while I have been running two different server environments on my Windows 7 OS. IIS runs on 127.0.0.1 and I have a Vagrant VM that uses 192.168.33.10. My hosts file looks something like: vagrantsite1.localhost 192.168.33.10 vagrantsite2.localhost 192.168.33.10 iissite1.localhost 127.0.0.1 iissite2.localhost 127.0.0.1 Up until a week or so back,...

How can I correlate session.sessionid and IIS Log session cookie?

asp.net,session,iis,asp-classic,iis-6
We are logging some tracking information to a database table within a classic asp site. One of the pieces of information captured is the users session ID (session.sessionid). Examples of what is captured are: 808592330 14267388 78330403 Then, separately in our IIS logs, session cookies are logged as such (these...

Monitor Application logs as part of Jenkins

c#,.net,iis,jenkins,continuous-integration
I have a CI server using Jenkins which builds the code, starts the server, and runs the application tests. I would like to monitor the logs during this process to check for errors (e.g., "ERROR"). I see a Log Parser Plugin for jenkins but that only seems to monitor the...

IIS hosted ASP.NET and SharePoint server libraries - authentication / security issue

asp.net,iis,sharepoint,asp.net-web-api,owin
I am currently working on a project where we are focused to develop as much as possible against the SharePoint CSOM library. Unfortunately CSOM offers no possibility to access Cross-Site-Publishing functionalities. So we decided to deploy a ASP.NET Web API web service on the target SharePoint system, which is hosted...

unexplained Session time out in ASP.NET

c#,asp.net,vb.net,iis
I have Webform ASP.NET 4.5 application. In the login page Session variable is set as :(simplified related code) Session["UserName"] = txtUserName.Text; (txtUserName.Text cannot be empty) and then Response.Redirect("Survey.aspx"); In survey page I have if (Session == null || Session["UserName"] == null) { string errorText = "Session was timed out due...

Host Four ASP.Net Projects in IIS as single direcory(maintain more projects in same url)

asp.net,iis,hosting,web-deployment
I m having a ASP.Net Webapplication it accessed by from many geography like India,China&America.In that application's login page fields are username,Password & Geography. Based on this login page geography option the application's functionalities will change in all page. In this project,If we add a feature for Indian users but that...

Access secured Web Services using integrated windows authentication from Angular app on different server

angularjs,authentication,iis,iis-7.5,windows-authentication
I have a web service (currently localhost:100) which uses Windows Authentication, is served through IIS and is set up with Access Control Allow Origin properties in the web.config: <httpProtocol> <customHeaders> <add name="Access-Control-Allow-Origin" value="http://localhost:81" /> <add name="Access-Control-Allow-Credentials" value="true" /> </customHeaders> </httpProtocol> I'm trying to access them from an angularJS app served...

SignalR: WebSockets is unsupported in the current application configuration

asp.net,iis,signalr,iis-express
I'm using SignalR 2.1.2 in my project. Everything was OK, But today I saw that notifications don't work in my project. I tried to troubleshoot issue So I checked Windows Event Viewer and saw this error: Exception information: Exception type: InvalidOperationException Exception message: WebSockets is unsupported in the current application...

deployment of a site asp.net and iis

c#,asp.net,iis
I know this is for some of you a stupid question but for me is a real problem. I have never deployed a site before What i have done so far: 1) publish the site from visual studio to a folder. 2) added to iis for testing everything works great...

Saving Image To a Temp Folder is Loosing Session

c#,asp.net,.net,iis
I have a method that saves an image to a temp folder: System.Web.HttpContext.Current.Server.MapPath("~/bin/temp/") I debugged each line, and I am sure that the following line is making my application restart, so it is loosing my session: bitmap.Save(pathProcessedImage); After this method is executed, the Global.asax.cs trigger these events: Session_End Application_Start Session_Start...

Deploy MVC Application to IIS 7.5

asp.net-mvc,iis,model-view-controller,windows-server-2008-r2,.net-framework-version
I have created a ASP.NET MVC Application with .Net Framework 4.5. I have tried to deploy in IIS 7.5 with Application Pool 4.0 but the following errors. Is there anything I should change in IIS Configuration or in Application Web.conf. Thanks in advance ! ...

How do subdomains work?

c#,asp.net-mvc-4,iis,subdomain,multi-tenant
I have a set up an ASP.net MVC application in my IIS at port 80. The website resolves for any subdomain. Like dev.localhost,test.localhost etc. No I have not set up any of these sub domain on my machine. I have no host file entries except the default, and no host...

Regex to match file extension while ignoring query string

regex,iis,url-rewrite-module
I'd like to build a IIS url rewrite rule that matches several file extensions but ignore the query string. Samples: /hello.html // Match /test?qs=world.html // Should not match /test?qs=world.html&qs2=x // Should not match Here is what I was using that does not work correctly: <add matchType="Pattern" input="{HTTP_URL}" pattern=".+\.(js|css|less|html|eot|svg|ttf|woff|json|xml)$" negate="true" />...

IIS 7.0 URL REWRITE

asp.net,iis,url-rewriting,web-config
I am setting up a redirect to WWW for one of our sites in the web.config and ran into a small issue. The code I have in the web.config for the rewrite is as follows : <rewrite> <rules> <rule name="Redirect to www" patternSyntax="Wildcard" stopProcessing="true"> <match url="*" /> <conditions> <add input="{HTTP_HOST}"...

Difference between containers (Docker) and IIS

windows,iis,docker
I am learning about containers (mostly Docker) since it is coming to windows. And the benefits seem very similar to IIS. I work behind a firewall building apps for my company (Line of Business). We have a bunch of VMs that will each host a family of web services. One...

Removing X-Frame-Options being added automatically only in Login page

c#,asp.net,asp.net-mvc,iis,iframe
I am developing an ASP.NET MVC application which needs to be loaded inside an iframe in another website. But the login page just won't appear inside the iframe because an Header is being sent in the response X-Frame-Options which is set to SAMEORIGIN. Browser is not displaying the page in...

Add Binding To IIS With PowerShell Without Overwriting Existing

powershell,iis,octopus-deploy
We use OctopusDeploy to create the website and we use the create website template that is on the community step sites. I have modified it slightly to ensure that if the website exists it adds the default binding however it is removing all the existing bindings. Is there a way...

Proper way to distribute web.config as a third party web service provider

c#,asp.net,.net,web-services,iis
I was wondering what's the best way to distribute the web.config when it's part of a web service that's meant to be installed by an installer on any machines. In my situation the web.config contains http handlers that's required by the web service to function properly, but once installed the...

ASP.NET address in IIS

asp.net,asp.net-mvc,iis
We have an ASP.NET MVC Intranet hosted on our IIS server. As you'll know, a Visual Studio project/solution called "MyProject" for example, will have the first folder containing the solution, then another one containing the project files, so it would be http://intranet/myproject/myproject/ for example. Is there a way to change...

IIS Print PDF through CMD using acrord32.exe

c#,asp.net,pdf,iis,printing
I have a web application where i'm trying to print directly to a printer. The code works locally, however, I can't seem to get it to work on the test server. The method is as follows; internal void PrintStockTransactionPdf(string documentNumber, EnStockTransactionType transType) { Guid fileName = Guid.NewGuid(); string tempFilePath =...