Tag Archives: Windows Vista

Vista MCE and HD – At Last

Recently – I finally decided to take the plunge with Vista Media Center Edition and High Definition Cable TV…. 

I’ve been a fan of MCE for some time, and up until February this year I’d been using Vista MCE with a standard analogue cable line into a dual receiver Hauppauge tuner card and doing relatively well.  Those of you following my rants about Comcast Cable TV of Montgomery County already know that I’d sell my grandma for a time when a better, cheaper solution to cable TV was available – and that time has finally arrived (I didn’t have to sell my Grandma – besides EBay prohibits the sale of family members).

Verizon now offer FIOS TV in my area, and with a standard premium package inclusive of HDTV on offer for $42.99 a month, it didn’t take much to ditch Comcast ($68.00 a month).

I’ve been keeping a close eye over the last few months on the handful of vendors offering Cable-Labs certified Vista PC’s and decided on the purchase of a new Dell XPS 420 with dual ATI TV Wonder Cable Card Tuners.  My decision came down to the following rationale:

  • Dell offers the cheapest Cable-Card solution (at time of writing).
  • Unless I fork out over 4G for a machine; most Vista machines offering Cable-Card are inferior to the Dell XPS.
  • ATI is pretty much the only supplier of Cable-Card tuner for Vista and Dell sold me a pair for $350, unlike other vendors charging $280 a piece.
  • Dell would ship me a machine within a month.
  • Dell is a well known brand.
  • Internal tuners do not sell me because my machine sits out of the way in the basement.

Two weeks after I place my order for an XPS-420 with 1TB disk, 4G RAM and the dual tuners a new box arrived on my doorstep – ahead of schedule.

Setup of my machine was straight forward – my dell shipped with Vista Home Premium and Cable Card support and the drivers for the ATI tuners installed.  After I uninstalled the free Dell software and turned off all unnecessary services in Vista (it’s a server, so no need for Aero) I was ready for the Verizon service person to come and install Cable Card TV.

At 11am one chilly Saturday morning the Verizon guy arrived – I’d called ahead and placed the installation order for Cable-Card so he came with this expectation.  My new XPS was running in my front room, connected to an LCD monitor (so no XBOX 360 Extender to confuse the issue) and MCE running and at the cable-card configuration screen.

The Verizon engineer had never installed Cable-Card in a computer before, but I assured him it was as easy as installing for an HD-TV.  I read somewhere ahead that each cable-card pairs with it’s host tuner, so make sure you know which ATI unit is tuner #0 and tuner #1 in MCE because the engineer calls in the cable-card serial number with HQ to activate the cable signal.

After a short wait on the phone with HQ both cable-cards were activated and receiving a signal – I was then able to tune Vista to an HD channel.  During the whole process the most difficult part was downloading the correct EPG (Guide) for my area because there are several for my zone and each has a slightly different channel number line up.  With correct EPG installed and tuners configured I was able to watch and record HDTV, the only issue I had was with some of the channels in the guide not being part of my service package, which caused Vista to pause looking for the signal when I tuned to these channels.

After tipping the Verizon guy and wishing him a good day I preceded to move my XPS to it’s resting place and hook up my XBOX 360. As with my older machine, this process was a breeze, and it didn’t take long before I had HDTV on the large screen.  A tip for those hooking up a similar setup – make sure you have a nice fast network link between your XBOX and MCE, no wireless for instance, otherwise HDTV will hog the bandwidth.

The acid test with my new setup was whether my wife would have any issues when she came home.  Lisa is familiar with Vista MCE so the new faster machine scored some brownie points, and the monthly savings on the cable bill also got me a high five.  So far we’ve been doing good with the new channel line up (lots more channels) and HD content.  One quirk we found with Vista MCE is that it doesn’t automatically choose HD channels when scheduled recordings are set to “any channel” – you have to explicitly choose the HD channel otherwise Vista records from the first SDTV channel (since HD channels are higher numbering in the channel list).  An episode of “Dancing with the Stars” in HD was day and night compared to SD, and once I demonstrated the difference it didn’t take much to convince Lisa to reprogram the list of scheduled recordings.

I’ve noticed that my MCE platform is a little sluggish when recording from two HD channels and playing a recorded show simultaneously, so I would recommend a minimum 4GB RAM and a dual or quad core processor if you like uninterrupted viewing.  I’ll report back as my new toy gets more usage…

