# A Smart-Contract Enabled Blockchain Traceability System Against Wine Supply Chain Counterfeiting

Sotiris P. Gayialis, Evripidis P. Kechagias, Georgios A. Papadopoulos, Elias Kanakis

<figure><img src="image_1.png" /></figure>

## To cite this version:

Sotiris P. Gayialis, Evripidis P. Kechagias, Georgios A. Papadopoulos, Elias Kanakis. A Smart-Contract Enabled Blockchain Traceability System Against Wine Supply Chain Counterfeiting. IFIP International Conference on Advances in Production Management Systems (APMS), Sep 2022, Gyeongju, South Korea. pp.477-484, 10.1007/978-3-031-16407-1_56. hal-05386128

HAL Id: hal-05386128

https://inria.hal.science/hal-05386128v1

Submitted on 27 Nov 2025

HAL is a multi-disciplinary open access archive for the deposit and dissemination of scientific research documents, whether they are published or not. The documents may come from teaching and research institutions in France or abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d'enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.

<figure><img src="image_2.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
<figure><img src="image_3.png" /></figure>

ifip

International Federation for Information Processing

This document is the original author manuscript of a paper submitted to an IFIP
conference proceedings or other IFIP publication by Springer Nature. As such, there
may be some differences in the official published version of the paper. Such
differences, if any, are usually due to reformatting during preparation for publication or
minor corrections made by the author(s) during final proofreading of the publication
manuscript.
# A Smart-Contract Enabled Blockchain Traceability System Against Wine Supply Chain Counterfeiting

Sotiris P. Gayialis<fnref n="1" />(✉) ID, Evripidis P. Kechagias<fnref n="1" /> ID, Georgios A. Papadopoulos<fnref n="1" /> ID, and Elias Kanakis²

**Abstract.** The need for effective traceability in the wine industry has dramatically increased in recent years due to the growing consumer awareness of the safety and the quality of products they buy. The loss of visibility as to the origin of a product can cause significant disruptions in the production and distribution of goods but also poses serious fraud risks. More specifically, bad or counterfeit wines may be produced and marketed when they can't be traced at all stages effectively. Fraud, such as adulteration with low-quality raw materials and wines, dilution, replacement of packaging contents and forgery of packages and labels, can be detected at the various stages of the wine supply chain. In order to combat wine supply chain counterfeiting blockchain technology has gained increased popularity as a means of enabling a secure traceability system. This paper presents the development of a smart-contracts-enabled blockchain traceability system that has been specifically designed for the wine supply chain and operates through the Ethereum Network.

**Keywords:** Blockchain · Ethereum · Smart contact · Traceability system · Counterfeiting · Alcoholic beverages · Wine supply chain

## 1 Introduction

Counterfeiting in the wine supply chain has always been and continues to remain a significant challenge for the stakeholders and the consumers. In addition to the severe health risks arising from fraudulent activities, emphasis should be laid on the adverse economic consequences for all wine supply chain stakeholders, i.e., cultivators, producers, distributors, wholesalers, retailers, etc. According to the European Commission's science and knowledge service [1], wine fraud costs the regular EU wine sector an estimated 1.3 billion euros per year, around 3% of the total sales value. In 2020, over one million liters of counterfeit alcoholic beverages were seized across Europe, increasing

<footnote n="1">¹ Sector of Industrial Management and Operational Research, School of Mechanical Engineering, National Technical University of Athens, 15772 Athens, Greece
{sotga,eurikechagias,gpapado}@mail.ntua.gr
² Entersoft S.A., 362 Sigrou Avenue, 17674 Athens, Greece
ekn@entersoft.gr</footnote>
to over 1.7 million in 2021 – the majority of which was wine – in targeted actions regularly led by the European Anti-Fraud Office (OLAF) as part of joint Europol-Interpol operations known as OPSON [2]. Apart from the economic impact of counterfeiting in spirits and wines, there are other effects such as job losses, which amount to 4800 per year [3]. To identify counterfeit wines, the findings of tests on suspicious wine samples are matched to data on real wine samples kept in the European Union Wine Databank. To achieve precise measurement data, analytical laboratories calibrate their results using a Certified Reference Material (CRM) [4]. However, the controls and checks by the public authorities can achieve limited success as they cannot detect the problem’s roots since they cannot trace the wine at various stages of their supply chain.

