Category Archives: Windows 8

You don’t have permission to mount the file

You can get the following error message in Windows 8 when you try to mount an ISO file with Windows Explorer:

“You don’t have permission to mount the file.”

 

no-permission-to-mount-the-file

Don’t panic, it is a false alarm, the ISO is successfully mounted, just check it in My Computer.

 

Technorati Tags: ,,

Remembering remote desktop passwords

It is really annoying that the remote desktop client sometimes remembers only your login name but not your password, because:

Your credentials did not work

Your system administrator does not allow the use of saved credentials to log on to the remote computer COMPUTER because its identity is not fully verified. Please enter new credentials.

rdp-credentials

To fix this start the Local Group Policy Editor (gpedit.msc), and navigate to this branch: Computer Configuration –> Administrative Templates –> System –> Credentials Delegation. Here open the Allow delegating saved credentials with NTLM-only server authentication option and set it to Enabled.

Click the Show… button in the Add servers to the list option and add the servers you want to apply this setting to. You must use the TERMSRV/computername format to specify a single computer, or you can use TERMSRV/* to refer to all servers.

 

Technorati-címkék: ,

IIS remote management from Windows 8.1

One of the coolest features of the Internet Information Services (IIS) Manager (inetmgr.exe) is that you can run it locally on your client computer, and you can remotely manage your IIS server with it on a graphical user interface. Just start inetmgr.exe, then click the Connect to a Server item in the File menu:

inetmgr-connect-to-file-menu

This starts a simple wizard, and if the server has the Web Management Service installed, you can instantly connect to your server, to your website or to your web application.

It is very quick and simple, if and only if you have that menu item. Because it doesn’t exist neither on Windows 7, nor on Windows 8 or 8.1 by default. (Wait, you have a Save Connections (well, in disabled state), but why?)

inetmgr-default

In case of Windows 7 I understand the historical reasons, but I couldn’t find any logical explanation for the newer client operating systems. If if has to be a separate download it could be a part of RSAT.

Stop whining and let’s fix this issue instead. Start Web Platform Installer where you can search for example for “remote” to find the IIS Manager for Remote Administration v1.1:

inetmgr-webpi-search

Don’t be shocked by the 2011 release date, it is exactly the tool what you need. Click Add in the row, then Install on the bottom, and finally click I Accept in the next dialog to accept the license terms. The download and the installations starts, but suddenly stops with the following error:

inetmgr-webpi-sorry

The installation failed because it requires Windows 7 or newer. Come on, I’m on Windows 8.1, dude!

OK, try it again, but at this time click the Direct Download Link link in the license dialog:

inetmgr-webpi-licence

This triggers your default browser which downloads the MSI installer into the folder you select. By the way you can find the download URL in the installation log as well by clicking the View log here link in the previous error dialog. In my case the installer was downloaded from here:

http://download.microsoft.com/download/D/A/5/DA588562-C4A4-4337-AE36-3A4548700CDF/inetmgr_amd64_v1.1_en-US.msi

Before starting the installer, open the Properties dialog of the MSI file and check the Run this program in compatibility mode checkbox:

inetmgr-compatibility

Click through the wizard, restart IIS Manager and now you can connect to your remote webserver. On the first connection IIS Manager may download additional modules just as usual:

inetmgr-features

 

Technorati-címkék: ,

Run as Administrator on Windows 8.1

I use Windows 8.1 for four weeks now with a non-admin account of course. When I need admin privileges, I start the app with the well-known Run as Administrator option. I search for the app:

RunAs-1

Then comes the usual UAC dialog:

RunAs-2

Where I enter my user name and password:

RunAs-3

And when I hit Enter, nothing happens. Nothing. What? It worked for years, how can it be broken now?

I was angry about it, because this was the only issue in Windows 8.1 that made me upset on a daily basis. Then, after weeks, I suddenly realized that it was my fault: I didn’t read the instructions. Do you see now?

Note to self: RTFM!

 

Technorati-címkék: ,

Enable the Hibernate button on Windows 8

I freshly installed Windows 8.1 RTM on my old laptop and the setup beautifully recognized all my devices and installed the drivers for them. However the Hibernate option didn’t show up in the shutdown menu. As a first try I enabled hibernation with the powercfg /h on command with no success.

It seems that after enabling hibernation, the Hibernate button must be enabled as well. On the left pane of the Power Options dialog you can find the Choose what the power buttons do action:

hibernate-power-options

When the Define power buttons and turn on password protection dialog is displayed you can turn on the Hibernate button with administrative privileges:

hibernate-shutdown-settings

Now you can click Hibernate in the old world:

hibernate-shutdown-menu

And in the new world as well:

hibernate-shutdown-charm

 

Technorati-címkék: ,

ASP.NET 4.0 forms authentication issues with IE11

As I mentioned earlier, solutions that rely on User-Agent sniffing may break, when a new browser or a new version of an existing browser is released. Unfortunately because ASP.NET also contains browser-specific code, the new Internet Explorer 11 may cause some problems there as well.

Lucky coincidence, that one day after my previous post Eric Lawrence published an article about IE11 and User-Agent sniffing. Some interesting facts from his article:

  • The IE team deliberately designed the UA string to cause most sniffing logic to interpret it either Gecko or WebKit and not as previous IE version.
  • During the summer the ASP.NET team published a set of patches to fix the IE11 issues in earlier .NET versions. For example KB2836939 is for .NET 4.0, and you can find more links in Eric’s article.

The issue we experienced was on an older server that was running ASP.NET 4.0. IE11 sent the forms authentication cookie to the server, but the server completely ignored it. In the web.config file the forms element didn’t contain the cookieless attribute, because the default UseDeviceProfile worked perfectly before, however now we had to set it to UseCookies to make the authentication work with IE11 as well.

The patch mentioned earlier was not installed on this server, and we have not seen similar issues on .NET 4.5.

By the way setting cookieless="UseCookies" explicitly is a good security practice.

 

Technorati-címkék: ,,,

IE11 User-Agent string

Windows 8.1 comes with the new Internet Explorer 11 which sends the following User-Agent string in the HTTP requests to the webservers:

Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; rv:11.0) like Gecko

To see what’s the point here, compare this with the old versions’ UA strings:

Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Trident/6.0)
Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0)

The format completely changed, what’s more the MSIE token is completely removed! This change may cause issues, if your code contains browser-specific parts, because your old code probably won’t recognize the new browser.

Even the ASP.NET platform contains codes which respect the client’s browser, and unfortunately there were some issues in the past when some features didn’t work well with the new browsers.

Thankfully the browser detection feature of ASP.NET is completely customizable with .browser files, and if you check the C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Config\Browsers\ie.browser file on Windows 8.1, you will see that it already contains a section for IE11:

<browser id="InternetExplorer" parentID="Mozilla">
   <identification>
     <userAgent match="Trident/(?'layoutVersion'[7-9]|0*[1-9]\d+)(\.\d+)?;(.*;)?\s*rv:(?'version'(?'major'\d+)(\.(?'minor'\d+)))" />
     <userAgent nonMatch="IEMobile" />
     <userAgent nonMatch="MSIE " />
   </identification>
   <capabilities>
     <capability name="browser"              value="InternetExplorer" />
     <capability name="version"              value="${version}" />
     <capability name="majorversion"         value="${major}" />
     <capability name="minorversion"         value="${minor}" />
     <capability name="layoutEngine"         value="Trident" />
     <capability name="layoutEngineVersion"  value="${layoutVersion}" />
     <capability name="type"                 value="InternetExplorer${major}" />
   </capabilities>
</browser>

My personal experience is that old web applications must be thoroughly tested with the new IE11, even if you didn’t write any browser-dependent code, because the platform you rely on may also contain such logic. You must be especially careful if you run ASP.NET 4.0 on the server (probably because you cannot do the in-place upgrade to 4.5).

In a next post I will write about some issues we saw while we tested our ASP.NET apps with IE11.

 

Technorati-címkék: ,,