Prolific PL-2303 Driver – Vista x64

I purchased a USB to RS232 Serial cable so I could hook up my GPS unit to my laptop and found out that installing the driver on Vista 64 was problematic. 

Disabling driver signing verification with the following command at an elevated prompt, followed by a reboot, enabled me to install the driver.


Download the prolific XP 64 bit driver (installs on Vista 64 after disabling driver signing verification) from:


Vista Slow File Copy – Fix

Are you tired of waiting around for Vista to copy your files, did XP seem so much faster at performing the same job?  You’re not alone in thinking there is a problem with the current RTM version of Vista. 

MS claim that they’ll fix the problem in Vista SP1 (whenever that is) but for now they’re keeping quiet about a hotfix.  Fortunately this hotfix is available to you if you know where to look.  So, I’ve made your life easier and included the locations below (I did not link directly because the site uses an anti-leech mechanism).





I noticed an improvement – transfers to my external USB drive are now 7-10MBS, much better than the 3MBS I was experiencing before the fix.

CDRW/DVDROM Driver or Corrupt under Vista/XP

For a few weeks now I have been puzzling over why my CDRW/DVD ROM driver refuses to load under Windows Vista.  I naively assumed that I needed to find a replacement driver from the manufacturer (IBM in my case), or perhaps my drive was bad. 

After replacing my laptop docking station and the drive unit , I could still not mount the drive, and the device manager gave me the following error:

Windows cannot load the device driver for this hardware. The driver may be corrupted or missing. (Code 39)

As a last ditch effort I Google'd the error and came across the following KB article:


This solved my issue. [:)]

ADATA 8GB Ready Boost Flash Drive

It’s been a busy, busy couple of weeks, and I’ve not been posting, but I had to mention my new purchase of an 8GB USB flash drive from AData.  Yes, you read that right 8GB!!! Wow, I remember when I thought 512MB attached to my key chain was impressive.  This little puppy is 200x speed with a 30mbs read and 20mbs write speed, which means it is perfect for Vista Ready Boost.

I am about to install a new copy of Vista on a new machine shortly, so I thought I’d try booting and installing from my new stick to see how fast it is.

.NET Wrapper for COM Elevation

Microsoft has ramped up the security in their latest operating system – Windows Vista, which means that developers now have to pay more attention to certain security constraints imposed by the operating system when developing applications.   Those of you readers who have read my prior posts on User Access Control in Vista (and the further reading article), may be interested in this small software project I put together. 

The Problem in a Nutshell

Vista requires that ALL users (even administrators) obtain an elevated security token before being permitted to execute protected API calls or accessing protected system resources (the registry for example).  In prior versions of Windows, system administrators were given a privileged security token at login and permitted to perform any task without further confirmation from the interactive user.  Windows Vista now allocates a low security token by default to all users and administrators, and an elevated token is only obtained with credentials (users) or confirmation (administrators) when required.

Elevation request is determined by Vista before any process is loaded – so if a particular process is running non-elevated then access to protected resources and APIs within that process is denied.  This is an important caveat, as it affects the way in which software developers approach application design.

How does one Elevate their Process?

There are several articles on the Internet about developing elevated processes in Vista, so I’ll not dwell on the steps here (my previous articles cover this subject), but essentially elevation request involves decorating .NET assemblies and WIN32 executables with elevation status in the application manifest file (may be embedded or side-by-side).

The COM Elevation Moniker is another method for obtaining elevation.  Using the CEM it is possible to host a COM (Component Object Model) component in elevated state using the dedicated system process – DLLHost.exe.  The Windows Vista SDK provides details on adding the necessary code to your project to elevate an out-of-proc component and making it available to your non-elevated application.

So why use the COM Elevation Moniker?

The CEM permits a non-elevated process to execute protected API calls and access protected resources by calling across process boundaries into an elevated process.  This is how Vista achieves mid-application elevation – look for the shield symbols in forms and property pages, to get an idea of what I am talking about. 

So what’s the big deal?

Development of a CEM component typically involves some work in C++.  Development of COM components in VB and .NET is of course possible, but when it comes down to accessing WIN32 calls to perform COM elevation most of the examples are published in C++.  Developing a managed CEM is possible but involves some work to get it operating correctly.

