Skip to content

Add enable_binding_cookie field to Access application#528

Merged
patryk merged 1 commit intocloudflare:masterfrom
Justin-Holmes:justin/add-enable-binding-cookie
Sep 28, 2020
Merged

Add enable_binding_cookie field to Access application#528
patryk merged 1 commit intocloudflare:masterfrom
Justin-Holmes:justin/add-enable-binding-cookie

Conversation

@Justin-Holmes
Copy link
Copy Markdown

@Justin-Holmes Justin-Holmes commented Sep 17, 2020

Description

Adds the enable_binding_cookie field to Access applications. This optional field when enabled will provide increased security against compromised authorization tokens and CSRF attacks. Cloudflare's API documentation should be updated soon with the added changes as well.

Related PR: cloudflare/terraform-provider-cloudflare#802.

Has your change been tested?

Here is a cURL request with the new field:

curl --request PUT \
  --url https://api.cloudflare.com/client/v4/accounts/<ACCOUNT_ID>/access/apps/<APP_ID> \
  --header 'authorization: Bearer <TOKEN>' \
  --header 'content-type: application/json' \
  --header 'x-auth-email: <EMAIL>' \
  --header 'x-auth-key: <KEY>' \
  --data '{
        "aud": REDACTED,
        "domain": "asdf.fans",
        "id": REDACTED,
        "name": "asdf-fans",
        "policies": [],
        "allowed_idps": [],
        "session_duration": "24h",
        "uid": REDACTED,
        "auto_redirect_to_identity": false,
        "enable_binding_cookie": true
}'
{
  "result": {
    "aud": REDACTED,
    "created_at": "2020-09-03T20:27:02Z",
    "domain": "asdf.fans",
    "id": REDACTED,
    "name": "asdf-fans",
    "policies": [],
    "allowed_idps": [],
    "auto_redirect_to_identity": false,
    "session_duration": "24h",
    "uid": REDACTED,
    "updated_at": "2020-09-17T17:46:02Z",
    "enable_binding_cookie": true
  },
  "success": true,
  "errors": [],
  "messages": []
}

Types of changes

What sort of change does your code introduce/modify?

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Copy link
Copy Markdown
Contributor

@jacobbednarz jacobbednarz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@patryk patryk merged commit b899dc9 into cloudflare:master Sep 28, 2020
@patryk
Copy link
Copy Markdown

patryk commented Sep 28, 2020

Thanks!

@Justin-Holmes Justin-Holmes deleted the justin/add-enable-binding-cookie branch September 28, 2020 17:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants