Support compressed (deflate) payload
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 35/100
Hướng nghiên cứu
Start by reading the linked RFC 7516 section 4.1.3 and tracing how ruby-jwt decodes and verifies payloads. The issue proposes inflating DEFLATE data between Base64 decoding and JSON parsing while retaining the raw encoded parts for signature verification; creation/signing is explicitly out of scope for the reporter. Done would require agreed behavior and tests for compressed-payload verification, but the issue has had no comment for years.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
See: RFC 7516 4.1.3
I am working with:
in Ruby.
I'm working in a constrained Ruby environment (Rhomobile platform) and ruby-jwt is well-suited for the environment since it has few dependencies. (I've used ruby-jwt before to implement openid-connect in that environment.)
Smart Health Cards are jws with I think only a small twist: the payload is compressed with DEFLATE. The signature is over the Base64 header and payload. But the payload is opaque to ruby-jwt, and it will fail trying verify claims because the payload is unintelligible to ruby-jwt.
FWIW, headers look something like:
{"zip":"DEF","alg":"ES256","kid":"7JvktUpf1_9NPwdM-70FJT3YdyTiSe2IvmVxxgDSRb0"}
Above is as implemented by California Department of Public Health for their digital Covid immunization records. (Yes the kid is real, it's no secret it's the kid of the current/only public key.)
May not take a lot to support. To read/verify, for example, would require inflating the payload after decoding the Base64, but before parsing the JSON, while still using the raw Base64 header and payload for computing the signature for signature verification. Have not examined creation/signing, as it's not something I need to do.
I've worked around for now by just using ad-hoc code and OpenSSL without ruby-jwt objects, though I do use JWT::SecurityUtils lightly. But I would love to use ruby-jwt.
Since I didn't get far with ruby-jwt I'm unclear how well supported EC is. There could be variations in the format, including possibly certificate chain.
I don't know if there are other use cases where payloads are compressed like this?
Is there an interest in supporting compressed payloads?
Willing to implement and/or help. I'd rather see this incorporated into ruby-jwt rather than making my own variant, and would be good to discuss.
Edit: I updated with RFC7516 4.1.3 reference. I left my original commentary, because Smart Health Cards are now emerging the real world, and I think may become one of the first popular use cases for compressed payload? The compression is done because these are encoded into QR Code images as one embodiment, and it makes quite a dense QR even with the compression.
- Ngôn ngữ chính
- Ruby
- Star
- 3.7k
- Fork
- 381
- Merge trung bình
- 17 giờ 10 phút
- Pull request đã merge (30 ngày)
- 11
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của jwt/ruby-jwt
-
Release with release-pleaseĐang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 15/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 68/100
jwt/ruby-jwt#743 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
jwt/ruby-jwt#723 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Introduce JWE supportĐang mởenhancement feature help wanted up for grabs
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
jwt/ruby-jwt#80 · 11 bình luận · 8 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
Issue tương tự
-
Add a dark modeĐang mởaccessibility enhancement good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
samiromer2/Ruby-Consent-Portal#35 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày
-
👩💻 équipe CE fonctionnalité
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 63/100
betagouv/conseillers-entreprises#4779 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Poetry updater rejects OR (||) Python constraints in PyprojectPreparer#update_python_requirementĐang mởL: python L: ruby:bundler
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
dependabot/dependabot-core#16819 ·
Maintainer thường phản hồi trong vòng 1 ngày