Luận văn application of blockchain technology in verification of agriculture products identity

Ứng dụng công nghệ blockchain trong xác minh danh tính sản phẩm nông nghiệp, giúp tăng cường tính minh bạch và bảo vệ người tiêu dùng.

Trường đại học

Đại học Bách Khoa TP.HCM

Chuyên ngành

Khoa học Máy tính

Người đăng

Ẩn danh

Thể loại

Luận án tốt nghiệp

2024

116
2
0

Phí lưu trữ

35 Point

Tóm tắt

I. Giới thiệu về Blockchain và xác thực sản phẩm nông sản

Công nghệ Blockchain đã trở thành giải pháp tiên tiến trong việc xác thực và truy xuất nguồn gốc sản phẩm nông sản. Hiện nay, các sản phẩm giả mạo nông sản gây ra những thách thức lớn cho thị trường toàn cầu, ảnh hưởng đến sức khỏe người tiêu dùng và lợi ích của các nông dân. Hệ thống xác thực blockchain cung cấp một cách tiếp cận minh bạch, phi tập trung, cho phép ghi lại toàn bộ chu kỳ sống của sản phẩm từ khâu gieo trồng đến phân phối. Mỗi bước trong chuỗi cung ứng được mã hóa và lưu trữ bất biến, tạo ra một hồ sơ kỹ thuật số đáng tin cậy mà các bên liên quan có thể truy cập và xác minh.

1.1. Khái niệm công nghệ Blockchain

Blockchain là một công nghệ sổ cái phân tán cho phép lưu trữ dữ liệu một cách an toàn và bất biến. Mỗi khối dữ liệu được liên kết bằng các hàm mã hóa, tạo thành một chuỗi không thể chỉnh sửa. Đặc điểm chính là tính phi tập trung, minh bạch, và an ninh cao, làm cho blockchain trở thành công cụ lý tưởng cho việc xác thực sản phẩm nông sản.

1.2. Vấn đề sản phẩm giả mạo trong nông sản

Sản phẩm nông sản giả mạo không tuân thủ tiêu chuẩn chất lượng, gây nguy hiểm cho người tiêu dùng và ảnh hưởng đến danh tiếng của sản xuất gia. Các phương pháp xác thực truyền thống thiếu minh bạch và dễ bị giả mạo. Giải pháp blockchain giúp xây dựng một hệ thống tin cậy, cho phép truy xuất nguồn gốc sản phẩm một cách chính xác.

II. Nguyên lý hoạt động của Blockchain trong xác thực nông sản

Hệ thống blockchain xác thực nông sản hoạt động dựa trên nguyên lý ghi lại mọi giao dịch và sự kiện quan trọng trong chuỗi cung ứng. Từng bên tham gia - nông dân, nhà phân phối, nhà bán lẻ, và người tiêu dùng - đều có một danh tính mã hóa độc nhất. Khi một sản phẩm được tạo ra hoặc chuyển giao, thông tin chi tiết được ghi vào blockchain với dấu thời gian. Nhờ cơ chế đồng thuận và mã hóa, các bản ghi này không thể bị xóa hoặc chỉnh sửa. Điều này đảm bảo rằng mỗi sản phẩm có một lịch sử hoàn chỉnh, có thể được kiểm chứng bởi bất kỳ bên nào.

2.1. Chuỗi cung ứng nông sản trên Blockchain

Chuỗi cung ứng blockchain ghi lại từng bước của sản phẩm nông sản từ canh tác đến tiêu thụ. Thông tin bao gồm: loại giống, quá trình canh tác, sử dụng phân bón, lịch sử vận chuyển, điều kiện bảo quản. Mỗi bước được xác nhận bởi các bên liên quan, tạo ra một hồ sơ minh bạch mà người tiêu dùng có thể kiểm tra qua ứng dụng di động hoặc mã QR.

2.2. Xác thực danh tính sản phẩm thông qua mã hóa

Mỗi sản phẩm được gán một mã định danh duy nhất được tạo ra bằng hàm mã hóa. Mã này không thể giả mạo hoặc nhân bản. Khi người tiêu dùng quét mã này, họ có thể truy cập toàn bộ lịch sử xác thực của sản phẩm, bao gồm các chứng chỉ, kiểm tra chất lượng, và thông tin nhà sản xuất.

