Get password for IIS Application Pool account


There are many instances where you have to provide a custom account identity to an App pool in IIS. There are also instances where you might have forgotten the password for that account which has to be set as identity for that Application Pool. In such cases, you can use the APPCMD command to retrieve the password for that user. One thing to remember is that there has to be an app pool existing in the machine already which has been assigned that account’s Identity for us to retrieve it’s password. Please note: This can be used for IIS 7 and above.


appcmd is an IIS tool used to manage IIS server. It provides many functions that can be used to manager server related activities like create/configure sites, start/recycle/stop app pools, etc.

Retrieve Password of an App Pool identity account:

  1. To retrieve password for an app pool identity account, open the command prompt in administrative mode.
  2. Navigate to C:\System\Windows32\inetsrv directory. This is the location where appcmd.exe exists.
  3. Type the below command and press enter.
    appcmd.exe list apppool <<app_pool_name>> /text:*
    For example: I have an app pool in my IIS named SampleAppPool which has been assigned a particular account’s identity whose password I would like to retrieve. So I would enter the below command in command prompt.

    cmdPress enter and the result will be as shown below. Due to security reasons, I have removed the username and password from the image but trust me, it shows the username and password there.resultHope this helps!
Posted in General, IIS, .NET | Tagged , , , , , | Leave a comment

Installing Windows Identity Foundation Runtime. Resolving Windows Identity Foundation SDK Installation error.


I had to install Windows Identity Foundation SDK in a Windows 2012 R2 server for setting up Claims-based authentication. So I downloaded the SDK and started the installation. Immediately I was shown this error popup.

WIF SDK Installation

The cause of the error is apparent – Windows Identity Foundation (WIF, going forward) is not installed in my server.


To install WIF runtime, follow the below steps if you’re using Windows Server 2012

  1. Open server manager. Click on Add Roles & features.
    Server Manager
  2. Click Next and navigate till the Features section. If you want to know how to navigate through “Add Roles and Features” dialog box, refer to my post here. Make sure you come back to this post once you reach Features section.
  3. Scroll down and you will find “Windows Identity Foundation”. Select that and click next.
    Note: In your case, it will be unchecked and not disabled and available for selection unlike the one shown here in the screen shot below.
    Windows Identity Foundation feature
  4. Click next and finish the installation.

This will install WIF Runtime in your server. After this is completed, run the SDK setup file again. This time, WIF SDK will get installed without any issues.

To install WIF Runtime on Windows 8, 8.1:

  1. In start menu, type “Turn Windows Features On and Off”. Open the dialog box.
  2. Scroll down and enable Windows Identity Foundation.
  3. Click OK.

This install WIF Runtime in Windows 8, 8.1.

Hope this helps!

Posted in .NET, General | Tagged , , , , , , , , , , , , | Leave a comment

[Solution] HTTP Error 500.19 The requested page cannot be accessed because the related configuration data for the page is invalid


I was deploying a web application on a server and I encountered an error when I browsed the website from IIS. The exact error page is given below:

HTTP Error 500.19 – Internal Server Error The requested page cannot be accessed because the related configuration data for the page is invalid.

Detailed Error Information:

Module IIS Web Core

Notification BeginRequest

Handler Not yet determined

Error Code 0x80070021

Config Error This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault=”Deny”), or set explicitly by a location tag with overrideMode=”Deny” or the legacy allowOverride=”false”.

Config File \?\C:\inetpub\wwwroot\My_Website\web.config

Config Source:

41:   <system.webServer>  
42:     <handlers>  
43:       <remove name="ExtensionlessUrlHandler-Integrated-4.0" />

This was the page shown to me on the browser.


After some browsing around, I found out that all the features and server roles were not enabled in my server.

Enabling Server roles and features in Windows Server 2012:

  1. Go to Server Manager. Click on Manage on the top-right.
  2. Click Next in the “Before you begin” view.
  3. In the “Installation Type” view, select “Role-based or feature-based installation” and click Next.
  4. In the “Server Selection” view, select the server from the list below and click Next.
  5. In the “Server Roles” view, scroll down, expand “Web Server“, select everything in the “Security” sub-section.
  6. In the “Application Development” section in the same view, I selected the below roles as they were sufficient for my requirement. After selecting the below, click Next.
    1. .NET Extensibility 3.5,
    2. .NET Extensibility 4.5,
    3. ASP.NET 3.5,
    4. ASP.NET 4.5,
    5. ISAPI Extensions,
    6. ISAPI Filters
  7. In the next view (Features), select everything in .NET Framework 3.5 Features and .NET Framework 4.5 Features. Then click Next.
  8. In the Confirmation screen, click “Install“.

