Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
4/8/2010

This code sample is named SecurityViewer. It demonstrates how work with security policies and certificates. The application displays all of the Security Policies, and all of the certificates installed on a mobile device. It also displays which of the Standard Security Configurationsthe device is currently in.

Feature Area

Relevant APIs

Usage

To run the code sample
  1. Navigate to the solution file (*.sln), and double-click it. By default, the solution files are copied to the following folders:

    C:\Program Files\Windows Mobile 6.5.3 DTK\Samples\Common\CS\SecurityViewer

    Microsoft Visual Studio launches and loads the solution.

  2. Build the solution (Ctrl+Shift+B).

  3. Deploy the solution (F5).

If you have not installed the SamplePrivDevelopercertificate, you will need to so that your Dll and CAB projects are signed correctly.

To install the certificate from the windows desktop
  1. Click Start> Run.

  2. Type the path-name to SamplePrivDeveloper.pfxcertificate, and click OK. By default, this is located in the following folder:

    C:\Program Files\Windows Mobile 6.5.3 DTK\Tools\Security\SDK Development Certificates

  3. Double-click the SamplePrivDeveloper.pfxcertificate icon. The Certificate Import Wizard appears.

  4. Click Next. The certificate path-name is filled-in.

  5. Click Next.

  6. Click Next(you do not need a password).

  7. Click Next. Accept the default options; automatically select the certificate store based on certificate type.

  8. 9. Click Finish.

See Mobile device Security Modelfor further details on how to install the SDK certificates onto the mobile device, and how to use the privileged SDK certificate to sign this application.

Remarks

This application must run as Privileged, which means that it must be signed with a security certificate that is in the mobile device's privileged certificate store.

See Certificate Management in Windows Mobile Devicesfor details on how to install the SDK certificates onto the device, and how to use the privileged SDK certificate to sign this application.

Development Environments

SDK:Windows Mobile Professional SDK and Windows Mobile Standard SDK

Development Environment:Visual Studio 2005 or 2008.

ActiveSync:Version 4.5.

See Also