International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

Artificial Intelligence Integrated Technology for Decentralized Applications and Smart Contracts

MAAN NAWAF ABBOOD Al-Imam Al-Adham college

Abstract In the present period, Blockchain Technology is one of the key regions of research just as execution explicitly in the space of . Presently days, various advanced digital forms of money are very conspicuous and shared all through the world in spite of enormous analysis and debates. These cryptographic forms of money incorporate , , , PeerCoin, , , Ripple, , , , , , Neo, NEM, PotCoin, , , Stellar, , , and numerous others. These blockchain based digital forms of money don't have any middle of the road bank or installment passage to record the log of the transactions. That is the primary reason in light of which numerous nations are not permitting the cryptographic forms of money as legitimate cash transaction. In any case, these blockchain based cryptographic forms of money are extremely celebrated and utilized as a result of colossal security highlights. This manuscript is focusing on the blockchain technology that is directly associated as the application domain of artificial intelligence.

Keywords: Artificial Intelligence, AI, AI based Blockchain, Blockchain Security

Introduction The blockchain organize is having a square of records in which every single record is related with the dynamic cryptography so every one of the transactions can be scrambled with no likelihood of sniffing or hacking endeavors [1, 2]. In current situation, the blockchain innovation is progressively engaged towards cryptographic forms of money in which the disseminated record is kept up for the transactions [3, 4]. The circulated record alludes to the reproduced, synchronized and shared advanced advantage for numerous areas and gadgets with the goal that the outsider control can't be conceivable. For instance, if a bank pursues the appropriated record with blockchain innovation can uphold higher level of security [5]. On the off chance that that bank is having one million clients, at that point the records of the transactions will be put away on those one million gadgets. It alludes to the way that the programmer should hack one million gadgets progressively as opposed to a solitary server. This is the real favorable position of utilizing the decentralized blockchain innovation [6, 7].

In case of centralized application, if hacker penetrates the server of a bank, then all the details and records of all the customers can be copied. That is the main reason because of which the government agencies should focus on decentralizing their web based applications [8, 9, 10].

Using blockchian technology, the servers of government for land registry, citizen information (including AADHAAR in India), Permanent Account Number (PAN) and many others can be made secured using decentralized apps.

ISSN: 2005-4238 IJAST 1023 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

Figure 1: Association of AI, Blockchain and Big Data

The blockchain based decentralized application can be used for following • (Birth, Marriage and Death) Certificates • Asset and Land Registry • Digital Identity of Government Documents • Incorporation Services • Notarized Documents • Personalized Government Services • Social Welfare and Benefits • Taxation • Polling / Voting / Assembly Elections

ISSN: 2005-4238 IJAST 1024 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

Figure 2: Blockchain Size from 2010 to 2019

According to the examination investigation and reports from Statista.com, the graphical view introduces the extent of BitCoinblockchain from year 2010 to current year 2019 and that is having colossal use all through the globe.