III. Lợi ích của Blockchain trong xác thực sản phẩm nông sản

Ứng dụng blockchain xác thực nông sản mang lại nhiều lợi ích đáng kể cho cả người tiêu dùng, nhà sản xuất, và các bên liên quan. Trước hết, minh bạch hoàn toàn trong chuỗi cung ứng cho phép người tiêu dùng biết rõ về nguồn gốc và quá trình sản xuất sản phẩm. Thứ hai, giảm thiểu gian lận nhờ vào tính bất biến của dữ liệu trên blockchain. Thứ ba, tăng cường tin tưởng giữa các bên liên quan vì tất cả dữ liệu đều có thể kiểm chứng độc lập. Cuối cùng, nâng cao hiệu quả hoạt động chuỗi cung ứng bằng cách tự động hóa các quy trình và giảm chi phí quản lý.

3.1. Minh bạch và xác thực nguồn gốc sản phẩm

Blockchain cho phép người tiêu dùng theo dõi toàn bộ hành trình sản phẩm nông sản từ nông trại đến bàn ăn. Mọi thông tin từ loại giống, phương pháp canh tác, sử dụng hóa chất, đến lịch sử vận chuyển đều được ghi lại công khai. Điều này tạo ra sự tin tưởng cao và cho phép người tiêu dùng đưa ra quyết định mua hàng thông minh dựa trên dữ liệu thực tế.

3.2. Giảm thiểu sản phẩm giả mạo và gian lận

Tính bất biến và phi tập trung của blockchain gây khó khăn cho việc giả mạo hoặc tạo ra các bản ghi sai lệch. Bất kỳ nỗ lực nào để chỉnh sửa dữ liệu đều sẽ được phát hiện ngay lập tức. Điều này giảm đáng kể tỷ lệ sản phẩm giả mạo và bảo vệ quyền lợi của những sản xuất gia hợp pháp.

3.3. Nâng cao hiệu quả chuỗi cung ứng

Hệ thống blockchain tự động hóa việc ghi lại và xác minh thông tin, giảm bớt các khâu thủ công. Điều này tăng tốc độ xử lý, giảm chi phí quản lý, và giảm lỗi sai do yếu tố con người. Các bên liên quan có thể truy cập dữ liệu kịp thời, giúp ra quyết định nhanh chóng hơn.

IV. Thách thức và triển vọng phát triển Blockchain xác thực nông sản

Mặc dù blockchain xác thực nông sản có tiềm năng lớn, vẫn tồn tại những thách thức cần vượt qua. Thách thức kỹ thuật bao gồm khả năng mở rộng hệ thống, chi phí triển khai, và vấn đề tương tác giữa các nền tảng blockchain khác nhau. Thách thức tổ chức liên quan đến sự đồng ý của các bên liên quan và thay đổi quy trình công việc. Tuy nhiên, với sự hỗ trợ từ chính phủ, các doanh nghiệp công nghệ, và nông dân, blockchain sẽ trở thành giải pháp tiêu chuẩn cho xác thực sản phẩm nông sản trong tương lai.

4.1. Các thách thức hiện tại trong triển khai

Chi phí ban đầu để triển khai hệ thống blockchain khá cao, đặc biệt đối với các nông dân nhỏ. Vấn đề khả năng mở rộng: khi số lượng giao dịch tăng, blockchain có thể chậm lại. Ngoài ra, cần có sự hợp tác giữa các bên liên quan để tiêu chuẩn hóa quy trình. Thiếu kỹ năng kỹ thuật cũng là rào cản đối với những người không quen công nghệ.

4.2. Triển vọng và phát triển trong tương lai

Tương lai của blockchain xác thực nông sản rất sáng sủa. Các công nghệ mới như Hyperledger Fabric giúp giảm chi phí và cải thiện hiệu suất. Sự hỗ trợ từ chính phủ và các tổ chức quốc tế sẽ tạo điều kiện thuận lợi cho phát triển hệ thống. Khi blockchain trở nên phổ biến hơn, chi phí sẽ giảm, và nhiều người sẽ áp dụng công nghệ này.

