Drug Traceability in Supply Chain of Healthcare Using Block chain-Based Approach

The supply chain for healthcare is an intricate web of interconnected businesses that includes manufacturers, pharmacies, hospitals, patients and suppliers of raw materials. Due to a number of issues, such as centralized control, conflicting stakeholder conduct, and a lack of information, tracking supply across this network is difficult. In addition to creating inefficiencies like those brought to light by the COVID-19 pandemic [1], this complexity can make it more difficult to mitigate the problem of counterfeit pharmaceuticals because they can quickly infiltrate the healthcare supply chain. Drugs that are intentionally manufactured fraudulently and/or mislabeled with regard to identity and/or source in order to pass for authentic goods are known as counterfeit drugs[2][3]. These prescriptions may include those with no active pharmaceutical ingredient (API), the wrong dosage, the wrong kind of API, a pollutants, or repackaged goods that has expired. It is possible for certain fake drugs to be manufactured under unsatisfactory circumstances and with improper formulations [4].


INTRODUCTION
The Health Research Funding Organisation estimates that up to 30% of medications supplied in developing nations are fake [5] [6].Furthermore, a recent study conducted by the World Health Organisation (WHO) revealed that fake pharmaceuticals are a leading cause of death in underdeveloped nations, with children being the majority of victims [7] [8].The pharmaceutical sector suffers enormous financial losses as a result of counterfeit pharmaceuticals, in addition to their detrimental effects on human life.Accordingly, it is estimated that the US pharmaceutical business loses $200 billion annually as a result of counterfeit medications [9] [10].Figure 1 depicts a typical medicine supply chain distribution procedure.Providing the raw materials needed to make medications that have been approved by regulatory bodies like the US Food and Drug Administration (USFDA) is the responsibility of an API provider.The medications are sent to a repackager or put into a lot by the manufacturer.Upon receiving many lots of the product, the primary distributor is incharge of distributing them to pharmacies in accordance with market demand.If there are too many lots, secondary distributors may be able to assist with the transfer of lots to pharmacies.Lastly, a pharmacy will give patients their medication [11], usually in accordance with a prescription from a doctor.

Figure1: Stake holders in the drug supply chain and their interactions
Drugs are typically transferred along the supply chain by independent logistics service companies like UPS or FedEx, and distributors occasionally use their own fleet of cars to deliver the goods.The intricate framework of the healthcare supply chain is the main cause of counterfeit medications finding their way into the end-user marketplace.Medication can easily go via this distribution mechanism with little to no information trail and substantiated documentation thanks to its intricacy [12].Therefore, the key to preventing counterfeit goods in the healthcare supply chain is constant product monitoring, efficient management, and tracking.A new paradigm for developing applications has been brought about by block chain technology, and it is mostly based on the data structure's successful implementation in the Bit coin application.The block chain data structure's basic idea is comparable to that of a linked list; that is, all nodes in the network share it, and each node maintains a local copy of every block (those linked to the longest chain) beginning with its genesis block [15].A wide range of real-world applications, including those for the Internet of Things [16], e-Government [17], and e-document management [18], have been developed recently.Due to the self-cryptographic validation structure among transactions (by hashes) and the public availability of a distributed ledger of transaction records in a peer-to-peer network, these applications take advantage of the advantages of block chain technology.One of the early attempts at block chain-based pharmaceutical supply chain tracing is presented in [20].Despite the fact that our solution and we take a comprehensive approach to the pharmaceutical supply chain and provide an end-to-end solution for drug traceability, previously [20] only concentrated on a portion of these issues.This is possible because of the focus on the pharmaceutical supply chain and the usage of block chains.First off, whereas [20] only includes the supplier, manufacturer, and wholesaler as stakeholders, our method identifies and involves all significant players in the drug supply chain, including the FDA, supplier, manufacturer, distributor, pharmacy, and patient.Consequently, unlike in a true drug supply, the chemists are shown as an external entity.Thirdly, we minimize human intervention and hence undesirable delays by using smart tracts technology to offer real-time, seamless traceability with push notifications.To be more precise, every drug lot is given a distinct smart contract that, in the case of a change in ownership, creates an event and sends the D App user a list of those events.But [20]'s smart contracts are configured for particular functions, such manufacturer, distributor, and supplier, necessitating manual confirmation from each party of which medications are received.This method may cause errors and delays in the unchangeable data that is kept on the ledger.Lastly, in order to assess the effectiveness of the suggested solution, we carried out a cost and security analysis and talked about how the suggested solution can within the pharmaceutical industry, numerous attempts have been undertaken to address the well-established difficulty of achieving traceability to mitigate against counterfeit pharmaceuticals.Nonetheless, a thorough examination of the literature reveals a number of shortcomings and possibilities for a thorough implementation of block chain technology for medication traceability.
The main contributions of this essay in this context can be summed up as follows. Many initiatives have been made in the pharmaceutical sector to address the well-known challenge of attaining traceability to protect against counterfeit medications.However, a careful review of the literature identifies a number of drawbacks and opportunities for a comprehensive application of block chain technology for pharmaceutical traceability.The following succinctly describes the primary contributions of this essay in this context. We create a smart contract that can manage different stakeholder transactions in the pharmaceutical supply chain. We introduce, put into practice, and evaluate the smart contract that outlines the fundamentals of our suggested course of action. We analyze costs and security to assess how well the suggested block chain-based solution performs.

