HttpCookiesSection 클래스

정의

웹 애플리케이션에 사용되는 쿠키의 속성을 구성합니다.

이 API는 제품 인프라를 지원하며 코드에서 직접 사용되지 않습니다.

public ref class HttpCookiesSection sealed : System::Configuration::ConfigurationSection
public sealed class HttpCookiesSection : System.Configuration.ConfigurationSection
type HttpCookiesSection = class
    inherit ConfigurationSection
Public NotInheritable Class HttpCookiesSection
Inherits ConfigurationSection
상속

예제

다음 코드 예제에서는 가져오는 방법을 보여 줍니다는 HttpCookiesSection 기존 웹 애플리케이션의 구성 파일에서 개체입니다.


  // Get the Web application configuration.
  System.Configuration.Configuration webConfig =
  WebConfigurationManager.OpenWebConfiguration("/aspnetTest");

  // Get the section.
  string configPath = "system.web/httpCookies";
  System.Web.Configuration.HttpCookiesSection httpCookiesSection =
  (System.Web.Configuration.HttpCookiesSection)webConfig.GetSection(
  configPath);

 ' Get the Web application configuration.
 Dim webConfig _
 As System.Configuration.Configuration = _
 WebConfigurationManager.OpenWebConfiguration("/aspnetTest")

 ' Get the section.
 Dim configPath As String _
 = "system.web/httpCookies"

 Dim httpCookiesSection _
 As System.Web.Configuration.HttpCookiesSection = _
 CType(webConfig.GetSection(configPath), _
 System.Web.Configuration.HttpCookiesSection)

설명

HttpCookiesSection 클래스를 사용하면 구성 파일의 httpCookies 섹션을 프로그래밍 방식으로 액세스하고 수정할 수 있습니다.

쿠키를 발급 하는 코드를 재정의 하지 않는 한 애플리케이션에 발급 된 모든 쿠키에 기본적으로 적용 되는 설정을 정의 합니다.

한 가지 목표는 httpCookies 요소를 사용 하도록 지원 하려면 HttpOnly 쿠키입니다. HttpOnly 쿠키 (사용 하 여 쿠키를 HttpOnly 특성) 사이트 간 스크립팅의 위험을 완화 하는 데 Internet Explorer 6에서 도입 되었습니다. HttpOnly 특성 쿠키를 클라이언트 쪽 스크립트를 통해 액세스 하지 못하게 방지 합니다. 에 포함 된 모든 정보는 HttpOnly 쿠키는 해커가 악성 웹 사이트에 공개 될 가능성이 적습니다. 자세한 내용은 MSDN (msdn.microsoft.com) "HttpOnly."에 대 한 검색

참고

합니다 HttpCookiesSection 읽고에서 섹션 속성에 따라 구성 파일의 관련 섹션 정보를 쓸 수 있습니다 AllowDefinition 값인 Everywhere합니다.

생성자

HttpCookiesSection()

이 API는 제품 인프라를 지원하며 코드에서 직접 사용되지 않습니다.

HttpCookiesSection 클래스의 새 인스턴스를 초기화합니다.

속성

CurrentConfiguration

현재 Configuration 인스턴스가 속해 있는 구성 계층 구조를 나타내는 최상위 ConfigurationElement 인스턴스에 대한 참조를 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
Domain

이 API는 제품 인프라를 지원하며 코드에서 직접 사용되지 않습니다.

쿠키 도메인 이름을 가져오거나 설정합니다.

ElementInformation

ElementInformation 개체의 사용자 지정할 수 없는 정보와 기능을 포함하는 ConfigurationElement 개체를 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
ElementProperty

ConfigurationElementProperty 개체 자체를 나타내는 ConfigurationElement 개체를 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
EvaluationContext

ContextInformation 개체의 ConfigurationElement 개체를 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
HasContext

CurrentConfiguration 속성이 null인지 여부를 나타내는 값을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
HttpOnlyCookies

이 API는 제품 인프라를 지원하며 코드에서 직접 사용되지 않습니다.

브라우저의 HttpOnly 쿠키에 대한 지원 활성화 여부를 나타내는 값을 가져오거나 설정합니다.

Item[ConfigurationProperty]

이 구성 요소의 속성이나 특성을 가져오거나 설정합니다.

(다음에서 상속됨 ConfigurationElement)
Item[String]

이 구성 요소의 속성, 특성 또는 자식 요소를 가져오거나 설정합니다.

(다음에서 상속됨 ConfigurationElement)
LockAllAttributesExcept

잠긴 특성의 컬렉션을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
LockAllElementsExcept

잠긴 요소의 컬렉션을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
LockAttributes

잠긴 특성의 컬렉션을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
LockElements

잠긴 요소의 컬렉션을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
LockItem

요소가 잠겨 있는지 여부를 나타내는 값을 가져오거나 설정합니다.

(다음에서 상속됨 ConfigurationElement)
Properties

속성 컬렉션을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
RequireSSL

이 API는 제품 인프라를 지원하며 코드에서 직접 사용되지 않습니다.

SSL(Secure Sockets Layer) 통신이 필요한지 여부를 나타내는 값을 가져오거나 설정합니다.

SameSite

쿠키의 SameSite 특성에 대한 값을 가져오거나 설정합니다.

SectionInformation

사용자가 지정할 수 없는 SectionInformation 개체의 정보와 기능을 포함하는 ConfigurationSection 개체를 가져옵니다.

(다음에서 상속됨 ConfigurationSection)

메서드

DeserializeElement(XmlReader, Boolean)

구성 파일에서 XML을 읽습니다.

