Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Enkripsi asimetris adalah proses penggunaan kunci publik dari
pasangan kunci publik/pribadi untuk mengenkripsi teks biasa, lalu menggunakan kunci pribadi
yang sesuai untuk mendekripsi ciphertext. Enkripsi asimetris mengandalkan
kriptografi asimetris, yang juga dikenal sebagai kriptografi kunci publik.
Di sisi lain, enkripsi simetris menggunakan kunci yang sama untuk mengenkripsi dan
mendekripsi data.
Alur kerja enkripsi asimetris
Berikut ini adalah deskripsi alur penggunaan kunci asimetris untuk mengenkripsi dan mendekripsi data. Dua peserta dalam alur kerja ini terdiri dari pengirim dan penerima. Pengirim membuat ciphertext menggunakan kunci publik penerima, lalu
penerima mendekripsi ciphertext menggunakan kunci pribadi penerima.
Hanya orang yang mengetahui kunci pribadi yang dapat mendekripsi ciphertext.
Pengirim mengambil kunci publik penerima.
Pengirim menggunakan kunci publik untuk mengenkripsi teks biasa.
Pengirim mengirimkan ciphertext ke penerima.
Penerima menggunakan kunci pribadi penerima untuk mendekripsi ciphertext. Penerima
kini dapat melihat teks biasa.
Contoh kasus penggunaan untuk enkripsi asimetris
Enkripsi asimetris hanya mendukung ukuran teks biasa yang sangat kecil, sehingga enkripsi asimetris umumnya digunakan untuk kunci enkripsi, bukan bagian data yang besar. Misalnya, Anda dapat menggunakan enkripsi asimetris sebagai variasi
enkripsi amplop. Dalam skenario ini, siapa pun yang memiliki akses ke kunci publik
dapat mengenkripsi kunci enkripsi data (DEK). Hanya Cloud KMS yang dapat mendekripsi DEK terenkripsi, atas nama pemilik kunci asimetris.
Algoritma enkripsi asimetris
Cloud Key Management Service mendukung algoritma RSA untuk enkripsi asimetris. RSA adalah
algoritma standar industri dan menawarkan pilihan ukuran kunci dan algoritma
ringkasan. Kriptografi RSA mengandalkan kesulitan dalam memfaktorkan bilangan bulat
besar menjadi dua faktor atau lebih. Makin besar ukuran kunci, makin sulit
faktor bilangan bulat.
Fungsi enkripsi asimetris Cloud KMS
Cloud KMS menyediakan fungsi berikut yang terkait dengan
enkripsi asimetris.
Kemampuan untuk mengambil kunci publik untuk kunci asimetris. Anda menggunakan
kunci publik untuk mengenkripsi data. Cloud KMS tidak secara langsung menyediakan metode untuk mengenkripsi data secara asimetris. Sebagai gantinya, Anda mengenkripsi data menggunakan
SDK dan alat yang tersedia secara terbuka, seperti OpenSSL. SDK dan alat ini memerlukan kunci publik yang Anda ambil dari Cloud KMS.
[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Sulit dipahami","hardToUnderstand","thumb-down"],["Informasi atau kode contoh salah","incorrectInformationOrSampleCode","thumb-down"],["Informasi/contoh yang saya butuhkan tidak ada","missingTheInformationSamplesINeed","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-09-10 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)."]]