### Enumeration

# Soup CookieJarAcceptPolicy

since: 3.0

#### Declaration

    enum Soup.CookieJarAcceptPolicy

#### Description [src]

The policy for accepting or rejecting cookies returned in responses.

Available since: 3.0

#### Members

`SOUP_COOKIE_JAR_ACCEPT_ALWAYS`

  Accept all cookies unconditionally.

  - Value: `0`
  - Nickname: `always`
  - Available since: 3.0
`SOUP_COOKIE_JAR_ACCEPT_NEVER`

  Reject all cookies unconditionally.

  - Value: `1`
  - Nickname: `never`
  - Available since: 3.0
`SOUP_COOKIE_JAR_ACCEPT_NO_THIRD_PARTY`

  Accept all cookies set by the main document loaded in the application using libsoup. An example of the most common case, web browsers, would be: If http://www.example.com is the page loaded, accept all cookies set by example.com, but if a resource from http://www.third-party.com is loaded from that page reject any cookie that it could try to set. For libsoup to be able to tell apart first party cookies from the rest, the application must call `soup_message_set_first_party()` on each outgoing `SoupMessage`, setting the `GUri` of the main document. If no first party is set in a message when this policy is in effect, cookies will be assumed to be third party by default.

  - Value: `2`
  - Nickname: `no-third-party`
  - Available since: 3.0
`SOUP_COOKIE_JAR_ACCEPT_GRANDFATHERED_THIRD_PARTY`

  Accept all cookies set by the main document loaded in the application using libsoup, and from domains that have previously set at least one cookie when loaded as the main document. An example of the most common case, web browsers, would be: if http://www.example.com is the page loaded, accept all cookies set by example.com, but if a resource from http://www.third-party.com is loaded from that page, reject any cookie that it could try to set unless it already has a cookie in the cookie jar. For libsoup to be able to tell apart first party cookies from the rest, the application must call `soup_message_set_first_party()` on each outgoing `SoupMessage`, setting the `GUri` of the main document. If no first party is set in a message when this policy is in effect, cookies will be assumed to be third party by default.

  - Value: `3`
  - Nickname: `grandfathered-third-party`
  - Available since: 3.0