BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Silverlight's New Security Model

Silverlight's New Security Model

The CLR has always had a comprehensive security model called Code Access Security (CAS). Unfortunately, the model is also very complex and, in the minds of most developers, simply overkill.

Silverlight replaces CAS with a simplified security model that is limited to yes/no decision based on who wrote the code. Code signing and manually edited security policies should become a thing of the past for CLR developers working under Silverlight.

According to Justin Van Patten

The new Silverlight security model consists of three access levels: Transparent, SafeCritical, and Critical. Transparent code has the least privilege (partial trust) and SafeCritical and Critical have the most privilege (full trust). Only assemblies trusted by Microsoft may elevate to full trust. These assemblies, called "Platform code", must be signed with the Microsoft public key and reside in a trusted location. All other code targeting Silverlight is referred to as "User code", and cannot elevate to full trust.

User code is only able to access Transparent and SafeCritical functionality. If User code tries to access a Critical API, a MethodAccessException is thrown.

This functionality will be available in Silverlight 1.1, which is currently targeting both Windows and OS X/x86. Already there are complaints that this version, unlike Silverlight 1.0, does not run on the older OS X/PowerPC.

Silverlight 1.1 Alpha is available for download. 

Rate this Article

Adoption
Style

BT