Financial Contract Administration in Construction via Cryptocurrency Blockchain and Smart Contract: A Proof of Concept

: The blockchain that uses cryptocurrency is a paradigm shift in the way of data storage, retrieval, and veriﬁcation due to the concept of decentralization. This paradigm is essential to ensure the security of crucial data in any project. Adding a smart contract to the blockchain would facilitate the automation of various processes. Thus, the cryptocurrency blockchain that uses the smart contract can be considered a suitable platform for an ecosystem of many industries. The construction industry needs a highly secure automated management system due to its complex contractual relationships and transactions between parties. Therefore, integrating the blockchain with the smart contract creates the most appropriate ecosystem to be developed. This study introduces an ecosystemic prototype using a programmable smart contract within a novel cryptocurrency blockchain for construction. The purpose of the prototype is to guarantee a decentralized system as an independent economic environment for the construction industry. The system guarantees the security of ﬁnancial transactions and focuses on the payment clauses in the construction contract as well. The results depended on three well-known hypothetical case scenarios from the construction site and were displayed in the form of extracted access data tables. The prototype proved the efﬁciency of the decentralized system for the construction industry by minimizing human-factor interference in the transaction process and thus reducing time waste and cost.


Introduction
In 2009, a global financial crisis occurred due to several causes, mainly due to the role played by banks in the centralization system of financial institutes [1].As a result of this financial crisis, people's trust in the centralized system was drastically affected.As the main disadvantage of a centralized system is that only one dominant agent is assigned to link others.This assignment is made to organize the transactions between the agents.A centralized system leads to an uncontrollable fee and time process because of the changing rules of transactions by the intuition of the dominant agent [2,3].In 2008, Satoshi Nakamoto [4] predicted the centralized system crisis and suggested moving into a decentralized system, leading to the creation of Bitcoin [5].Bitcoin is a cryptocurrency used for financial transactions, managed and handled by a system called a blockchain.

Blockchain, Smart Contract, and Cryptocurrency Mechanism
The importance of blockchain technology is the security of data for the distributed ledgers among participants, such as transactions inside the decentralized system [6].The blockchain has a hashing security technique that makes the decentralized system a safe environment for data security [7].In addition, time-stamping in the hashing system is the linchpin of the security of digital data [6].Thus, the cryptographic system, a computer system that utilizes cryptography to secure information and communications by operating computer codes, of the blockchain creates a high-security environment for crucial documents.As a result, blockchain has overcome the weaknesses of the centralized system.
The emergence of blockchain in Bitcoin came within the technology of decentralization recording ledger that guarantees security [8].These records are used for the confirmation of transactions for the financial activities that are stored inside blocks.The block is added to the system by the mining processes, the procedure of adding transactions to the substantial distributed general ledger of existing transactions (i.e., the blockchain) where complex calculations are performed by the users as miners.The mining process is an indication for the confirmation of transactions that represents the users' witnesses of them.These confirmations are necessary for the contract administration activities, which make the records more resilient and transparent.Subsequently, and due to the block mining, the transaction is recorded inside the block.The organization of the clashes resulting from the crowded transactions is operated by the time-stamping technology [6].This organization leads to the blocks' mining for the longest path of the block chaining.The miner creates the block by complex calculations using processors, and once the block is created, the miner will be awarded a cryptocurrency bonus.The bonus motivates the users such as owners and stockholders to use the system and raises the value of the cryptocurrency due to its frequent use.This mining process is also called "proof of work" as the bonus proof of the mining activity [5].As soon as the block is created and added to the system, this block will be connected to the other blocks by using cryptographic links that rely on a hashing technique.Hashing is a security tool that integrates with the generation of blocks [9,10].Figure 1a illustrates the hashing technique named SHA-256.The newborn block has its own hashing that is linked with older block hashing.Once any attacker tries to change the data in this block, the hash changes in the manipulated block, and the difference resulting from manipulation in the hash will be detected, as clearly shown in Figure 1b.This hashing linking strategy helps the blockchain obtain security as a consequence of the elimination of the dominant agent's role.
The cryptocurrency blockchain is a system of the blockchain in which the block contains transactions for digital currency instead of data [11].Numerous platforms produced cryptocurrencies such as Bitcoin, Ether, Litecoin, etc.Some of these platforms (e.g., Ethereum) were developed to use smart contracts.Blockchain is not only limited to financial transactions but also can be used as a multi-tasking platform.As a result, it can be transformed into a programmable platform that can include a set of programs such as smart contracts.Thus, any program can be coded inside a block that is distributed among the blockchain users.The term of the contract comes from the agreement of all users to run the program simultaneously through the blockchain distribution system.The coded program is immutable to changes by the security system of the blockchain [2,12].As a result of these properties, blockchain and smart contracts have been used in many complex industries [13], such as medical [14,15], energy [16,17], and insurance [18], as well as construction .

