-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Elixir: Plug Header Groups & Plug Name #17
Conversation
8ae6f56
to
d4912d9
Compare
d4912d9
to
5772776
Compare
6ef07fb
to
5c4ffb1
Compare
5c4ffb1
to
764ad7c
Compare
This comment was marked as outdated.
This comment was marked as outdated.
764ad7c
to
3ee6506
Compare
a96be30
to
ce21c6e
Compare
ce21c6e
to
f1c6448
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to print out and review the docs as a separate task so that we can release this now.
I'm at a nitpicking phase where my main nits seems to be:
- front loading sentences
- simplifying sentences
- removing subclauses by rewriting
- removing much of the emphasis so that it doesn't become less important to the reader
- for example "Should no proof headers be included, the request is considered invalid" ; "If there are no proof headers the request is invalid"
- moving important stuff earlier
For technical writing I have to ditch the writing style I like and think more along the guidelines in https://www.plainlanguage.gov/guidelines/
I’m going to be busy with internal tasks today and we’re not yet ready to pull this into our projects because of other changes blocking this test release. Just remember to flag the release date to be changed from today when putting other comments in place so that we get that updated. I’d rather have the documentation fixed than not. If you see particularly egregious text that needs fixing, please also check the Typescript and Ruby to see if the text is equally awful. We probably won’t fix it in this PR (I think that I’ve seen an issue we need to resolve in the Ruby code, but haven’t verified it to be sure), but I would like to have it flagged. |
67dd8fa
to
5e491cd
Compare
0c7fd4a
to
a61a97e
Compare
- Add support for header groups in `AppIdentity.Plug` to better handle fallback headers. Kinetic’s original Elixir implementation always verified only the _first_ value from a _list_ of headers, like so: ```elixir with [] <- Conn.get_req_header(conn, "header-1"), [] <- Conn.get_req_header(conn, "header-2"), [] <- Conn.get_req_header(conn, "header-3") do :error else [value | _] -> {:ok, value} end ``` AppIdentity.Plug always processes all values of a header and puts the result in a map with the header name as the key, it meant that we would have had to check these results in turn. Instead, the `header_groups` option allows you to collect all _related_ headers into one result key: ```elixir plug AppIdentity.Plug, header_groups: %{ "app" => ["header-1", "header-2", "header-3"] }, ... ``` - Add support for alternate names so that `AppIdentity.Plug` can be specified multiple times in a pipeline and will store its data separately. Signed-off-by: Austin Ziegler <[email protected]>
These changes do not affect any implementation, but adds some security recommendations for secret handling that were omitted from the initial released version of the specification. 1. Generated secret values should be prefixed for improved leak detection by scanning tools, such as those deployed by GitHub. The reference implementations do not generate application objects *except* for the integrated test suites, and the secrets are always generated on each independent run. 2. Secret values should be stored in memory-safe and leak-resistant mechanisms. The reference implementations already use closures to wrap the secret and custom inspection definitions to ensure that the secrets cannot be accidentally leaked. Signed-off-by: Austin Ziegler <[email protected]>
- Mark all 'head' matrix entries as `continue-on-error` - Add Ruby 3.2 to the Ubuntu 22.04 test scenarios. Signed-off-by: Austin Ziegler <[email protected]>
Kinetic Commerce is not *currently* working on implementations in Swift or Kotlin. Signed-off-by: Austin Ziegler <[email protected]>
Technical Change Notes ====================== - Add latest PNPM to the test matrix. - Also fix some issues with the lockfile. - Set release date as this July 7, 2023. - Rework some comments based on April documentation comments. - Allow Poison v5. Signed-off-by: Austin Ziegler <[email protected]>
Technical Change Notes ====================== Various CI errors that are proving to be hard to deal with; we will deprecate those for this version. This forces a full version upgrade for semver. - Add an .npmrc to try to fix issues with PNPM resolution still Signed-off-by: Austin Ziegler <[email protected]>
a61a97e
to
a27ee98
Compare
412ab9e
to
bc3e365
Compare
Signed-off-by: Austin Ziegler <[email protected]>
bc3e365
to
35529d8
Compare
Elixir: Plug Header Groups & Plug Name (d307900)
Add support for header groups in
AppIdentity.Plug
to better handle fallback headers. Kinetic’s original Elixir implementation always verified only the first value from a list of headers, like so:AppIdentity.Plug always processes all values of a header and puts the result in a map with the header name as the key, it meant that we would have had to check these results in turn. Instead, the
header_groups
option allows you to collect all related headers into one result key:Add support for alternate names so that
AppIdentity.Plug
can be specified multiple times in a pipeline and will store its data separately.Spec: Extend security details for secret handling (8b7edd0)
These changes do not affect any implementation, but adds some security recommendations for secret handling that were omitted from the initial released version of the specification.
Generated secret values should be prefixed for improved leak detection by scanning tools, such as those deployed by GitHub.
The reference implementations do not generate application objects except for the integrated test suites, and the secrets are always generated on each independent run.
Secret values should be stored in memory-safe and leak-resistant mechanisms.
The reference implementations already use closures to wrap the secret and custom inspection definitions to ensure that the secrets cannot be accidentally leaked.