11/12/2025
Luận văn application of blockchain technology in verification of agriculture products identity

Trích đoạn nội dung tài liệu

VIETNAM NATIONAL UNIVERSITY HO CHI MINH CITY HO CHI MINH UNIVERSITY OF TECHNOLOGY FACULTY OF COMPUTER SCIENCE AND ENGINEERING CAPSTONE PROJECT Application of Blockchain technology in verification of agriculture products identity Major: Computer Science THESIS COMMITTEE: CC-CS 12 REVIEWER: Mrs. Le Thanh Van SUPERVISOR: Assoc. Nguyen Duc Thai, PhD —o0o— STUDENT 1: Le Quang Khoi (2053151) STUDENT 2: Luu Trinh Thien (2053451) STUDENT 3: Ngo Quang Nguyen (2053276) HO CHI MINH CITY, April 2024 VIETNAM NATIONAL UNIVERSITY HO CHI MINH CITY HO CHI MINH UNIVERSITY OF TECHNOLOGY FACULTY OF COMPUTER SCIENCE AND ENGINEERING CAPSTONE PROJECT Application of Blockchain technology in verification of agriculture products identity Major: Computer Science THESIS COMMITTEE: CC-CS 12 REVIEWER: Mrs. Le Thanh Van SUPERVISOR: Assoc.

Nguyen Duc Thai, PhD —o0o— STUDENT 1: Le Quang Khoi (2053151) STUDENT 2: Luu Trinh Thien (2053451) STUDENT 3: Ngo Quang Nguyen (2053276) HO CHI MINH CITY, April 2024 ĐẠI HỌC QUỐC GIA TP.HCM CỘNG HÒA XÃ HỘI CHỦ NGHĨA VIỆT NAM ---------- Độc lập - Tự do - Hạnh phúc TRƯỜNG ĐẠI HỌC BÁCH KHOA KHOA: KH&KT Máy tính NHIỆM VỤ LUẬN ÁN TỐT NGHIỆP BỘ MÔN: Hệ thống & Mạng máy tính Chú ý: Sinh viên phải dán tờ này vào trang nhất của bản thuyết trình HỌ VÀ TÊN: Lê Quang Khôi – Student ID: 2053151 Ngô Quang Nguyên – StudentID: 2053276 Lưu Trịnh Thiên – StudentID: 2053451 NGÀNH: Khoa học Máy tính LỚP: 1. Đầu đề luận án: Application of Blockchain Technology in Verification of Agriculture Products Identity. Nhiệm vụ (yêu cầu về nội dung và số liệu ban đầu): - To do research on blockchain technology - To apply blockchain technology to trace agricultural products with using Hyperledger. Ngày giao nhiệm vụ luận án: 22/01/2024 4.

Ngày hoàn thành nhiệm vụ: 07/06/2024 5. Họ tên giảng viên hướng dẫn: TS. Nguyễn Đức Thái Nội dung và yêu cầu LVTN đã được thông qua Bộ môn. Ngày 22 tháng 01 năm 2024 CHỦ NHIỆM BỘ MÔN GIẢNG VIÊN HƯỚNG DẪN CHÍNH (Ký và ghi rõ họ tên) (Ký và ghi rõ họ tên) TS.

Nguyễn Đức Thái TS. Nguyễn Đức Thái PHẦN DÀNH CHO KHOA, BỘ MÔN: Người duyệt (chấm sơ bộ): _______________________ Đơn vị: _______________________________________ Ngày bảo vệ: __________________________________ Điểm tổng kết: _________________________________ Nơi lưu trữ luận án: _____________________________ iii Declaration of Authorship We, Luu Trinh Thien, Ngo Quang Nguyen and Le Quang Khoi, declare that this project titled “Application of Blockchain technology in verification of agriculture products iden- tity” and the work presented in it are our own. We confirm that: • This work was done genuinely under the instruction of Dr. Nguyen Duc Thai.

• Where we have consulted the published work of others, this is always clearly at- tributed. • Where we have quoted from the work of others, the source is always given. With the exception of such quotations, this project is entirely my own work. • We have acknowledged all main sources of help.