Blockchain, Smart Contract, and Cryptocurrency in Construction Industry
In the construction industry, the contractual parties (i.e., owner, consultants, main contractors, subcontractors, and suppliers) and the documents are extremely complex in their types and procedures [19].In addition, the workflow of the construction industry is changeable and challenging during different construction phases [20].Thus, the blockchain is a suitable technique that can be used to overcome these challenges.Through blockchain, the parties can be represented as users, and the transactions can be expressed in numerous shapes such as documents, materials, and financial flow.Particularly, the financial transaction is the most important of these transactions, making it a promising research field for cryptocurrency.

Blockchain, Smart Contract, and Cryptocurrency in Construction Industry
In the construction industry, the contractual parties (i.e., owner, consultants, main contractors, subcontractors, and suppliers) and the documents are extremely complex in their types and procedures [19].In addition, the workflow of the construction industry is changeable and challenging during different construction phases [20].Thus, the blockchain is a suitable technique that can be used to overcome these challenges.Through blockchain, the parties can be represented as users, and the transactions can be expressed in numerous shapes such as documents, materials, and financial flow.Particularly, the financial transaction is the most important of these transactions, making it a promising research field for cryptocurrency.
Several studies showed the potential for using the blockchain and smart contracts in the construction industry (Table 1).J. Mason [21] used blockchain and smart contracts in Building Information Modeling (BIM) to represent document modeling at different levels of complexity and coordination of clashes.Some of these clashes were a result of management issues arising from several questions, for example: Who owned the model?How to modify the model in the construction industry?and so on.J. H. Yoon and P. Pishdad-Bozorgi [22] concluded that blockchain and smart contracts were most commonly used in construction supply chain management.Z. Wang et al. [23] developed a framework to cover the poor traceability and real-time information leakage in the precast concrete supply chain.A. Tezel et al. [24] developed an empirical discussion model by Ethereum that dealt with: project bank accounts, reverse auction-based tendering for bidders and asset tokenization for project financing.The validation for this model was tested and ensured by the feedback of three workshop groups but not applied to real-life implementation.Several studies showed the potential for using the blockchain and smart contracts in the construction industry (Table 1).J. Mason [21] used blockchain and smart contracts in Building Information Modeling (BIM) to represent document modeling at different levels of complexity and coordination of clashes.Some of these clashes were a result of management issues arising from several questions, for example: Who owned the model?How to modify the model in the construction industry?and so on.J. H. Yoon and P. Pishdad-Bozorgi [22] concluded that blockchain and smart contracts were most commonly used in construction supply chain management.Z. Wang et al. [23] developed a framework to cover the poor traceability and real-time information leakage in the precast concrete supply chain.A. Tezel et al. [24] developed an empirical discussion model by Ethereum that dealt with: project bank accounts, reverse auction-based tendering for bidders and asset tokenization for project financing.The validation for this model was tested and ensured by the feedback of three workshop groups but not applied to real-life implementation.Amer A. Hijazi et al. [25] integrated BIM and supply chain management to support reliable digital deliverables and to transfer values in construction supply chain applications.Furthermore, smart contracts and blockchain were used to generate a structured framework for the financial transactions in the construction industry.F. Elghaish et al. [26] developed a financial model using the Hyperledger network (IBM ® Blockchain Cloud Beta 2).Then, M. Das et al. [27] improved this model by covering cost reimbursements, profits, and cost savings through integrated project delivery (IPD) for the architecture, engineering, and construction (AEC) industry.In addition, M. Das et al. [27] used the Ethereum platform for smart contracts, which used the contract's terms and conditions related to the interim payment in construction.Although smart contracts and blockchain were employed in several fields in the construction industry, limited studies employed them in construction contract management and administration [28].Charles Shen and Feniosky Pena-Mora [29] discussed the ability to use smart contracts and blockchain not only in cryptocurrency but also in everything such as contract management in governmental agenda for decisionmaking.Furthermore, Srinath Perera et al. [30] proposed their utilization in the framework of contract administration for the payment according to time, cost, and quality related to the construction supply chain.As shown in Table 1, several studies presented potential frameworks compared to fewer studies that presented actual applications, which makes room for improvement and development.Figure 2 shows the summary of publications retrieved from the Scopus database related to the blockchain and smart contracts in the construction industry throughout the previous four years.According to Figure 2, the trend in blockchain and smart contracts is rocketing up.Thus, blockchain and smart contracts are highly predicted to be a viral research discipline in the construction industry in the coming years.

