adobe / aio-lib-java-cloudmanager

Java wrapper to the Adobe Cloud Manager API.
https://opensource.adobe.com/aio-lib-java-cloudmanager/
Apache License 2.0
3 stars 9 forks source link

Support PEM encoded PKCS#8 private keys #11

Closed kwin closed 4 years ago

kwin commented 4 years ago

Currently each consumer needs to create the private key instance themself. It would be handy if the AdobeClientCredentials would provide some method which creates a PrivateKey from a given String in the format outlined at https://tools.ietf.org/html/rfc7468#section-10

The code for that is pretty straight-forward actually and one can use an approach like outlined in https://www.baeldung.com/java-read-pem-file-keys#3-get-private-key-from-pem-string.

The only question is whether only RSA keys should be supported or other types (DSA, EC) as well