Smart contracts are decentralized applications running on Blockchain. A very large number of smart contracts has been deployed on Ethereum. Meanwhile, security flaws of contracts have led to huge pecuniary losses and destroyed the ecological stability of contract layer on Blockchain. It is thus an emerging yet crucial issue to effectively and efficiently detect vulnerabilities in contracts. Existing detection methods like Oyente and Securify are mainly based on symbolic execution or analysis. These methods are very time-consuming, as the symbolic execution requires the exploration of all executable paths or the analysis of dependency graphs in a contract. In this work, we propose ContractWard to detect vulnerabilities in smart contracts with machine learning techniques. First, we extract bigram features from simplified operation codes of smart contracts. Second, we employ five machine learning algorithms and two sampling algorithms to build the models. ContractWard is evaluated with 49502 real-world smart contracts running on Ethereum. The experimental results demonstrate the effectiveness and efficiency of ContractWard. The predictive Micro-F1 and Macro-F1 of ContractWard are over 96% and the average detection time is 4 seconds on each smart contract when we use XGBoost for training the models and SMOTETomek for balancing the training sets.
Self‐powered photodetectors (PDs) based on inorganic metal halide perovskites are regarded as promising alternatives for the next generation of photodetectors. However, uncontrollable film growth and sluggish charge extraction at interfaces directly limit the sensitivity and response speed of perovskite‐based photodetectors. Herein, by assistance of an atomic layer deposition (ALD) technique, CsPbBr3 perovskite thin films with preferred orientation and enlarged grain size are obtained on predeposited interfacial modification layers. Thanks to improved film quality and double side interfacial engineering, the optimized CsPbBr3 (Al2O3/CsPbBr3/TiO2, ACT) perovskite PDs exhibit outstanding performance with ultralow dark current of 10−11 A, high detectivity of 1.88 × 1013 Jones and broad linear dynamic range (LDR) of 172.7 dB. Significantly, excellent long‐term environmental stability (ambient conditions >100 d) and flexibility stability (>3000 cycles) are also achieved. The remarkable performance is credited to the synergistic effects of high carrier conductivity and collection efficiency, which is assisted by ALD modification layers. Finally, the ACT PDs are successfully integrated into a visible light communication system as a light receiver on transmitting texts, showing a bit rate as high as 100 kbps. These results open the window of high performance all‐inorganic halide perovskite photodetectors and extends to rational applications for optical communication.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.