Research Problem
One of the crucial processes in construction projects is contract administration.On account of that, the way the administration works may lead to huge cost overruns and time waste.In practice, the contract is often created by the owner's contract engineer, and this provides an advantage for the owner to be a centralized agent.After agreement sealing, the contract will be administrated by the contract engineer of the owner and the contractor.Although the contract in this situation is created to meet a win-win situation, the human factor in the administration will exploit and cause defects in the contract conditions due to manipulations.This manipulation will convert the situation into a win-lose situation or even a lose-lose situation [47].Thus, the effectiveness of the contract administration is much observed in the financial transactions, and consequently, the inaccurate administration of the financial processes leads to cost and time loss.In addition, poor administration can delay the invoices in the review process and payment because of the individual contract party's administration and centralizing of the system to the owner's contract administrator.This causes the need for a fourth trusted party for contract administration and to eliminate the human manipulation factor in contracts' manipulations as well.

Research Aim and Objective
This research aims to create a resilient, transparent, synchronized, and traceable platform to minimize the human manipulation factor in construction contract administration.

Research Problem
One of the crucial processes in construction projects is contract administration.On account of that, the way the administration works may lead to huge cost overruns and time waste.In practice, the contract is often created by the owner's contract engineer, and this provides an advantage for the owner to be a centralized agent.After agreement sealing, the contract will be administrated by the contract engineer of the owner and the contractor.Although the contract in this situation is created to meet a win-win situation, the human factor in the administration will exploit and cause defects in the contract conditions due to manipulations.This manipulation will convert the situation into a win-lose situation or even a lose-lose situation [47].Thus, the effectiveness of the contract administration is much observed in the financial transactions, and consequently, the inaccurate administration of the financial processes leads to cost and time loss.In addition, poor administration can delay the invoices in the review process and payment because of the individual contract party's administration and centralizing of the system to the owner's contract administrator.This causes the need for a fourth trusted party for contract administration and to eliminate the human manipulation factor in contracts' manipulations as well.

Research Aim and Objective
This research aims to create a resilient, transparent, synchronized, and traceable platform to minimize the human manipulation factor in construction contract administration.In addition, the developed prototype can be a promising decentralized research platform for future research works.The objective of this study is to introduce a prototype that uses a blockchain system for recording financial transactions in the construction industry.Thus, the smart contract inside the blockchain will take control of the contract's conditions, terms, and administration.The prototype plays the role of the third trusted party for the contractual parties to deal with financial transactions.Consequently, this prototype's target is to minimize manipulations that can be done by a human factor in contract administration for financial transactions.The expected benefit of the prototype is to reduce the losses in time and cost during the contract administration.The system covers the submission of the site's works according to agreed milestones, and the financial transaction shall be held by a novel proposed cryptocurrency, "Unicoin", for the construction industry.The aim of this proposed cryptocurrency for the construction industry is to get rid of the centralization of any currency [2] and allow the study of the effectiveness of a crypto-economic system in construction individually in the future.This study is a part of a long-term vision, which is to create an integrated ecosystem using blockchain specially developed for the construction industry.This vision, as shown in Figure 3, aims to connect the construction parties through the smart contract application with the integration of the Internet of Things (IoT).However, the application is not only limited to the construction site process but also for construction modeling such as documents, BIM, supply chain . . .etc.The following sections explain the prototype features, developing tools, the implementation of the case study, and performance calculations.These sections will help observe and realize the performance and the properties of the prototype.Internet of Things (IoT).However, the application is not only limited to the construction site process but also for construction modeling such as documents, BIM, supply chain …etc.The following sections explain the prototype features, developing tools, the implementation of the case study, and performance calculations.These sections will help observe and realize the performance and the properties of the prototype.

Methodology
Figure 4 shows the research methodology's procedures.First, a prototype was created using a Python programming language for the back end, while the front end was created by Visual Studio C# and Postman interface application.Then, a case study of three scenarios was used to showcase the prototype's capabilities and validate it.After that, the prototype's performance was evaluated by two main criteria: the storage size and the latency time.Finally, the outcomes of the research were discussed.

Methodology
Figure 4 shows the research methodology's procedures.First, a prototype was created using a Python programming language for the back end, while the front end was created by Visual Studio C# and Postman interface application.Then, a case study of three scenarios was used to showcase the prototype's capabilities and validate it.After that, the prototype's performance was evaluated by two main criteria: the storage size and the latency time.Finally, the outcomes of the research were discussed.