What about cross boundary communication? – This is the klutz of the problem with authoring CEM components, how to communicate across process boundaries?  COM development answered this problem a long time ago, and the same is true now as it was then – marshalling data and cross process communication is handled by the COM infrastructure.  But what about managed code?  If you’ve managed to solve the problem of invoking a .NET assembly as a COM CEM component, you still have to communicate over .NET interop, which may not be ideal.

Surely someone must have a way to perform elevation in the managed world?

The .NET Wrapper for COM Elevation

I wanted a way for managed developers to attribute their code classes in such away that embedded methods of these classes would request elevation from the Vista operating system before execution of such methods.  So I went about developing a library to encapsulate the complexities of the COM Elevation Moniker.  The end result is available to download from here.

After downloading the ZIP files and unpacking it, the library is packaged as an MSI installer file, which must be installed as an administrator to make use of the library functionality.  The installer also installs some example code to demonstrate use of the library.

How does the Managed Wrapper Library Work?

Essentially, the wrapper library exists as a managed and non-managed server.  The non-managed COM server provides the infrastructure to elevate managed code by hosting it’s own .NET AppDomain.  The managed server assembly is loaded into the elevated AppDomain and executes code developed by the end user of my library.

Communication between the hosted managed server and client code is achieved using an IPC (Inter-Process Communication) channel developed against WCF (Windows Communication Foundation).  The exact specifics of this set up is beyond the scope of this blog post, but involves the use of CodeDOM (dynamic code generation) to create a dynamic messaging system between elevated code and non-elevated client proxy. 

My wrapper library is very much “beta” at present.  I’ve published my library in the hope that I can attract a number of developers to use it and let me know their initial thoughts.  Documentation is sparse, but I am working on publishing a technical manual. It is important to understand that end-users of my library require no knowledge of WCF development, C++, or COM expertise, which makes my library versatile and easy to use by managed developers of different skill-level.

For now, I’ll end this post with a thank-you – for taking an interest in my project.  I look forward to receiving feedback (good and bad), especially any pertaining to security aspects.

Cable Labs Certified Media Center – Requirements

Cable Labs is really putting the screws on OEM users, who like to home-brew their media center PC on the cheap.  To view and record HDTV content on a new Vista MCE PC, the following is a list of required components (thanks Chris Lanier):

1) Vista Home Premium or Ultimate
2) HDCP Video Card
3) Special BIOS w/ OCUR bit set
4) OCUR (CableCARD Reader/Digital Cable Tuner)
5) OCUR Product Key (separate from Windows Product Key)
6) Sign MS agreement
7) Sign CableLabs agreement
8) Video drivers that support COPP, PVP-OPM, CGMS-A
9) Sound card to support exact requirements of CableLabs

Thought: The OCUR product key worries me a little, how much does one want to bet that the product key is pre-installed with a new system and not made available to the end consumer – preventing upgrade/re-pave of the system.

So.. essentially you’re looking at a completely new box – no hope of just adding cable card support to your existing MCE hardware.  At present, very few vendors are providing Cable Labs certified PCs, and I haven’t seen much in the way of certified bare-bones systems either.

According to Engadget, Vidabox are coming out with an all sing and dancing cable-card, Blue Ray, HD DVD unit in March, but it at $4500 it’s not cheap:


Conclusion: it is still early days.  Vista isn’t yet mainstream, and many vendors have yet to come out of the “Cable Labs” woodwork.  I expect to see a change throughout this year as devices come onto the market that support cable card HDTV.

Windows Vista UAC – Further Reading

Then and Now

Microsoft Windows XP™ initially creates all user accounts as local administrators. Administrators have full access to system-wide resources and can execute any privileged operation. Microsoft guidelines suggest that users run day-to-day tasks under a least privileged account (LUA), however many users prefer to operate at the administrator level for the following typical reasons:

  • Home users like administrator rights for similar reasons – applications are installed and available immediately without configuration in separate profile or execution restriction.
  • ActiveX controls are glorified COM controls deployable via the Internet and, like COM, require installation. LUA users typically do not receive installation rights, breaking the use of badly designed Active-X controls (controls requiring access to protected areas of the operating system).
  • Reduced dependency on helpdesk support – if users can install their own applications there is a reduced burden on the helpdesk and support group because there is no need for centralized deployment mechanisms (SMS, Group Policy) and/or system administrators to install applications manually.

