Aracılığıyla paylaş


DnsPermissionAttribute Sınıf

Tanım

Dikkat

Code Access Security is not supported or honored by the runtime.

Etki Alanı Adı Sunucularından bilgi isteme iznini belirtir.

public ref class DnsPermissionAttribute sealed : System::Security::Permissions::CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
[System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public sealed class DnsPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
[System.Serializable]
public sealed class DnsPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
public sealed class DnsPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
[<System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
type DnsPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
[<System.Serializable>]
type DnsPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
type DnsPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
Public NotInheritable Class DnsPermissionAttribute
Inherits CodeAccessSecurityAttribute
Devralma
Öznitelikler

Açıklamalar

Dikkat

Kod Erişim Güvenliği (CAS), .NET Framework ve .NET tüm sürümlerinde kullanım dışı bırakılmıştır. .NET'nin son sürümleri CAS ek açıklamalarını dikkate almaz ve CAS ile ilgili API'ler kullanılıyorsa hata üretir. Geliştiriciler, güvenlik görevlerini yerine getirmek için alternatif yöntemler aramalıdır.

tarafından DnsPermissionAttribute bildirilen güvenlik bilgileri, öğesinin uygulandığı sınıf olan öznitelik hedefinin meta verilerinde DnsPermissionAttribute depolanır. Sistem daha sonra bu bilgilere çalışma zamanında erişir. SecurityAction Oluşturucuya geçirilen, izin verilebilen DNS hedeflerini belirler.

Bu güvenlik öznitelikleri yalnızca Bildirimli Güvenlik için kullanılır. Kesinlik Temelli Güvenlik için ilgili DnsPermission sınıfı kullanın.

Güvenlik erişimi tamamen kısıtlanmış veya tamamen kısıtlanmamıştır. Unrestricted Özelliğini true erişim izni vermek veya false erişim sağlamak için olarak ayarlayın. Bu özelliği adlandırılmış parametre olarak ayarlayın.

Öznitelikleri kullanma hakkında daha fazla bilgi için bkz . Öznitelikler.

Oluşturucular

Name Description
DnsPermissionAttribute(SecurityAction)
Geçersiz.

Belirtilen DnsPermissionAttribute değerle sınıfının yeni bir örneğini SecurityAction başlatır.

Özellikler

Name Description
Action
Geçersiz.

Bir güvenlik eylemi alır veya ayarlar.

(Devralındığı yer: SecurityAttribute)
TypeId
Geçersiz.

Türetilmiş bir sınıfta uygulandığında, bu Attributeiçin benzersiz bir tanımlayıcı alır.

(Devralındığı yer: Attribute)
Unrestricted
Geçersiz.

Özniteliği tarafından korunan kaynağa yönelik tam (kısıtlanmamış) iznin bildirilip bildirilmediğini belirten bir değer alır veya ayarlar.

(Devralındığı yer: SecurityAttribute)

Yöntemler

Name Description
CreatePermission()
Geçersiz.

Sınıfının yeni bir örneğini DnsPermission oluşturur ve döndürür.

Equals(Object)
Geçersiz.

Bu örneğin belirtilen bir nesneye eşit olup olmadığını gösteren bir değer döndürür.

(Devralındığı yer: Attribute)
GetHashCode()
Geçersiz.

Bu örneğin karma kodunu döndürür.

(Devralındığı yer: Attribute)
GetType()
Geçersiz.

Geçerli örneğin Type alır.

(Devralındığı yer: Object)
IsDefaultAttribute()
Geçersiz.

Türetilmiş bir sınıfta geçersiz kılındığında, bu örneğin değerinin türetilmiş sınıf için varsayılan değer olup olmadığını gösterir.

(Devralındığı yer: Attribute)
Match(Object)
Geçersiz.

Türetilmiş bir sınıfta geçersiz kılındığında, bu örneğin belirtilen bir nesneye eşit olup olmadığını gösteren bir değer döndürür.

(Devralındığı yer: Attribute)
MemberwiseClone()
Geçersiz.

Geçerli Objectbasit bir kopyasını oluşturur.

(Devralındığı yer: Object)
ToString()
Geçersiz.

Geçerli nesneyi temsil eden bir dize döndürür.

(Devralındığı yer: Object)

Belirtik Arabirim Kullanımları

Name Description
_Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)
Geçersiz.

Bir ad kümesini karşılık gelen bir dağıtma tanımlayıcısı kümesine eşler.

(Devralındığı yer: Attribute)
_Attribute.GetTypeInfo(UInt32, UInt32, IntPtr)
Geçersiz.

Bir arabirimin tür bilgilerini almak için kullanılabilecek bir nesnenin tür bilgilerini alır.

(Devralındığı yer: Attribute)
_Attribute.GetTypeInfoCount(UInt32)
Geçersiz.

Bir nesnenin sağladığı tür bilgisi arabirimlerinin sayısını alır (0 ya da 1).

(Devralındığı yer: Attribute)
_Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)
Geçersiz.

Bir nesne tarafından kullanıma sunulan özelliklere ve yöntemlere erişim sağlar.

(Devralındığı yer: Attribute)

Şunlara uygulanır

Ayrıca bkz.