• We will take full responsibility under any circumstances of content-related fraud or cheating in our group’s Specialized Project. Signed: Date: v HO CHI MINH UNIVERSITY OF TECHNOLOGY Abstract FACULTY OF COMPUTER SCIENCE AND ENGINEERING Department of Computer Science Application of Blockchain technology in verification of agriculture products identity by Luu Trinh Thien, Ngo Quang Nguyen and Le Quang Khoi Nowadays, counterfeit products has been a pressing and complicated challenge in today’s global marketplace. counterfeit products, often produced without acceptance to quality standards or property rights, pose significant risks to both consumers and businesses. One of the many kinds of products that easily get counterfeited is agriculture products, due to a lack of ways of verification.

In this project, we aim to leverage Blockchain technology to establish a secure and transparent system for the verification of agricultural product iden- tities. Traditional methods of verifying the origin and authenticity of agriculture products often lack transparency, traceability, and are easy to cheat. The proposed solution employs Blockchain’s decentralized to deal with these challenges. With these said statements, we will create a system that records every significant event in the life cycle of an agricultural product, from seeding to distribution.

Each participant in the supply chain, including farmers, distributors, retailers, and consumers, will have a unique cryptographic identity, ensuring traceability at every stage. The transparency of the Blockchain will allow consumers to access a record of the product’s journey, includ- ing information about the seeding process, certifications obtained, and transportation de- tails. This ensures that end-users can make good decisions based on accurate and verified data. By implementing a Blockchain-based verification system for agricultural products, the project aims to build trust among consumers, reduce fraud, enhance the efficiency of supply chain operations, and ultimately promote the overall integrity of the agricultural industry.

Keywords: Imitation goods, Blockchain technology, cryptographic identity vii Acknowledgements This specialized project was completed under the guidance of Dr. Nguyen Duc Thai, De- partment of Computer Science and Engineering, Ho Chi Minh city University of Technol- ogy. We would like to sincerely thank Dr. Nguyen Duc Thai for helping us with expertise, discussions, suggestions and facilitation convenient for us to complete the project.

We would also like to express our deep gratitude to the teachers of the Faculty of Com- puter Science and Engineering, Ho Chi Minh city University of Technology, who imparted professional knowledge, helped us to improve our learning and growing over the past time. Finally, we would like to express our sincere thanks to our families, who have always supported and encouraged us throughout the project. ix Contents Declaration of Authorship iii Abstract v Acknowledgements vii 1 Introduction 1 1.1 Website application development .2 Mobile application development .3 Front-end development .4 Front-end programming .1 The production units .2 The processing units .3 The distribution units. 16 User registration and authentication.

16 Verification of product identity. 16 Integration with Ethereum wallets .2 Non-Functional requirements. 17 Privacy and Compliance .1 System usecase diagram .4 Add wallet for authenticate .5 Create and update business information .6 Update product’s diary .3 Add wallet for authenticate .4 Create and update business information .5 Update product’s diary .1 Build private contract Hyperledger Fabric .2 Build public Blockchain for recording diary of products .2 Business’s Blockchain interaction .4 View, controller and database .2 Verify the JWT .1 Log out of all devices features .1 Introduction to Redis .2 Comparing Redis with Other Databases - Differences from RDBMS (relational database management system) .3 Comparing Redis with Other Databases - Differences from Other NoSQL Databases .2 Using hash function to hash the passwords .3 The problem of keeping private_key for users .1 Usage and Deployment .2 Enums and Structs .3 Constructor and Modifiers .2 The private key encryption .2 Create artifacts and running the network .3 Chaincode implementation and deploy .4 Fabric SDK in Nodejs .2 Sign in with wallet address .3 View and Update business information .4 Register new products .5 View and Update product diary .2 Update product diary .6 View history of transactions .7 Verify product by QR code. 99 10 Evaluation and Conclusion 101 10.1 Summary of Results .2 Challenges and troubles.

