├── .github ├── workflows │ ├── LICENSE.md │ ├── update.yml │ ├── archive.yml │ ├── ghpages.yml │ └── publish.yml └── CODEOWNERS ├── LICENSE.md ├── .editorconfig ├── .gitignore ├── Makefile ├── CONTRIBUTING.md ├── README.md └── draft-deshpande-secevent-http-multi-set-push.md /.github/workflows/LICENSE.md: -------------------------------------------------------------------------------- 1 | This project is in the public domain. 2 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | # License 2 | 3 | See the 4 | [guidelines for contributions](https://github.com/appsdesh/draft-deshpande-secevent-http-multi-set-push/blob/main/CONTRIBUTING.md). 5 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # See http://editorconfig.org 2 | 3 | root = true 4 | 5 | [*.{md,xml,org}] 6 | charset = utf-8 7 | insert_final_newline = true 8 | trim_trailing_whitespace = true 9 | -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | # Automatically generated CODEOWNERS 2 | # Regenerate with `make update-codeowners` 3 | draft-deshpande-secevent-http-multi-set-push.md apoorva.deshpande@okta.com aaron@parecki.com 4 | draft-todo-yourname-protocol.md apps.desh@gmail.com 5 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.html 2 | *.pdf 3 | *.redxml 4 | *.swp 5 | *.txt 6 | *.upload 7 | *~ 8 | .tags 9 | /*-[0-9][0-9].xml 10 | /.*.mk 11 | /.gems/ 12 | /.idea/ 13 | /.refcache 14 | /.venv/ 15 | /.vscode/ 16 | /lib 17 | /node_modules/ 18 | /versioned/ 19 | Gemfile.lock 20 | archive.json 21 | draft-deshpande-secevent-http-multi-set-push.xml 22 | draft-todo-yourname-protocol.xml 23 | package-lock.json 24 | report.xml 25 | !requirements.txt 26 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | LIBDIR := lib 2 | include $(LIBDIR)/main.mk 3 | 4 | $(LIBDIR)/main.mk: 5 | ifneq (,$(shell grep "path *= *$(LIBDIR)" .gitmodules 2>/dev/null)) 6 | git submodule sync 7 | git submodule update --init 8 | else 9 | ifneq (,$(wildcard $(ID_TEMPLATE_HOME))) 10 | ln -s "$(ID_TEMPLATE_HOME)" $(LIBDIR) 11 | else 12 | git clone -q --depth 10 -b main \ 13 | https://github.com/martinthomson/i-d-template $(LIBDIR) 14 | endif 15 | endif 16 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing 2 | 3 | This repository relates to activities in the Internet Engineering Task Force 4 | ([IETF](https://www.ietf.org/)). All material in this repository is considered 5 | Contributions to the IETF Standards Process, as defined in the intellectual 6 | property policies of IETF currently designated as 7 | [BCP 78](https://www.rfc-editor.org/info/bcp78), 8 | [BCP 79](https://www.rfc-editor.org/info/bcp79) and the 9 | [IETF Trust Legal Provisions (TLP) Relating to IETF Documents](http://trustee.ietf.org/trust-legal-provisions.html). 10 | 11 | Any edit, commit, pull request, issue, comment or other change made to this 12 | repository constitutes Contributions to the IETF Standards Process 13 | (https://www.ietf.org/). 14 | 15 | You agree to comply with all applicable IETF policies and procedures, including, 16 | BCP 78, 79, the TLP, and the TLP rules regarding code components (e.g. being 17 | subject to a Simplified BSD License) in Contributions. 18 | -------------------------------------------------------------------------------- /.github/workflows/update.yml: -------------------------------------------------------------------------------- 1 | name: "Update Generated Files" 2 | # This rule is not run automatically. 3 | # It can be run manually to update all of the files that are part 4 | # of the template, specifically: 5 | # - README.md 6 | # - CONTRIBUTING.md 7 | # - .note.xml 8 | # - .github/CODEOWNERS 9 | # - Makefile 10 | # 11 | # 12 | # This might be useful if you have: 13 | # - added, removed, or renamed drafts (including after adoption) 14 | # - added, removed, or changed draft editors 15 | # - changed the title of drafts 16 | # 17 | # Note that this removes any customizations you have made to 18 | # the affected files. 19 | on: workflow_dispatch 20 | 21 | jobs: 22 | build: 23 | name: "Update Files" 24 | runs-on: ubuntu-latest 25 | permissions: 26 | contents: write 27 | steps: 28 | - name: "Checkout" 29 | uses: actions/checkout@v5 30 | 31 | - name: "Update Generated Files" 32 | uses: martinthomson/i-d-template@v1 33 | with: 34 | make: update-files 35 | token: ${{ github.token }} 36 | 37 | - name: "Push Update" 38 | run: git push 39 | -------------------------------------------------------------------------------- /.github/workflows/archive.yml: -------------------------------------------------------------------------------- 1 | name: "Archive Issues and Pull Requests" 2 | 3 | on: 4 | schedule: 5 | - cron: '0 0 * * 0,2,4' 6 | repository_dispatch: 7 | types: [archive] 8 | workflow_dispatch: 9 | inputs: 10 | archive_full: 11 | description: 'Recreate the archive from scratch' 12 | default: false 13 | type: boolean 14 | 15 | jobs: 16 | build: 17 | name: "Archive Issues and Pull Requests" 18 | runs-on: ubuntu-latest 19 | permissions: 20 | contents: write 21 | steps: 22 | - name: "Checkout" 23 | uses: actions/checkout@v5 24 | 25 | # Note: No caching for this build! 26 | 27 | - name: "Update Archive" 28 | uses: martinthomson/i-d-template@v1 29 | env: 30 | ARCHIVE_FULL: ${{ inputs.archive_full }} 31 | with: 32 | make: archive 33 | token: ${{ github.token }} 34 | 35 | - name: "Update GitHub Pages" 36 | uses: martinthomson/i-d-template@v1 37 | with: 38 | make: gh-archive 39 | token: ${{ github.token }} 40 | 41 | - name: "Save Archive" 42 | uses: actions/upload-artifact@v4 43 | with: 44 | name: archive 45 | path: archive.json 46 | -------------------------------------------------------------------------------- /.github/workflows/ghpages.yml: -------------------------------------------------------------------------------- 1 | name: "Update Editor's Copy" 2 | 3 | on: 4 | push: 5 | paths-ignore: 6 | - README.md 7 | - CONTRIBUTING.md 8 | - LICENSE.md 9 | - .gitignore 10 | pull_request: 11 | paths-ignore: 12 | - README.md 13 | - CONTRIBUTING.md 14 | - LICENSE.md 15 | - .gitignore 16 | 17 | jobs: 18 | build: 19 | name: "Update Editor's Copy" 20 | runs-on: ubuntu-latest 21 | permissions: 22 | contents: write 23 | steps: 24 | - name: "Checkout" 25 | uses: actions/checkout@v5 26 | 27 | - name: "Setup" 28 | id: setup 29 | run: date -u "+date=%FT%T" >>"$GITHUB_OUTPUT" 30 | 31 | - name: "Caching" 32 | uses: actions/cache@v4 33 | with: 34 | path: | 35 | .refcache 36 | .venv 37 | .gems 38 | node_modules 39 | .targets.mk 40 | key: i-d-${{ steps.setup.outputs.date }} 41 | restore-keys: i-d- 42 | 43 | - name: "Build Drafts" 44 | uses: martinthomson/i-d-template@v1 45 | with: 46 | token: ${{ github.token }} 47 | 48 | - name: "Update GitHub Pages" 49 | uses: martinthomson/i-d-template@v1 50 | if: ${{ github.event_name == 'push' }} 51 | with: 52 | make: gh-pages 53 | token: ${{ github.token }} 54 | 55 | - name: "Archive Built Drafts" 56 | uses: actions/upload-artifact@v4 57 | with: 58 | name: drafts 59 | path: | 60 | draft-*.html 61 | draft-*.txt 62 | -------------------------------------------------------------------------------- /.github/workflows/publish.yml: -------------------------------------------------------------------------------- 1 | name: "Publish New Draft Version" 2 | 3 | on: 4 | push: 5 | tags: 6 | - "draft-*" 7 | workflow_dispatch: 8 | inputs: 9 | email: 10 | description: "Submitter email" 11 | default: "" 12 | type: string 13 | 14 | jobs: 15 | build: 16 | name: "Publish New Draft Version" 17 | runs-on: ubuntu-latest 18 | steps: 19 | - name: "Checkout" 20 | uses: actions/checkout@v5 21 | with: 22 | # Needed for tracing file history for replacement status 23 | fetch-depth: 0 24 | fetch-tags: true 25 | 26 | # See https://github.com/actions/checkout/issues/290 27 | - name: "Get Tag Annotations" 28 | run: git fetch -f origin ${{ github.ref }}:${{ github.ref }} 29 | 30 | - name: "Setup" 31 | id: setup 32 | run: date -u "+date=%FT%T" >>"$GITHUB_OUTPUT" 33 | 34 | - name: "Caching" 35 | uses: actions/cache@v4 36 | with: 37 | path: | 38 | .refcache 39 | .venv 40 | .gems 41 | node_modules 42 | .targets.mk 43 | key: i-d-${{ steps.setup.outputs.date }} 44 | restore-keys: i-d- 45 | 46 | - name: "Build Drafts" 47 | uses: martinthomson/i-d-template@v1 48 | with: 49 | token: ${{ github.token }} 50 | 51 | - name: "Upload to Datatracker" 52 | uses: martinthomson/i-d-template@v1 53 | with: 54 | make: upload 55 | env: 56 | UPLOAD_EMAIL: ${{ inputs.email }} 57 | 58 | - name: "Archive Submitted Drafts" 59 | uses: actions/upload-artifact@v4 60 | with: 61 | name: published 62 | path: "versioned/draft-*-[0-9][0-9].*" 63 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | # SECEVENT Drafts 4 | 5 | This is the working area for individual Internet-Drafts. 6 | 7 | ## Push-Based Delivery For Multiple Security Event Token (SET) Using HTTP 8 | 9 | * [Editor's Copy](https://appsdesh.github.io/draft-deshpande-secevent-http-multi-set-push/#go.draft-deshpande-secevent-http-multi-set-push.html) 10 | * [Datatracker Page](https://datatracker.ietf.org/doc/draft-deshpande-secevent-http-multi-set-push) 11 | * [Individual Draft](https://datatracker.ietf.org/doc/html/draft-deshpande-secevent-http-multi-set-push) 12 | * [Compare Editor's Copy to Individual Draft](https://appsdesh.github.io/draft-deshpande-secevent-http-multi-set-push/#go.draft-deshpande-secevent-http-multi-set-push.diff) 13 | 14 | ## TODO - Your title 15 | 16 | * [Editor's Copy](https://appsdesh.github.io/draft-deshpande-secevent-http-multi-set-push/#go.draft-todo-yourname-protocol.html) 17 | * [Datatracker Page](https://datatracker.ietf.org/doc/draft-todo-yourname-protocol) 18 | * [Individual Draft](https://datatracker.ietf.org/doc/html/draft-todo-yourname-protocol) 19 | * [Compare Editor's Copy to Individual Draft](https://appsdesh.github.io/draft-deshpande-secevent-http-multi-set-push/#go.draft-todo-yourname-protocol.diff) 20 | 21 | 22 | ## Contributing 23 | 24 | See the 25 | [guidelines for contributions](https://github.com/appsdesh/draft-deshpande-secevent-http-multi-set-push/blob/main/CONTRIBUTING.md). 26 | 27 | The contributing file also has tips on how to make contributions, if you 28 | don't already know how to do that. 29 | 30 | ## Command Line Usage 31 | 32 | Formatted text and HTML versions of the draft can be built using `make`. 33 | 34 | ```sh 35 | $ make 36 | ``` 37 | 38 | Command line usage requires that you have the necessary software installed. See 39 | [the instructions](https://github.com/martinthomson/i-d-template/blob/main/doc/SETUP.md). 40 | 41 | -------------------------------------------------------------------------------- /draft-deshpande-secevent-http-multi-set-push.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Push-Based Delivery For Multiple Security Event Token (SET) Using HTTP" 3 | abbrev: "Push-multi-SET" 4 | category: std 5 | 6 | docname: draft-deshpande-secevent-http-multi-set-push-latest 7 | submissiontype: IETF 8 | number: 9 | date: 10 | v: 3 11 | area: "Security" 12 | workgroup: "Security Events" 13 | keyword: 14 | - security event 15 | - secevent 16 | venue: 17 | group: "Security Events" 18 | type: "Working Group" 19 | mail: "id-event@ietf.org" 20 | arch: "https://mailarchive.ietf.org/arch/browse/id-event/" 21 | github: "appsdesh/draft-deshpande-secevent-http-multi-set-push" 22 | latest: "https://appsdesh.github.io/draft-deshpande-secevent-http-multi-set-push/draft-deshpande-secevent-http-multi-set-push.html" 23 | 24 | author: 25 | - 26 | fullname: Apoorva Deshpande 27 | organization: Okta 28 | email: apoorva.deshpande@okta.com 29 | - 30 | fullname: Aaron Parecki 31 | organization: Okta 32 | email: aaron@parecki.com 33 | 34 | normative: 35 | RFC8417: 36 | RFC7231: 37 | RFC8935: 38 | RFC9110: 39 | RFC8446: 40 | RFC9728: 41 | RFC8259: 42 | RFC2277: 43 | 44 | informative: 45 | 46 | 47 | --- abstract 48 | 49 | This specification defines how multiple Security Event Tokens (SETs) can be 50 | delivered to an intended recipient using HTTP POST over TLS. The SETs 51 | are transmitted in the body of an HTTP POST request to an endpoint 52 | operated by the recipient, and the recipient indicates successful or 53 | failed transmission via the HTTP response. 54 | 55 | --- middle 56 | 57 | # Introduction 58 | 59 | This specification defines a mechanism by which a transmitter of a Security Event Token (SET) {{RFC8417}} can deliver multiple SETs to an intended SET Recipient via HTTP POST {{RFC7231}} over TLS in a single POST call. {{RFC8935}} focuses on the delivery of the single SET to the receiver. This specification defines an efficient transport mechanism and builds onto {{RFC8935}} to transmit multiple SETs to the receiver in a single POST call. 60 | 61 | Push-Based delivery for multiple SETs is intended to help in following scenarios: 62 | 63 | - The transmitter of the SET has multiple outstanding SETs to be communicated to the receiver 64 | - The transmitter wants to reduce the number of outbound calls to the same receiver to optimize performance, avoid being ratelimited when number of SETs to be communicated is high 65 | - The receiver wants to optimize processing multiple SETs 66 | 67 | This specification will handle all the usecases and scenarios for the {{RFC8935}} and make it more extensible to support multiple SETs per one outbound POST call. 68 | 69 | Similar to {{RFC8935}} this specification makes mechanism for exchanging configuration metadata such as endpoint URLs, cryptographic keys, and possible implementation constraints such as buffer size limitations between the transmitter and recipient is out of scope. 70 | 71 | # Push endpoint to receive multiple SETs 72 | 73 | Each Receiver that supports this specification MUST support a new push endpoint that receives multiple SETs in a single call. This endpoint MUST be capable of serving HTTP POST {{RFC7231}} requests. This endpoint MUST be TLS {{RFC8446}} enabled and MUST reject any communication not using TLS. 74 | The Transmitter obtains this endpoint from the Receiver outside the scope of this specification. 75 | 76 | 77 | # SET delivery semantics 78 | 79 | In this SET delivery using HTTP over TLS, zero or more SETs are delivered in a JSON {{RFC8259}} document 80 | to the SET Receiver. The receiver either acknowledges the successful receipt of the SETs or indicates failure in processing of one or more SETs in a JSON document to the Transmitter. 81 | 82 | After successful (acknowledged) SET delivery, SET Transmitters are not required to retain or record SETs for retransmission. Once a SET is acknowledged, the SET Recipient SHALL be responsible for retention, if needed. Transmitters may also discard undelivered SETs under deployment-specific conditions, such as if they have not been acknowledged (successful or failure) for over too long a period of time or if an excessive amount of storage is needed to retain them. 83 | 84 | Upon receiving a SET, the SET Recipient reads the SET and validates it in the manner described in {{Section 2 of RFC8935}}. The SET Recipient MUST acknowledge receipt to the SET Transmitter, and SHOULD do so in a timely fashion (e.g., miliseconds). The SET Recipient SHALL NOT use the event acknowledgement mechanism to report event errors other than those relating to the parsing and validation of the SET. 85 | 86 | ## Acknowledgement for all SETs 87 | A Transmitter MUST ensure that it includes the `jti` value of each SET it receives, either in an ack or a setErrs value, to the Transmitter from which it received the SETs. A Transmitter SHOULD retry sending the same SET again if it was never responded to either in an ack value or in a setErrs value by a receiver in a reasonable time period. A Transmitter MAY limit the number of times it retries sending a SET. A Transmitter MAY publish the retry time period and maximum number of retries to its peers, but such publication is outside the scope of this specification. 88 | 89 | ## Uniqueness of SETs 90 | A Transmitter MUST NOT send two SETs with the same `jti` value if the SET has been either acknowledged through ack value or produced an error indicated by a setErrs value. If a Transmitter wishes to re-send an event after it has received a error response through a setErrs value, then it MUST generate a new SET that has a new (and unique) jti value. 91 | 92 | ## Transmitting SETs 93 | 94 | To transmit a SET to a SETs Recipient, the SET Transmitter makes an HTTP POST request to a TLS-enabled HTTP endpoint provided by the SET Recipient. The body of this request is of the content type `"application/json"` and the Accept header field MUST be `"application/json"`. 95 | 96 | A Transmitter may initiate communication with the receiver in order to: 97 | 98 | - Send SETs to the Receiver 99 | - Receive acknowledgement of the SETs in response 100 | 101 | It MAY contain the following fields: 102 | 103 | `sets` 104 | OPTIONAL. A JSON object containing key-value pairs in which the key of a field is a string that contains the jti claim of the SET that is specified in the value of the field. This field MAY be omitted to indicate that no SETs are being delivered by the initiator in this communication. The Transmitter SHOULD limit 20 SETs in the sets. 105 | 106 | 107 | The following is a non-normative example of a response. 108 | 109 | { 110 | "sets": { 111 | "4d3559ec67504aaba65d40b0363faad8": 112 | "eyJhbGciOiJub25lIn0. 113 | eyJqdGkiOiI0ZDM1NTllYzY3NTA0YWFiYTY1ZDQwYjAzNjNmYWFkOCIsImlhdC 114 | I6MTQ1ODQ5NjQwNCwiaXNzIjoiaHR0cHM6Ly9zY2ltLmV4YW1wbGUuY29tIiwi 115 | YXVkIjpbImh0dHBzOi8vc2NpbS5leGFtcGxlLmNvbS9GZWVkcy85OGQ1MjQ2MW 116 | ZhNWJiYzg3OTU5M2I3NzU0IiwiaHR0cHM6Ly9zY2ltLmV4YW1wbGUuY29tL0Zl 117 | ZWRzLzVkNzYwNDUxNmIxZDA4NjQxZDc2NzZlZTciXSwiZXZlbnRzIjp7InVybj 118 | ppZXRmOnBhcmFtczpzY2ltOmV2ZW50OmNyZWF0ZSI6eyJyZWYiOiJodHRwczov 119 | L3NjaW0uZXhhbXBsZS5jb20vVXNlcnMvNDRmNjE0MmRmOTZiZDZhYjYxZTc1Mj 120 | FkOSIsImF0dHJpYnV0ZXMiOlsiaWQiLCJuYW1lIiwidXNlck5hbWUiLCJwYXNz 121 | d29yZCIsImVtYWlscyJdfX19.", 122 | "3d0c3cf797584bd193bd0fb1bd4e7d30": 123 | "eyJhbGciOiJub25lIn0. 124 | eyJqdGkiOiIzZDBjM2NmNzk3NTg0YmQxOTNiZDBmYjFiZDRlN2QzMCIsImlhdC 125 | I6MTQ1ODQ5NjAyNSwiaXNzIjoiaHR0cHM6Ly9zY2ltLmV4YW1wbGUuY29tIiwi 126 | YXVkIjpbImh0dHBzOi8vamh1Yi5leGFtcGxlLmNvbS9GZWVkcy85OGQ1MjQ2MW 127 | ZhNWJiYzg3OTU5M2I3NzU0IiwiaHR0cHM6Ly9qaHViLmV4YW1wbGUuY29tL0Zl 128 | ZWRzLzVkNzYwNDUxNmIxZDA4NjQxZDc2NzZlZTciXSwic3ViIjoiaHR0cHM6Ly 129 | 9zY2ltLmV4YW1wbGUuY29tL1VzZXJzLzQ0ZjYxNDJkZjk2YmQ2YWI2MWU3NTIx 130 | ZDkiLCJldmVudHMiOnsidXJuOmlldGY6cGFyYW1zOnNjaW06ZXZlbnQ6cGFzc3 131 | dvcmRSZXNldCI6eyJpZCI6IjQ0ZjYxNDJkZjk2YmQ2YWI2MWU3NTIxZDkifSwi 132 | aHR0cHM6Ly9leGFtcGxlLmNvbS9zY2ltL2V2ZW50L3Bhc3N3b3JkUmVzZXRFeH 133 | QiOnsicmVzZXRBdHRlbXB0cyI6NX19fQ." 134 | } 135 | } 136 | 137 | _Figure 1: Example of SET Transmission_ 138 | 139 | In the above example, the Transmitter is sending 2 SETs to the Receiver. 140 | 141 | { 142 | "sets": {}, 143 | } 144 | 145 | _Figure 2: Example of empty SET transmission_ 146 | 147 | In the above example, the Transmitter is sending zero SETs to the Receiver. This placeholder/empty request provides the Receiver to respond back with ack/err for previously transmitted SETs 148 | 149 | The SET Transmitter MAY include in the request an Accept-Language header field to indicate to the SET Recipient the preferred language(s) in which to receive error messages. 150 | 151 | ## Response Communication 152 | 153 | A Receiver MUST repond to the communication by sending an HTTP response. The body of this response is of the content type `"application/json"`. It MAY contain the following fields: 154 | 155 | `ack` 156 | OPTIONAL. An array of strings, in which each string is the `jti` value of a previously received SET that is acknowledged in this object. This array MAY be empty or this field MAY be omitted to indicate that no previously received SETs are being acknowledged in this communication. 157 | 158 | `setErrs` 159 | OPTIONAL. A JSON object containing key-value pairs in which the key of a field is a string that contains the `jti` value of a previously received SET that the sender of the communication object was unable to process. The value of the field is a JSON object that has the following fields: 160 | 161 | `err` 162 | OPTIONAL. The short reason why the specified SET failed to be processed. Error codes are described in Section 2.4 of [RFC8935]. 163 | 164 | `description` 165 | OPTIONAL. An explanation of why the SET failed to be processed 166 | 167 | The response MUST include a Content-Language header field whose value indicates the language of the error descriptions included in the response body. If the SET Recipient can provide error descriptions in multiple languages, they SHOULD choose the language to use according to the value of the Accept-Language header field sent by the SET Transmitter in the transmission request, as described in Section 5.3.5 of [RFC7231]. If the SET Transmitter did not send an Accept-Language header field, or if the SET Recipient does not support any of the languages included in the header field, the SET Recipient MUST respond with messages that are understandable by an English-speaking person, as described in Section 4.5 of [RFC2277]. 168 | 169 | ### Success Response {#success-response} 170 | 171 | If the Receiver is successful in processing the request, it MUST return the HTTP status code 202 (Accepted). The response MUST have the content-type `"application/json"`. 172 | 173 | HTTP/1.1 202 Accepted 174 | Content-type: application/json 175 | 176 | { 177 | "ack": [ 178 | "3d0c3cf797584bd193bd0fb1bd4e7d30" 179 | ] 180 | } 181 | 182 | _Figure 3: Example of SET Transmission response with ack_ 183 | 184 | In the above example, the Receiver acknowledges one of the SETs it previously received. There are no errors reported by the Receiver. 185 | 186 | HTTP/1.1 202 Accepted 187 | Content-type: application/json 188 | 189 | { 190 | "ack": [ 191 | "f52901c499611ef94540242ac12000322", 192 | "0636e274399711ef9454-0242ac120002", 193 | "d563c72479a04ff0ba415657fa5e2cb11" 194 | ], 195 | "setErrs": { 196 | "4d3559ec67504aaba65d40b0363faad8" : { 197 | "err": "invalid_key", 198 | "description": "Failed validation" 199 | } 200 | } 201 | } 202 | 203 | _Figure 4: Example of SET Transmission response, ack and errors_ 204 | 205 | In the above example, the Receiver acknowledges three of the SETs it previously received. There are errors reported by the Receiver for acklowledging one SET. 206 | 207 | ### Failure Response 208 | 209 | In the event of a general HTTP error condition, the SET Recipient responds with the applicable HTTP Status Code, as defined in Section 6 of [RFC7231]. 210 | 211 | When the SET Recipient detects an error parsing, or authenticating a SET transmitted in a SET Transmission Request, the SET Recipient SHALL respond with an HTTP Response Status Code of 400 (Bad Request). The Content-Type header field of this response MUST be `"application/json"`, and the body MUST be a UTF-8 encoded JSON [RFC8259] object containing the following name/value pairs: 212 | 213 | `err` 214 | OPTIONAL. The short reason why the API failed to process the request. (Not specific to any SETs, but usually indicate service level failure or processing error) 215 | 216 | `description` 217 | OPTIONAL. A UTF-8 string containing a human-readable description of the error that may provide additional diagnostic information. The exact content of this field is implementation specific. 218 | 219 | Note that failure responses in this specification are not specific to any failures related to any specific SET processing. SET specific errors should be communicated by a success response payload defined in the {{success-response}} Section. 220 | 221 | Example error codes that can indicate API level failures MAY include but not limited to: 222 | 223 | - invalid_request (request is malformated) 224 | - authentication_failed (authentication token provided by the Trasnmitter is expired, revoked or invalid) 225 | - access_denied (The transmitter does not have adequate permissions to invoke this API call). 226 | - many_sets (Transmitter included too many SETs in a single request, this is an idication for the transmitter to make a request with lower number of SETs or to comply with max SETs count that receiver published outside of this spec) 227 | 228 | 229 | HTTP/1.1 400 Bad Request 230 | Content-Language: en-US 231 | Content-Type: application/json 232 | 233 | { 234 | "err": "authentication_failed", 235 | "description": "Access token has expired." 236 | } 237 | 238 | _Figure 5: Example Error Response (authentication_failed) 239 | 240 | Above non-normative example error response indicating that the access token included in the request is expired. 241 | 242 | #### Out of order delivery 243 | 244 | A Response may contain `jti` values in its ack or setErrs that do not correspond to the SETs received in the same Request to which the Response is being sent. They MAY consist of values received in previous Requests. 245 | 246 | ### Error Response 247 | 248 | The receiver MUST respond with an error response if it is unable to process the request. The error response MUST include the appropriate error code as described in {{Section 2.4 of RFC8935}}. 249 | 250 | # Authentication and Authorization {#authn-and-authz} 251 | 252 | The Transmitter MUST verify the identity of the Receiver by validating 253 | the TLS certification presented by the Receiver, and verifying that 254 | it is the intended recipient of the request, before sending the SETs. 255 | 256 | The Transmitter SHOULD attempt to obtain the OAuth Protected Resource 257 | Metadata {{RFC9728}} for the Receiver's Push-Based delivery for multiple SETs endpoint. If such metadata is found, the Transmitter MUST obtain an access token using the metadata. 258 | If no such metadata is found, then the Transmitter MAY use any means to 259 | authorize itself to the Receiver. 260 | 261 | # Delivery Reliability 262 | A Transmitter MUST attempt to deliver any SETs it has previously attempted to deliver to a Receiver until: 263 | - It receives an acknowledgement through the ack value for that SET in a subsequent communication with the Receiver 264 | - It receives a setErrs object for that SET in a subsequent communication with the Receiver 265 | - It has attempted to deliver the SET a maximum number of times and has failed to communicate either due to communication errors or lack of inclusion in ack or setErrs in subsequent communications that were conducted for the maximum number of times. The maximum number of attempts MAY be set by the Transmitter for itself and SHOULD be communicated offline to the Receivers 266 | 267 | Additionally consider Delivery Relieability aspects discussed in {{Section 4 of RFC8935}} . 268 | 269 | # Conventions and Definitions 270 | 271 | {::boilerplate bcp14-tagged} 272 | 273 | 274 | # Security Considerations 275 | 276 | ## Too many SETs in the response 277 | This mechanism allows a transmitter to send a large number of SETs in a single request. A malicious or misconfigured transmitter could send an extremely large payload, attempting to exhaust memory or CPU resources on the receiver during JSON parsing or JWT validation. 278 | 279 | Receivers MUST protect themselves against such attacks. It is RECOMMENDED that Receivers establish and document a reasonable upper limit on the number of SETs they will process in a single call. Transmitter MUST obey the maximum number of SETs to be communicated to the receiver. This will avoid any potential truncations/loss of information at the receiver. 280 | 281 | If a Receiver receives a batch exceeding this limit, it SHOULD reject the entire request with a `413 Payload Too Large` HTTP status code. 282 | 283 | 284 | ## Authentication and Authorization 285 | Transmitter MUST follow the procedures described in section {{authn-and-authz}} in order to securely authenticate and authorize Receiver 286 | 287 | ## HTTP and TLS 288 | Transmitter MUST use TLS {{RFC8446}} to communicate with Receiver and is subject to the security considerations of HTTP {{Section 17 of RFC9110}}. 289 | 290 | ## Event Delivery Latency 291 | The primary purpose of security event tokens is the timely communication of security-sensitive information. While this specification enables batching for efficiency, Transmitters MUST NOT unduly delay the transmission of events in an attempt to create larger batches. 292 | 293 | Delaying the transmission of a time-sensitive event, such as a credential compromise or session revocation, defeats the purpose of the protocol and provides an adversary with a larger window of opportunity to act. 294 | 295 | It is RECOMMENDED that Transmitters implement a batching policy that sends a pending batch of SETs when either of the following conditions is met: 296 | - The number of SETs in the batch reaches a configured size limit. 297 | - A configured amount of time (e.g., 1-2 seconds) has elapsed since the oldest SET in the batch was generated. 298 | 299 | This ensures a balance between network efficiency and the real-time nature of the communication. 300 | 301 | ## Information Disclosure in Error Responses 302 | 303 | The `setErrs` is designed for debugging and provides valuable feedback. However, if implemented incorrectly, it can become a souce of information leakage, disclosing internal details or enable enumeration type attacks. 304 | 305 | It is RECOMMENDED that the `setErrs` information is helpful without revealing sensitive information about internal architecture. 306 | 307 | ## Event Ordering and Processing Guarantees 308 | 309 | This specification is a transport efficiency mechanism and it does not address transactional aspects of the request. Every SET is an independent event in the request to the receiver. The event ordering in the request does not imply any chronological depependence. For chronological dependence the receiver should look at the time related event claims.The 310 | 311 | The Transmitter should not assume the ordered processing of the SETs by the receiver sub-systems. This specification does not add any transactional requirements on the receiver. 312 | 313 | Additional security consideration in {{Section 5 of RFC8935}}. 314 | 315 | # Privacy Considerations 316 | 317 | Privacy Considerations from {{Section 6 of RFC8935}} apply. 318 | 319 | # IANA Considerations 320 | 321 | This document has no IANA actions. 322 | 323 | --- back 324 | 325 | # Acknowledgments 326 | {:numbered="false"} 327 | 328 | TODO acknowledge. 329 | --------------------------------------------------------------------------------