Methodology
Figure 4 shows the research methodology's procedures.First, a prototype was created using a Python programming language for the back end, while the front end was created by Visual Studio C# and Postman interface application.Then, a case study of three scenarios was used to showcase the prototype's capabilities and validate it.After that, the prototype's performance was evaluated by two main criteria: the storage size and the latency time.Finally, the outcomes of the research were discussed.

Model Features
The prototype developed in this research uses the blockchain and smart contracts technologies and aims to record the financial transactions inside the construction contract conditions.Figure 5 illustrates the prototype's overall workflow, where the user connects

Model Features
The prototype developed in this research uses the blockchain and smart contracts technologies and aims to record the financial transactions inside the construction contract conditions.Figure 5 illustrates the prototype's overall workflow, where the user connects to his own server and links with other nodes by using the Postman application interface.Then, the user runs the blockchain prototype and chooses sign-in authorization.After that, the smart contract will be run by all users inside the blockchain.
Buildings 2022, 12, 1072 to his own server and links with other nodes by using the Postman application int Then, the user runs the blockchain prototype and chooses sign-in authorization.that, the smart contract will be run by all users inside the blockchain.Figure 6 explains the category of work that the porotype can handle.After the sign into the system by their roles (e.g., owner, contractor, or consultant), they ca the contract.Algorithm A1 (Appendix A) shows the pseudocode for the blockchain tionality to mine the block and the transaction procedures for any user.In addi fourth party has been added to the system as an "admin".This admin has complet trol and surveillance over the transactions, inputs, and outputs, as shown in Algo A2 (Appendix A).Several contract types and delivery systems can be embedded in prototype, but in this study in specific, the lump-sum contract and design-bid-bui livery system were adopted to showcase the model's abilities.In this type of contra contractual party agrees on the work milestones.These milestones are indicated wit mission time for work packages valued and inserted into the smart contract by th tractor according to the project schedule.The submission system of milestones has v standards upon the contract conditions.These standards limit the conflicts among p The most common contract conditions are within the International Federation of Co ing Engineers (FIDIC) Silver Book guidelines [48].Its procedures are similar to tho plained in this section and are adopted in this study.Other modifications in cond can also be included by users.Once the contractor submits the work by changing the stone status, the consultant can start the revision and approval processes for the mile Figure 6 explains the category of work that the porotype can handle.After the users sign into the system by their roles (e.g., owner, contractor, or consultant), they can sign the contract.Algorithm A1 (Appendix A) shows the pseudocode for the blockchain functionality to mine the block and the transaction procedures for any user.In addition, a fourth party has been added to the system as an "admin".This admin has complete control and surveillance over the transactions, inputs, and outputs, as shown in Algorithm A2 (Appendix A).Several contract types and delivery systems can be embedded into the prototype, but in this study in specific, the lump-sum contract and design-bid-build delivery system were adopted to showcase the model's abilities.In this type of contract, the contractual party agrees on the work milestones.These milestones are indicated with submission time for work packages valued and inserted into the smart contract by the contractor according to the project schedule.The submission system of milestones has various standards upon the contract conditions.These standards limit the conflicts among parties.The most common contract conditions are within the International Federation of Consulting Engineers (FIDIC) Silver Book guidelines [48].Its procedures are similar to those explained in this section and are adopted in this study.Other modifications in conditions can also be included by users.Once the contractor submits the work by changing the milestone status, the consultant can start the revision and approval processes for the milestone.Consequently, the consultant's approval processes start, and in case of approval, the owner can perform the cryptocurrency financial transaction and also deduces the 10% retention from each transaction.Algorithm A3 (Appendix A) shows the previous procedures of the consultant's approval processes in the code.All retentions will be refunded to the contractor after the owner takes over the project, as shown in Algorithm A4 (Appendix A) of the owner's part of the code.Contrastingly, if there is disapproval, the contractor has two options: The first is to rework the site works and resubmit the milestone to get the consultant's approval.The second is to make a claim objection to the consultant's disapproval.Meanwhile, the admin monitors and controls the parties' processes.These monitoring and controlling processes are done by signing the users into the system, the reports extracted from the transactions, and the blockchain display.

