# \[Glossary\] Cryptographic Hash Function

**URL:** <https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322>\
**Category:** แบ่งปันไอเดีย💡\
**Tags:** content-idea\
**Created:** [August 16, 2022, 3:20am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322 "2022-08-16T03:20:29Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Namtan](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/namtan/32/23_2.png) [@Namtan](https://discuss.hashpire.io/u/Namtan)\
**Post date:** [August 16, 2022, 3:20am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/1 "2022-08-16T03:20:29Z")

</div>

Hash Function

คือ ฟังก์ชันการทำงานแบบทางเดียว (One-way function) ซึ่งสามารถแปลงข้อมูล (Input) ที่มีความยาวเท่าไรก็ได้ (Arbitrary length) ออกมาเป็นข้อมูล (Output) ที่ความยาวคงที่ (Fixed-length) โดยผลลัพธ์ที่ได้จะถูกเรียกว่า " Hash value "

* * *

> คำถามที่รบกวนให้ Reviewer ช่วยตอบค่ะ
> 
> 1. มีข้อมูลตรงส่วนไหนที่อ่านแล้วไม่เข้าใจ ไม่ชัดเจน หรือมีไอเดียว่าควรปรับเป็นแบบไหนหรือไม่
> 2. มีข้อมูลตรงส่วนไหนที่ไม่ถูกต้อง อย่างไร
> 3. อ่านจบแล้วได้อะไรจากบทความนี้บ้าง ได้ความเข้าใจเพิ่มเติมไหม

---

<div class="post-metadata">

**Author:** ![parinyar](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/parinyar/32/127_2.png) [@parinyar](https://discuss.hashpire.io/u/parinyar)\
**Post date:** [August 16, 2022, 4:08am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/2 "2022-08-16T04:08:33Z")

</div>

ส่วนตัวผมคิดว่าเราควรจะอธิบายว่า Hash function คืออะไรแบบกระชับๆ เลยดีกว่าไหมครับ เช่น

Hash Function คือกลไกในการแปลงข้อมูลผ่านกระบวนการทางคณิตศาสตร์ เพื่อให้ได้ข้อมูลที่มีความเฉพาะเจาะจง และไม่สามารถทำการถอดรหัสย้อนกลับได้ ผลลัพธ์ที่ได้จากกระบวนการนี้จะถูกเรียกว่า “Hash value”

ตัวอย่างของ Hash Value

```auto
hello -> 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824
Hello -> 185f8db32271fe25f561a6fc938b2e264306ec304eda518007d1764826381969

```

พี่น้ำตาลลองเอาไปเกาๆ ดูหน่อยนะครับ @Namtan

ref : [https://zipmex.com/th/glossary/hash/](https://zipmex.com/th/glossary/hash/)

---

<div class="post-metadata">

**Author:** ![parinyar](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/parinyar/32/127_2.png) [@parinyar](https://discuss.hashpire.io/u/parinyar)\
**Post date:** [August 16, 2022, 4:10am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/3 "2022-08-16T04:10:16Z")

</div>

อยากจะได้ข้อความที่อธิบายประมาณนี้ด้วยครับว่า “แม้ input จะเปลี่ยนแปลงเพียงตัวเดียว hash value ก็จะเปลี่ยนแปลงไปแบบสิ้นเชิง” อะไรประมาณนี้ครับ

---

<div class="post-metadata">

**Author:** ![Namtan](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/namtan/32/23_2.png) [@Namtan](https://discuss.hashpire.io/u/Namtan)\
**Post date:** [August 16, 2022, 4:13am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/4 "2022-08-16T04:13:49Z")

</div>

จริง ๆ จะมีอีกบทความที่เป็นคุณสมบัติของ Hash Function เลยคิดว่ามันน่าจะอยู่ในคุณสมบัติมั้ย อันนี้หรือยังไง

---

<div class="post-metadata">

**Author:** ![parinyar](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/parinyar/32/127_2.png) [@parinyar](https://discuss.hashpire.io/u/parinyar)\
**Post date:** [August 16, 2022, 6:08am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/5 "2022-08-16T06:08:01Z")

</div>

ผมว่าเดี๋ยวตอนเขียนบทความเราค่อยไปลงลึกก็ได้ครับ

---

<div class="post-metadata">

**Author:** ![Pantitas](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/pantitas/32/4_2.png) [@Pantitas](https://discuss.hashpire.io/u/Pantitas)\
**Post date:** [August 16, 2022, 10:17am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/6 "2022-08-16T10:17:16Z")

</div>

## AW

 ![Glossary-template-01](https://discuss.hashpire.io/uploads/default/original/1X/784db3236ce18a1a208e20563cf376f5d88c5ef0.png)

---

<div class="post-metadata">

**Author:** ![anakornk](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/anakornk/32/3_2.png) [@anakornk](https://discuss.hashpire.io/u/anakornk)\
**Post date:** [August 18, 2022, 7:15am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/7 "2022-08-18T07:15:43Z")

</div>

กราฟฟิกควรจะประกอบ text ให้ text อ่านรู้เรื่องมากขึ้น

 ![image](https://discuss.hashpire.io/uploads/default/original/1X/8f73ef8d6c1d2e90ba3f95b0c9574e20d714b2da.jpeg)

 ![image](https://discuss.hashpire.io/uploads/default/original/1X/1e688e4cbdaa7875668968291f0b6aa3c69090f6.png)

---

<div class="post-metadata">

**Author:** ![anakornk](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/anakornk/32/3_2.png) [@anakornk](https://discuss.hashpire.io/u/anakornk)\
**Post date:** [August 18, 2022, 7:22am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/8 "2022-08-18T07:22:27Z")

</div>

> [@Namtan](#):
>
> คำถามที่รบกวนให้ Reviewer ช่วยตอบค่ะ

1. บทความนี้ต้องการที่จะ Define ว่า Cryptography Hash Function คืออะไร?  
Hash Function : one way function ที่ input ความยาวเท่าไรก็ได้ (arbitrary length) และ output เป็น fix value. cryptographic ในที่นี้ คือ crytographically secure ยากที่จะโจมตี

> A **hash function** is any [function](https://en.wikipedia.org/wiki/Function_(mathematics)) that can be used to map [data](https://en.wikipedia.org/wiki/Data_(computing)) of arbitrary size to fixed-size values. The values returned by a hash function are called _hash values_ , _hash codes_ , _digests_ , or simply _hashes_ .

ไม่น่าจะเรียกว่าการเข้ารหัส ? การเข้ารหัสมันต้องถอดได้?

---

<div class="post-metadata">

**Author:** ![anakornk](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/anakornk/32/3_2.png) [@anakornk](https://discuss.hashpire.io/u/anakornk)\
**Post date:** [August 18, 2022, 7:24am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/9 "2022-08-18T07:24:20Z")

</div>

> [@Namtan](#):
>
> คือ กลไกในการแปลงข้อมูลธรรมดา โดยการเข้ารหัสผ่านกระบวนการทางคณิตศาสตร์ เพื่อให้ได้ข้อมูลที่มีลักษณะจำเพาะของข้อมูลนั้น ๆ และไม่สามารถทำการถอดรหัสย้อนกลับได้ โดยผลลัพธ์ที่ได้จากกระบวนการนี้จะถูกเรียกว่า " Hash value "

อ่านแล้วเหมือนอธิบายว่าคือ one way function ที่ output value มัน unique.

ซึ่ง hash. function เป็นone way function ที่ output value มัน unique. แต่จะมีที่ว่า input ความยาวเท่าไรก็ได้ output fix size

---

<div class="post-metadata">

**Author:** ![anakornk](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/anakornk/32/3_2.png) [@anakornk](https://discuss.hashpire.io/u/anakornk)\
**Post date:** [August 18, 2022, 7:25am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/10 "2022-08-18T07:25:48Z")

</div>

@parinyar ดู permissionหน่อยว่าทำไม assign @Namtan ไม่ได้ ถ้าไมได้ เดียวคืนนี้ดูเอง

---

<div class="post-metadata">

**Author:** ![parinyar](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/parinyar/32/127_2.png) [@parinyar](https://discuss.hashpire.io/u/parinyar)\
**Post date:** [August 18, 2022, 7:35am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/11 "2022-08-18T07:35:29Z")

</div>



---

<div class="post-metadata">

**Author:** ![system](https://discuss.hashpire.io/uploads/default/original/1X/bac5456b4265cb6fe479f4d3931a8d32d1f8fd24.png) [@system](https://discuss.hashpire.io/u/system)\
**Post date:** [August 18, 2022, 7:36am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/12 "2022-08-18T07:36:46Z")

</div>



---

<div class="post-metadata">

**Author:** ![parinyar](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/parinyar/32/127_2.png) [@parinyar](https://discuss.hashpire.io/u/parinyar)\
**Post date:** [August 18, 2022, 7:37am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/13 "2022-08-18T07:37:45Z")

</div>



---

<div class="post-metadata">

**Author:** ![parinyar](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/parinyar/32/127_2.png) [@parinyar](https://discuss.hashpire.io/u/parinyar)\
**Post date:** [August 18, 2022, 7:38am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/14 "2022-08-18T07:38:49Z")

</div>

เรียบร้อยแล้วครับ ตอนแรก assign ได้เฉพาะ staff group เลย assign พี่น้ำตาลไม่ได้  
ผมปรับให้เป็น assign ได้ทุก trust level 0-4 แทนแล้วครับ

---

<div class="post-metadata">

**Author:** ![Pantitas](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/pantitas/32/4_2.png) [@Pantitas](https://discuss.hashpire.io/u/Pantitas)\
**Post date:** [August 18, 2022, 7:42am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/15 "2022-08-18T07:42:45Z")

</div>

@anakornk ส่วนนี้ ที่ใช้แค่ text เพราะเห็นเป็นคอนเทนต์แนว Glossary ซึ่งจะเป็นเหมือนบัตรคำศัพท์ ปันก็เเลยไม่ได้มีการใส่ diagram รูปภาพเข้าไปเพิ่มค่ะ หรือถ้ามองว่าควรมีก็อาจจะเปลี่ยนรูปแบบการนำเสนอแทนค่ะ

---

<div class="post-metadata">

**Author:** ![Namtan](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/namtan/32/23_2.png) [@Namtan](https://discuss.hashpire.io/u/Namtan)\
**Post date:** [August 18, 2022, 8:03am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/16 "2022-08-18T08:03:33Z")

</div>



---

<div class="post-metadata">

**Author:** ![Namtan](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/namtan/32/23_2.png) [@Namtan](https://discuss.hashpire.io/u/Namtan)\
**Post date:** [August 18, 2022, 8:15am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/19 "2022-08-18T08:15:28Z")

</div>



---

<div class="post-metadata">

**Author:** ![anakornk](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/anakornk/32/3_2.png) [@anakornk](https://discuss.hashpire.io/u/anakornk)\
**Post date:** [August 18, 2022, 11:17am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/20 "2022-08-18T11:17:31Z")

</div>

> [@Pantitas](#):
>
> ส่วนนี้ ที่ใช้แค่ text

hmmmm เข้าใจ แต่บางทีภาพมันจะช่วยอธิบายได้หน่อย  
เอางี้ว่าถ้ามีรูปและทำให้เข้าใจง่ายขึ้นก็อยากให้มี

---

<div class="post-metadata">

**Author:** ![anakornk](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/anakornk/32/3_2.png) [@anakornk](https://discuss.hashpire.io/u/anakornk)\
**Post date:** [August 18, 2022, 11:38am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/21 "2022-08-18T11:38:57Z")

</div>

@Namtan ตากี้แก้เพิ่มให้ ความยาวคงที่คือแค่ fixed length  
digest จริงๆ คือ hash value

---

<div class="post-metadata">

**Author:** ![anakornk](https://discuss.hashpire.io/user_avatar/discuss.hashpire.io/anakornk/32/3_2.png) [@anakornk](https://discuss.hashpire.io/u/anakornk)\
**Post date:** [August 18, 2022, 11:41am UTC](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322/22 "2022-08-18T11:41:35Z")

</div>

> [@Namtan](#):
>
> ฟังก์ชัน

อยากให้เสริมอธิบายนิดนึงว่า ฟังชั่นคืออะไร เพื่อคนที่แบบ เลขไม่แข็ง ไม่รู้คืออะไร อย่างอื่นโอเคแล้ว

[Next page](https://discuss.hashpire.io/t/glossary-cryptographic-hash-function/322.md?page=2)