This would install all the required features and server roles in the server. After installation has succeeded, close the wizard, reset IIS (optional) and try accessing the application again in the browser. The issue should be resolved and you will be able to access the application.

Hope this helps!!

Posted in IIS, .NET | Tagged , , , , , , , , , , , , , | 1 Comment

New year, new resolutions, new hopes. Happy New Year!!

Dear readers,

Firstly, I would like to thank you for visiting my blog and encouraging me to write more posts. However, I’ve been very busy lately and have not been able to post much from the past few months.

So now, with the new year starting tomorrow, I would like to take a resolution that I would write a new post regularly here (at least 2 posts per month) and make this blog more useful and also improve my knowledge further.

I have also taken a resolution to improve my skills on Azure primarily and also on development of Windows universal apps. I will work hard to achieve these by the mid of this year. I’m yet to plan for the next half of the year ;-) During the course of the first 6 months, I will make it a point to post all my learning here in an easy-to-understand way so that it can help others who are also looking to learn the same.

Duh! Enough of boring talk. Coming to the actual point, I would like to wholeheartedly wish you all a very very happy new year! :-) Hope you all have a great year ahead with lots of wonderful moments!

Looking forward to making 2015 wonderful! Cheers!

Posted in General | Leave a comment

2014 in review

The stats helper monkeys prepared a 2014 annual report for this blog.

Here’s an excerpt:

The concert hall at the Sydney Opera House holds 2,700 people. This blog was viewed about 23,000 times in 2014. If it were a concert at Sydney Opera House, it would take about 9 sold-out performances for that many people to see it.

Click here to see the complete report.

Posted in General | Leave a comment

Do a factory reset to MAC OS X 10.9 Mavericks


This post will explain all the steps that need to be taken in order to do a factory reset to your MAC. I have followed these steps on my MAC OSX 10.9 Mavericks and everything works fine after that.

Steps to be followed are given below :

  1. Turn off your MAC : The first step you need to do is to SHUT DOWN your mac machine.
  2. Hold down option key and power button for a few seconds. This will turn on your mac but it will not directly boot to the desktop. Instead, it will show two hard disks; One is your actual hard drive which stores all the data. The other is a recovery hard drive. See screen clip below.Make sure you first select the WiFi network below. Then, click on Recovery HD and click on the Upward arrow under it.
  3. Now Mac will reboot. Once you have clicked on the upward arrow, the mac will reboot. Once it has rebooted, it will show the MAC OS X Utilities. See screen clip below.
  4. Here, select Disk Utility and click on Continue. Once this screen appears, click on Disk Utility and then click Continue. You will now be directed to another window where you can erase or re-partition the hard drive. In our case, we need to erase the hard disk completely.
  5. In the Disk Utility window, select Macintosh HD in the left-side pane, then select the “Erase” tab in the right-side pane, then select Macintosh HD Extended (journaled) in the drop down and finally click on erase. I have attached a sample screen clip below to depict the process.

    Click on “Erase” again to confirm. Once it is finished, you can see that the hard drive is completely erased by looking at the free space given at the bottom of disk utility window.
  6. Now close the disk utility window. It will now show the Mac OS X Utilities window again. Here, select Reinstall Mac OS X and click on Continue. Click Continue again in the next two windows. Now as your mac is connected to WiFi, it will download the OS from the Apple for re-installation. Select I Agree. Then in the next window, you will have to select the drive in which you want to install the OS. Here, select Macintosh HD and click on Install and then click on Continue.
    Now the Mac OS will start downloading and this process will take quite some time depending on your internet speed. With my 4MBps internet, it took around 4 hours to download. So be patient. ;-)
  7. Once the download is complete, the Mac will automatically reboot and directly move to the installation screen where it shows the installation progress. Even this process takes some time. Generally around 15 minutes to half an hour.
  8. After the installation has succeeded, click on Restart. The Mac will anyhow automatically restart after a few seconds. So no problem even if you don’t hit the restart button :-)
  9. Success : Once the system restarts, we have a fresh OS installed which can now be setup again as per our wish. You will now see the screen where you need to select the country and then keyboard layout and stuff. So basically, if you see this screen, it means you now have a brand new OS installed afresh.
  10. Continue with the setup of your mac until you see the desktop. Once you see the desktop, your Mac is now fully cleaned and reset and ready to run.

You can also refer to this excellent video which shows the steps live.

Hope this helps!!

Posted in Mac OS X | Tagged , , , , , , , , , , , , , | 6 Comments