This documentation is archived and is not being maintained.

ContentUser Class

Represents a user or user-group for granting access to rights managed content.

Namespace:  System.Security.RightsManagement
Assembly:  WindowsBase (in WindowsBase.dll)

public class ContentUser
You cannot directly create an instance of this class in XAML.

As with other System.Security.RightsManagement types, ContentUser is only usable in full trust applications.

The following example shows how to use Owner property to assign a variable of this type. For the full sample, see Rights Managed Package Publish Sample.

WriteStatus("   Reading '" + xrmlFilename + "' permissions.");
    StreamReader sr = File.OpenText(xrmlFile);
    xrmlString = sr.ReadToEnd();
catch (Exception ex)
    MessageBox.Show("ERROR: '"+xrmlFilename+"' open failed.\n"+
        "Exception: " + ex.Message, "XrML File Error",
        MessageBoxButton.OK, MessageBoxImage.Error);
    return false;

WriteStatus("   Building UnsignedPublishLicense");
WriteStatus("       from '" + xrmlFilename + "'.");
UnsignedPublishLicense unsignedLicense =
    new UnsignedPublishLicense(xrmlString);
ContentUser author = unsignedLicense.Owner;


Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0