{"id":32104,"date":"2024-06-28T19:00:21","date_gmt":"2024-06-28T13:30:21","guid":{"rendered":"https:\/\/www.getastra.com\/blog\/?p=32104"},"modified":"2024-06-29T22:21:27","modified_gmt":"2024-06-29T16:51:27","slug":"polyfill-supply-chain-attack","status":"publish","type":"post","link":"https:\/\/www.getastra.com\/blog\/security-audit\/polyfill-supply-chain-attack\/","title":{"rendered":"Polyfill Supply Chain Attack Injects 100,000+ Websites with Malware via CDN Assets"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\"><code>Polyfill.js<\/code> is a Javascript library that helps old browsers run new modern features which these old browsers do not support natively. The library is popular among developers for helping them offer consistent user experience regardless of the browser environment the user is using. In February 2024, a Chinese company bought the domain <code>polyfill.io<\/code>  and the Github account associated with it. Since then, they&#8217;ve been serving malware via <code>cdn.polyfill.io<\/code> as pointed by the team at <a href=\"https:\/\/sansec.io\/research\/polyfill-supply-chain-attack\" target=\"_blank\" rel=\"noopener\">Sansec<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Who_is_Impacted\"><\/span>Who is Impacted?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">More than 100,000 websites embed <code>cdn.polyfill.io<\/code> to support old browser compatibility. A comprehensive list of websites <a href=\"https:\/\/publicwww.com\/websites\/%22cdn.polyfill.io%22\/\" target=\"_blank\" rel=\"noopener\">can be seen here<\/a>, some popular names include Intuit, Metro, pCloud etc.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It was found that the same company has been injecting malware from a number of other domains too, these include &#8211; <code>bootcss.com, bootcdn.net, staticfile.net etc.<\/code><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If we combine the impact of above domains, the total number of affected websites is more than 300,000. <\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Chronology_of_The_%E2%80%98Supply_Chain\"><\/span>Chronology of The &#8216;Supply Chain&#8217; <span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"has-text-color has-background has-link-color wp-elements-124288e817f2e22fa1b917256beb0928 wp-block-paragraph\" style=\"color:#333333;background-color:#fef1d5;font-size:18px\">Your security is as strong as your weakest link.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">A supply chain attack works on the above principle. It attacks the weakest link in the entire stream of an attack, instead of directly targeting the end victim. Often organizations are targeted through their suppliers or open source libraries they&#8217;re using as a part of the supply chain attack. Here&#8217;s how the Polyfill supply chain attack happened: <\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>The OSS code for polyfill was hosted on Fastly and was maintained by the community.<\/li>\n\n\n\n<li>The last maintainer announced that they&#8217;re selling the project to a Chinese company in February 2024. This Chinese company apparently was into CDN services.<\/li>\n\n\n\n<li>After acquisition the a new CNAME was added to the <code>polyfill.io<\/code> domain &#8211; <code>polyfill.io.bsclink.cn<\/code><\/li>\n\n\n\n<li>The moment above happened, polyfill&#8217;s original creator warned everyone:<\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1176\" height=\"744\" src=\"\/cdn-cgi\/image\/quality=80,format=auto,onerror=redirect,metadata=none\/https:\/\/cdn-blog.getastra.com\/2024\/06\/c25b2ea8-polyfill-supply-chain-attack-tweet-from-founder.png\" alt=\"\" class=\"wp-image-32126\" style=\"width:841px;height:auto\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">The above was pointed out by several users on Github too. Here&#8217;s <a href=\"https:\/\/github.com\/formatjs\/formatjs\/issues\/4363\" target=\"_blank\" rel=\"noopener\">another example<\/a> where a Github user noticed the CNAME change.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"How_to_detect_if_you_are_vulnerable_to_Polyfill_Supply_Chain_Attack\"><\/span>How to detect if you are vulnerable to Polyfill Supply Chain Attack?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li>If you use Polyfill, there&#8217;s a high probability that the polyfill js vulnerability affected you as well. If CDN provider is serving traffic from one of the affected domains listed below, then you might be affected:\n<ul class=\"wp-block-list\">\n<li>cdn.polyfill.io<\/li>\n\n\n\n<li><code>bootcss.com<\/code><\/li>\n\n\n\n<li><code>bootcdn.net<\/code><\/li>\n\n\n\n<li><code>staticfile.net<\/code><\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>Some of the symptoms of the Polyfill io attack infection include:<\/strong>\n<ul class=\"wp-block-list\">\n<li>Redirection of end users to malicious sites<\/li>\n\n\n\n<li>Cross Site Scripting (XSS) attacks<\/li>\n\n\n\n<li>Stealing user information or hijacking sessions<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\"><a href=\"https:\/\/www.getastra.com\/services\/vulnerability-scanning-services\">Astra&#8217;s Vulnerability Scanner<\/a> is Actively Detecting Polyfill Supply Chain Attack<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The security research and detection team at Astra keeps a close eye on such vulnerabilities. We&#8217;ve proactively added detection for Polyfill supply chain attack.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1400\" height=\"800\" src=\"\/cdn-cgi\/image\/quality=80,format=auto,onerror=redirect,metadata=none\/https:\/\/cdn-blog.getastra.com\/2024\/06\/68f4098d-polyfill-vulnerability-detection-astra.png\" alt=\"\" class=\"wp-image-32143\" srcset=\"\/cdn-cgi\/image\/quality=80,format=auto,onerror=redirect,metadata=none\/https:\/\/cdn-blog.getastra.com\/2024\/06\/68f4098d-polyfill-vulnerability-detection-astra.png 1400w, \/cdn-cgi\/image\/width=400,height=230,fit=crop,quality=80,format=auto,onerror=redirect,metadata=none\/https:\/\/cdn-blog.getastra.com\/2024\/06\/68f4098d-polyfill-vulnerability-detection-astra.png 400w\" sizes=\"auto, (max-width: 1400px) 100vw, 1400px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n<style>\n.astraPentestWrap{\n  padding:35px;\n  border: 6px;\n  background-image: url('https:\/\/cdn-blog.getastra.com\/2024\/08\/838dc804-smallimgicbg.png');\n  background-size: cover;\n  background-repeat: no-repeat;\n  position: relative;\n  background-position: right;\n  height: auto;\n  border-radius: 10px;\n  margin: 20px 0px;\n}\n.pentestHeading{\n  color: #575757;\n  font-size: 24px;\n  font-weight: 600;\n  color: #575757;\n  max-width: 450px;\n}\n.ctaHead {\n    display: flex;\n    align-items: center;\n    grid-gap: 1rem;\n}\n.ctaOne {\n    text-decoration: none;\n    background-color: #2F76F8;\n    color: #ffffff !important;\n    padding: 10px 25px;\n    border-radius: 6px;\n    font-weight: 600;\n}\n.ctaTwo {\n    text-decoration: none;\n    background-color: #24BC94;\n    color: #ffffff !important;\n    padding: 10px 25px;\n    border-radius: 6px;\n    font-weight: 600;\n}\n.spanBoldBlue {\n    color: #3078FE;\n    font-weight: 700;\n}\n.animeImg{\n  position: absolute;\n  bottom: 0px;\n  right: -20px;\n  height: 250px;\n  width: 240px;\n}\n@media(max-width: 768px){\n}\n@media(max-width: 576px){\n   .pentestHeading{\n      font-size: 28px;\n    }\n   .ctaHead{\n     flex-direction: column;\n     align-items: flex-start;\n   }\n   .animeImg{\n    display: none;\n  }\n}\n<\/style>\n<div class=\"astraPentestWrap\">\n<p class=\"pentestHeading\">Astra Pentest is built by the team of experts that helped\u00a0secure <span class=\"spanBoldBlue\">Microsoft, Adobe, Facebook, and Buffer<\/span><\/p>\n\n<div class=\"ctaHead\"><a class=\"ctaOne\" href=\"\/contact-us\" target=\"_blank\" rel=\"noopener\">Book a Demo<\/a>\n<a class=\"ctaTwo\" href=\"\/pentest\/pricing\" target=\"_blank\" rel=\"noopener\">View Pricing<\/a><\/div>\n<img decoding=\"async\" class=\"animeImg\" src=\"\/cdn-cgi\/image\/quality=80,format=auto,onerror=redirect,metadata=none\/https:\/\/cdn-blog.getastra.com\/2024\/08\/96ad3cf0-girlcta.png\" alt=\"character\" \/>\n\n<\/div>","protected":false},"excerpt":{"rendered":"<p>Polyfill.js is a Javascript library that helps old browsers run new modern features which these old browsers do not support natively. The library is popular among developers for helping them offer consistent user experience regardless of the browser environment the user is using. In February 2024, a Chinese company bought the domain polyfill.io and the &#8230; <a title=\"Polyfill Supply Chain Attack Injects 100,000+ Websites with Malware via CDN Assets\" class=\"read-more\" href=\"https:\/\/www.getastra.com\/blog\/security-audit\/polyfill-supply-chain-attack\/\" aria-label=\"Read more about Polyfill Supply Chain Attack Injects 100,000+ Websites with Malware via CDN Assets\">Read more<\/a><\/p>\n","protected":false},"author":2,"featured_media":32149,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[340],"tags":[],"class_list":["post-32104","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-security-audit"],"_links":{"self":[{"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/posts\/32104","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/comments?post=32104"}],"version-history":[{"count":13,"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/posts\/32104\/revisions"}],"predecessor-version":[{"id":32178,"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/posts\/32104\/revisions\/32178"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/media\/32149"}],"wp:attachment":[{"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/media?parent=32104"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/categories?post=32104"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.getastra.com\/blog\/wp-json\/wp\/v2\/tags?post=32104"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}