Ensuring that users operate day-to-day tasks as LUA mitigates the impact of malware on critical areas of the operating system and installed applications. However, standard users find they cannot perform typical configuration tasks (change the system time zone or install a printer) without administration rights. Moreover, some applications will not operate on Windows XP without using the “run-as” option or logging on as an administrator, usually involving special permission changes for legacy applications and opening up security vulnerabilities. Windows 95 and 98 had no security model, so legacy applications initially developed for these platforms that have migrated with subsequent versions may not consider security constraints.

UAC – Under the Hood

Windows Vista supports two types of user accounts – standard users and administrator users. Standard users behave much like the LUA user on Windows XP where protected resources on the platform are restricted without prompt for administrator credentials. Unlike the least privileged account-type on Windows XP, standard users can make more configuration changes than before. Only when standard users attempt to change a system-wide resource setting does Vista prompt for administrator credentials. Administrator accounts operate in one of two modes – filtered or elevated. Standard users receive a standard “filtered token,” denoting reduced permissions, upon logon, whereas administrators receive two tokens – the “filtered token” and a “full access token.” During normal operation, administrators use the filtered token, when attempting to execute privileged operations the Application Information Service – a system service facilitating the elevation of user privilege – will elevate the administrator to the higher full trust token.

Application Manifest Files and Elevation

How does Vista know when to elevate? Firstly, to dispel a myth that elevation can occur at any time during the execution of a process – incorrect. The AIS determines required elevations on a per-process basis – and how exactly does it do that?

The Application Information Service makes some assumptions about certain applications – applications labeled “setup.exe,” “update.exe,” and MSI files (plus a few other criteria) are installation applications and AIS requests administrator full access credentials or confirmation. All other application types execute using the filtered token, unless an accompanied manifest file stipulates otherwise.

What is a manifest file?

A manifest file is an XML file associated with an executable application (EXE), containing metadata about the application, and may include trust information for elevation. The following is an example manifest file:

<?xml version=”1.0″ encoding=”UTF-8″ standalone=”yes”?>

<assembly xmlns=”urn:schemas-microsoft-com:asm.v1″ manifestVersion=”1.0″>

<trustInfo xmlns=”urn:schemas-microsoft-com:asm.v3″>



<requestedExecutionLevel level=”requireAdministrator” uiAccess=”true”/>




In the above manifest file, the requestedExecutionLevel stipulates the required level and whether elevation is required. Possible levels of execution are:

  • asInvoker – The application executes at the same level as the standard user filtered token
  • highestAvailable – The application executes at the highest level of privilege the user can obtain
  • requireAdministrator – The application requires administrator full access token privilege

.NET EXE assemblies are associated with manifest files when the manifest has the same name as the executable with a “.manifest” extension. For example, the executable test.exe is associated with the manifest file test.exe.manifest. Embedding of the manifest as a resource is also possible.

WIN32 executables also use a manifest to request elevation, although, unlike managed assemblies, WIN32 manifest files must embed in the executable file. The following information details embedding of a WIN32 manifest file:


Default Behavior

The following is the default behavior for Vista installations:

  • UAC is enabled by default, so users may experience compatibility prompts with legacy applications
  • The first account created during Vista installation is an administrator account (with dual tokens), all subsequent created accounts are standard user accounts
  • The built in administrator account is disabled by default
  • Elevation prompts are displayed on the secure desktop

The Shield Icon

Common practice is to display a “shield icon” on all controls that require elevation. The following image shows the date and time properties – the standard user can make configuration changes, however, if they press the “Change Date and Time” button AIS will prompt for administrator credentials or consent.

Wait a minute! How can an application prompt for elevation mid-process if AIS determines the execution level before execution?

Answer – Vista provides a clever mechanism called the “COM Elevation Moniker,” which is a mechanism in which applications can execute code in a WIN32 COM server, out of process executable, with elevated execution privileges. Further documentation on developing for Vista UAC provides more in depth detail on the COM Elevation Moniker.

Windows Vista – User Account Control

Presently, users of the Microsoft Windows™ operating system have had to face several challenges to secure the integrity of the data residing on their computer. Users have had to cope with the vast slew of malware, including viruses, spyware, and root-kits, which typically cause damage to data and/or applications residing on the user’s desktop pc. As quickly as anti-virus vendors release tools to prevent the threat of virus attack or spyware installation, hackers and script-kiddies release newer and smarter versions to work around the safeguards. Microsoft is constantly battling to produce patches and updates to close security vulnerabilities in their operating systems and applications, and now we live in a time where third-party developers are required to embed security aware code in their applications.