The decentralized application (dApp) alludes to the product application that executes on the dispersed channels with the goal that the hacking of application will be close to incomprehensible [11]. In customary brought together application, the application is sent on a solitary server [12[. The principle constraint with concentrated methodology is that in the event that that incorporated server is hacked, at that point everything can be harmed or replicated from that server. If there should be an occurrence of decentralized application, there is no single server rather capacity is done on all the customer gadgets so the replication of the transaction should be possible with most extreme accessibility of transaction records [13]. In the situation of decentralized application, the programmer should break every one of the gadgets related with that application and that will be troublesome continuously utilizing keen contracts. In shrewd contracts based dApp, the dynamic token sharing is actualized with the goal that the transactions will have greatest safety efforts [14].

Smart Contracts The programming is required for the globalization based transactions. It means that the transactions can be done across the people who can't communicate because of different continents, languages and traditions. Smart Contracts automatically validate the transactions and business dealings between the people who can't understand the language of each other [15, 16].

Free and Open Source Tools for Blockchain Development Hydrachain (https://github.com/HydraChain/hydrachain) integrates the Creation of Permissioned Distributed Ledgers, Setup of Private Chain, Fully Compatible with Ethereum Protocol and many others.

Multichain (URL: https://www.multichain.com/) integrates the approach that is Compatible with Bitcoin, Fully Customizable, Fine-Grained Managed Permissions, Rapid Creation and Deployment of New Blockchain, Powerful Data Sharing and Encryption and enormous others.

ISSN: 2005-4238 IJAST 1025 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

OpenChain (https://www.openchain.org) is having the Digitally Signed transactions, Custom rule definitions for ledgers, Robustness and Fine Validation, Client Server Architecture, Module Design with Real Time Validations, Immutability with Security with the enormous features.

Ethereum (https://www.ethereum.org) is having Smart Wallets and Smart Money, Creation of Own Cryptocurrency Development, Security against third party intervention or downtime, Execution of Smart Contracts, Virtual Shares with Crowd Fund and Crowd Sale.

Corda https://www.corda.net is thePlatform for Blockchain and Distributed , Smart Contracts, Development of Distributed Apps, Notary Infrastructure for Sequencing and Validation of Transactions, Flow based Framework for Negotiation and Communication in the participants

Credits https://credits.com is having the Smart Contract Programming, Real Time Monitoring of Network Transactions, Web Wallet with Security using Private and Public Keys

BigChainDB with https://www.bigchaindb.com is havingBig Data enabled Blockchain Database, Decentralized Management and Control, Dynamic Management of Digital Assets, Byzantine Fault Tolerant (BFT) for high performance computing applications, Rich Permissioning at each Transaction, Integration with MongoDBNoSQL for fast transaction processing with unstructured data, Resistance to Tamper and Faults for Security

Quorum with URL https://www.jpmorgan.com/global/Quorum includes Enterprise Level Smart Contract and Platform, Peer Permissioning, High Performance using Raft based Consensus, Exchange of Private Messages with Secured Contracts, Fully Customizable for Large Scale Business and Corporate Applications, Integration with CakeShop Software Development Kit (SDK) for Graphical User Interface (GUI) enabled Smart Contracts, Quorum Networks and APIs.

Symbiont Assembly , URL: https://symbiont.io/ is having Byzantine Fault-Tolerance, Handling Thousands or more Transactions Per Second, Elimination of data loss with storage of real time critical documents on network, Sharing of data with advanced encryption and dynamic cryptography, Maintenance of transaction logs and lifetime without third party intervention

Embark, URL: https://embark.status.im/ withPeer to Peer Secured Messaging, Development and Distribution of Decentralized Apps with Decentralized Communication with Orbit and Whisper, Integration with Web Technologies including Foundation, React, Angular and others, Custom Framework Development, Association with Simulated including Ganache, Automatic Smart Contract deployment, Integration with EthereumBlockchains, Testing Environment for Smart Contracts using Web3

Solidity, URL: https://github.com/ethereum/solidity is theHigh Level Programming Language for Smart Contracts, Contract Oriented Statically Typed Programming Language, Object Oriented with support to multiple blockchian platforms, Compatible with Ethereum, Tendermint, and ErisDB, Creation of Smart Contracts for Crowdfunding, Muti-Signature Wallets, Voting, Blind Auctions and many others

Truffle, URL: https://truffleframework.com/ is the Platform for Smart Contract Programming with compilation, linking and binary management, Development Environment with Framework for Testing, Testing of Contracts using Chai library and Mocha Framework, NodeJS support for Mocha and Chai integration for unit testing

ISSN: 2005-4238 IJAST 1026 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

Programming Blockchain using Open Source Development Environments Solidity Solidity is one of the amazing and superior programming language for composing keen contracts. It pursues object arranged programming worldview with higher level of security and execution which can be coordinated with grouped blockchain stages. The code of solidity is incorporated and changed to bytecode which is executed on Ethereum Virtual Machine (EVM) [17, 18]. Solidity Programming is having the key base of different programming dialects and contents including Python, JavaScript, C++ so it very well may be coordinated to numerous conditions and stages for incorporation with blockchains. To work with Solidity Programming, there are many Integrated Development Environments (IDEs) and Editors which can be utilized including Remix, EthFiddle, JetBrains and numerous others [19, 20].

To begin with Solidity Programming, Remix is one of the ground-breaking IDEs that is open source and furthermore gives the electronic interface. The electronic interface of Remix IDE is simple for the engineers to make the Smart Contracts with Blockchain Programming.

Figure 3: Remix IDE for Blockchain Programming

The URL of Web Based Remix IDE is remix.ethereum.org that can be accessed directly on the web browsers for writing, compiling and executing the smart contracts.

Figure 4: Writing New in Solidity

ISSN: 2005-4238 IJAST 1027 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

Figure 5: Compile and Run Code in Remix IDE

On click of Deploy option in Remix IDE, the code is executed and detailed logs of the transaction can be viewed.

ISSN: 2005-4238 IJAST 1028 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

Figure 6: View Logs and Transaction Details

The detailed logs of the Blockchain Transaction can be analyzed associated with the transaction. There are multiple parameters in the transaction log including Gas Limit. The Gas Limit in Smart Contract Programming refers to the amount of work or throughput associated with the transaction [21].

Embark The framework of Embark provides the tools and libraries for development of decentralized apps so that blockchain based implementation can be done. Embark can be used as an alternate to Truffle. To work with Embark, there is need to integrate Node Version Manager (NVM) having multiple versions of NodeJS.

NVM can be installed as follows curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash nvm install --lts nvm use --lts

Once NVM is installed, the toolkit of Embark can be associated as follows

ISSN: 2005-4238 IJAST 1029 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

npm -g install embark

After installation, the initialization instruction is executed for the new project embark new mysmartcontract cdmysmartcontract

Using "embark run", the dashboard of Embark is invoked

The token generation can be further written in code pragma solidity ^0.4.25; import "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol"; contractCryptoToken is ERC20 { string public name = "CryptoToken"; string public symbol = "MC"; uint256 public decimals = 18; constructor() public { } }

As in the above example, MC refers to the new MC. It can be anything as per the requirements of the smart contract associated with the blockchain [22].

Method and Approach The presented work is solely associated with the artificial intelligence integrated blockchain architecture so that the overall performance and the security can be elevated. This presented work is having the integration of smart contract with the cavernous evaluation of the effectiveness in the assorted domains. In addition, the work is having the smart contract programming whereby the cumulative escalation to the security can be enhanced. The smart contracts programming is the prime feature in the blockchain the artificial intelligence features to enforce the higher degree of performance and effectiveness.

Conclusion As blockchain based advancement is the developing area of research, there is have to work out various issues identified with protection and asset improvement. In blockchain and decentralized applications, the information is imitated to huge gadgets and the issues of security and trustworthiness emerge. With the improvement and sending of cutting edge calculations, the execution of blockchain based usage can be raised.

References [1] Drew, J., 2017. Real talk about artificial intelligence and blockchain. Journal of Accountancy, 224(1), p.22. [2] Lin, I.C. and Liao, T.C., 2017. A Survey of Blockchain Security Issues and Challenges. IJ Network Security, 19(5), pp.653-659. [3] Biswas, K. and Muthukkumarasamy, V., 2016, December. Securing smart cities using blockchain technology. In 2016 IEEE 18th international conference on high performance computing and communications; IEEE 14th international conference on smart city; IEEE 2nd international conference on data science and systems (HPCC/SmartCity/DSS) (pp. 1392- 1393). IEEE. [4] Karame, G.O. and Androulaki, E., 2016. Bitcoin and blockchain security. Artech House. [5] Dorri, A., Kanhere, S.S., Jurdak, R. and Gauravaram, P., 2017, March. Blockchain for IoT security and privacy: The case study of a smart home. In 2017 IEEE International Conference on Pervasive Computing and Communications Workshops (PerCom Workshops) (pp. 618- 623). IEEE.

ISSN: 2005-4238 IJAST 1030 Copyright ⓒ 2020 SERSC

International Journal of Advanced Science and Technology Vol. 29, No.02, (2020), pp. 1023-1031

[6] Li, X., Jiang, P., Chen, T., Luo, X. and Wen, Q., 2017. A survey on the security of blockchain systems. Future Generation Computer Systems. [7] Park, J. and Park, J., 2017. Blockchain security in cloud computing: Use cases, challenges, and solutions. Symmetry, 9(8), p.164. [8] Khan, M.A. and Salah, K., 2018. IoT security: Review, blockchain solutions, and open challenges. Future Generation Computer Systems, 82, pp.395-411. [9] Aitzhan, N.Z. and Svetinovic, D., 2018. Security and privacy in decentralized energy trading through multi-signatures, blockchain and anonymous messaging streams. IEEE Transactions on Dependable and Secure Computing, 15(5), pp.840-852. [10] Dorri, A., Steger, M., Kanhere, S.S. and Jurdak, R., 2017. Blockchain: A distributed solution to automotive security and privacy. IEEE Communications Magazine, 55(12), pp.119-125. [11] Mamoshina, P., Ojomoko, L., Yanovich, Y., Ostrovski, A., Botezatu, A., Prikhodko, P., Izumchenko, E., Aliper, A., Romantsov, K., Zhebrak, A. and Ogu, I.O., 2018. Converging blockchain and next-generation artificial intelligence technologies to decentralize and accelerate biomedical research and healthcare. Oncotarget, 9(5), p.5665. [12] Yuan, Y. and Wang, F.Y., 2016, November. Towards blockchain-based intelligent transportation systems. In 2016 IEEE 19th International Conference on Intelligent Transportation Systems (ITSC) (pp. 2663-2668). IEEE. [13] Swan, M., 2015. Blockchain thinking: The brain as a decentralized autonomous corporation [commentary]. IEEE Technology and Society Magazine, 34(4), pp.41-52. [14] Godsiff, P., 2015. Bitcoin: bubble or blockchain. In Agent and Multi-Agent Systems: Technologies and Applications (pp. 191-203). Springer, Cham. [15] Zheng, Z., Xie, S., , H.N. and Wang, H., 2016. Blockchain challenges and opportunities: A survey. Work Pap.–2016. [16] Swan, M., 2018. Blockchain for business: Next-generation enterprise artificial intelligence systems. In Advances in Computers (Vol. 111, pp. 121-162). Elsevier. [17] Swan, M., 2018. Blockchain for business: Next-generation enterprise artificial intelligence systems. In Advances in Computers (Vol. 111, pp. 121-162). Elsevier. [18] Samaniego, M. and Deters, R., 2017, June. Internet of smart things-IoST: Using blockchain and CLIPS to make things autonomous. In 2017 IEEE International Conference on Cognitive Computing (ICCC) (pp. 9-16). IEEE. [19] Dai, J. and Vasarhelyi, M.A., 2017. Toward blockchain-based accounting and assurance. Journal of Information Systems, 31(3), pp.5-21. [20] Sun, J., Yan, J. and Zhang, K.Z., 2016. Blockchain-based sharing services: What blockchain technology can contribute to smart cities. Financial Innovation, 2(1), p.26. [21] Rantos, K., Drosatos, G., Demertzis, K., Ilioudis, C. and Papanikolaou, A., 2018. Blockchain-based consents management for personal data processing in the IoT ecosystem. In proceedings of the 15th International Conference on Security and Cryptography (SECRYPT 2018), part of ICETE (pp. 572-577). [22] Marwala, T. and Xing, B., 2018. Blockchain and artificial intelligence. arXiv preprint arXiv:1802.04451.

ISSN: 2005-4238 IJAST 1031 Copyright ⓒ 2020 SERSC