Non-Face-to-Face P2P (Peer-to-Peer) Real-Time Token Payment Blockchain System
Abstract
:1. Introduction
2. Related Works
2.1. ERC-20
2.2. MetaMask
2.3. Limitations of Existing Solutions
2.4. Background Technology
2.4.1. Ethereum Keystore
- Generating a Keystore
Listing 1. Keystore file example. |
{ “version”:4, “id”:“64cbaeb8-431b-41d4-a5e6-0508fc509b74”, “address”:“0x1bff0b319a73b51159fb4e2d0111d5c93fa1b3d6”, “crypto”:{ “ciphertext”:“1ab011aeae5d288465a1f4c89cf6b4a494ba90d908ef015ffa43fa9838ff1483”, “cipherparams”:{ “iv”:“2dd0641c64f19d978854a0ab3e27c0a8”}, “cipher”:“aes-128-ctr”, “kdf”:“scrypt”, “kdfparams”:{ “dklen”:32, “salt”:“cfaeccc4d27f0305f0af2d3d87214a360a06714cdf2320db44c815b9c03b4ce8”, “n”:4096, “r”:8, “p”:1 }, “mac”:“5ad80b19d7338245fb12129c2c441eee104ab054171edfd07c44cd602cdefdf6”, “machash”:“sha3256” } } |
- Decrypting Keystore
2.4.2. Symverse
- SCT-20
- Transactions
+ (number of none-zero-byte) *680
+ (number of zero-byte) *40
+ contract_operation_gas
3. Token Payment Blockchain System
3.1. Overall Architecture
3.2. Key Management Module
3.3. Token Management Module
3.4. Token Transfer Module
3.5. DDoS Protection Module
3.6. Real Name Verification Module
4. Implementation
4.1. System Environment
4.2. Wallet Creation
4.3. Token Creation
Listing 2. Array of SCT-20 input parameters. |
sct_data = [ “0x14” // SCT20 “0x0”, // SCT20_CREATE Command [ “eSportsToken”, // Token Name “EST”, // Token Symbol “0x204fce5e3e25026110000000”, // Token Amount (1 Billion) “0x00035b875ec2c5410002” // Owner’s SymID ] ] |
Listing 3. Sct_data RLP encoding result. |
0xec1480e98c6553706f727473546f6b656e834553548c204fce5e3e250261100000008a00035b875ec2c54100 |
Listing 4. SCT-20 information. |
( [jsonrpc] => 2.0 [id] => 1 [result] => Array ( [creator] => 0x00035b875ec2c5410002 [name] => eSportsToken [owner] => 0x00035b875ec2c5410002 [state] => active [stateCode] => 0x0 [symbol] => EST [total] => 0x204fce5e3e25026110000000 [type] => sct20 ) ) |
4.4. Balance Inquiry
4.5. Token Transfer
4.6. DDoS Protection
Listing 5. Geolocation query with IP lookup. |
SELECT * FROM global_ip WHERE startipL <= “. ip2long({$_SERVER[‘REMOTE_ADDR’]}). “ AND endipL >= “. ip2long({$_SERVER[‘REMOTE_ADDR’]}) |
4.7. Database
4.8. User Interface of Client Side
4.9. External Interface
5. Experiment and Results
5.1. System Environment
5.2. Performance Testing
5.2.1. Wallet Creation Response Time
5.2.2. Balance Inquiry Response Time
6. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
References
- Jain, A.K.; Gupta, B.B. A survey of phishing attack techniques, defence mechanisms and open research challenges. Enterp. Inf. Syst. 2022, 16, 527–565. [Google Scholar] [CrossRef]
- Jeong, Y.H.; Ha, H.J., 2nd. Messenger Phishing Crime: Trends and Responses. Crim. Investig. Stud. 2022, 8, 31–54. [Google Scholar] [CrossRef]
- Entriken, W.; Shirley, D.; Evans, J.; Sachs, N. Eip-721: Erc-721 non-fungible token standard. Ethereum Improv. Propos. 2018, 721, 109–113. [Google Scholar]
- Tama, B.A.; Kweka, B.J.; Park, Y.; Rhee, K.-H. A Critical Review of Blockchain and Its Current Applications. In Proceedings of the 2017 International Conference on Electrical Engineering and Computer Science (ICECOS), Palembang, Indonesia, 22–23 August 2017; pp. 109–113. [Google Scholar]
- Gad, A.G.; Mosa, D.T.; Abualigah, L.; Abohany, A.A. Emerging Trends in Blockchain Technology and Applications: A Review and Outlook. J. King Saud Univ. Comput. Inf. Sci. 2022, 34, 6719–6742. [Google Scholar] [CrossRef]
- Shah, K.; Patel, N.; Thakkar, J.; Patel, C. Exploring applications of blockchain technology for Industry 4.0. Mater. Today Proc. 2022, 62, 7238–7242. [Google Scholar] [CrossRef]
- Ahmed, M.R.; Meenakshi, K.; Obaidat, M.S.; Amin, R.; Vijayakumar, P. Blockchain Based Architecture and Solution for Secure Digital Payment System. In Proceedings of the ICC 2021—IEEE International Conference on Communications Communications, Montreal, QC, Canada, 14–23 June 2021; pp. 1–6. [Google Scholar]
- Vogelsteller, F.; Buterin, V. EIP-20: ERC-20 Token Standard. 2015. Available online: https://eips.ethereum.org/EIPS/eip-20 (accessed on 14 March 2022).
- Friedhelm, V.; Lüders, B.K. Measuring ethereum-based erc20 token networks. In Financial Cryptography and Data Security, Proceedings of the 23rd International Conference, FC 2019, Frigate Bay, St. Kitts and Nevis, 18–22 February 2019; Revised Selected Papers 23; Springer International Publishing: Berlin/Heidelberg, Germany, 2019. [Google Scholar]
- Moon, H.; Park, S. A De Facto Standard for ERC-20 API Functional Specifications and Its Conformance Review Method for Ethereum Smart Contracts, Korea Information Processing Society. Softw. Data Eng. 2022, 11-10, 399–408. [Google Scholar]
- Wood, G. Ethereum: A Secure Decentralised Generalised Transaction Ledger. Berlin Version beacfbd. 24 October 2022. Available online: https://gavwood.com/paper.pdf (accessed on 14 March 2023).
- Symverse. SymVerse Whitepaper. 2022. Available online: https://symverse.com/en/learn/whitepaper/ (accessed on 14 March 2023).
- Lee, W. Using the MetaMask Crypto-Wallet. Beginning Ethereum Smart Contracts Programming: With Examples in Python, Solidity, and JavaScript; Apress: Berkeley, CA, USA, 2023; pp. 111–144. [Google Scholar]
- Bauer, D.P. ERC-721 Nonfungible Tokens. Getting Started with Ethereum: A Step-by-Step Guide to Becoming a Blockchain Developer; Apress: Berkeley, CA, USA, 2022; pp. 55–74. [Google Scholar]
- Wang, L.; Ding, G.; Zhao, Y.; Wu, D.; He, C. Optimization of LevelDB by separating key and value. Parallel and Distributed Computing, Applications and Technologies. In Proceedings of the 2017 18th International Conference on Parallel and Distributed Computing, Applications and Technologies (PDCAT), Taipei, Taiwan, 18–20 December 2017; pp. 421–428. [Google Scholar]
- Son, J.; Park, J. Forensic analysis of MetaMask cryptocurrency wallet artifacts. J. Digit. Forensics 2022, 16, 151–165. [Google Scholar]
- Suratkar, S.; Shirole, M.; Bhirud, S. Cryptocurrency wallet: A review. In Proceedings of the 2020 4th International Conference on Computer, Communication and Signal Processing (ICCCSP), Chennai, India, 22–23 April 2020; pp. 1–7. [Google Scholar]
- Willian, D.; Jekov, B.; Hristov, P. Analysis of the cybersecurity weaknesses of DLT ecosystem. Software Engineering and Algorithms. In Proceedings of the 10th Computer Science Online Conference, Online, 21 April–2 May 2021; Springer International Publishing: Berlin/Heidelberg, Germany, 2021; Volume 1. [Google Scholar]
- Kaur, P.; Dhir, A.; Bodhi, R.; Singh, T.; Almotairi, M. Why do people use and recommend m-wallets? J. Retail. Consum. Serv. 2020, 56, 102091. [Google Scholar] [CrossRef]
- Taylor, S.; Kim, S.H.-Y.; Ariffin, K.A.Z.; Abdullah, S.N.H.S. A comprehensive forensic preservation methodology for crypto wallets. Forensic Sci. Int. Digit. Investig. 2022, 42–43, 301477. [Google Scholar] [CrossRef]
- Brian, M. Evaluation of Security in Hardware and Software Cryptocurrency Wallets; School of Computing Edinburgh, Napier University Edinburgh: Edinburgh, UK, 2019. [Google Scholar]
- Voskobojnikov, A.; Wiese, O.; Koushki, M.M.; Roth, V. The U in crypto stands for usable: An empirical study of user experience with mobile cryptocurrency wallets. In Proceedings of the 2021 CHI Conference on Human Factors in Computing Systems, Yokohama Japan, 8–13 May 2021. [Google Scholar]
- Pansara, P.; Patel, R.; Shah, K.; Jhaveri, R.; Parmar, V. Chat Application Security: Implementing Blockchain-based End-to-End Encryption. In Proceedings of the 2023 10th International Conference on Computing for Sustainable Global Development (INDIACom), New Delhi, India, 15–17 March 2023. [Google Scholar]
- Raikwar, M.; Gligoroski, D. DoS Attacks on Blockchain Ecosystem. In European Conference on Parallel Processing; Springer International Publishing: Cham, Switzerland, 2022. [Google Scholar] [CrossRef]
- Purathani, P.; Wei, X.Y.; Lei, P.; Robin, D. Attainable Hacks on Keystore Files in Ethereum Wallets—A Systematic Analysis. In Future Network Systems and Security, Proceedings of the 5th International Conference, FNSS 2019, Melbourne, VIC, Australia, 27–29 November 2019; Springer: Berlin/Heidelberg, Germany, 2019. [Google Scholar]
- Pascal, U. Innovative Wallet Using Trusted On-Line Keystore, Blockchain Research & Applications for Innovative Networks and Services (BRAINS). In Proceedings of the 2021 3rd Conference on Blockchain Research & Applications for Innovative Networks and Services (BRAINS), Paris, France, 12–14 September 2021. [Google Scholar]
- Niko, L.; Kimmo, H.; Outi-Marja, L.; Anni, K.; Jarno, S. CryptoVault—A Secure Hardware Wallet for Decentralized Key Management. In Proceedings of the 2021 IEEE International Conference on Omni-Layer Intelligent Systems (COINS), Barcelona, Spain, 1–4 August 2021. [Google Scholar]
- Phuc, T.S.D.; Lee, C. Password Hashing Algorithms—From Past to Future. J. Platf. Technol. 2015, 3, 63–75. [Google Scholar]
- Andreas, M.; Antonopoulos, G.W. Mastering Ethereum: Building Smart Contracts and DApps; O’Reilly Media: Sebastopol, CA, USA, 2018. [Google Scholar]
- Coinmarketcap. Available online: https://coinmarketcap.com/currencies/symverse/ (accessed on 14 March 2023).
- Symverse SCT Guide. Available online: https://github.com/symverse-lab/Document/wiki/SCT-Guide (accessed on 14 March 2023).
Name | Description | |
---|---|---|
Method | totalSupply | Provide the total amount of tokens |
balanceOf | Querying token balances | |
transfer | Transfer Tokens | |
transferFrom | Send tokens on a proxy | |
approve | Delegate the right to withdraw your own tokens to spenders | |
allowance | Allowance returns the number of tokens a spender can proxy withdraw from an owner | |
Event | transfer | Emitted when value tokens are moved from one account (from) to another (to). |
approval | Emitted when the allowance of a spender for an owner is set by a call to approve |
Browser | Path |
---|---|
Chrome | %USERPROFILE%\AppData\Local\Google\Chrome\User Data\{PROFILE}\Local Extension Settings\{ID} |
Edge | %USERPROFILE%\AppData\Local\Microsoft\Edge\User Data\{PROFILE}\Local Extension Settings\{ID} |
Parameters | Type | Description |
---|---|---|
Name | Address | Smart contract (token) name |
Symbol | String | Smart contract (token) symbol. The length should be from 3 to 10 |
Amount | Int | Total supply |
Owner | Address | 10 bytes—address of the contract owner |
Type | Function | Description | SCT Gas | Total Gas |
---|---|---|---|---|
SCT20 | SCT20_CREATE | Create SCT20 contract | 49,000 | 8,049,000 |
SCT20_TRANSFER | Transfer token | 7000 | 56,000 | |
SCT20_TRANSFER_FROM | Token delegation transfer | 9000 | 58,000 | |
SCT20_MINT | Issue additional token | 7000 | 56,000 | |
SCT20_BURN | Token burn | 7000 | 56,000 | |
SCT20_PAUSE | Contract suspension | 4000 | 53,000 | |
SCT20_UNPAUSE | Resume suspended contract | 4000 | 53,000 |
Field | Type | Description |
---|---|---|
from | address | [10] bytes, sender address |
nonce | int | the count of transaction publication in the account |
gasPrice | int | gas price per gas unit |
gas | int | gas amount for executing transaction |
to | address | [10] bytes, receiver address or contract address or nil |
value | int | the value sent with this transaction or amount of deposit |
input | data | [] byte, rlp encoded data (contract or sct) |
type | int | Transaction type (0: general (default), 1: sct, 2: deposit) |
workNodes | [] address | array, list of work nodes that deliver the transaction (count = 1) |
extraData | int | [] byte |
Environments | Specifications | Environments | Specifications |
---|---|---|---|
OS | Centos 7.4.17 | Database | mySQL 5.7.36 sqlite3 |
Language | PHP/HTML/Dart/Javascript | Webserver | Apache 2.4.52 |
Webserver- plugin | Php 7.4.1 Scrypt 1.4.2 | Blockchain | symverse |
UI framework | Flutter/Bootstrap | gsym | |
Test tool | JMeter V5.5 | Browser | Chrome version 111.0.5563.66 (build) (64bits) |
Table Name | Table ID |
---|---|
User | nr_user |
Wallet | est_wallet |
Transfer | nr_charge |
Charge | nr_deposit |
Withdraw | nr_withdraw |
Statics transfer | nr_settle_sale |
Statics join | nr_stat_join |
Realname log | nr_log_sms |
DDoS ban ip | nr_ddos_ip |
Menu | Description | |
---|---|---|
Class1 | Class2 | |
Client | Login | Login with member ID and password |
HP authentication | Mobile phone real name verification | |
Charge | Token charging function for payment | |
Charge list | Recently charged history list | |
Transfer | Transfer listings for sending to sellers | |
Transfer list | List of sent history records |
Menu | Description | |
---|---|---|
Class1 | Class2 | |
Seller | Transfer list | Deposits and withdrawals of tokens and error history |
Convert list | Details of application for conversion and details of results | |
Convert application | Application for changing safely traded tokens to fiat |
Menu | Description | |
---|---|---|
Class1 | Class2 | |
Platform | Statistics | Member registration status by time/day/month |
Member management | Member list/real name authentication management | |
Settlement management | Settlement information/daily settlement/settlement statistics | |
Deposit and withdrawal management | Conversion list/charging list/real-time notification | |
Mobile gift certificate management | Mobile gift certificate sales list/purchase list | |
Manager management | Admin list and administrator privilege setting |
I/FID | Sender | Receiver | Interface Description | Data Format |
---|---|---|---|---|
IF_001 | KSDT server | gsym | Symverse work node | JSON |
IF_002 | Credit rating agency | Ok-names | Ok-names real name inquiry | JSON |
IF_003 | Symverse | Symverse CA | Issue SymID | JSON |
No | Role | OS | CPU | Memory | Disk | Spec |
---|---|---|---|---|---|---|
1 | Web Server | Ubuntu 20.04.3 LTS | AMD Ryzen 5 PRO 3400GE | 8G | SSD 256GB | -mySQL 5.7.36 |
-Apache 2.4.52 | ||||||
-PHP 7.4.1 | ||||||
-sqlite3 | ||||||
2 | Node Server | CentOS Linux release 7.4.1708 | Intel(R) Xeon(R) CPU E3-1230 v6 @ 3.50GHz | 8G | SSD 512GB | -gSym |
3 | Client | Windows 10 Pro(64bit) | Intel core i7-8750H 2.20Ghz | 16G | SSD 512GB | -chrome V111.0.5563.65 |
-jMeter v5.5 |
Requests | Requests | Response Times (ms) | Throughput | Network (KB/s) | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Label | # of Samples | KO | Error% | Average | Min | Max | Median | 90th pct | 95th pct | 99th pct | Transaction (Per sec) | Receive | Send |
Total | 8000 | 2 | 0.03% | 1222.38 | 11 | 2037 | 1568.00 | 1732.00 | 1767.00 | 1829.00 | 27.98 | 10.37 | 6.07 |
User10 | 1000 | 0 | 0.00% | 322.70 | 230 | 552 | 314.50 | 404.00 | 404.00 | 450.96 | 30.66 | 11.35 | 6.59 |
User20 | 2000 | 0 | 0.00% | 646.74 | 210 | 912 | 650.50 | 800.95 | 800.95 | 861.00 | 30.52 | 11.30 | 6.56 |
User50 | 5000 | 2 | 0.04% | 1632.57 | 11 | 2037 | 1646.00 | 1784.00 | 1784.00 | 1843.00 | 30.47 | 11.30 | 6.54 |
Requests | Requests | Response Times (ms) | Throughput | Network (KB/s) | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Label | # of Samples | KO | Error% | Average | Min | Max | Median | 90th pct | 95th pct | 99th pct | Transaction (Per sec) | Receive | Send |
Total | 8000 | 2 | 0.10% | 1148.02 | 6 | 1891 | 1483.00 | 1612.00 | 1641.00 | 1700.00 | 17.00 | 6.32 | 3.65 |
User10 | 1000 | 0 | 0.00% | 304.58 | 209 | 488 | 296.00 | 360.90 | 390.00 | 431.98 | 32.27 | 11.94 | 6.93 |
User20 | 2000 | 0 | 0.00% | 608.69 | 191 | 825 | 617.00 | 711.00 | 737.00 | 786.99 | 32.42 | 12.00 | 6.97 |
User50 | 5000 | 8 | 0.16% | 1532.44 | 6 | 1891 | 1544.00 | 1633.00 | 1661.00 | 1712.99 | 32.47 | 12.11 | 6.97 |
Requests | Requests | Response Times (ms) | Throughput | Network (KB/sec) | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Label | # of Samples | KO | Error% | Average | Min | Max | Median | 90th pct | 95th pct | 99th pct | Transaction (Per sec) | Receive | Send |
Total | 65,000 | 230 | 0.35% | 425.91 | 0 | 1980 | 571.00 | 920.00 | 1022.00 | 1229.00 | 383.81 | 168.20 | 82.17 |
User50 | 5000 | 0 | 0.00% | 83.01 | 31 | 307 | 78.00 | 121.00 | 140.00 | 185.00 | 560.73 | 242.54 | 120.47 |
User100 | 10,000 | 1 | 0.01% | 156.17 | 15 | 638 | 136.00 | 276.00 | 329.00 | 426.00 | 565.55 | 244.71 | 121.49 |
User200 | 20,000 | 18 | 0.09% | 387.40 | 4 | 1496 | 368.00 | 651.00 | 737.00 | 896.99 | 482.35 | 209.33 | 103.54 |
User300 | 30,000 | 211 | 0.70% | 598.63 | 0 | 1980 | 571.00 | 920.00 | 1022.00 | 1229.00 | 475.01 | 210.84 | 101.34 |
Requests | Requests | Response Times (ms) | Throughput | Network (KB/sec) | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Label | # of Samples | KO | Error% | Average | Min | Max | Median | 90th pct | 95th pct | 99th pct | Transaction (Per sec) | Receive | Send |
Total | 65,000 | 210 | 0.32% | 830.81 | 0 | 3067 | 1131.00 | 1610.00 | 1764.00 | 2060.99 | 223.60 | 97.89 | 47.88 |
User50 | 5000 | 0 | 0.00% | 191.60 | 48 | 524 | 186.00 | 276.00 | 307.00 | 370.99 | 247.34 | 106.98 | 53.14 |
User100 | 10,000 | 1 | 0.01% | 372.60 | 8 | 1660 | 356.00 | 571.00 | 652.00 | 822.99 | 252.31 | 109.17 | 54.20 |
User200 | 20,000 | 32 | 0.16% | 752.27 | 3 | 2151 | 738.00 | 1112.90 | 1228.95 | 1468.00 | 250.26 | 108.91 | 53.68 |
User300 | 30,000 | 177 | 0.59% | 1142.44 | 0 | 3067 | 1131.00 | 1610.00 | 1764.00 | 2060.99 | 251.95 | 111.39 | 53.81 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Ko, H.-J.; Han, S.-S.; Jeong, C.-S. Non-Face-to-Face P2P (Peer-to-Peer) Real-Time Token Payment Blockchain System. Appl. Sci. 2023, 13, 7364. https://doi.org/10.3390/app13137364
Ko H-J, Han S-S, Jeong C-S. Non-Face-to-Face P2P (Peer-to-Peer) Real-Time Token Payment Blockchain System. Applied Sciences. 2023; 13(13):7364. https://doi.org/10.3390/app13137364
Chicago/Turabian StyleKo, Hyug-Jun, Seong-Soo Han, and Chang-Sung Jeong. 2023. "Non-Face-to-Face P2P (Peer-to-Peer) Real-Time Token Payment Blockchain System" Applied Sciences 13, no. 13: 7364. https://doi.org/10.3390/app13137364
APA StyleKo, H.-J., Han, S.-S., & Jeong, C.-S. (2023). Non-Face-to-Face P2P (Peer-to-Peer) Real-Time Token Payment Blockchain System. Applied Sciences, 13(13), 7364. https://doi.org/10.3390/app13137364