SecureEnvironment 클래스
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
사용자 활성화, 라이선스 바인딩 및 기타 권한 관리 작업에 대한 보안 클라이언트 세션을 나타냅니다.
public ref class SecureEnvironment : IDisposable
[System.Security.SecurityCritical(System.Security.SecurityCriticalScope.Everything)]
public class SecureEnvironment : IDisposable
public class SecureEnvironment : IDisposable
[<System.Security.SecurityCritical(System.Security.SecurityCriticalScope.Everything)>]
type SecureEnvironment = class
interface IDisposable
type SecureEnvironment = class
interface IDisposable
Public Class SecureEnvironment
Implements IDisposable
- 상속
-
SecureEnvironment
- 특성
- 구현
예제
다음 예제에서는 클래스의 사용을 보여 있습니다.SecureEnvironment
string applicationManifest = "<manifest></manifest>";
if (File.Exists("rpc.xml"))
{
StreamReader manifestReader = File.OpenText("rpc.xml");
applicationManifest = manifestReader.ReadToEnd();
}
if (_secureEnv == null)
{
if (SecureEnvironment.IsUserActivated(new ContentUser(
_currentUserId, AuthenticationType.Windows)))
{
_secureEnv = SecureEnvironment.Create(
applicationManifest, new ContentUser(
_currentUserId, AuthenticationType.Windows));
}
else
{
_secureEnv = SecureEnvironment.Create(
applicationManifest,
AuthenticationType.Windows,
UserActivationMode.Permanent);
}
}
Dim applicationManifest As String = "<manifest></manifest>"
If File.Exists("rpc.xml") Then
Dim manifestReader As StreamReader = File.OpenText("rpc.xml")
applicationManifest = manifestReader.ReadToEnd()
End If
If _secureEnv Is Nothing Then
If SecureEnvironment.IsUserActivated(New ContentUser(_currentUserId, AuthenticationType.Windows)) Then
_secureEnv = SecureEnvironment.Create(applicationManifest, New ContentUser(_currentUserId, AuthenticationType.Windows))
Else
_secureEnv = SecureEnvironment.Create(applicationManifest, AuthenticationType.Windows, UserActivationMode.Permanent)
End If
End If
설명
다른 System.Security.RightsManagement 형식과 마찬가지로 완전 SecureEnvironment 신뢰 애플리케이션에서만 사용할 수 있습니다.
속성
| Name | Description |
|---|---|
| ApplicationManifest |
ApplicationManifest 생성될 때 지정된 값을 SecureEnvironment 가져옵니다. |
| User |
만들 때 SecureEnvironment 지정된 사용자 또는 사용자 그룹을 가져옵니다. |
메서드
| Name | Description |
|---|---|
| Create(String, AuthenticationType, UserActivationMode) |
애플리케이션 권한 매니페스트AuthenticationTypeUserActivationMode를 지정하여 보안 클라이언트 세션을 만듭니다. |
| Create(String, ContentUser) |
지정된 권한 매니페스트를 사용하여 지정된 사용자에 대한 보안 클라이언트 세션을 만듭니다. |
| Dispose() |
에서 사용하는 모든 리소스를 SecureEnvironment해제합니다. |
| Dispose(Boolean) |
관리되지 않는 리소스를 SecureEnvironment 해제하고 관리되는 리소스를 선택적으로 해제합니다. |
| Equals(Object) |
지정된 개체가 현재 개체와 같은지 여부를 확인합니다. (다음에서 상속됨 Object) |
| GetActivatedUsers() |
활성화된 사용자 목록을 반환합니다. |
| GetHashCode() |
기본 해시 함수로 사용됩니다. (다음에서 상속됨 Object) |
| GetType() |
현재 인스턴스의 Type 가져옵니다. (다음에서 상속됨 Object) |
| IsUserActivated(ContentUser) |
권한 관리 콘텐츠에 액세스하기 위해 지정된 사용자가 활성화되었는지 여부를 나타냅니다. |
| MemberwiseClone() |
현재 Object단순 복사본을 만듭니다. (다음에서 상속됨 Object) |
| RemoveActivatedUser(ContentUser) |
지정된 사용자에 대한 라이선스 활성화를 제거합니다. |
| ToString() |
현재 개체를 나타내는 문자열을 반환합니다. (다음에서 상속됨 Object) |