{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,10,8]],"date-time":"2026-10-08T11:41:07Z","timestamp":1791459667102,"version":"4.3.4"},"reference-count":66,"publisher":"Association for Computing Machinery (ACM)","issue":"1","license":[{"start":{"date-parts":[[2020,12,31]],"date-time":"2020-12-31T00:00:00Z","timestamp":1609372800000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/www.acm.org\/publications\/policies\/copyright_policy#Background"}],"funder":[{"DOI":"10.13039\/501100001381","name":"National Research Foundation Singapore","doi-asserted-by":"crossref","award":["National Satellite of Excellence in Trustworthy Software Systems"],"award-info":[{"award-number":["National Satellite of Excellence in Trustworthy Software Systems"]}],"id":[{"id":"10.13039\/501100001381","id-type":"DOI","asserted-by":"crossref"}]},{"DOI":"10.13039\/501100003453","name":"Natural Science Foundation of Guangdong Province","doi-asserted-by":"crossref","award":["2020A1515011494"],"award-info":[{"award-number":["2020A1515011494"]}],"id":[{"id":"10.13039\/501100003453","id-type":"DOI","asserted-by":"crossref"}]},{"DOI":"10.13039\/501100001809","name":"National Natural Science Foundation of China","doi-asserted-by":"crossref","award":["61902170"],"award-info":[{"award-number":["61902170"]}],"id":[{"id":"10.13039\/501100001809","id-type":"DOI","asserted-by":"crossref"}]}],"content-domain":{"domain":["dl.acm.org"],"crossmark-restriction":true},"short-container-title":["ACM Trans. Softw. Eng. Methodol."],"published-print":{"date-parts":[[2021,1,31]]},"abstract":"<jats:p>Automated program repair is an emerging area that attempts to patch software errors and vulnerabilities. In this article, we formulate and study a problem related to automated repair, namely automated patch transplantation. A patch for an error in a donor program is automatically adapted and inserted into a \u201csimilar\u201d target program. We observe that despite standard procedures for vulnerability disclosures and publishing of patches, many un-patched occurrences remain in the wild. One of the main reasons is the fact that various implementations of the same functionality may exist and, hence, published patches need to be modified and adapted. In this article, we therefore propose and implement a workflow for transplanting patches. Our approach centers on identifying patch insertion points, as well as namespaces translation across programs via symbolic execution. Experimental results to eliminate five classes of errors highlight our ability to fix recurring vulnerabilities across various programs through transplantation. We report that in 20 of 24 fixing tasks involving eight application subjects mostly involving file processing programs, we successfully transplanted the patch and validated the transplantation through differential testing. Since the publication of patches make an un-patched implementation more vulnerable, our proposed techniques should serve a long-standing need in practice.<\/jats:p>","DOI":"10.1145\/3412376","type":"journal-article","created":{"date-parts":[[2020,12,31]],"date-time":"2020-12-31T18:48:06Z","timestamp":1609440486000},"page":"1-36","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":35,"title":["Automated Patch Transplantation"],"prefix":"10.1145","volume":"30","author":[{"given":"Ridwan Salihin","family":"Shariffdeen","sequence":"first","affiliation":[{"name":"National University of Singapore, Singapore"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0001-8633-3372","authenticated-orcid":false,"given":"Shin Hwei","family":"Tan","sequence":"additional","affiliation":[{"name":"Southern University of Science and Technology, China"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Mingyuan","family":"Gao","sequence":"additional","affiliation":[{"name":"National University of Singapore, Singapore"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-7127-1137","authenticated-orcid":false,"given":"Abhik","family":"Roychoudhury","sequence":"additional","affiliation":[{"name":"National University of Singapore, Singapore"}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"320","published-online":{"date-parts":[[2020,12,31]]},"reference":[{"key":"e_1_2_1_1_1","volume-title":"Retrieved","author":"Sarubbo Agostino","year":"2019","unstructured":"Agostino Sarubbo . 2019 . Agostino\u2019s blog . Retrieved February 24, 2019, from https:\/\/blogs.gentoo.org\/ago Agostino Sarubbo. 2019. Agostino\u2019s blog. Retrieved February 24, 2019, from https:\/\/blogs.gentoo.org\/ago"},{"key":"e_1_2_1_2_1","volume-title":"Retrieved","author":"LLVM Developer Group","year":"2019","unstructured":"LLVM Developer Group . 2019 . The Clang Project . Retrieved March 11, 2019, from https:\/\/clang.llvm.org. LLVM Developer Group. 2019. The Clang Project. Retrieved March 11, 2019, from https:\/\/clang.llvm.org."},{"key":"e_1_2_1_3_1","volume-title":"Retrieved","author":"Research Microsoft","year":"2019","unstructured":"Microsoft Research . 2019 . The Z3 Theorem Prover . Retrieved March 11, 2019, from https:\/\/github.com\/Z3Prover\/z3. Microsoft Research. 2019. The Z3 Theorem Prover. Retrieved March 11, 2019, from https:\/\/github.com\/Z3Prover\/z3."},{"key":"e_1_2_1_4_1","volume-title":"The Docker Project. Retrieved","author":"Docker Inc. 2020.","year":"2019","unstructured":"Docker Inc. 2020. The Docker Project. Retrieved March 5, 2019 , from https:\/\/www.docker.com\/. Docker Inc. 2020. The Docker Project. Retrieved March 5, 2019, from https:\/\/www.docker.com\/."},{"key":"e_1_2_1_5_1","volume-title":"Proceedings 2000 International Conference on Image Processing (Cat. No. 00CH37101)","volume":"2","author":"Michael","unstructured":"Michael D. Adams and Faouzi Kossentini. 2000. JasPer: A software-based JPEG-2000 codec implementation . In Proceedings 2000 International Conference on Image Processing (Cat. No. 00CH37101) , Vol. 2 . IEEE, 53--56. Michael D. Adams and Faouzi Kossentini. 2000. JasPer: A software-based JPEG-2000 codec implementation. In Proceedings 2000 International Conference on Image Processing (Cat. No. 00CH37101), Vol. 2. IEEE, 53--56."},{"key":"e_1_2_1_6_1","doi-asserted-by":"publisher","DOI":"10.1007\/s10515-006-0002-0"},{"key":"e_1_2_1_7_1","doi-asserted-by":"publisher","DOI":"10.1109\/SP.2017.67"},{"key":"e_1_2_1_8_1","doi-asserted-by":"publisher","DOI":"10.1145\/2771783.2771796"},{"key":"e_1_2_1_9_1","volume-title":"Proceedings of the 8th USENIX Conference on Operating Systems Design and Implementation (OSDI\u201908)","author":"Cadar Cristian","year":"2008","unstructured":"Cristian Cadar , Daniel Dunbar , and Dawson Engler . 2008 . KLEE: Unassisted and automatic generation of high-coverage tests for complex systems programs . In Proceedings of the 8th USENIX Conference on Operating Systems Design and Implementation (OSDI\u201908) . USENIX Association, Berkeley, CA, 209--224. http:\/\/dl.acm.org\/citation.cfm?id= 1855741.1855756. Cristian Cadar, Daniel Dunbar, and Dawson Engler. 2008. KLEE: Unassisted and automatic generation of high-coverage tests for complex systems programs. In Proceedings of the 8th USENIX Conference on Operating Systems Design and Implementation (OSDI\u201908). USENIX Association, Berkeley, CA, 209--224. http:\/\/dl.acm.org\/citation.cfm?id=1855741.1855756."},{"key":"e_1_2_1_10_1","doi-asserted-by":"publisher","DOI":"10.1145\/2663716.2663755"},{"key":"e_1_2_1_11_1","doi-asserted-by":"publisher","DOI":"10.1145\/2642937.2642982"},{"key":"e_1_2_1_12_1","doi-asserted-by":"publisher","DOI":"10.1109\/TSE.2007.70731"},{"key":"e_1_2_1_13_1","doi-asserted-by":"publisher","DOI":"10.1145\/2338965.2336775"},{"key":"e_1_2_1_14_1","doi-asserted-by":"publisher","DOI":"10.1109\/WCRE.2010.15"},{"key":"e_1_2_1_15_1","doi-asserted-by":"publisher","DOI":"10.1145\/3318162"},{"key":"e_1_2_1_16_1","doi-asserted-by":"publisher","DOI":"10.1145\/3238147.3238219"},{"key":"e_1_2_1_17_1","doi-asserted-by":"publisher","DOI":"10.1145\/3213846.3213871"},{"key":"e_1_2_1_18_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2007.30"},{"key":"e_1_2_1_19_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2013.6606626"},{"key":"e_1_2_1_20_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2009.5070531"},{"key":"e_1_2_1_21_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSM.1992.242533"},{"key":"e_1_2_1_22_1","doi-asserted-by":"publisher","DOI":"10.1109\/SANER.2016.76"},{"key":"e_1_2_1_23_1","doi-asserted-by":"publisher","DOI":"10.5555\/2337223.2337225"},{"key":"e_1_2_1_24_1","doi-asserted-by":"publisher","DOI":"10.1109\/TSE.2011.104"},{"key":"e_1_2_1_25_1","doi-asserted-by":"publisher","DOI":"10.1145\/3106237.3106253"},{"key":"e_1_2_1_26_1","doi-asserted-by":"publisher","DOI":"10.1145\/2837614.2837617"},{"key":"e_1_2_1_27_1","doi-asserted-by":"publisher","DOI":"10.1145\/3180155.3180190"},{"key":"e_1_2_1_28_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-319-22183-0_21"},{"key":"e_1_2_1_29_1","doi-asserted-by":"publisher","DOI":"10.1007\/s10664-016-9470-4"},{"key":"e_1_2_1_30_1","doi-asserted-by":"publisher","DOI":"10.1145\/2931037.2948705"},{"key":"e_1_2_1_31_1","doi-asserted-by":"publisher","DOI":"10.1145\/3241980"},{"key":"e_1_2_1_32_1","doi-asserted-by":"publisher","DOI":"10.1145\/3180155.3180247"},{"key":"e_1_2_1_33_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2015.63"},{"key":"e_1_2_1_34_1","doi-asserted-by":"publisher","DOI":"10.1145\/2884781.2884807"},{"key":"e_1_2_1_35_1","volume-title":"McKinley","author":"Meng Na","year":"2011","unstructured":"Na Meng , Miryung Kim , and Kathryn S . McKinley . 2011 . Systematic editing: Generating program transformations from an example. In ACM SIGPLAN Notices, Vol. 46 . ACM , 329--342. Na Meng, Miryung Kim, and Kathryn S. McKinley. 2011. Systematic editing: Generating program transformations from an example. In ACM SIGPLAN Notices, Vol. 46. ACM, 329--342."},{"key":"e_1_2_1_36_1","volume-title":"McKinley","author":"Meng Na","year":"2013","unstructured":"Na Meng , Miryung Kim , and Kathryn S . McKinley . 2013 . LASE : Locating and applying systematic edits by learning from examples. In Proceedings of the 2013 International Conference on Software Engineering (ICSE'13). IEEE Press , 502--511. Na Meng, Miryung Kim, and Kathryn S. McKinley. 2013. LASE: Locating and applying systematic edits by learning from examples. In Proceedings of the 2013 International Conference on Software Engineering (ICSE'13). IEEE Press, 502--511."},{"key":"e_1_2_1_37_1","doi-asserted-by":"publisher","DOI":"10.5555\/2486788.2486890"},{"key":"e_1_2_1_38_1","volume-title":"ACM SIGOPS\/EuroSys European Conference on Computer Systems (Eurosys\u201908)","author":"Padioleau Y.","unstructured":"Y. Padioleau , J. Lawall , R. R. Hansen , and G. Muller . 2008. Documenting and automating collateral evolutions in Linux device drivers . In ACM SIGOPS\/EuroSys European Conference on Computer Systems (Eurosys\u201908) . Y. Padioleau, J. Lawall, R. R. Hansen, and G. Muller. 2008. Documenting and automating collateral evolutions in Linux device drivers. In ACM SIGOPS\/EuroSys European Conference on Computer Systems (Eurosys\u201908)."},{"key":"e_1_2_1_39_1","doi-asserted-by":"publisher","DOI":"10.1145\/1352592.1352618"},{"key":"e_1_2_1_40_1","doi-asserted-by":"publisher","DOI":"10.1145\/1950365.1950401"},{"key":"e_1_2_1_41_1","doi-asserted-by":"publisher","DOI":"10.1145\/1629575.1629585"},{"key":"e_1_2_1_42_1","volume-title":"Proceedings of the IEEE\/ACM International Conference on Automated Software Engineering (ASE\u201910)","author":"Pham Nam H.","year":"1858","unstructured":"Nam H. Pham , Tung Thanh Nguyen , Hoan Anh Nguyen , and Tien N. Nguyen . 2010. Detection of recurring software vulnerabilities . In Proceedings of the IEEE\/ACM International Conference on Automated Software Engineering (ASE\u201910) . ACM, New York, NY, 447--456. DOI:https:\/\/doi.org\/10.1145\/ 1858 996.1859089 10.1145\/1858996.1859089 Nam H. Pham, Tung Thanh Nguyen, Hoan Anh Nguyen, and Tien N. Nguyen. 2010. Detection of recurring software vulnerabilities. In Proceedings of the IEEE\/ACM International Conference on Automated Software Engineering (ASE\u201910). ACM, New York, NY, 447--456. DOI:https:\/\/doi.org\/10.1145\/1858996.1859089"},{"key":"e_1_2_1_43_1","doi-asserted-by":"publisher","DOI":"10.1145\/2771783.2771791"},{"key":"e_1_2_1_44_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSM.2004.1357803"},{"key":"e_1_2_1_45_1","doi-asserted-by":"publisher","DOI":"10.1109\/ASE.2013.6693095"},{"key":"e_1_2_1_46_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2017.44"},{"key":"e_1_2_1_47_1","doi-asserted-by":"publisher","DOI":"10.1109\/WCRE.2008.54"},{"key":"e_1_2_1_48_1","doi-asserted-by":"publisher","DOI":"10.1145\/1321631.1321746"},{"key":"e_1_2_1_49_1","volume-title":"Retrieved","year":"2016","unstructured":"Shodan. 2016 . Devices Vulnerable to Heartbleed . Retrieved September 14, 2018, from https:\/\/www.shodan.io\/report\/89bnfUyJ Shodan. 2016. Devices Vulnerable to Heartbleed. Retrieved September 14, 2018, from https:\/\/www.shodan.io\/report\/89bnfUyJ"},{"key":"e_1_2_1_50_1","volume-title":"CodeCarbonCopy. In Proceedings of the 2017 11th Joint Meeting on Foundations of Software Engineering (ESEC\/FSE'17)","author":"Sidiroglou-Douskos Stelios","year":"2017","unstructured":"Stelios Sidiroglou-Douskos , Eric Lahtinen , Anthony Eden , Fan Long , and Martin Rinard . 2017 . CodeCarbonCopy. In Proceedings of the 2017 11th Joint Meeting on Foundations of Software Engineering (ESEC\/FSE'17) . ACM, 95--105. Stelios Sidiroglou-Douskos, Eric Lahtinen, Anthony Eden, Fan Long, and Martin Rinard. 2017. CodeCarbonCopy. In Proceedings of the 2017 11th Joint Meeting on Foundations of Software Engineering (ESEC\/FSE'17). ACM, 95--105."},{"key":"e_1_2_1_51_1","doi-asserted-by":"publisher","DOI":"10.1145\/2737924.2737988"},{"key":"e_1_2_1_52_1","doi-asserted-by":"publisher","DOI":"10.1145\/2786805.2786825"},{"key":"e_1_2_1_53_1","doi-asserted-by":"publisher","DOI":"10.1145\/2786805.2786825"},{"key":"e_1_2_1_54_1","doi-asserted-by":"publisher","DOI":"10.1145\/3180155.3180243"},{"key":"e_1_2_1_55_1","doi-asserted-by":"publisher","DOI":"10.5555\/2818754.2818813"},{"key":"e_1_2_1_56_1","doi-asserted-by":"publisher","DOI":"10.1145\/2950290.2950295"},{"key":"e_1_2_1_57_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSME.2016.71"},{"key":"e_1_2_1_58_1","doi-asserted-by":"publisher","DOI":"10.5555\/2337223.2337269"},{"key":"e_1_2_1_59_1","doi-asserted-by":"publisher","DOI":"10.1145\/3180155.3180250"},{"key":"e_1_2_1_60_1","doi-asserted-by":"publisher","DOI":"10.1109\/ASE.2013.6693094"},{"key":"e_1_2_1_61_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2009.5070536"},{"key":"e_1_2_1_62_1","volume-title":"Proceedings of the 26th ACM SIGSOFT International Symposium on Software Testing and Analysis (ISSTA\u201917)","author":"Xin Qi","unstructured":"Qi Xin and Steven P. Reiss . 2017. Identifying test-suite-overfitted patches through test case generation . In Proceedings of the 26th ACM SIGSOFT International Symposium on Software Testing and Analysis (ISSTA\u201917) . ACM, New York, NY, 226--236. DOI:https:\/\/doi.org\/10.1145\/3092703.3092718 10.1145\/3092703.3092718 Qi Xin and Steven P. Reiss. 2017. Identifying test-suite-overfitted patches through test case generation. In Proceedings of the 26th ACM SIGSOFT International Symposium on Software Testing and Analysis (ISSTA\u201917). ACM, New York, NY, 226--236. DOI:https:\/\/doi.org\/10.1145\/3092703.3092718"},{"key":"e_1_2_1_63_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2017.45"},{"key":"e_1_2_1_64_1","first-page":"1","article-title":"Nopol: Automatic repair of conditional statement bugs in Java programs","volume":"99","author":"Xuan J.","year":"2016","unstructured":"J. Xuan , M. Martinez , F. DeMarco , M. Clement , S. Lamelas Marcote , T. Durieux , D. Le Berre , and M. Monperrus . 2016 . Nopol: Automatic repair of conditional statement bugs in Java programs . IEEE Transactions on Software Engineering PP , 99 (2016), 1 -- 1 . J. Xuan, M. Martinez, F. DeMarco, M. Clement, S. Lamelas Marcote, T. Durieux, D. Le Berre, and M. Monperrus. 2016. Nopol: Automatic repair of conditional statement bugs in Java programs. IEEE Transactions on Software Engineering PP, 99 (2016), 1--1.","journal-title":"IEEE Transactions on Software Engineering PP"},{"key":"e_1_2_1_65_1","doi-asserted-by":"publisher","DOI":"10.1002\/spe.4380210706"},{"key":"e_1_2_1_66_1","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2017.67"}],"container-title":["ACM Transactions on Software Engineering and Methodology"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3412376","content-type":"unspecified","content-version":"vor","intended-application":"text-mining"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3412376","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,6,17]],"date-time":"2025-06-17T21:25:01Z","timestamp":1750195501000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3412376"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2020,12,31]]},"references-count":66,"journal-issue":{"issue":"1","published-print":{"date-parts":[[2021,1,31]]}},"alternative-id":["10.1145\/3412376"],"URL":"https:\/\/doi.org\/10.1145\/3412376","relation":{},"ISSN":["1049-331X","1557-7392"],"issn-type":[{"value":"1049-331X","type":"print"},{"value":"1557-7392","type":"electronic"}],"subject":[],"published":{"date-parts":[[2020,12,31]]},"assertion":[{"value":"2019-11-01","order":0,"name":"received","label":"Received","group":{"name":"publication_history","label":"Publication History"}},{"value":"2020-07-01","order":1,"name":"accepted","label":"Accepted","group":{"name":"publication_history","label":"Publication History"}},{"value":"2020-12-31","order":2,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}