Laporkan Masalah

Perbandingan Efisiensi Algoritma Hash SHA-256 dan BLAKE2b-512 Untuk Pencatatan Data IoT Smart Farm Dalam Jaringan Blockchain Ganache di Lingkungan K3S

Reyhan Gusnur Putra, Dr. Ronald Adrian, S.T., M.Eng.

2025 | Tugas Akhir | D4 TEKNOLOGI JARINGAN

Sistem pertanian pintar membutuhkan pencatatan data yang terpercaya namun tetap ringan. Proyek ini membandingkan efisiensi dua algoritma hash, SHA-256 dan BLAKE2b-512 untuk pencatatan jejak data ke blockchain Ethereum lokal Ganache yang diorkestrasi dengan K3s. Solusi yang dirancang memakai arsitektur sederhana. Simulator mengirim payload JSON. Middleware berbasis Node.js dan Express menghitung nilai hash. Jejak ringkas berupa hash dan waktu dicatat ke blockchain Ethereum lokal dengan Ganache. Seluruh layanan dijalankan di K3s agar lingkungan uji konsisten dan mudah diskalakan. Penelitian membandingkan efisiensi dua algoritma hash yaitu SHA-256 dan BLAKE2b-512. Pengujian memakai variasi jumlah data antara 50 sampai 500 dengan ulang sebanyak 600 kali per titik uji. Hasil menunjukkan SHA-256 lebih cepat dan stabil. Rata rata latensi berada sekitar dua milidetik dengan simpangan kecil. Throughput lebih tinggi dibanding BLAKE2b-512 yang rata rata berada sekitar tiga milidetik dengan throughput lebih rendah. Perbedaan ini tampil konsisten pada seluruh variasi beban. Antrean menuju transaksi on chain lebih terjaga ketika hash lebih cepat selesai di middleware. Kesimpulannya. Untuk skenario hash logging pada smart farm berbasis blockchain lokal. SHA-256 lebih efisien dan selaras dengan tipe bytes32 di Solidity. BLAKE2b-512 tetap relevan bila dibutuhkan keluaran 512 bit. Orkestrasi K3s membantu ketersediaan dan reprodusibilitas pengujian.

Smart farming systems require reliable yet lightweight data logging. This report compares the efficiency of two hash algorithms, SHA-256 and BLAKE2b-512, for logging data trails to a local Ganache Ethereum blockchain orchestrated with K3s. The designed solution uses a simple architecture. The simulator sends JSON payloads. Node.js and Express-based middleware calculates hash values. Concise traces consisting of hashes and timestamps are recorded to the local Ethereum blockchain with Ganache. All services are run on K3s to ensure a consistent and easily scalable test environment. The research compares the efficiency of two hash algorithms, SHA-256 and BLAKE2b-512. The test uses a variety of data amounts between 50 and 500, repeated 600 times per test point. The results show that SHA-256 is faster and more stable. The average latency was around two milliseconds with a small deviation. The throughput was higher than BLAKE2b-512, which averaged around three milliseconds with a lower throughput. This difference was consistent across all load variations. The queue for on-chain transactions was better maintained when the hash was completed faster in the middleware. Conclusion. For the hash logging scenario on a local blockchain-based smart farm, SHA-256 is more efficient and compatible with the bytes32 type in Solidity. BLAKE2b-512 remains relevant when 512-bit output is required. K3s orchestration helps with the availability and reproducibility of testing.

Kata Kunci : IoT, Smart Farm, Blockchain, Kubernetes, K3s, Hashing, SHA-256, BLAKE2b-512, Node.js, Express, Crypto, Latensi, Throughput

  1. D4-2025-477927-abstract.pdf  
  2. D4-2025-477927-bibliography.pdf  
  3. D4-2025-477927-tableofcontent.pdf  
  4. D4-2025-477927-title.pdf