{"id":45818,"date":"2024-11-18T17:12:08","date_gmt":"2024-11-18T22:12:08","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=45818"},"modified":"2024-11-18T17:12:08","modified_gmt":"2024-11-18T22:12:08","slug":"retrofitting-spatial-safety-to-hundreds-of-millions-of-lines-of-c","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2024\/11\/18\/retrofitting-spatial-safety-to-hundreds-of-millions-of-lines-of-c\/","title":{"rendered":"Retrofitting Spatial Safety to Hundreds of Millions of Lines of C++"},"content":{"rendered":"<p><a href=\"https:\/\/security.googleblog.com\/2024\/11\/retrofitting-spatial-safety-to-hundreds.html\">Google Security<\/a>:<\/p>\n<blockquote cite=\"https:\/\/security.googleblog.com\/2024\/11\/retrofitting-spatial-safety-to-hundreds.html\"><p>Based on an analysis of <a href=\"https:\/\/googleprojectzero.blogspot.com\/p\/0day.html\">in-the-wild exploits tracked by Google&rsquo;s Project Zero<\/a>, spatial safety vulnerabilities represent 40% of in-the-wild memory safety exploits over the past decade[&#8230;]<\/p><p>[&#8230;]<\/p><p>A key element of our strategy focuses on <a href=\"https:\/\/blog.google\/technology\/safety-security\/tackling-cybersecurity-vulnerabilities-through-secure-by-design\/\">Safe Coding<\/a> and using memory-safe languages in new code.<\/p><p>[&#8230;]<\/p><p>However, this transition will take multiple years as we adapt our development practices and infrastructure. Ensuring the safety of our billions of users therefore requires us to go further: we&rsquo;re also retrofitting secure-by-design principles to our existing C++ codebase wherever possible.<\/p><p>[&#8230;]<\/p><p><a href=\"https:\/\/libcxx.llvm.org\/Hardening.html\">Hardened libc++<\/a>, recently added by open source contributors, introduces a set of security checks designed to catch vulnerabilities such as out-of-bounds accesses in production. [&#8230;] Hardening libc++ resulted in an average 0.30% performance impact across our services (yes, only a third of a percent).<\/p><\/blockquote>\n\n<p>Previously:<\/p>\n<ul>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2023\/01\/06\/memory-safe-languages-in-android-13\/\">Memory Safe Languages in Android 13<\/a><\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"<p>Google Security: Based on an analysis of in-the-wild exploits tracked by Google&rsquo;s Project Zero, spatial safety vulnerabilities represent 40% of in-the-wild memory safety exploits over the past decade[&#8230;][&#8230;]A key element of our strategy focuses on Safe Coding and using memory-safe languages in new code.[&#8230;]However, this transition will take multiple years as we adapt our development [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"2024-11-18T22:12:12Z","apple_news_api_id":"393ea75e-50c2-444e-a8e5-8673cfab7430","apple_news_api_modified_at":"2024-11-18T22:12:13Z","apple_news_api_revision":"AAAAAAAAAAD\/\/\/\/\/\/\/\/\/\/w==","apple_news_api_share_url":"https:\/\/apple.news\/AOT6nXlDCRE6o5YZzz6t0MA","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[4],"tags":[326,27,456,74,71,48],"class_list":["post-45818","post","type-post","status-publish","format-standard","hentry","category-programming-category","tag-c-plus-plus","tag-craft","tag-googlechrome","tag-opensource","tag-programming","tag-security"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/45818","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=45818"}],"version-history":[{"count":1,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/45818\/revisions"}],"predecessor-version":[{"id":45819,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/45818\/revisions\/45819"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=45818"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=45818"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=45818"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}