System Design
As shown in Figure 7, the schema illustrates the system's workflow and design.The  As shown in Figure 7, the schema illustrates the system's workflow and design.The URL connection link is mentioned within the code.After the code runs, the node connection to the server starts by using the Postman interface.Then the user signs into the server system, where signing in requires a username and a password.The user portal contains the user's information such as Unicoin credit, ID, and company name.The types of users that the system is designed for are the owner, the consultants, the contractor, and the admin.Each type of user has authority for a group of actions.Firstly, the owner inserts a project into the system.The project is identified by two inputs: the project name and address.Consequently, the system will create a unique ID for the project.The project insertion is available to the consultant in case the consultant inserts the project in place of the owner.The project creation is limitless for each owner, so there could be more than one project in the system owned by one owner.In addition, the contract creation inside the project is limited to the owner's and consultant's authority, where the contract creation requires five inputs: the project's name, the contract type, the contract start date, the contract price in Unicoin, and the amount or percentage of retention.A limitless number of contracts can be created because each project can include numerous types of contracts.The contractor's authority is only limited to activities creation in which the activities represent the milestones.Each contract can contain an endless number of activities.The activity creation requires six inputs: activity's name, project's name, activity's price from the contract price, activity's start and finish dates, status, and approval.
, 1072 10 of 24 represent the milestones.Each contract can contain an endless number of activities.The activity creation requires six inputs: activity's name, project's name, activity's price from the contract price, activity's start and finish dates, status, and approval.The admin has the authority to allow the sign-up of other users.The signing-up requires a username, a password, and an e-mail address.Each user has an interactive activity with the others.Once the contractor finishes the site works that are related to the milestone, he can submit the milestone to the consultant.Thus, the contractor submission is The admin has the authority to allow the sign-up of other users.The signing-up requires a username, a password, and an e-mail address.Each user has an interactive activity with the others.Once the contractor finishes the site works that are related to the milestone, he can submit the milestone to the consultant.Thus, the contractor submission is carried out by changing the activity status to "done" or "not done".Then, the consultant has two options: to "approve" the contractor's submission or to "not approve".If the consultant approves of the milestone, the owner can perform the transaction and apply the retention in the payment.On the other hand, if the consultant disapproves of the milestone, the contractor should resubmit the milestone after the site work improvement.As soon as the consultant approves the resubmission, the owner can make the payment.However, the contractor can claim the consultant's disapproval if the disapproval causes time loss and cost incurring where this claim is identified by the contract's name and the insertion of the comments.
Generally, and blockchain-wise, the overseer of this whole process is the admin.The admin can display the blockchain of all actions throughout the whole project inside the system.The chain contains the index, which is the number of blocks, and a proof-ofwork model, which is the complex mechanism of confirmation of mining and recording cryptocurrency transactions through Hashing.Each block has its own hash and the previous block's hash as well to apply the blockchain's concept.In addition, time-stamping is used inside the blocks to organize the spent time of each process inside the system.Notification of users' actions is sent to each user.The admin can show all the notifications for the system's users.The notifications are beneficial for integrating the prototype with mobile applications, IoT system devices, and equipment on the construction site.

Model Creation Tool
Two programming languages were used to develop the prototype.Python Spyder 3.7.9 was used to create the prototype's code and Visual studio C# to develop the prototype's graphical user interface (GUI).Firstly, each user signs into the system using an individual URL link to connect the user nodes to the server.The user then employs the Postman interface application to connect the node to the system.Secondly, the prototype uses the blockchain accommodating the construction contract condition as a chain code to create a smart contract.Hence, the blockchain records each action of the transactions and smart contracts inside the blocks.The financial transaction uses a novel cryptocurrency for contracting called Unicoin.The Unicoin's exchange value was calculated as an average of the values of the two most common cryptocurrencies, Bitcoin and Ether.Lastly, the data can be extracted as a database format using Microsoft access.The prototype was designed to deal with lump sum contract types in specific.A case study of three scenarios was used to test the prototype, and the results were interpreted and displayed in the form of database tables extracted from the model in the following sections.