(다음에서 상속됨 ConfigurationElement)
DeserializeSection(XmlReader)

구성 파일에서 XML을 읽습니다.

(다음에서 상속됨 ConfigurationSection)
Equals(Object)

현재 ConfigurationElement 인스턴스를 지정된 개체와 비교합니다.

(다음에서 상속됨 ConfigurationElement)
GetHashCode()

현재 ConfigurationElement 인스턴스를 나타내는 고유 값을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
GetRuntimeObject()

파생 클래스에서 재정의될 때 사용자 지정 개체를 반환합니다.

(다음에서 상속됨 ConfigurationSection)
GetTransformedAssemblyString(String)

지정된 어셈블리 이름의 변환된 버전을 반환합니다.

(다음에서 상속됨 ConfigurationElement)
GetTransformedTypeString(String)

지정된 형식 이름의 변환된 버전을 반환합니다.

(다음에서 상속됨 ConfigurationElement)
GetType()

현재 인스턴스의 Type을 가져옵니다.

(다음에서 상속됨 Object)
Init()

ConfigurationElement 개체를 초기 상태로 설정합니다.

(다음에서 상속됨 ConfigurationElement)
InitializeDefault()

ConfigurationElement 개체 값의 기본 집합을 초기화하는 데 사용됩니다.

(다음에서 상속됨 ConfigurationElement)
IsModified()

이 구성 요소가 파생 클래스에서 구현되었을 때 마지막으로 저장되거나 로드된 이후 수정되었는지 여부를 나타냅니다.

(다음에서 상속됨 ConfigurationSection)
IsReadOnly()

ConfigurationElement 개체가 읽기 전용인지 여부를 나타내는 값을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
ListErrors(IList)

ConfigurationElement 개체와 모든 하위 요소의 잘못된 속성 오류를 전달된 목록에 추가합니다.

(다음에서 상속됨 ConfigurationElement)
MemberwiseClone()

현재 Object의 단순 복사본을 만듭니다.

(다음에서 상속됨 Object)
OnDeserializeUnrecognizedAttribute(String, String)

역직렬화하는 동안 알 수 없는 특성을 발견했는지 여부를 나타내는 값을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
OnDeserializeUnrecognizedElement(String, XmlReader)

역직렬화하는 동안 알 수 없는 요소를 발견했는지 여부를 나타내는 값을 가져옵니다.

(다음에서 상속됨 ConfigurationElement)
OnRequiredPropertyNotFound(String)

필수 속성이 없으면 예외를 throw합니다.

(다음에서 상속됨 ConfigurationElement)
PostDeserialize()

deserialization 후에 호출됩니다.

(다음에서 상속됨 ConfigurationElement)
PreSerialize(XmlWriter)

serialization 전에 호출됩니다.

(다음에서 상속됨 ConfigurationElement)
Reset(ConfigurationElement)

잠금 및 속성 컬렉션을 비롯하여 ConfigurationElement 개체의 내부 상태를 다시 설정합니다.

(다음에서 상속됨 ConfigurationElement)
ResetModified()

파생 클래스에서 구현되는 경우 IsModified() 메서드의 값을 false로 다시 설정합니다.

(다음에서 상속됨 ConfigurationSection)
SerializeElement(XmlWriter, Boolean)

파생 클래스에서 구현될 때 구성 요소의 내용을 구성 파일에 씁니다.

(다음에서 상속됨 ConfigurationElement)
SerializeSection(ConfigurationElement, String, ConfigurationSaveMode)

ConfigurationSection 개체의 병합되지 않은 뷰가 들어 있는 XML 문자열을 파일에 쓸 단일 섹션으로 만듭니다.

(다음에서 상속됨 ConfigurationSection)
SerializeToXmlElement(XmlWriter, String)

파생 클래스에서 구현될 때 구성 요소의 외부 태그를 구성 파일에 씁니다.

(다음에서 상속됨 ConfigurationElement)
SetPropertyValue(ConfigurationProperty, Object, Boolean)

속성을 지정된 값으로 설정합니다.

(다음에서 상속됨 ConfigurationElement)
SetReadOnly()

IsReadOnly() 개체와 모든 하위 요소에 대한 ConfigurationElement 속성을 설정합니다.

(다음에서 상속됨 ConfigurationElement)
ShouldSerializeElementInTargetVersion(ConfigurationElement, String, FrameworkName)

구성 개체 계층이 .NET Framework 지정된 대상 버전에 대해 직렬화될 때 지정된 요소를 serialize해야 하는지 여부를 나타냅니다.

(다음에서 상속됨 ConfigurationSection)
ShouldSerializePropertyInTargetVersion(ConfigurationProperty, String, FrameworkName, ConfigurationElement)

구성 개체 계층이 .NET Framework 지정된 대상 버전에 대해 serialize될 때 지정된 속성을 serialize해야 하는지 여부를 나타냅니다.

(다음에서 상속됨 ConfigurationSection)
ShouldSerializeSectionInTargetVersion(FrameworkName)

구성 개체 계층 구조가 지정된 대상 버전의 .NET Framework 직렬화될 때 현재 ConfigurationSection 인스턴스를 serialize해야 하는지 여부를 나타냅니다.

(다음에서 상속됨 ConfigurationSection)
ToString()

현재 개체를 나타내는 문자열을 반환합니다.

(다음에서 상속됨 Object)
Unmerge(ConfigurationElement, ConfigurationElement, ConfigurationSaveMode)

ConfigurationElement 개체를 수정하여 저장되지 않아야 하는 값을 모두 제거합니다.

(다음에서 상속됨 ConfigurationElement)

적용 대상

추가 정보