{"id":21869,"date":"2023-04-27T16:10:46","date_gmt":"2023-04-28T00:10:46","guid":{"rendered":"http:\/\/www.palada.net\/index.php\/2023\/04\/27\/news-15600\/"},"modified":"2023-04-27T16:10:46","modified_gmt":"2023-04-28T00:10:46","slug":"news-15600","status":"publish","type":"post","link":"http:\/\/www.palada.net\/index.php\/2023\/04\/27\/news-15600\/","title":{"rendered":"Magecart threat actor rolls out convincing modal forms"},"content":{"rendered":"<p>To ensnare new victims, criminals will often devise schemes that attempt to look as&nbsp;realistic&nbsp;as possible. Having said that, it is not every day that we&nbsp;see&nbsp;the fraudulent copy exceed the original piece.<\/p>\n<p>While following up on an ongoing Magecart credit card skimmer campaign, we were almost fooled by a payment form that looked so well done we thought it was real. The threat actor used original logos from the compromised store and&nbsp;customized a web element known as a modal&nbsp;to perfectly hijack the checkout page.<\/p>\n<p>While the technique to insert frames or layers is not new, the remarkable thing here is that the skimmer looks more authentic than the original payment page. We were able to&nbsp;observe&nbsp;several more compromised sites with the same pattern of using a custom-made and fraudulent modal.<\/p>\n<p>This skimmer and associated campaigns represent one of the most active Magecart attacks we have been tracking in recent months.<\/p>\n<h2>Smooth checkout&nbsp;<\/h2>\n<p>We&nbsp;identified a&nbsp;compromised&nbsp;online&nbsp;website for&nbsp;a Parisian travel accessory&nbsp;store&nbsp;running on the PrestaShop CMS. A skimmer we <a href=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/03\/new-kritec-skimmer\" target=\"_blank\">previously identified as Kritec<\/a>, was injected and loading malicious JavaScript that&nbsp;altered the checkout process. In the following section, we will compare the checkout process when the skimmer is active and when it is not.<\/p>\n<h3>Fraudulent payment form<\/h3>\n<p>What we see here is the use of a &#8216;<a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/CSS\/:modal\" target=\"_blank\">modal<\/a>&#8216; which is a web page element displayed in front of the current active page. The modal disables and grays out the background so that the user can focus on the presented element instead. This is an elegant way for website owners to keep their customers on the same web site and have them interact with another form.<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file6854_264365_e.png\" alt=\"\" width=\"916\" height=\"676\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 1: Compromised store loads fake payment modal<\/em><\/p>\n<p>The problem is that this modal is entirely fake and designed to steal credit card data. It may sound hard to believe given everything matches to the original brand and feel of the site. Before digging further into why it is fraudulent, we will take a look at the same online store when the skimmer has been disabled.<\/p>\n<h3>Actual (real) payment form<\/h3>\n<p>In order to view this legitimate sequence, we first had to block the skimmer when requesting the e-commerce page. In our case, we simply blocked the connection to the malicious domain where the skimmer is hosted. As a result, the website will display what the original payment form should be (prior to the compromise).<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file73914_264365_e.png\" alt=\"\" width=\"987\" height=\"653\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 2: Legitimate payment form when same store is not compromised<\/em><\/p>\n<p>The actual payment flow for this merchant is to redirect users to a third-party processor hosted by Dalenys, <a href=\"https:\/\/www.payplug.com\/blog\/dalenys-joins-forces-with-payplug-to-transform-your-payments\/\" target=\"_blank\">now part of Payplug<\/a>, a French payment solutions company. So rather than display a modal, it loads the webpage for the payment processor to allow the user to enter their banking information. Once that is validated, it will take them back to the merchant page.<\/p>\n<h2>Malicious&nbsp;modal<\/h2>\n<p>The malicious modal is built very cleanly and contains an animation that&nbsp;displays the store&#8217;s logo in the middle and then moves it back up. We have to give credit where credit is due: this is a very well done skimmer that is actually a smoother user experience than the store&#8217;s default. We should also note that the malware author is not only well versed in web design, they also use proper language (French) for each form field.<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file68786_264365_e.png\" alt=\"\" width=\"521\" height=\"740\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 3: A closer look at the fake modal<\/em><\/p>\n<p>However, we noticed a small mistake in the hyperlink for <em>Politique de confidentialit&eacute;<\/em> (terms of use). That link redirects to the terms of use for <a href=\"https:\/\/www.mercadopago.com.ar\/\" target=\"_blank\">Mercardo Pago<\/a>, a payment processor&nbsp;used in South America. It is likely the threat actor copied the data from a previous template and did not notice their mistake. This is just a detail, and does not affect the functionality of the skimmer at all.<\/p>\n<p>We can try to look for this erroneous hyperlink within the skimmer source code in order to confirm that the modal&nbsp;was&nbsp;created by the threat actor. The skimmer is rather complex and heavily obfuscated but we can see that HTML content is&nbsp;generated dynamically and goes through a <em>decodeURIComponent<\/em> routine.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file14011_264365_e.png\" alt=\"\" width=\"818\" height=\"579\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><\/p>\n<p style=\"text-align: center;\"><em>Figure 4: Extracting code from the skimmer to reveal connection with the modal<\/em><\/p>\n<p>If we step through the code until the modal is loaded, we can grabbing the Base64 value corresponding to the HTML content. One we have it, we can convert it to plain text and finally see the reference to mercadopago,&nbsp;that is proof that the skimmer is the one rendering&nbsp;this beautiful modal. In fact, we can see the whole&nbsp;thing is&nbsp;an iframe called v.ECPay:<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file34067_264365_e.png\" alt=\"\" width=\"1059\" height=\"552\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 5: The iframe created by the skimmer to display the modal<\/em><\/p>\n<h2>Full payment flow<\/h2>\n<p>We recreated the payment flow from the perspective of a customer shopping via that compromised store. We can see that upon selecting the credit card payment option, the malicious modal is loaded and will harvest their payment card details.<\/p>\n<p>A fake error is then displayed briefly &#8220;votre paiment a &eacute;t&eacute; annul&eacute;&#8221; (your payment was cancelled) before the user is redirected to the real payment URL:<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file67566_264365_e.gif\" alt=\"\" width=\"1061\" height=\"976\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 6:&nbsp;Payment process flow with the skimmer active<\/em><\/p>\n<p>On the second attempt, the payment will go through and victims&nbsp;will be unaware of what just happened.<\/p>\n<p>The skimmer will drop a cookie which will serve as an indication that the current session is now marked as completed. If the user was to go back and attempt the payment again, the malicious modal would no longer be displayed (instead the real payment method by the external processor Dalenys will be used).<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file37928_264365_e.png\" alt=\"\" width=\"604\" height=\"400\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 7: Cookie dropped by skimmer once data has been stolen<\/em><\/p>\n<h2>Ongoing, covert campaigns<\/h2>\n<p>We now believe this Kritec skimmer is part of the same&nbsp;compromises with injections into vulnerable websites where malicious code is&nbsp;placed within the Google Tag Manager script. It is possible multiple threat actors are involved in&nbsp;those campaigns and customizing skimmers accordingly.<\/p>\n<p>While many hacked stores had a generic skimmer, it appears the custom modals&nbsp;were developed fairly recently, maybe a month or two ago. The threat actor is using different domains to host the skimmer but names them in a similar way: <strong>[name of store]-loader.js<\/strong>.<\/p>\n<p>We crawled several thousand e-commerce sites and found more fraudulent modals, in different languages.<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file72784_264365_e.png\" alt=\"\" width=\"737\" height=\"753\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 8: A Dutch e-commerce site with the fake modal<\/em><\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file18429_264365_e.png\" alt=\"\" width=\"695\" height=\"755\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 9: A Finnish e-commerce site with the fake modal<\/em><\/p>\n<p>Discerning whether an online store is trustworthy has become very difficult and this case is&nbsp;a&nbsp;good example of a skimmer that would not raise any suspicion.<\/p>\n<p>If you are a Malwarebytes customer, you will get a notification and block when attempting to make a purchase from a store that has been compromised by this skimmer.<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/easset_upload_file2247_264365_e.png\" alt=\"\" width=\"922\" height=\"350\" style=\"display: block; margin-left: auto; margin-right: auto;\" \/><em>Figure 10: Skimmer being blocked by Malwarebytes<\/em><\/p>\n<h2>Indicators of Compromise<\/h2>\n<p><strong>Domain names<\/strong><\/p>\n<pre>genlytec[.]us<br \/>shumtech[.]shop<br \/>zapolmob[.]sbs<br \/>daichetmob[.]sbs<br \/>interytec[.]shop<br \/>pyatiticdigt[.]shop<br \/>stacstocuh[.]quest<\/pre>\n<p><strong>IP addresses<\/strong><\/p>\n<pre>195.242.110[.]172<br \/>195.242.110[.]83<br \/>195.242.111[.]146<br \/>45.88.3[.]201<br \/>45.88.3[.]63<\/pre>\n<p><strong>YARA rule<\/strong><\/p>\n<div>\n<pre>rule&nbsp;kritecloader<br \/>{<br \/>&nbsp;strings:<br \/>&nbsp; &nbsp; &nbsp;$string = \"'fetchModul'\"<br \/>&nbsp; &nbsp; &nbsp;$string2 = \"'setAttribu'\"<br \/>&nbsp; &nbsp; &nbsp;$string3 = \"'contentWin'\"<br \/>&nbsp; &nbsp; &nbsp;$string4 = \"'zIndex'\"<br \/><br \/>condition:<br \/>&nbsp; &nbsp; all of them<br \/>}<\/pre>\n<hr \/>\n<p dir=\"ltr\">Whether you are visiting an&nbsp;online store from home or while at work, web protection is a critical layer&nbsp;in your&nbsp;overall&nbsp;defense. Malwarebytes Premium for&nbsp;<a href=\"https:\/\/www.malwarebytes.com\/premium\" target=\"_blank\">consumers<\/a>&nbsp;and Endpoint Protection for&nbsp;<a href=\"https:\/\/www.malwarebytes.com\/business\/endpoint-protection\" target=\"_blank\">businesses<\/a>&nbsp;provide real-time protection against threats like Magecart.<\/p>\n<p style=\"text-align: center;\"><a href=\"https:\/\/www.malwarebytes.com\/business\/contact-us\/\" class=\"blue-cta-bttn\">TRY NOW<\/a><\/p>\n<\/p><\/div>\n<p><a href=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/kritec-art\" target=\"bwo\" >https:\/\/blog.malwarebytes.com\/feed\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<table cellpadding=\"10\">\n<tr>\n<td valign=\"top\" align=\"left\">\n<p>Categories: <a href=\"https:\/\/www.malwarebytes.com\/blog\/category\/threat-intelligence\" rel=\"category tag\">Threat Intelligence<\/a><\/p>\n<p>Tags: magecart<\/p>\n<p>Tags: skimmer<\/p>\n<p>Tags: modal<\/p>\n<p>Tags: fraud<\/p>\n<p>Tags: e-commerce<\/p>\n<p>It&#8217;s hard to put individuals at fault when the malicious copy is better than the original. This credit card skimmer was built to fool just about anyone.<\/p>\n<table width=\"100%\">\n<tr>\n<td align=\"right\">\n<p><b>(<a href=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/kritec-art\" title=\"Magecart threat actor rolls out convincing modal forms\">Read more&#8230;<\/a>)<\/b><\/p>\n<\/td>\n<\/tr>\n<\/table>\n<\/td>\n<\/tr>\n<\/table>\n<p>The post <a rel=\"nofollow\" href=\"https:\/\/www.malwarebytes.com\/blog\/threat-intelligence\/2023\/04\/kritec-art\">Magecart threat actor rolls out convincing modal forms<\/a> appeared first on <a rel=\"nofollow\" href=\"https:\/\/www.malwarebytes.com\">Malwarebytes Labs<\/a>.<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"colormag_page_container_layout":"default_layout","colormag_page_sidebar_layout":"default_layout","footnotes":""},"categories":[10488,10378],"tags":[17476,9751,19622,29229,19623,12040],"class_list":["post-21869","post","type-post","status-publish","format-standard","hentry","category-malwarebytes","category-security","tag-e-commerce","tag-fraud","tag-magecart","tag-modal","tag-skimmer","tag-threat-intelligence"],"_links":{"self":[{"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/posts\/21869","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/comments?post=21869"}],"version-history":[{"count":0,"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/posts\/21869\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/media?parent=21869"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/categories?post=21869"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.palada.net\/index.php\/wp-json\/wp\/v2\/tags?post=21869"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}