# Key Pair

ชุดของ key ที่จะใช้เป็นหนึ่งในวิธีการ authenticate เพื่อ access เข้าสู่ Compute Instance&#x20;

key pair คือชุดคู่ของ public key และ private key จะสร้างขึ้นมาคู่กับ ตามหลักการของ Asymmetic Cryptography หรือ Public-key Cryptography ที่จะเก็บ public key ไว้กับระบบ และเก็บ private key ไว้ที่ user ทำให้นอกจากจะเป็นการ authenticate เพื่อ access เข้าไปใช้งาน instance แล้ว ยังจะทำให้การสื่อสารไป-มา ระหว่าง device ของเรา กับ Compute Instance ถูก encrypt ไว้ด้วย public key แล้วจะมีแค่ผู้ที่มี private key เท่านั้น ที่จะสามารถ decrypt ข้อมูลมาอ่านได้

เป็นตัวเลือกการ authentication ที่เพิ่ม security ให้กับการใช้งาน Compute Instance ที่เราแนะนำ

## Recommendations

{% content-ref url="/pages/KaglK7JPd8l2eek39h6a" %}
[Creating a New Key Pair](/ncs-documents/compute/key-pair/creating-a-new-key-pair.md)
{% endcontent-ref %}

{% content-ref url="/pages/p6gJ6tb47asU55WUU0My" %}
[Importing an Existing Key Pair](/ncs-documents/compute/key-pair/importing-an-existing-key-pair.md)
{% endcontent-ref %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs-epc.gitbook.io/ncs-documents/compute/key-pair.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