Case Study and Results
As an implementation for the developed model, the prototype was applied to three different scenarios of a villa construction project for 5-month project duration.A summary of the project information is presented in Appendix A (Table A1).The users signed in to the system according to their roles (i.e., owner, contractor, and consultant).The owner created a project inside the blockchain and entered the project's information.Then, the consultant inserted the contract's conditions as a smart contract inside the project.After that, the contractor created five milestones for the project for each month inside the contract, as shown in Table 2.The contractor created the value of the milestone according to the progress value of each milestone.The case study was applied in Egypt and thus used the Egyptian Pound (EGP).The exchange rate at the time of the study was EGP 981,307 to one Bitcoin and EGP 38,117 to one Ether; thus, the Unicoin was considered the average of both exchange rates (EGP 509,712).Table 3 shows the value of each monthly milestone and the payment value after the retention deduction by 10% according to the FIDIC silver book.The retention was deducted from each payment, and then the retentions of the whole project were returned after the project hand-over by the owner.Three scenarios of the case study are illustrated in Figure 8.The first is the normal "business-as-usual" scenario where the contactor had submitted the work on time.Afterward, the consultant approved the whole submission, which allowed the owner to make payments of all the milestones smoothly.Figure 9 shows a sample of the prototype's interface for the submission, approval, and payment of the first milestone.The time-stamping in this study is the time for running the three scenarios.The procedures of the three scenarios and the milestone payment are shown in Table 4. 12, 1072 12 Three scenarios of the case study are illustrated in Figure 8.The first is the no "business-as-usual" scenario where the contactor had submitted the work on time.A ward, the consultant approved the whole submission, which allowed the owner to m payments of all the milestones smoothly.Figure 9 shows a sample of the prototype terface for the submission, approval, and payment of the first milestone.The time-sta ing in this study is the time for running the three scenarios.The procedures of the t scenarios and the milestone payment are shown in Table 4.The second scenario is similar to the first scenario till the last submission.In the last submission, the contractor had submitted the milestone.However, the consultant rejected the submission, and therefore, its status became "not approved" until the contractor met the submission requirements.Then, the contractor would resubmit the work and would take the approval of the consultant.Lastly, the owner would make the last payment.The model would then calculate the retention similarly to the first scenario.The third scenario is the same as the second scenario, but the contractor had an objection to the disapproval because it had incurred the contractor's cost and had caused a work delay.A third party had caused this work disapproval.Consequently, the contractor would submit a claim about the disapproval and would wait for a reply.At this point and after the claim's submission, the consultant and the owner will make a decision.If the decision is to accept the claim, the contractor will receive the payment of the fifth milestone.In case of the claim is rejected, the owner will not make the payment to the contractor, and will transfer the claim into any dispute resolution methods (e.g., arbitration, adjudication, or litigation).Figure 10 shows a sample of the block used for approving the first milestone for the case study in the blockchain.

Performance Evaluation
The system performance was evaluated in terms of transfer latency and storage size, which can effectively reflect the computing capability needed to be deployed for endorsing and maintaining the prototype [49].

Performance Evaluation
The system performance was evaluated in terms of transfer latency and storage size, which can effectively reflect the computing capability needed to be deployed for endorsing and maintaining the prototype [49].

Storage Size
The developed prototype contains a number of transactions, and their average storage size is shown in Table 5.As each transaction is presented in a block, the data size in each block is 3261 bytes.Figure 11 shows the structure of the Merkle tree, where each node has a 32-byte fixed length of hash strings, and the total size of the tree is 608 bytes.Thus, the total size of the block is 3980 bytes; 1000 transactions would then be stored in 100 blocks in case there is 10 transaction per block.For instance, if 10 blocks are generated in a day, the storage size shall be approximately 29.9 KB (details are shown in Table 6), which is considered in the acceptable range.

Latency Performance Test
The round-trip time latency was used as a performance metric to evaluate the latency performance.Here, the round-trip time refers to the time taken by a user to send a transaction request to the blockchain till confirmation from the blockchain network.Figure 12 shows the results of the latency performance in a 10-round test.It can be observed that the latency time was 27.36 ms for the query and 19.37 ms for the upload on average, which is considered within the acceptable range and trivial for the users' experience.

Discussion
There are various outcomes from this research as a result of developing the prototype for contract administration in financial activities that uses the blockchain cryptocurrency paradigm in different scenarios of construction site work submission.One of the crucial outcomes is the automation of the contract administration procedures and the minimization of the human manipulation factor involved in financial activities.These outcomes were achieved by assigning the smart contract as a trusted party in the contract administration.A. Savelyev [50] argued that the smart contract in the blockchain is not clear for the party's obligations due to the changes according to force majeure.However, in this proposed prototype, the smart contract can refer to standards and contract conditions such as those of FIDIC that were used in this study, thus making the terms of obligation for each part obvious since the smart contract administrates the contract.A. P. Gurgun