RELATED WORK
We present a critical overview of existing efforts focused at addressing the issue of product traceability in the healthcare supply chain emphasizing solutions proposed for anti-counterfeiting.We have included both block chain and non-block chain-based approaches and categorized them accordingly A.
Usual Methods To Ensure Drug Traceability Traceability can be described as the capacity to obtain any or all information about an object during its lifecycle through documented identifications.Any traceable object throughout the supply chain is the subject of discussion and is known as a Traceable Resource Unit (TRU).There are two goals for traceability: monitoring the transaction history and the TRU's current location.In this situation, a traceability system needs to be able to obtain data about the medication that is the TRU in the supply chain in order to record it identify and set it apart from other TRUs.This is done by employing several identification approaches.a mechanism for documenting the connections between TRUs, and a mechanism for recording the attributes of the TRUs [21].Traditional supply chain management solutions have employed RFID tags and barcodes for identification, Wireless Sensor Networks (WSN) for data capture, and Electronic Product Codes (EPC) for product identification, capture, and sharing to enable the tracking of goods through various stages [22].In this situation, GS1 standards barcodes with unique serialized product identifiers, lot production dates, and expiration dates are used by Smart-Track [23].The GS1 barcode's data is collected during a number of supply chain operations and utilized to keep an ongoing record of ownership transfers.An end user (patient) can utilize a smart phone app to confirm authenticity through a central data repository maintained by the Global Data Synchronization Network (GDSN) as each stakeholder records possession of the product.Pharmacy and hospital units can scan the barcode at the warehouse in the downstream supply chain to confirm the product's characteristics.Similar to this, the Data-Matrix tracking system [24] generates a Data-Matrix for every medication that contains the following information: the product and manufacturer IDs, the package's unique ID, the authentication code, and any optional meta-data.This enables the patient to use the Data-Matrix that is attached to confirm the drug's provenance.

B. DRUG TRACEABILITY SOLUTIONS BASED ON BLOCKCHAIN
Conventional approaches to pharmaceutical supply chain traceability are usually centralized and lack openness among chain partners, allowing the central authority to change information without informing other stakeholders.A block chain-based system, on the other hand, provides provenance, data security, transparency, immutability, and authenticated transaction records.Block chain is an immutable, decentralized shared ledger that can be used in many different types of transaction-based business environments.Although the terms transparency and traceability are frequently used synonymously, they signify quite different ideas.Transparency is typically used to describe high-level supply chain information.For instance, the names of suppliers, the locations of facilities, the components of the product, etc., with the goal of mapping the entire supply chain.But traceability is tied to specifics; it considers picking a particular component to track, deciding on mutual protocols for corresponding with partners, putting procedures in place to generate and collect precise data, picking a platform to store traceability data on, and figuring out how to distribute data on the platform.Despite the fact that the two names refer to distinct ideas, they are mutually dependent since a thorough grasp of the supply chain is necessary to obtain detailed information.To this end, several current methods make use of the cryptographic features of block chain to create a verifiable, decentralized track and trace system for prescription medications.Without providing any technical information or particular application, Mettler [32] has talked of using a block chain-based solution to address a variety of healthcare-related concerns.The benefits of block chain technology in the pharmaceutical supply chain were discussed by Kurki [33].But much like in [32],there was simply conceptual discussion offered.Muni and yand OngTzeErn [20] suggested utilizing Ethereum for a traceability system in order to combat counterfeiting.The suggested solution makes use of smart contracts, but it is neither implemented or evaluated, which makes it difficult to fully comprehend its contribution.A drug traceability system called Drug ledger was proposed by Huang et al. [34].It creates both the authenticity and privacy of stakeholders' traceability information without compromising the system's robustness, and it reflects the actual drug transaction logic in the supply chain.Drug ledger uses the enlarged UTXO data structure, particularly the package, repackage, and unpackage sections, to complete its workflow.UTXO data structures are programmable, but their low state space utilization, high storage costs, and lack in programmability have raised worries about their application, as evidenced by recent research like [35].AHyperledger-basedapproachformedicationtraceabilityinthepharmaceuticalsupplychainwas presented by Faisal et al. [36].The authors indicate that the suggested system performs better in terms of throughput and minimizes delay with reduced resource consumption; however, their solution was only evaluated in a small-scale network and was not thoroughly tested.This endeavour also brought to light the difficulty in using block chain technology to achieve scalable solutions, a topic that has drawn a lot of attention recently in publications like [22].Similar reservations apply to the strategy employed by Hulseap-ple [38], who created a private block chain in tandem with Bit coin and uses it as a ledger to hash certain data in order to safeguard chain transactions.On their block chain, each thing has a permanent record that makes it.