Determining the percentage of counterfeit wines is considered rather impossible as wines are included in the food and beverage sector, so the data available is not entirely clear. Also, the huge variety in this industry complicates things by highlighting the need for a more detailed industry fragmentation. In addition, exportable wines are often counterfeited within the borders of a country of production before export, making it difficult to detect the counterfeit. However, according to estimates by the World Health Organization, the proportion of counterfeit alcohol on the international market is estimated at around 25% of the total, especially in Southeast Asia and the Eastern Mediterranean, where unregistered alcohol consumption is around 50% or more than total alcohol consumption (45.4% in the Southeast Asia region, 70.5% in the Eastern Mediterranean region) [5].

This paper contributes to the scientific community as well as to the wine industry sector as it presents in detail the development of a smart-contract-enabled blockchain traceability system that has been specifically designed for the wine supply chain. The development of the system is based on a thorough study of the wine industry and the business processes of the wine supply chain, concluding with accurate design specifications. The proposed system operates through the Ethereum Main Net Network, and its various characteristics are presented in this paper. In Sect. 2, it is discussed how a blockchain traceability system can significantly reduce counterfeiting in the wine supply chain. Additionally, the way the system operates is explained, and its interaction with the wine supply stakeholders is shown. Section 3 of the paper presents how the traceability system is being developed by analyzing the required tools and including an indicative smart contract code of the first phase of development.

## 2 Applying Blockchain Technology in the Wine Supply Chain

All stakeholders can achieve significant benefits by implementing an effective blockchain traceability system [6]. More specifically, the cultivators and producers can improve the production quality of the wines and reduce or even eliminate the financial damage from the sale of products that do not meet the required specifications. At the same time, the distributors and sellers can achieve secure transportation, the government can ensure that all operations comply with policies and legislations, and the consumer can validate that the wine has not undergone any type of counterfeiting [7].
Many efforts have taken place aiming to combat the wine counterfeiting problem. However, most of them achieved limited success without holistically addressing traceability [8]. The most commonly faced challenges are i) the collection of data, in a secure way, from all parts of the wine supply chain and ii) the creation of non-copyable product labels that serve as the link between the physical products and the digital data [9–11]. This research, aiming to overcome the aforementioned challenges effectively, presents the development of a blockchain-based system that enables the stakeholders to detect all the information related to each individual bottle of wine, including a complete history of dates, locations, and sensor data. Additionally, the consumer can receive a one-of-its-kind digital wine passport that proves the origin and authenticity of the wine. In other words, the system can provide reverse control to each one of the stakeholders of the wine supply chain, from the cultivator to the final consumer, presenting all the authentic information related to the product and ensuring faster and safer transactions. Advanced technologies implemented for effective traceability cover three dimensions: i) secure data sharing using blockchain technology, ii) real-time data collection from the Internet of Things (IoT) sensors and enterprise systems directly transmitted to the blockchain

<figure><img src="image_4.png" /><figcaption>Fig. 1. Wine supply chain stakeholders’ interaction with the system</figcaption></figure>
system, and iii) reliable and secure data access through non-copyable labels. Figure 1 presents the interaction of the wine supply chain stakeholders with the blockchain-based system through the aforementioned technologies.

The exchange of all information between the different stakeholders throughout the supply chain will take place using a blockchain network without compromising privacy and security. IoT sensors will be used to collect the necessary data (humidity, temperature, location, etc.) at various stages of the wine supply chain in order to ensure the cultivation, production, and transportation conditions. A crucial part of fraud prevention will be the type of labels, placed on the bottle seals or packages for traceability and authentication. Various smart labels such as NFC tags, RFIDs, and engraved QR Codes will enable access to the bottle's info. The labels will also include advanced marking techniques such as tamper-evident labels, 2D and 3D holograms, digital watermarks, color-shift inks, or invisible printing that will prevent copying or cloning. The increased counterfeiting protection will be achieved by combining smart labels with data veracity control measures (e.g., third-party certification bodies) and short data entry frequency (the time lag between the moment the event occurs and the moment when the related information is written on the blockchain ledger).

Figure 2 presents a sample use case scenario for a wine bottle that moves between the producer, the wholesaler/retailer and the consumer. After each bottle is produced, it receives a unique encrypted bottle identifier (smart label) and is linked to a digital passport that contains all info related to that specific bottle. The digital passport can provide proof of authenticity, provenance, ownership & access to special contents such as info related to the production, sale and transportation that can be added by all involved stakeholders. Each time the bottle moves to another wine supply chain stakeholder, its authenticity is verified, the digital ownership is transferred, and sale and transportation data are added. Involved stakeholders and consumers can, therefore, trace the bottle's supply chain. When the bottle is sold to a consumer, the smart label can be scanned in order to verify its authenticity, provenance, receive a digital ownership certificate and "burn" the bottle in order to show it has now been consumed.