Discussion
There are various outcomes from this research as a result of developing the prototype for contract administration in financial activities that uses the blockchain cryptocurrency paradigm in different scenarios of construction site work submission.One of the crucial outcomes is the automation of the contract administration procedures and the minimization of the human manipulation factor involved in financial activities.These outcomes were achieved by assigning the smart contract as a trusted party in the contract administration.
A. Savelyev [50] argued that the smart contract in the blockchain is not clear for the party's obligations due to the changes according to force majeure.However, in this proposed prototype, the smart contract can refer to standards and contract conditions such as those of FIDIC that were used in this study, thus making the terms of obligation for each part obvious since the smart contract administrates the contract.A. P. Gurgun and K. Koc [51] mentioned the advantages of the smart contract, which is the automation of processing.However, they also stated a key disadvantage which is the difficulty of using it in cases of disputes between parties and changes in the contractual terms.The proposed prototype attempted to overcome this disadvantage by providing the flexibility to make claims in case of disputes which converts the prototype into a tool for studies in case of the disputes' resolution.In the case of the parties' agreement for changes in contractual terms, the admin's role will take place.The parties can send the customized terms that need to be added or to be changed, and the admin converts them into codes inside the prototype.These additions shall be one of the saved standards inside the system in case of future work, and they can be linked to deeper learning tools for future studies.In other words, this study has introduced a prototype for studying the effectiveness of the blockchain and smart contracts within the construction industry, negating the hypotheses of some previous research that stated the obstacles and disadvantages of utilizing smart contracts in this field.
The prototype can effectively minimize time waste and costs in the construction project due to the usage of a fully automized system.The time and cost-saving occur due to the elimination of the centralization system, such as a bank or an accounting firm that approves the transaction.This elimination saves the cost and fees demanded by the central party and reduces the time of the approval as well.In addition, the replacement of documents and accounts that need to be checked with digitally recorded documents shall take much less time since they are all on one platform available to different parties.Moreover, blockchain has real-time transparency transactions, as mentioned by T. Ko et al. [52], where the users in the blockchain witness the transaction, and the miners create the block to record the transaction inside it.As a result, this saves the transaction time, while the cost is saved by erasing the centralized party's fee.The performance of the prototype less latency by 50% than other existed platforms [46] according to the specialized scale of the prototype in the activities.Thus, blockchain plays a party that does not have to overpower the user by adding time and cost constraints leading to cost and time reduction.
Alluding to the cost of the project, a novel cryptocurrency has been suggested.This cryptocurrency symbolizes decentralization from any financial institution and any centralization of another cryptocurrency.Meanwhile, other studies have mentioned the barriers to using cryptocurrency in construction projects [53].The prototype will allow the application of cryptocurrencies such as those mentioned by Abbas Yazdinejad et al. [54], Tomé Almeida, and Rui Ferreira [55].The prototype can also be used as a research platform to study the effect of this cryptocurrency and reconsider minimizing these barriers where the possibility of the adoption of blockchain and cryptocurrency in the construction industry can be studied.In addition, the future vision that can be analyzed is the availability to transfer from and to other currency types.Most importantly, this study will be the basic tool for assessing the blockchain technology adoption level within the construction industry.
There are limitations detected in the performance of private blockchains, such as Ethereum, that is against consortium blockchain, such as Hyperledger Fabric [56][57][58].Pongnumkul et al. [56] concluded that the Hyperledger Fabric outperforms in three different metric performance parameters: time, latency, and throughput.Panwar and Bhatnagar [57] calculated the performance of changing amount of transactions and deduced that Hyperledger Fabric is less in latency and more in throughput than Ethereum.Monrat et al. [58] analyzed the latency performance and found out that the Hyperledger Fabric is better than Ethereum.In the essence of the higher efficiency of Hyperledger, the powerful smart contract engine and the resource development availability make Ethereum a good alternative for private and consortium blockchain for high performance.The proposed prototype seeks to be the base platform for development while looking forward to higher future efficiency and a powerful engine to combine the advantages of both Ethereum and Hyperledger Fabric in performance.
This study introduced a prototype with full data mining elements.The first of these elements is the source of data, where users can log in to the system (module) using the world wide web (WWW).The second element is the database, where the data are distributed and synchronized among the users inside a database which, in this study, was saved by Microsoft Access attached to the module.The mining engine, the third element, was fulfilled by the confirmation of the contractual parties.This confirmation occurred by linking the user (miners) with the modules of the prototype.Finally, the evaluation of the data was carried out by measuring the latency time and the block size of data generated inside the block.The mined data can also be evaluated by attaching the system to spreadsheets for the analyzing.
One of the limitations in the construction industry is poor synchronization due to the sudden changes in the occasional project's behavior [59].The system is creating an environment of synchronization, traceability, and transparency to get more resilient base actions in the construction.Blockchain allows sharing the data and alarms for any changes in a facilitated way for the construction industry's stockholders.