C. DRUG TRACEABILITY SYSTEM BASED ON BLOCKCHAIN FOR PHARMACEUTICAL
SUPPLY CHAINS A high-level architecture for the suggested medication traceability system, together with the stakeholders and how they interact with the smart contract, are shown in Figure 2. Through software devices with a front-end layer denoted by a D App (Decentralized Application), which is connected to the smart contract, on-chain resources, and decentralized storage system by an application program interface (API) like Infura, the stakeholders are envisaged to have access to the smart contract, decentralized storage system, and on-chain resources.

FIGURE 2. A high-level architecture for the proposed block chain-based system for pharmaceutical supply chain
Web3, and JSON RPC.The stakeholders will interact with the smart contract to initiate pre-authorized function calls and with the decentralized storage systems to access data files.Finally, their interaction with the on-chain resources will be for obtaining information such as logs, IPFS hashes, and transactions.More details on the system components are presented below. Regulatory organizations like the FDA, producers, distributors, pharmacies, and patients are examples of stakeholders.Based on their position in the supply chain, these stakeholders participate in the smart contract and are given specialized roles.Additionally, in order to track supply chain transactions, they are granted access to on-chain resources including history and log information.They also have permission to view data kept on the IPFS, including informational pamphlets and photos of drug lots. The IPFS (Decentralised Storage System) offers an inexpensive off-chain storage solution for storing data related to supply chain transactions.This ensures the integrity, dependability, and accessibility of the stored data.Every uploaded file on the server generates a unique hash, which is used to maintain data integrity.The various hashes for the various uploaded files are then stored on the block chain and accessed via the smart contract.Any modifications made to any uploaded file are reflected in the corresponding hash.
 Implementation of the supply chain is managed by Ethereum Smart Contract.In order to trace the history of transactions and handle hashes from the decentralized storage server that gives participants access to supply chain data, the smart contract is vital to the process.In addition, the smart contract defines the roles of the various supply chain players, and modifiers are used to grant authorized . In-chain the logs and events produced by the smart contract, which enable track and trace, are kept in resources.Additionally, a decentralized registration and identity system is Employed as a non-chain resource to link each participant's Ethereum address to a human-readable text.Since the D App user will only need to use the proposed solution to confirm that the drug under consideration is not counterfeit and came from a reputable manufacturer, no real-time tracking willbenecessaryasthesystemcomponentsareintendedtoworktogetherseamlesslytotrackthe history of the drug under consideration to verify its authenticity.There are various methods that can be used to track the real-time position of a drug lot.IoT-enabled smart containers, for instance, have sensors that follow and continually monitor the TRU from its beginning location to its destination.The Internet of Things sensor comprises a temperature sensor and a Global Positioning System (GPS) receiver to determine the TRU's location.
Figure3 illustrates interaction among different participants of the supply chain within proposed system and can be loosely divided into three phases explained below.
Manufacturing: To begin the process of manufacturing a drug lot, a manufacturer usually sends an FDA approval request.The producer starts the manufacturing process as soon as the FDA grants approval for the request, and everyone involved is informed of the occurrence photographs of the medication Lot will be uploaded by the manufacturer to the IPFS, which will then send a hash to the smart contract so that authorized parties can view the photographs at a later time.The medication lot will be shipped to the distributor, who will package it, bringing the production process to an end.Distribution: The distribution procedure will now begin.The distributor will package the medication lot and upload a picture of it to the IPFS, which will provide a hash to the smart contract.The distribution phase will come to an end when the drug lot packages are distributed to pharmacies.Purchase/Usage The contact between the pharmacist and the patient is the subject of the final stage in the sequence diagram.Here, the pharmacy will start selling drug lot boxes and notify all supply chain participants of the sale.Next, a picture of the drug package that was sold will be posted to the IPFS, and the IPFS will send a hash to.

IMPLEMENTATION OF PROPOSED TRACEABILITY SYSTEM
The Ethereum block chain platform is utilized in the development of the suggested solution.Since Ethereum is a permissionless public block chain, everyone can access it.Remix IDE is used to compile and test the Solidity-written smart contract.Remix is an online web-based development environment that lets users create and run smart contract scripts as well as test and debug the Solidity code's environment.The entire code1 is now accessible to the general audience.

CONCLUSION
In this paper, investigated the challenge of drug traceability within pharmaceutical supply chains highlighting its significance specially to protect against counterfeit drugs.We have developed and evaluated a block chain-based solution for the pharmaceutical supply chain to track and trace drugs in a decentralized manner.Specifically, our proposed solution leverages cryptographic fundamentals underlying block chain technology to achieve tamper-proof logs of events within the supply chain and utilizes smart contracts within Ethereum block chain to achieve automated recording of events that are accessible to all participating stakeholders.Demonstrated that our proposed solution is cost efficient in terms of the amount of gas spent in executing the different functions that are triggered within the smart contract .Moreover, the conducted security analysis has shown that our proposed solution achieves protection against malicious attempts targeting is integrity, availability and non repudiation of transaction data which is critical in a complex multi-party settings such as the pharmaceutical supply chain.Continue our efforts to enhance the efficiency of pharmaceutical supply chains and envision to focus on extending the proposed system to achieve end to end transparency and verifiability of drugs use as future work.

Figure4
Figure4: System Architecture Modules Pharmacy Seller