Prior to Windows XP Service Pack 2, the Windows platform did little to protect the user from malware. It was up to the initiative of individual users to install anti-virus and anti-spyware applications, and to keep up to date with the Windows patches and updates. Microsoft heard the cries of its customers, and in 2004 announced the release of Windows XP Service Pack 2. SP2 brought a number of security enhancements to the Windows platform in the flavor of enhanced firewall, Internet Explorer popup blocker, automatic updates, and security warnings about the execution of ActiveX controls from the web.

The existence of Windows XP SP2 was not enough to protect the end-user; SP2 went further to alert the user to suspicious activity from malware, but did not protect the users from their own mistakes. For example, many users fail to acknowledge the importance of the message contained in security prompts and blindly ignore the warnings to accomplish their task. Third party applications and web browsers not taking advantage of SP2 security constraints are still able to download malware from the Internet without detection. In 2005, Song BMG Music Entertainment installed root kit software on their audio CDs to circumvent piracy and to provide Sony with music listener statistics – users running Windows full administrator privileged accounts were susceptible to the root-kit from simply inserting these audio CDs in their CDROM tray.

Most of aforementioned problems with malware have one thing in common – they all operate on the assumption that the interactive user is running with full administrator privileges. By default, Windows XP installs a default “Administrator” account, and most users perform their day-to-day tasks under this account. Use of administrator accounts alleviates execution problems with poorly written applications – software that unnecessarily uses privileged areas of the operating system, provides the convenience of on the spot installation of applications without switching accounts (and sometimes a reboot), and gives the user total control over the operating system. The first step in the direction of securing the Windows platform is to restrict the everyday user to least user privilege – LUA.

Converting to LUA is only half of the battle – many applications (non-XP certified) will not execute properly without administrative privileges. Services and third-party background processes still act as security vulnerability because they execute in higher privileged contexts, and can provide a security hole for hackers to exploit. Microsoft has stepped up to the plate and has provided a potential solution to lessen the security concerns from users of its Windows platform – enter Windows Vista and User Access Control.

Windows Vista – Providing a more secure environment

Security is not a process – it is a mentality, and must be considered from the initial development of software applications, though to user execution. Developers writing software atop the .NET Framework can take advantage of Code Access Security – restrictions applied to code elements for different execution contexts – to protect the user at the application level, and now Microsoft have taken the next step and added enhanced security restriction at the operating system level in the form of User Access Control on the Vista platform.

What is UAC?

 Regardless of whether a particular user has administrator rights, all users logging on to the Vista platform receive a “filtered token” at login time, which prevents access to security sensitive operations. When the time comes to execute a privileged operation, the user must elevate to a higher level of operation.

What does this mean to the end user?

Users without administration rights attempting to execute a privileged operation observe a request for administration credentials. This is akin to the “run-as” operation on Windows XP/2003 where a user can execute a process as another user, except UAC enables elevation for particular privileged operations, not just the execution of an application.

Microsoft refers to this process of elevation request as “over-the-shoulder” credentials.

Users with administration rights also experience the effects of UAC. Since all users, administrators included, login with a filtered token UAC will prompt administrators with a consent dialog before promoting to an elevated token for secure execution.

It is worth noting that Windows determines elevation requirements before a process is executed and if elevation is required the entire process is elevated to the privileged level upon successful OTS credential or administrator consent.

UAC consists of more than just elevation. Effectively, UAC does away with the “Power Users” group, which provided users with administrative privileges to perform basic system tasks while running applications. UAC now enables standard users to perform standard configuration tasks and Windows will prompt for elevation for specific privileged operations.

UAC provides a short-term solution for legacy applications operating in “XP compatibility” mode with a virtual file system and registry. When a legacy application requires write permission to a protected area of the file system or registry, the changes affect a virtual copy allowing the legacy application to function without hurting the operating system. Microsoft intends this solution as short-term as developers begin to author UAC aware applications.

Windows prompts for elevation via a secure desktop to prevent malicious applications from tricking users into requesting elevation without their knowledge – whilst the consent/credential dialog is visible; the user is operating within a secure desktop, preventing any software applications from interacting with the user interface.