103 Reference 105 xv List of Figures 5.1 System Usecase diagram .2 Authenticate Usecase diagram .3 Authenticate Usecase description .4 Register Usecase diagram .5 Register Usecase description .6 Add wallet Usecase diagram .7 Add wallet Usecase description .8 Create and update information Usecase diagram .9 Create and update information Usecase description .10 Update product diary Usecase diagram .11 Update product diary Usecase description .12 Register product Usecase diagram .13 Register product Usecase description .14 Verify product Usecase diagram .15 Verify product Usecase description .16 Build contract Usecase diagram .17 Build contract Usecase description .18 Authenticate activity diagram .19 Register activity diagram .20 Add wallet activity diagram .21 Update information activity diagram .22 Update product diary activity diagram .23 Register product activity diagram .24 Verify product activity diagram .25 Build contract activity diagram .26 Architecture design for build private contract between two business .27 Architecture design for tracking product system .28 System class diagram .30 Business’s Blockchain interaction .32 View, controller and database .34 Verify the JWT .1 How Redis is typpcially used.3 How does an RSA work .1 The JWT’s content.2 The token is still valid .3 The JWT is blocked.4 Redis Cloud service.6 Send the image to the IPFS and recieve a CID.9 Running the network with docker .10 Create the channel with shell scripts .12 An example of our chaincode .13 Query a contract by stakeholder .14 Query a contract by its Id .1 Email and Password .3 Connect wallet page .4 Enter business information .6 View profile of a company .5 View business information .7 Update business information page .8 Register new product .11 Transfer ownership to other company .12 History of all transactions .14 Consumers view product on their phones .15 Consumers view product on their phones. 95 xvii List of Tables 6.1 Comparison between Redis and RDBMS .2 Comparison between Redis and NoSQL Databases .3 Comparison between Redis and Traditional database. 102 xix List of Abbreviations DApp Decentralized Application UX User Experience QR Quick Response EVM Ethereum Virtual Machine IPFS Interplanetary File System CID Content Identifier OTP One Time Password JWT JSON Web Token SDK Software Development Kit MSP Membership Service Provider RDBMS Relational Database Management System 1 Chapter 1 Introduction In today’s global marketplace, counterfeit products present a significant and complex chal- lenge. These products, often lacking adherence to quality standards and property rights, pose considerable risks to both consumers and businesses.

Agricultural products are par- ticularly susceptible to counterfeiting due to a lack of reliable verification methods. This project focuses on leveraging Blockchain technology to establish a secure and transpar- ent system for verifying the identities of agricultural products. Traditional methods of confirming the origin and authenticity of these products often lack transparency, trace- ability, and are vulnerable to manipulation. The proposed solution utilizes Blockchain’s decentralized nature to address these challenges.

The system will record every significant event in the life cycle of an agricultural product, from seeding to distribution. Each partici- pant in the supply chain, such as farmers, distributors, retailers, and consumers, will have a unique cryptographic identity, ensuring traceability at every stage. The transparency of the Blockchain will enable consumers to access a comprehensive record of the prod- uct’s journey, including information about the seeding process, certifications obtained, and transportation details. This ensures that end-users can make informed decisions based on accurate and verified data.

By implementing a Blockchain-based verification system for agricultural products, the project aims to build trust among consumers, reduce fraud, enhance the efficiency of supply chain operations, and ultimately promote the overall in- tegrity of the agricultural industry.1 Problem statement One of the biggest challenges when a consumer wants to buy a product is identifying the product’s origin. And tracking the product’s origin becomes more crucial when they are agricultural victuals which have a long supply chain, from breed level to processing unit, from manufacturer to distributor, and from retailers to end consumers. This kind of prod- uct plays a necessary role and could be the products usually consumed by the customers. However, with their long life on the supply chain, they become troublesome to control, and could be counterfeited.

Let’s go to an example, where we explain everything in a more intuitive way. Imagine a consumer - Lan wants to buy some vegetables for her family’s dinner. From gossiping with the housewives in her neighborhood, she knows that vegetables from the VNVG (an example business) have high quality but affordable prices. When she goes to the supermarket, she seems to be confused because there are a lot of vegetables with the VNVG brand and they have different prices for the same kind of vegetables.

This is the problem we mentioned above - the Counterfeit consumer goods. Even though there is only a product with the VNVG brand, that product has nothing to be sure it is from the original company- the VNVG.

Nội dung được bảo vệ bản quyền — Tải xuống đầy đủ