<figure><img src="image_5.png" /><figcaption>Fig. 2. Sample use case scenario</figcaption></figure>
## 3 Developing the Blockchain Traceability System

To address the issue of traceability in the wine supply chain, the Ethereum Main Net blockchain network was selected to take advantage of the transparency and decentralized character it offers. The Ethereum network is perhaps the most well-known public blockchain network. Developed in 2015, it is open-source and has been developed specifically for the easy development and implementation of smart contracts [12]. The Smart Contract can be considered a digitized real world contract. It is a code (small program) uploaded to a blockchain network and is executed automatically when certain specific prerequisites are met. When a smart contract is created, it can never be altered. Ethereum has its own cryptocurrency called Ether, which facilitates the transactions of smart contracts since it is integrated into the network. The main advantage of Ethereum is the built-in programming language called Solidity, which has been developed for smart contract applications and is Turing Complete. The cryptocurrency from which it is powered and on which the Ethereum network operates is Ether which is used as “ETH”. When each user sends ETH or uses an Ethereum application, they pay a gas fee in “gwei” (10-9 ETH) to use the Ethereum network. This end is an incentive for a miner to process and verify what the user is trying to accomplish.

<table><caption>Table 1. Indicative smart contract for the wine producer</caption><thead><tr><th>Smart Contract's Variables Definition</th><th colspan="2">Smart Contract's Functions</th></tr></thead><tbody><tr><td><pre><code>pragma solidity 0.4.26;</code></pre><pre><code>contract ProducerData { address admin; struct Item { uint code; uint burncode; uint8 unittype; uint itemsincontainers; uint rawmaterialcode; string lotnumber; uint productiondate; uint bestbeforedate; uint gln; string info1; bool status; }</code></pre><pre><code>mapping(uint => Item) itemArray; uint count;</code></pre><pre><code>constructor() public { admin = msg sender; count = 0; }</code></pre></td><td><pre><code>function insertItem( uint code, uint burncode, uint8 unittype, uint itemsincontainers, string lotnumber, uint productiondate, uint bestbeforedate, uint gln, string info1, bool status) public restricted { itemArray(code) = Item( code, burncode, unittype, itemsincontainers, rawmaterialcode, lotnumber, productiondate, bestbeforedate, gln, info1, status); count++ }</code></pre><pre><code>function getCount() public restricted view returns (uint) { return count; }</code></pre><pre><code>function STATUS() public view returns (bool, string) {</code></pre></td><td><pre><code>function burnItem(uint code, uint burncode) public { uint tempcode = itemAr- ray(code).burncode; if (tempcode == burncode) { itemArray(code).status = false; } }</code></pre><pre><code>function infoItem(uint code) public view returns (uint8, uint, uint, string, uint, uint, uint) { return ( itemArray(code).unittype, itemAr- ray(code).itemsincontainers, itemAr- ray(code).rawmaterialcode, itemArray(code).lotnumber, itemArray(code).productiondate, itemArray(code).bestbeforedate, itemArray(code).gln); }</code></pre><pre><code>modifier restricted() { require(msg sender == admin); _; }</code></pre></td></tr></tbody></table>

The code of an indicative smart contract containing wine producers' data and functions is presented in Table 1. The first column of the table includes the tested compiler
version and the definition of the variables. The remaining two columns present the smart contract functions and the access modifier. This is just an indicative presentation of the code for demonstration purposes, as many more variables, functions, and stakeholder contracts are necessary for creating the fully functional traceability system.

Additionally, a brief overview of the technological solutions that are part of the blockchain traceability system is presented in Fig. 3. The truffle framework/toolset is used to develop the blockchain traceability system. It is a development toolset based on Ethereum Blockchain, which is used to create DApps (Distributed Applications), i.e., applications structured in the decentralized network through a blockchain server. It allows the development, compiling, testing, and deployment of smart contracts, their penetration into web apps, and the front-end configuration for apps. Ganache, a local personal Ethereum network, is used to test smart contracts before deploying them to the Ethereum Main Net. The users connect to the network through the React Javascript library, used to create the system's user interface, while the Web3.js library collection allows communication with a local or remote Ethereum node using HTTP, IPC or Web-Socket. In order for the user to connect to the blockchain server, it is necessary to have a metamask account, a wallet which enables users through a web browser/application, to manage their ETHs and interact with Dapps.

Finally, Etherscan.io, a blockchain explorer is used to give the user access to data from the Ethereum platform. It is a search engine through which the user can monitor the Dapp in real-time by receiving information about the transactions that take place, the smart contracts as well as the costs of any transaction (gas fees).

<figure><img src="image_6.png" /><figcaption>Fig. 3. Technologies used for developing the blockchain traceability system</figcaption></figure>
# 4 Conclusions

The paper presented ongoing research for the development of a blockchain-based traceability system against counterfeiting in the wine supply chain. After analyzing what technologies are needed and how the system should operate and interact with the supply chain stakeholders, the methodology and the technological tools for developing the system in the Ethereum network were analyzed. The system's first version has been developed as a Dapp based on smart contracts. An indicative smart contract code for the producer's data was also presented in this paper. As it becomes clear from this research, blockchain can become a valuable aid in order to effectively combat the wine supply chain counterfeiting that has severe health and economic consequences. In the next steps of the research, the system will enter its final development phase utilizing all the necessary tools presented in this paper. Afterwards, the system will be tested, in real-life conditions, in wineries and their partners in the supply chain (cultivators, distributors, transporters, wholesalers, retail stores). After testing the system in the wine supply chain, improvements will be made in order to release its final version.

**Acknowledgements.** The present work is co-funded by the European Union and Greek national funds through the Operational Program "Competitiveness, Entrepreneurship and Innovation" (EPANΕΚ), under the call "RESEARCH - CREATE - INNOVATE" (project code: T2EDK - 00508 and Acronym: COUNTERBLOCK).

# References

1. OECD/EUIPO: Trends in Trade in Counterfeit and Pirated Goods (2019)

2. OLAF: Over 1 million litres of wine and alcoholic beverages seized under OLAF-led operation, Brussels, Belgium (2021)

3. EURACTIV: Fake wines and spirits cost the EU 'at least' 4,800 jobs per year, Brussels, Belgium (2016)

4. Donarski, J., Camin, F., Fauhl-Hassek, C., Posey, R., Sudnik, M.: Sampling guidelines for building and curating food authenticity databases. Trends Food Sci. Technol. **90**, 187–193 (2019). https://doi.org/10.1016/j.tifs.2019.02.019

5. Hammer, J.H., Parent, M.C., Spiker, D.A.: World Health Organization: Global status report on alcohol and health 2018 (2018)

6. Brookbanks, M., Parry, G.: The impact of a blockchain platform on trust in established relationships: a case study of wine supply chains. Supply Chain Manag. Int. J. **27**, 128–146 (2022). https://doi.org/10.1108/SCM-05-2021-0227

7. Li, K., Lee, J.-Y., Gharehgozli, A.: Blockchain in food supply chains: a literature review and synthesis analysis of platforms, benefits and challenges. Int. J. Prod. Res., 1–20 (2021). https://doi.org/10.1080/00207543.2021.1970849

8. Shwetha, A.N., Prabodh, C.P.: A comprehensive review of blockchain based solutions in food supply chain management. In: 2021 5th International Conference on Computing Methodologies and Communication (ICCMC), pp. 519–525. IEEE (2021)

9. Jabbar, S., Lloyd, H., Hammoudeh, M., Adebisi, B., Raza, U.: Blockchain-enabled supply chain: analysis, challenges, and future directions. Multimedia Syst. **27**(4), 787–806 (2020). https://doi.org/10.1007/s00530-020-00687-0
10. Wu, H., et al.: Data management in supply chain using blockchain: challenges and a case study. In: 2019 28th International Conference on Computer Communication and Networks (ICCCN), pp. 1–8. IEEE (2019)

11. Dutta, P., Choi, T.-M., Somani, S., Butala, R.: Blockchain technology in supply chain operations: applications, challenges and research opportunities. Transp. Res. Part E Logist. Transp. Rev. **142**, 102067 (2020). https://doi.org/10.1016/j.tre.2020.102067

12. Sujeetha, R., Deiva Preetha, C.A.S.: A literature survey on smart contract testing and analysis for smart contract based blockchain application development. In: 2021 2nd International Conference on Smart Electronics and Communication (ICOSEC), pp. 378–385. IEEE (2021)