Title: Windows Vista
1Windows Vista
- Platform for the next generation of software
2What is Windows Vista?Next Generation of Windows
OS
Confident Your PC just works safe,
reliable, and low-cost to manage
Clear Organize information effectively, and
focus on business
Connected Connect with people,
information and devices anytime, anywhere
3Windows VistaIs there anything left really?
WS-Management
Aero
User Account Control
Restart Manager
Sync Center
Windows SideBar
Network Access Protection
Windows Feedback Services
Monad
Ink Analysis
Windows Presentation Foundation
Ad-hoc Meeting Networks
Secure Startup
Reading Pane
Windows Imaging Format
Protected Mode IE
Presentation Settings
Parental controls
Windows Communication Foundation
High Resolution/High DPI
Cancelable I/O
Registry/File System Virtualization
Network Location Awareness
Stacks
MMC 3.0
People Near Me
Quick Search
Single binary
Shell Property System
Power Management
Windows Service Hardening
Live Icons
Crypto Next Generation
SuperFetch
Glass
Peer Name Resolution Protocol
User Experience
IPv6
Preview Pane
Windows Vista Display Driver Model
Transactional Registry
Winlogon Rearchitecture
Windows Resource Protection
Search Folders
Taskbar Thumbnails
Desktop Window Manager
Split Tokens
User Mode Driver Framework
Memory Diagnostics
Windows Workflow Foundation
Function Discovery API
XAML
Startup Repair Toolkit
Windows Filtering Platform
Flip3D
Windows Installer 4.0
Credential Providers
Open Package Specification
Windows Defender
New Open/Save Dialogs
InfoCard
RSS Platform
Segoe UI Font
Transactional File System
Mandatory Integrity Control
New Explorers
Resource Exhaustion Diagnostics
Eventing and Instrumentation
Windows Sideshow
Wizard Framework
XML Paper Specification
Confident Clear Connected
Windows Disk Diagnostics
UI Privilege Isolation
4What is (UX)?
5Delivering on Fundamentals
- Protected Modein IE7
- User Account Protection
- Full Volume Encryption
- Apps and Files load faster
- Fast Startup
- Sleep state
- Component Based Setup and Deployment
- Windows Imaging Format (WIM)
- Customer Feedback
- Hardware Monitoring
- Goal is 50 fewer Reboots
- Service Restarts
6AERO is the User Interface for Windows Vista
applications
Authentic Energetic Reflective Open
Approachable
7The Windows Vista User Interface
8The Windows Vista User InterfaceDeveloper
Opportunities
- Windows Vista User Interface Guidelines
- High-resolution icons
- Common controls (comctl32.dll v6)
- CommandLinks
- Button-styled control for important tasks
- TaskDialog
- Error messages and prompts
- New Wizard Framework
- Use Vista themes in Wizards and dialogs
9New controls and design
10Visualize, Organize SearchDeveloper
Opportunities
- Enable a simpler data management experience in
your application - OLE DB Provider for Windows Search
- Read write properties (Property Provider API)
- New Common File Dialogs for opening/saving files
- Make your custom file formats part of the
experience - Metadata support (read/write indexing)
Property Handlers - Full-text indexing IFilter
- Live Icons Thumbnail Providers
- Rich preview in Reading Pane Preview Handlers
11Resources
- Windows Vista User Interface Guidelines
msdn.microsoft.com/windowsvista/experience - MSDN dev center msdn.microsoft.com/ui/
- Windows Vista Development Forums
forums.microsoft.com/msdn/
12User Account Control
- By default, all interactive processes run as
standard user - User consent is required to run a process with
elevated privileges - Security shield identifies operations that
require privilege elevation
13How will this affect my apps?
- Registry and File System Virtualization redirects
some write operations to per-user virtual stores - userprofile\AppData\Local\VirtualStore
- HKEY_CURRENT_USER\Software\Classes\VirtualStore
- Virtualization is a Windows Vista compatibly
feature for existing applications. - New and updated applications should not rely on
Virtualization. - Windows Vista applications should provide a
manifest and specify the appropriate
requestedExecutionLevel element. (Note this is a
logo requirement)
14Why not just turn off the UAC?
- Why not just run Windows 98?
- Educate yourself and your company!
- We will continue to make this sexier
- Protect your users and customers!
15User Account Control and virtualization
16Steps for Ensuring UAC Compatibility
- Determine if your app runs as a standard user
- Identify operations that require privilege
elevation - Address identified operations, where possible
- Mark your application as UAC-aware
- Address necessary operations that require
privilege elevation
17Identifying Privileged Operations
- Use the Standard User Analyzer tool
- Identifies operations that will require privilege
elevation - Can be run on Windows XP
- Will soon be released to the Microsoft.com
download center - Configure machine-wide settings during
installation, rather than on first-run - Change machine-wide setting to per-user, where
appropriate
18Using the Standard User Analyzer Tool
19Marking Your App as UAC-Aware
- Provide a manifest (XML file)
- A manifest is an XML file, named
.exe.manifest - Set the requestedExecutionLevel element
(typically set to asInvoker) - This turns off Virtualization for your app
- Manifests can be external or embedded
- External manifests are located in the same folder
as the executable - Embedded manifests are included as a native Win32
resource
20Creating a Manifest
- Add an XML file item to the project
- Rename it .exe.manifest
xmlns"urnschemas-microsoft-comasmv.v1
manifestVersion"1.0"
version"1.0.0.0" processorArchitecture"X86"
name"AppName" type"win32" /
App Description
"
/
21Embedding a Manifest in an Assembly
- Add a resource file to the project (Text File
item) and rename it .rc - Add pre-build event to compile resource
- \rc.exe (ProjectDir)(ProjectName)
.rc - Add Win32 resources to assembly
define RT_MANIFEST 24 define APP_MANIFEST
1 APP_MANIFEST RT_MANIFEST .exe.manifest
appName.resn32Resource
22Current Issues with Visual Studio 2005
- Schema/Intellisense error when editing project
file - Symptoms
- Erroneous schema error displayed for
element - Incorrect suggestion from Intellisense to use
- Workaround you can safely ignore these errors
- The Visual Studio debugger does not elevate
processes - Symptoms
- You hit F5 to debug an .exe that requires
elevation and you dont get an elevation prompt - The process was not elevated, so calls to
privileged operations will fail - Workarounds
- Launch the solution as elevated (right click and
select Run as administrator) - Use a remote debugger
23Addressing Privileged Operations
- Consider other requestedExecutionLevel values
- requireAdministrator or highestAvailable
- Some applications may require elevated privileges
for only a subset of their features - Privilege elevation cannot occur in-process, you
must launch a separate process - Requires re-factoring into separate partitions
- UI elements that invoke privileged operations
should be decorated with the security shield icon
(logo requirement) - Privileged partitions must be launched with
either ShellExecute or the COM elevation moniker
24Launching with ShellExecute
- Example
- Note that the CreateProcess API does not elevate
Process proc new Process() proc.StartInfo
new ProcessStartInfo() proc.StartInfo.CreateN
oWindow true proc.StartInfo.UseShellExecute
true proc.StartInfo.FileName
"PrivilegedExe.exe" proc.EnableRaisingEvents
true proc.Exited new EventHandler(OnExeExi
ted) proc.Start()
25Making an App UAC-Aware
26Down-level Considerations
- User Account Control is not supported on previous
version of Windows - What happens if you run a UAC-Compatible app on
Windows XP? - requestedExecutionLevel element is ignored on
previous versions of Windows - All processes run with the users highest
privileges - For standard users, calls to privileged
operations will fail - Strategies for ensuring partitioned applications
continue to work correctly on XP - For apps that require elevation, test for
required privileges during process start-up (e.g.
IsUserAdmin) and exit gracefully if not found
27Resources
- Best Practices and Guidelines for Applications in
a Least Privileged Environment http//msdn.microso
ft.com/library/en-us/dnlong/html/AccProtVista.asp?
frametrue - Standard User Analyzer Toolhttp//download.micros
oft.com - COM Elevation Moniker Documentation
- http//msdn.microsoft.com/library/en-us/com/html/
1595ebb8-65af-4609-b3e7-a21209e64391.asp - UAC Team Bloghttp//blogs.msdn.com/uac
28How do I ensure that my application will work
under User Account Control?
If your app runs correctly as a Standard User
No action needed ?
If your app doesnt run as a Standard User
Remove any operations that require elevated
privileges Set machine-wide settings during
installation
If your app targets administrators
Include manifest with new attributes to request
approval
If only certain operations require elevated
privileges
Factor into separate processes Identify
administrative operations with a shield icon
Developer Best Practices and Guidelines for
Applications in a Least Privileged Environment
http//msdn.microsoft.com/library/default.asp?url
/library/en-us/dnlong/html/AccProtVista.asp?frame
true
29Johan.Lindfors_at_microsoft.comhttp//blogs.msdn.com
/johanl