pkeys are immutable on OpenSSL 3.0\e[0m (OpenSSL::PKey::PKeyError)
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ó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 25/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- ruby
- Lĩnh vực
- cryptography, security
Hướng nghiên cứu
Bắt đầu với mẫu trong Fastfile:821 và tái hiện lỗi tại OpenSSL::PKey::EC#private_key= bằng Ruby 3.0 và OpenSSL 3.1. Đọc các API xây dựng khóa và ký của OpenSSL::PKey::EC để xác định cách được hỗ trợ nhằm sử dụng các giá trị khóa riêng tư và khóa công khai được cung cấp. Công việc được hoàn thành khi luồng ký và xác minh được báo cáo không còn phát sinh lỗi bất biến, đồng thời có coverage cho hành vi của OpenSSL 3.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
HI, how do I use the existing private key and public key to encrypt the message? The keys are immutable now.
Fastfile:821:in `private_key=': \e[31m[!] pkeys are immutable on OpenSSL 3.0\e[0m (OpenSSL::PKey::PKeyError)
Environment:
ruby 3.0.0p0 (2020-12-25 revision 95aff21468) [arm64-darwin21]
openssl (3.1.0, default: 2.2.0)
fastlane | 2.212.2 | ✅ Up-To-Date
Sample Code:
def get_force_update_message
message = "message"
private_key = "sample_private_key"
public_key = "sample_public_key"
# encrypt
group = OpenSSL::PKey::EC::Group.new('secp256k1')
key = OpenSSL::PKey::EC.new(group)
key.private_key = OpenSSL::BN.new(private_key, 16)
signature = key.dsa_sign_asn1(message)
signature_base64 = Base64.encode64(signature).gsub("\n", "")
# verify
public_key_bn = OpenSSL::BN.new(public_key, 16)
key.public_key = OpenSSL::PKey::EC::Point.new(group, public_key_bn)
key.dsa_verify_asn1(message, signature)
return "#{message}&#{signature_base64}"
end
Error:
[17:13:51]: Error in your Fastfile at line 821
[17:13:51]: 819: group = OpenSSL::PKey::EC::Group.new('secp256k1')
[17:13:51]: 820: key = OpenSSL::PKey::EC.new(group)
[17:13:51]: => 821: key.private_key = OpenSSL::BN.new(private_key, 16)
[17:13:51]: 822:
[17:13:51]: 823: signature = key.dsa_sign_asn1(message)
[17:13:51]: pkeys are immutable on OpenSSL 3.0
+------+----------------------+-------------+
| fastlane summary |
+------+----------------------+-------------+
| Step | Action | Time (in s) |
+------+----------------------+-------------+
| 1 | default_platform | 0 |
| 2 | xcodes | 0 |
| 3 | ensure_env_vars | 0 |
| 4 | set_info_plist_value | 0 |
| 5 | ensure_env_vars | 0 |
+------+----------------------+-------------+
[17:13:51]: fastlane finished with errors
Looking for related GitHub issues on fastlane/fastlane...
Found no similar issues. To create a new issue, please visit:
https://github.com/fastlane/fastlane/issues/new
Run `fastlane env` to append the fastlane environment to your issue
Fastfile:821:in `private_key=': \e[31m[!] pkeys are immutable on OpenSSL 3.0\e[0m (OpenSSL::PKey::PKeyError)
from Fastfile:821:in `get_force_update_message'
from Fastfile:252:in `block (2 levels) in parsing_binding'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/lane.rb:33:in `call'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/runner.rb:49:in `block in execute'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/runner.rb:45:in `chdir'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/runner.rb:45:in `execute'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/lane_manager.rb:47:in `cruise_lane'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/command_line_handler.rb:36:in `handle'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/commands_generator.rb:110:in `block (2 levels) in run'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/commander-4.6.0/lib/commander/command.rb:187:in `call'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/commander-4.6.0/lib/commander/command.rb:157:in `run'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/commander-4.6.0/lib/commander/runner.rb:444:in `run_active_command'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:124:in `run!'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/commander-4.6.0/lib/commander/delegates.rb:18:in `run!'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/commands_generator.rb:354:in `run'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/commands_generator.rb:43:in `start'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/fastlane/lib/fastlane/cli_tools_distributor.rb:123:in `take_off'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/gems/fastlane-2.212.2/bin/fastlane:23:in `<top (required)>'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/bin/fastlane:25:in `load'
from /opt/homebrew/Cellar/fastlane/2.212.2/libexec/bin/fastlane:25:in `<main>'
- Ngôn ngữ chính
- C
- Star
- 276
- Fork
- 205
- Merge trung bình
- 21 giờ 17 phút
- Pull request đã merge (30 ngày)
- 17
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
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 ruby/openssl
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Add OpenSSL::SSL::SSLContext#client_hello_cb= (binding for SSL_CTX_set_client_hello_cb())Có thể đã có người làm @kou đã nhận 37 ngày trước. Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 53/100
ruby/openssl#1125 · 6 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Documenting how to use OpenSSL::SSL::SSLContext in PQC use casesCó thể đã có người làm @junaruga đã nhận 23 ngày trước. Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
ruby/openssl#1118 · 6 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Expose XOFs like SHAKE128 and SHAKE256Có thể đã có người làm @rhenium đã nhận 133 ngày trước. Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
ruby/openssl#1082 · 4 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
Issue tương tự
-
isolation2 lockmodes fails on cassert builds: extra AccessShareLock on partition rootCó thể đã có người làm @tuhaihe đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
apache/cloudberry#2356 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
windows-artifacts: the win-arm64 job uses a Visual Studio generator missing from windows-11-armĐang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 86/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
wasm-micro-runtime/wasm-micro-runtime#5217 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
HandBrake/HandBrake#8278 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày