비대칭 암호화는 공개/비공개 키 쌍에서 공개 키를 사용하여 일반 텍스트를 암호화한 다음 해당하는 비공개 키를 사용하여 암호 텍스트를 복호화하는 프로세스입니다. 비대칭 암호화는 공개 키 암호법이라고도 하는 비대칭 암호법을 기반으로 합니다.
반면 대칭 암호화는 데이터를 암호화하고 복호화하는 데 동일한 키를 사용합니다.
비대칭 암호화 워크플로
다음은 비대칭 키를 사용하여 데이터를 암호화 및 복호화하기 위한 흐름을 설명합니다. 이 워크플로의 두 참가자는 발신자와 수신자로 구성됩니다. 발신자는 수신자의 공개 키를 사용하여 암호 텍스트를 생성하고, 이후 수신자는 수신자의 비공개 키를 사용하여 암호 텍스트를 복호화합니다.
비공개 키를 아는 사람만 암호 텍스트를 복호화할 수 있습니다.
발신자가 수신자의 공개 키를 검색합니다.
발신자가 공개 키를 사용하여 일반 텍스트를 암호화합니다.
발신자가 수신자에게 암호 텍스트를 보냅니다.
수신자는 수신자의 비공개 키를 사용하여 암호 텍스트를 복호화합니다. 이제 수신자는 일반 텍스트를 볼 수 있습니다.
비대칭 암호화 사용 사례의 예시
비대칭 암호화는 매우 작은 크기의 일반 텍스트만 지원하므로 일반적으로 대량 데이터가 아닌 암호화 키에 사용됩니다. 예를 들어 봉투 암호화의 한 변형으로 비대칭 암호화를 사용할 수 있습니다. 이 시나리오에서는 공개 키에 액세스할 수 있는 누구나 데이터 암호화 키(DEK)를 암호화할 수 있습니다. 이후 Cloud KMS만 비대칭 키 소유자를 대신하여 암호화된 DEK를 복호화할 수 있습니다.
비대칭 암호화 알고리즘
Cloud Key Management Service는 비대칭 암호화를 위한 RSA 알고리즘을 지원합니다. RSA는 업계 표준 알고리즘이며 키 크기와 다이제스트 알고리즘에 대한 선택권을 제공합니다. RSA 암호법은 큰 정수를 두 개 이상의 인수로 인수 분해하기가 어렵다는 점을 이용합니다. 키 크기가 클수록 정수를 인수 분해하기가 더 어려워집니다.
비대칭 키의 공개 키를 검색하는 기능. 공개 키를 사용하여 데이터를 암호화합니다. Cloud KMS는 데이터를 비대칭으로 암호화하는 방법을 직접 제공하지는 않습니다. 대신 OpenSSL과 같이 공개적으로 사용 가능한 SDK 및 도구를 사용하여 데이터를 암호화합니다. 이러한 SDK 및 도구에는 Cloud KMS에서 검색되는 공개 키가 필요합니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-09-05(UTC)"],[],[],null,["# Asymmetric encryption\n\n*Asymmetric encryption* is the process of using a public key from a\npublic/private key pair to encrypt plaintext, and then using the corresponding\nprivate key to decrypt the ciphertext. Asymmetric encryption relies on\nasymmetric cryptography, also known as public key cryptography.\n\nSymmetric encryption, on the other hand, uses the same key to encrypt and\ndecrypt data.\n\nAsymmetric encryption workflow\n------------------------------\n\nThe following describes the flow for using an asymmetric key to encrypt and\ndecrypt data. The two participants in this workflow consists of a sender and a\nrecipient. The sender creates ciphertext using the recipient's public key, and\nthen the recipient decrypts the ciphertext using the recipient's private key.\nOnly someone with knowledge of the private key can decrypt the ciphertext.\n\n1. The sender retrieves the recipient's public key.\n\n2. The sender uses the public key to encrypt plaintext.\n\n3. The sender sends the ciphertext to the recipient.\n\n4. The recipient uses the recipient's private key to decrypt the ciphertext. The\n recipient can now view the plaintext.\n\nExample use case for asymmetric encryption\n------------------------------------------\n\nAsymmetric encryption only supports a very small plaintext size, so\nasymmetric encryption is generally used for encryption keys, not large pieces of\ndata. As an example, you can use asymmetric encryption as a variation of\n[envelope encryption](/kms/docs/envelope-encryption). In this scenario, anyone with access to the public key\ncan encrypt the data encryption key (DEK). Only Cloud KMS can then\ndecrypt the encrypted DEK, on behalf of the owner of the asymmetric key.\n\nAsymmetric encryption algorithms\n--------------------------------\n\nCloud Key Management Service supports RSA algorithms for asymmetric encryption. RSA is\nan industry standard algorithm and offers choices of key size and digest\nalgorithm. RSA cryptography relies on the difficulty in factoring a large\ninteger into two or more factors. The larger the key size, the more difficult it\nis to factor the integers.\n\nCloud KMS asymmetric encryption functionality\n---------------------------------------------\n\nCloud KMS provides the following functionality related to\nasymmetric encryption.\n\n- Ability to [create an asymmetric key](/kms/docs/creating-asymmetric-keys) with [key purpose](/kms/docs/algorithms#key_purposes) of\n `ASYMMETRIC_DECRYPT`. For information about which algorithms\n Cloud KMS supports, see [asymmetric encryption algorithms](/kms/docs/algorithms#asymmetric_encryption_algorithms).\n\n- Ability to [retrieve the public key](/kms/docs/retrieve-public-key) for an asymmetric key. You use the\n public key to [encrypt data](/kms/docs/encrypt-decrypt-rsa#encrypt_data). Cloud KMS does not directly\n provide a method to asymmetrically encrypt data. Instead, you encrypt data using\n openly available SDKs and tools, such as [OpenSSL](https://www.openssl.org/). These SDKs and tools\n require the public key that you retrieve from Cloud KMS.\n\n- Ability to [decrypt data with an asymmetric key](/kms/docs/encrypt-decrypt-rsa#decrypt_data)."]]