Conclusions
Blockchain and smart contracts can be used in complex industry procedures such as construction projects.These tools are paradigm shifts in automatizing the construction project's processes in different sectors such as supply chain, site inspection, and project financial payment.Through this study's analyses of the smart contract blockchain cryptocurrency approach, the prototype was shown to be effective and convenient according to the implementation results and observations.The prototype's concept has met the conditions to reduce the contract administrator's dominance by replacing the centralized system and human manipulation factor in the contract with a decentralized automated system.The prototype can be a promising tool for creating a decentralized, resilient, traceable, transparent, and synchronized platform for the construction industry of other contractual procedures.The long-term vision of the platform can integrate the submission site quality work by using IoT with the contract administration system.This future vision aims to transfer the construction industry from human administration to automation of the procedures by using an independent decentralized system.
This study fulfills a part of the future vision at the financial scale.The required developments to meet the project's financial requirements are to study the effect of the system economical-wise and to obtain more varieties of the components of projects' transactions through the prototype.One of the examples of these varieties is the type of contracts: to make them cost-based contracts and not only price-based.The delivery system can be enhanced and upgraded to include more classes such as management contracting and integrated management systems.In addition, to make the transactions more comprehensive in the future, they can include different types of activities such as documents and resources (e.g., money, equipment, and manpower).The future vision of the developed prototype is not only applied on the project scale but also on the portfolio scale to integrate the transactions within different projects.
Moreover, another scope for the future vision of the prototype that the researchers can adopt is converting the prototype into an integrated platform.This platform will use the identical prototype blockchain in this research to connect every single party and activity in the construction industry.Developing such a platform requires the usage of drones, sensors, and virtual reality (VR) technologies in the construction and supply chain.These devices will be used for the application, approval, and material delivery in the construction site work using deep learning technology [60][61][62], a machine-based learning technique that replicates human actions [63].The connection between the device and the blockchain platform will occur using IoT technology [64].In addition, the platform will allow converting any currency into the platform's cryptocurrency to generate a novel economic system in the construction industry.In brief, the future vision of the prototype in this research is to automate the construction industry and control it from any place around the world with a high potential for economic development.
In conclusion, the developed prototype had achieved the study objective of providing a resilient, trusted, transparent, and decentralized system for construction financial contract administration.The evaluation of latency performance is efficient in specific construction contract administration activities.On the other hand, the storage size of the block is light and makes the performance more efficient with the ability to improve the size in the future.The prototype is flexible to help in the development of other add-ins applications for the future IoT system (such as sensors, drones, and tracking cameras) and be integrated with different activities.In addition, the prototype has a promising future to overcome other platforms in performance.The system of the prototype provides financial freedom by using a decentralized economic system by releasing the centralization of financial institutions such as banks.Consequently, the prototype provides a decentralized ecosystem to minimize human error, provide resilience in case of lessons learned, and be an environment for future researchers to study the effect and the improvement's possibilities.

Figure 1 .
Figure 1.The SHA-256 hashing technique.(a) The mechanism of the cryptographic linking in the blockchain that grants security within the decentralization system.(b) The attack detection by the hashing system.

Figure 1 .
Figure 1.The SHA-256 hashing technique.(a) The mechanism of the cryptographic linking in the blockchain that grants security within the decentralization system.(b) The attack detection by the hashing system.

Buildings 2022, 12 , 1072 6 of 24 Figure 2 .
Figure 2. Blockchain and smart contract publications through the years in construction engineering.

Figure 2 .
Figure 2. Blockchain and smart contract publications through the years in construction engineering.

Figure 3 .
Figure 3.The future vision for blockchain technology with the integration of IoT in the construction industry.

Figure 3 .
Figure 3.The future vision for blockchain technology with the integration of IoT in the construction industry.

Figure 6 .
Figure 6.Data relations among parties in the developed prototype.

Figure 8 .
Figure 8.The three scenarios of the hypothetical case study.

Figure 8 .
Figure 8.The three scenarios of the hypothetical case study.

Figure 8 .
Figure 8.The three scenarios of the hypothetical case study.

Figure 9 .
Figure 9. Prototype interface of a sample of submission, approval, and payment in the first milestone.

Figure 9 .
Figure 9. Prototype interface of a sample of submission, approval, and payment in the first milestone.

Table 4 .
The output for the three scenarios procedures from the database.

Figure 10 .
Figure 10.A sample block for approving the first milestone inside the blockchain.

Figure 11 .
Figure 11.The structure of the Merkle tree.

Figure 11 .
Figure 11.The structure of the Merkle tree.

Figure 12 .
Figure 12.The results of the round-trip time latency in 10 tests for the prototype.

Figure 12 .
Figure 12.The results of the round-trip time latency in 10 tests for the prototype.

Table 1 .
Recent studies employed blockchain and smart contracts in construction-related work.

Table 2 .
Milestones' values at different progress percentages for the case study.

Table 3 .
Payment and invoice values for each milestone.

Table 5 .
Storage size of different transactions for full block.

Table 6 .
Storage size calculation in the block.

Table 6 .
Storage size calculation in the block.