emqx / emqx/MQTT-Client-Examples

PKCS#8 formatted client certificate key file fails to load in Java demo's mutual authentication

Open
#146 1 comment 0 reactions 1 assignee Claimed by @Zhiw View on GitHub
Dominant language
Kotlin
Stars
1k
Forks
718
PR merge metrics
No merged PRs in 30d

Description

OpenSSL version: OpenSSL 3.3.1 4 Jun 2024 (Library: OpenSSL 3.3.1 4 Jun 2024)
The generated certificate key file format is PKCS#8, but the example only loads PKCS#1 keys.
Please modify the example code to adapt to both formats, or add version-specific parameters when generating certificates.

Error message:
org.bouncycastle.asn1.pkcs.PrivateKeyInfo cannot be cast to org.bouncycastle.openssl.PEMKeyPair

---
*This issue was automatically translated from Chinese.*

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.