例hereに基づいて、AWS Cloudfrontの署名付きURLを生成しようとしています。UnsupportedAlgorithm:このバックエンドはこのキーのシリアル化をサポートしていません。 - Pythonの暗号化load_pem_private_key
cryptography.exceptions.UnsupportedAlgorithm – the serialized key is of a type that is not supported by the backend or if
the key is encrypted with a symmetric cipher that is not supported by the backend.
:それは例外があるため、次の発生することを述べているドキュメントを読んで
File "command_util.py", line 98, in rsa_signer
backend=default_backend()
File "runtime/cryptography/hazmat/primitives/serialization.py", line 20, in load_pem_private_key
return backend.load_pem_private_key(data, password)
File "runtime/cryptography/hazmat/backends/multibackend.py", line 286, in load_pem_private_key
_Reasons.UNSUPPORTED_SERIALIZATION
UnsupportedAlgorithm: This backend does not support this key serialization.
:ライン上
private_key = serialization.load_pem_private_key(
key_file.read(),
password=None,
backend=default_backend()
)
は私がUnsupportedAlgorithm: This backend does not support this key serialization.
完全なトレースは以下の通りですエラーが発生します
指定されたPEMファイルは-----BEGIN RSA PRIVATE KEY-----
で始まり、-----END RSA PRIVATE KEY-----
で終わります。
私はこのアプリケーションを開発する際にgoogle appengine sdkを使用しています。
このエラーメッセージを理解し、この作業を行う方法を理解する助けが必要です。
ニース、私は質問を追跡していた。 –