{"id":6361,"date":"2024-04-08T14:34:18","date_gmt":"2024-04-08T21:34:18","guid":{"rendered":"https:\/\/objectsecurity.com\/?p=6361"},"modified":"2024-11-15T15:06:15","modified_gmt":"2024-11-15T23:06:15","slug":"xz-utils-backdoor","status":"publish","type":"post","link":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/","title":{"rendered":"Detecting the xz-utils Backdoor with Automation"},"content":{"rendered":"<p><div class=\"fusion-fullwidth fullwidth-box fusion-builder-row-1 fusion-flex-container has-pattern-background has-mask-background nonhundred-percent-fullwidth non-hundred-percent-height-scrolling\" style=\"--awb-border-radius-top-left:0px;--awb-border-radius-top-right:0px;--awb-border-radius-bottom-right:0px;--awb-border-radius-bottom-left:0px;--awb-flex-wrap:wrap;\" ><div class=\"fusion-builder-row fusion-row fusion-flex-align-items-flex-start fusion-flex-content-wrap\" style=\"max-width:1872px;margin-left: calc(-4% \/ 2 );margin-right: calc(-4% \/ 2 );\"><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-0 fusion_builder_column_1_1 1_1 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:100%;--awb-margin-top-large:0px;--awb-spacing-right-large:1.92%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:1.92%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-text fusion-text-1\"><p><span style=\"font-size: 16.0pt;\"><strong>In this ObjectSecurity blog post, we discuss how automated binary vulnerability analysis helps detect advanced attacks such as the recently discovered <em>&#8220;<code>xz-utils<\/code> backdoor&#8221;<\/em>, which was committed on March 25, 2024 to a ubiquitous library in the Linux ecosystem, via the <code>xz-utils<\/code> GitHub repository that has since been removed from the site by Github and Microsoft. This malware was disguised as a binary file meant to act as input for an <em>automated test<\/em> that runs along with new public build versions of the <code>xz-utils<\/code> library. Had this exploit not been detected by Andres Freund, a developer at Microsoft, countless Linux\/Unix systems would have become vulnerable to what is suspected to be a nation state attack.<br \/>\n<\/strong><\/span><\/p>\n<p>On March 25<sup>th<\/sup>, 2024, this intentional backdoor was committed to a ubiquitous library in the Linux ecosystem, via the <code>xz-utils<\/code> GitHub repository that has since been removed from the site by Github and Microsoft. This malware was disguised as a binary file meant to act as input for an <em>automated test<\/em> that runs along with new public build versions of the <code>xz-utils<\/code> library.<\/p>\n<p>Only after a multi-stage parsing process is completed, does the backdoor become injected into release versions of <em><code>xz-utils<\/code><\/em>. The payload injected at the end of this process results in a malicious shared object (.SO) file in versions 5.6.0 and 5.6.1 of the <code>liblzma<\/code> dependency of <code>xz-utils<\/code>.<\/p>\n<p><code>xz-utils<\/code> defines a shared library called <code>liblzma<\/code> that is meant to provide compression and decompression capabilities to numerous downstream dependents. One of these dependents is the SSH daemon, sshd. This daemon is the core program of any SSH server. Thus, had this attack succeeded, it would have effectively made Linux servers and computers open for unauthorized access. Thankfully, this exploit was detected by Andres Freund, a developer at Microsoft. You can read his original OSS post <a href=\"https:\/\/openwall.com\/lists\/oss-security\/2024\/03\/29\/4.\" target=\"_blank\" rel=\"noopener\"><\/a><u>here<\/u>. Due to the complexity of the exploit, it is suspected that a nation state is behind this attack.<\/p>\n<p>CISA has also catalogued this backdoor as <span style=\"text-decoration: underline;\"><a href=\"https:\/\/nvd.nist.gov\/vuln\/detail\/CVE-2024-3094\" target=\"_blank\" rel=\"noopener\"><\/a><\/span><u>CVE-2024-3094<\/u>.<\/p>\n<p><strong>This is the first attack of its kind: <\/strong>This is because the malware itself is not truly present in the source code alone. <u>Only when we examine the binary are we capable of detecting this backdoor<\/u>.<\/p>\n<\/div><div class=\"fusion-text fusion-text-2\"><h2>Finding the Abused <code><em>system()<\/em><\/code> Call<\/h2>\n<\/div><\/div><\/div><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-1 fusion_builder_column_1_2 1_2 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:50%;--awb-margin-top-large:0px;--awb-spacing-right-large:3.84%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:3.84%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-text fusion-text-3\"><p>The infected <code>libzma.so.5.6.X<\/code> instead allows for remote code execution (RCE) prior to authentication by extracting a command from the authenticating client&#8217;s SSH certificate and passing it to <code>system()<\/code>, in the place where <code>RSA_public_decrypt<\/code> would execute normally.<\/p>\n<p>If we perform a backtrace in GDB, we can see the path obfuscation taken before reaching <code>system()<\/code> (see screenshot).<\/p>\n<p>The analysis of the call shows a recursive structure at address <code>0x132C8<\/code> in the liblzma binary file. The process likely depends on interactions with other binaries, such as standard libraries, and this is likely a dead end for many more novice reverse engineers. What stands out, though, is the obfuscated control flow.<\/p>\n<\/div><\/div><\/div><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-2 fusion_builder_column_1_2 1_2 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:50%;--awb-margin-top-large:0px;--awb-spacing-right-large:3.84%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:3.84%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-image-element \" style=\"text-align:center;--awb-caption-title-font-family:var(--h2_typography-font-family);--awb-caption-title-font-weight:var(--h2_typography-font-weight);--awb-caption-title-font-style:var(--h2_typography-font-style);--awb-caption-title-size:var(--h2_typography-font-size);--awb-caption-title-transform:var(--h2_typography-text-transform);--awb-caption-title-line-height:var(--h2_typography-line-height);--awb-caption-title-letter-spacing:var(--h2_typography-letter-spacing);\"><span class=\" fusion-imageframe imageframe-none imageframe-1 hover-type-none\"><img data-recalc-dims=\"1\" decoding=\"async\" width=\"624\" height=\"409\" title=\"Picture14\" src=\"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture14.png?resize=624%2C409&#038;ssl=1\" alt class=\"img-responsive wp-image-4545\" srcset=\"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture14.png?resize=200%2C131&amp;ssl=1 200w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture14.png?resize=300%2C197&amp;ssl=1 300w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture14.png?resize=400%2C262&amp;ssl=1 400w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture14.png?resize=500%2C328&amp;ssl=1 500w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture14.png?resize=600%2C393&amp;ssl=1 600w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture14.png?fit=624%2C409&amp;ssl=1 624w\" sizes=\"(max-width: 1075px) 100vw, (max-width: 640px) 100vw, 624px\" \/><\/span><\/div><\/div><\/div><\/div><\/div><div class=\"fusion-fullwidth fullwidth-box fusion-builder-row-2 fusion-flex-container has-pattern-background has-mask-background nonhundred-percent-fullwidth non-hundred-percent-height-scrolling\" style=\"--awb-border-radius-top-left:0px;--awb-border-radius-top-right:0px;--awb-border-radius-bottom-right:0px;--awb-border-radius-bottom-left:0px;--awb-flex-wrap:wrap;\" ><div class=\"fusion-builder-row fusion-row fusion-flex-align-items-flex-start fusion-flex-content-wrap\" style=\"max-width:1872px;margin-left: calc(-4% \/ 2 );margin-right: calc(-4% \/ 2 );\"><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-3 fusion_builder_column_1_1 1_1 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:100%;--awb-margin-top-large:0px;--awb-spacing-right-large:1.92%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:1.92%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-text fusion-text-4\"><p>We now demonstrate the automated findings of <a href=\"https:\/\/objectsecurity.com\">ObjectSecurity&#8217;s BinLens\u2122<\/a> (formerly ObjectSecurity OT.AI Platform)\u00a0below, where this control flow is further analyzed and characterized as a particularly malevolent finding.<\/p>\n<h2>ROP Exploitation<\/h2>\n<p>The results of our analysis showed the liblzma binary to behave as a Return-Oriented Programming (ROP) attack. The output showed, consistently, an overly complex control flow and the presence of a vast amount of ROP weaknesses. This type of attack leverages existing code snippets within a program, known as \u201cgadgets,\u201d to execute arbitrary operations. Each gadget typically ends with a return instruction and is meticulously chosen to perform a step towards executing an attacker\u2019s payload without the need to inject new code, thus evading typical security measures that scan for code injections.<\/p>\n<h3>Understanding Return-Oriented Programming (ROP)<\/h3>\n<p>At its core, ROP is a sophisticated exploitation technique that abuses the way software handles subroutine returns. It manipulates the stack, which is a crucial data structure used to store return addresses and local variables for functions. In a typical ROP attack, an adversary carefully crafts a stack that includes a sequence of return addresses, each pointing to a chosen gadget. By manipulating the program\u2019s execution flow, these gadgets are executed in sequence to perform arbitrary actions.<\/p>\n<p>The technique hinges on finding and using sequences of machine instructions that are already present in the running program\u2019s memory, the \u201cgadgets\u201d. These gadgets are pieced together to construct a payload that achieves the attacker\u2019s objectives, such as compromising a system or stealing data.<\/p>\n<h3>Correlating Weird Control Flow with Increased ROP Attack Potential<\/h3>\n<p>The complexity of control flow in an application can significantly impact its vulnerability to ROP attacks. When control flow is irregular or convoluted, it often indicates numerous branches and potential execution paths. This environment can be ripe for ROP for several reasons:<\/p>\n<ol>\n<li><strong>Increased Gadget Availability<\/strong>: Complex control flows imply a higher diversity of code snippets and function epilogues. This variety provides a richer set of gadgets for attackers to exploit, enabling them to find the necessary components to string together their desired malicious functionality. <em>A prominent feature of the <code>liblzma<\/code> backdoor is its complex control flow and increased number of ROP gadgets.<\/em><\/li>\n<li><strong>Obfuscation and Detection Evasion<\/strong>: Irregular control flows can make it more challenging for static analysis tools to accurately map out potential execution paths and detect anomalous sequences that might signify an exploit. This obfuscation naturally aids attackers in hiding their exploit chains within the legitimate complexity of the software. <em>The <code>xz-utils<\/code> attack employs a sophisticated linker manipulation that can evade detection.<\/em><\/li>\n<li><strong>Compromised Flow Integrity<\/strong>: The very nature of ROP exploits involves diverting the intended control flow of a program. A binary that inherently contains complex or non-linear execution paths may be more susceptible to further manipulations without these anomalies being readily apparent to monitoring tools or even during manual review. <em>Once triggered, the <code>liblzma<\/code> attack highjacks the control flow to access the SSH daemon for backdoor access.<\/em><\/li>\n<\/ol>\n<h3>Unveiling the Veil: The Critical Role of Linker Operations in Cybersecurity<\/h3>\n<p>The Procedure Linkage Table (PLT) and the Global Offset Table (GOT) are fundamental components in the dynamic linking process that enables programs to utilize shared libraries for common functionality. This system is both programmable and dynamic, which conserves memory and supports modular programming. However, this flexibility also introduces significant risks. When manipulated, the PLT and GOT can alter the intended control flow of an application, potentially turning into conduits for ROP attacks.<\/p>\n<p>When malware, like that found in the <code>xz-utils<\/code> case, consistently interacts with the PLT and GOT at specific addresses, it reveals a methodical approach to hijack these mechanisms. This consistency is a critical signal, a pattern that, once recognized, can be monitored and mitigated against.<\/p>\n<h3>Correlation Between ROP Gadgets and Linker Addresses<\/h3>\n<p><a href=\"https:\/\/objectsecurity.com\">ObjectSecurity&#8217;s BinLens\u2122<\/a> (formerly ObjectSecurity OT.AI Platform) demonstrates consistent interactions at a common address, spanning multiple key sections that our platform utilizes to measure linker manipulations in PLT and GOT. This uniformity in address usage across four critical linker sections is an assessment of our platform&#8217;s monitoring capabilities. These findings also associated to a function, <code>__cxa_finalize<\/code>, that correlates to the presence of multiple ROP gadgets in this region:<\/p>\n<\/p>\n<p><span><code>Analyzing section 1<\/code><\/span><br \/>\n<span><code>__cxa_finalize at 17824 interacts with cat 1 linker ops<\/code><\/span><br \/>\n<span><code>Analyzing section 2<\/code><\/span><br \/>\n<span><code>__cxa_finalize at 17824 interacts with cat 2 linker ops <\/code><\/span><br \/>\n<span><code>Analyzing section 3<\/code><\/span><br \/>\n<span><code>__cxa_finalize at 17824 interacts with cat 3 linker ops<\/code><\/span><br \/>\n<span><code>Analyzing section 4<\/code><\/span><br \/>\n<span><code>__cxa_finalize at 17824 interacts with cat 4 linker ops<\/code><\/span><\/p>\n<div class=\"table-2\" style=\"--awb-margin-top:1px;--awb-margin-right:1px;--awb-margin-bottom:1px;--awb-margin-left:1px;\"><\/div>\n<p>\n<p>We report that this dual identification is shown as the basis of a detection mechanism for this class of attacks that leverage complex execution flows and ROP gadgets. With this level of insight, red, purple, and blue teams are equipped to preemptively address and neutralize sophisticated attack vectors, securing their systems against the most cunning of cyber adversaries.<\/p>\n<\/div><\/div><\/div><\/div><\/div><div class=\"fusion-fullwidth fullwidth-box fusion-builder-row-3 fusion-flex-container has-pattern-background has-mask-background nonhundred-percent-fullwidth non-hundred-percent-height-scrolling\" style=\"--awb-border-radius-top-left:0px;--awb-border-radius-top-right:0px;--awb-border-radius-bottom-right:0px;--awb-border-radius-bottom-left:0px;--awb-flex-wrap:wrap;\" ><div class=\"fusion-builder-row fusion-row fusion-flex-align-items-flex-start fusion-flex-content-wrap\" style=\"max-width:1872px;margin-left: calc(-4% \/ 2 );margin-right: calc(-4% \/ 2 );\"><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-4 fusion_builder_column_1_1 1_1 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:100%;--awb-margin-top-large:0px;--awb-spacing-right-large:1.92%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:1.92%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-text fusion-text-5\"><h2>Validation of Findings<\/h2>\n<p>We wanted to know with the unpatched and patched <code>liblzma<\/code> samples whether the detection of ROP gadgets alone is sufficient in making the determination that this backdoor exists within our analyses. The <em>logistic regression model<\/em> is chosen as an ideal method for this analysis because it allows for the integration of multiple factors and provides a probabilistic framework for assessing the impact of these factors on the likelihood of our platform\u2019s final determinations.<\/p>\n<p>We modeled our findings across three populations:<\/p>\n<ul>\n<li><strong>Liblzma5.6.0<\/strong> is an infected population<\/li>\n<li><strong>Liblzma5.6.1<\/strong> is an infected population<\/li>\n<li><strong>Liblzma5.6.2<\/strong> is the patched healthy population<\/li>\n<\/ul>\n<p>The analysis results are the number of total ROP gadgets, the number of ROP gadgets within the same region as a linker manipulated address with multiple categories of linker manipulations, and the number of categories of linker manipulations at a common address of four possible categories of linker manipulations.<\/p>\n<p>We regularized the logistic regression model to handle the issues of perfect separation, a common challenge in datasets with distinct group differences. This regularization helped stabilize the estimates and provided more reliable insights into the relationships between our predictors and the outcome.<\/p>\n<\/div><\/div><\/div><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-5 fusion_builder_column_1_2 1_2 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:50%;--awb-margin-top-large:0px;--awb-spacing-right-large:3.84%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:3.84%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-text fusion-text-6\"><p><strong>The results are as follows:<\/strong><\/p>\n<p>Coefficients: ([[-0.00069303, 0.30343857, 0.5774888]])<br \/>\nIntercept: ([-0.27405023])<\/p>\n<p><strong>Coefficients<\/strong>:<\/p>\n<ul>\n<li><strong>ROP Gadgets<\/strong>: (-0.00069303). Slightly decreases the likelihood of infection with increasing number. Minimal effect.<\/li>\n<li><strong>ROP Path<\/strong>: (0.30343857). Increases the likelihood of infection significantly with more detections.<\/li>\n<li><strong>Linker Manipulations<\/strong>: (0.5774888). Strongly increases the likelihood of infection with higher values; most influential factor.<\/li>\n<\/ul>\n<p><strong>Intercept<\/strong> ((-0.27405023)): Baseline log odds of being non-infected when all predictors are zero.<\/p>\n<\/div><\/div><\/div><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-6 fusion_builder_column_1_2 1_2 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:50%;--awb-margin-top-large:0px;--awb-spacing-right-large:3.84%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:3.84%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-image-element \" style=\"--awb-caption-title-font-family:var(--h2_typography-font-family);--awb-caption-title-font-weight:var(--h2_typography-font-weight);--awb-caption-title-font-style:var(--h2_typography-font-style);--awb-caption-title-size:var(--h2_typography-font-size);--awb-caption-title-transform:var(--h2_typography-text-transform);--awb-caption-title-line-height:var(--h2_typography-line-height);--awb-caption-title-letter-spacing:var(--h2_typography-letter-spacing);\"><span class=\" fusion-imageframe imageframe-none imageframe-2 hover-type-none\"><img data-recalc-dims=\"1\" decoding=\"async\" width=\"643\" height=\"483\" title=\"Picture15\" src=\"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture15.png?resize=643%2C483&#038;ssl=1\" alt class=\"img-responsive wp-image-4546\" srcset=\"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture15.png?resize=200%2C150&amp;ssl=1 200w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture15.png?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture15.png?resize=400%2C300&amp;ssl=1 400w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture15.png?resize=500%2C376&amp;ssl=1 500w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture15.png?resize=600%2C451&amp;ssl=1 600w, https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Picture15.png?fit=643%2C483&amp;ssl=1 643w\" sizes=\"(max-width: 1075px) 100vw, (max-width: 640px) 100vw, 643px\" \/><\/span><\/div><\/div><\/div><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-7 fusion_builder_column_1_1 1_1 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:100%;--awb-margin-top-large:0px;--awb-spacing-right-large:1.92%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:1.92%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div class=\"fusion-text fusion-text-7\"><p>This analysis shows that while ROP gadgets are prevalent in the infected populations, their sheer numbers alone do not significantly increase the likelihood of a backdoor being present. Instead, the context in which these gadgets appear, particularly their association with linker manipulations, is necessary for backdoor detection.<\/p>\n<p>Therefore, the results from this analysis shows that the Linker Manipulations analysis of <a href=\"https:\/\/objectsecurity.com\">ObjectSecurity&#8217;s BinLens\u2122<\/a> (formerly ObjectSecurity OT.AI Platform)\u00a0is the strongest predictor of detecting a ROP backdoor, followed by the ROP Path that depends on the findings from Linker Manipulations. The analysis of ROP gadgets alone has a negligible inverse effect on infection likelihood, indicating that their presence must be contextualized with more specific manipulative actions to accurately detect backdoors.<\/p>\n<h2>A Call to Arms in Cybersecurity: Detecting <code><em>liblzma<\/em><\/code> Attack in BinLens<\/h2>\n<p>The significance of finding ROP gadgets corresponding to addresses associated with the PLT and GOT cannot be overstated. ROP is a cunning exploitation technique that avoids direct code injection by reusing existing code snippets in the program. By chaining these snippets, attackers can execute arbitrary malicious functionality. The presence of ROP gadgets at PLT and GOT addresses is particularly alarming \u2014 it suggests that these critical sections are being targeted as vector points for executing attack sequences.<\/p>\n<p>In light of the recent security breach through the <code>xz-utils<\/code> library, <a href=\"https:\/\/objectsecurity.com\">ObjectSecurity&#8217;s BinLens\u2122<\/a> (formerly ObjectSecurity OT.AI Platform)\u00a0stands ready as a fully automated and effective solution designed to detect such backdoors and other exploits. It provides comprehensive tools that benefit red, purple, and blue teams, ensuring greater visibility within the binary samples of critical infrastructure.<\/p>\n<p>This exploration into the depths of dynamic linking and ROP exploits is a testament to the power of modern cybersecurity defense strategies, such as offered by <a href=\"https:\/\/objectsecurity.com\">ObjectSecurity&#8217;s BinLens\u2122<\/a> (formerly ObjectSecurity OT.AI Platform). As we share these insights, we invite the global community to engage, learn, and fortify.<\/p>\n<p>The fight against cyber threats is relentless, but so are we. Let\u2019s turn our knowledge into our most potent weapon in the cybersecurity arsenal.<\/p>\n<h2><strong>Resources<\/strong><\/h2>\n<ol>\n<li>Freund, Andres. oss-security mailing list. &#8220;backdoor in upstream xz\/liblzma leading to ssh server compromise&#8221;. 3\/29\/24. <a href=\"https:\/\/openwall.com\/lists\/oss-security\/2024\/03\/29\/4\">https:\/\/openwall.com\/lists\/oss-security\/2024\/03\/29\/4<\/a><\/li>\n<li>NIST. &#8220;CVE-2024-3094 Detail&#8221;. 3\/29\/24. <a href=\"https:\/\/nvd.nist.gov\/vuln\/detail\/CVE-2024-3094\">https:\/\/nvd.nist.gov\/vuln\/detail\/CVE-2024-3094<\/a><\/li>\n<li>Weems, Anthony. xzbot Github page.\u00a0 <a href=\"https:\/\/github.com\/amlweems\/xzbot\/tree\/main?tab=readme-ov-file\">https:\/\/github.com\/amlweems\/xzbot\/tree\/main?tab=readme-ov-file<\/a><\/li>\n<li>smx. XZ Backdoor Analysis Github page. <a href=\"https:\/\/gist.github.com\/smx-smx\/a6112d54777845d389bd7126d6e9f504\">https:\/\/gist.github.com\/smx-smx\/a6112d54777845d389bd7126d6e9f504<\/a><\/li>\n<li><a href=\"https:\/\/objectsecurity.com\">ObjectSecurity&#8217;s BinLens\u2122<\/a> (formerly ObjectSecurity OT.AI Platform) website. <a href=\"https:\/\/objectsecurity.com\">https:\/\/objectsecurity.com<\/a><\/li>\n<\/ol>\n<\/div><\/div><\/div><\/div><\/div><div class=\"fusion-fullwidth fullwidth-box fusion-builder-row-4 fusion-flex-container has-pattern-background has-mask-background nonhundred-percent-fullwidth non-hundred-percent-height-scrolling\" style=\"--awb-border-radius-top-left:0px;--awb-border-radius-top-right:0px;--awb-border-radius-bottom-right:0px;--awb-border-radius-bottom-left:0px;--awb-flex-wrap:wrap;\" ><div class=\"fusion-builder-row fusion-row fusion-flex-align-items-flex-start fusion-flex-content-wrap\" style=\"max-width:1872px;margin-left: calc(-4% \/ 2 );margin-right: calc(-4% \/ 2 );\"><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-8 fusion_builder_column_1_3 1_3 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:33.333333333333%;--awb-margin-top-large:0px;--awb-spacing-right-large:5.76%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:5.76%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div style=\"text-align:center;\"><a class=\"fusion-button button-flat button-xlarge button-default fusion-button-default button-1 fusion-button-default-span fusion-button-default-type\" style=\"--button-border-radius-top-left:2px;--button-border-radius-top-right:2px;--button-border-radius-bottom-right:2px;--button-border-radius-bottom-left:2px;\" target=\"_self\" href=\"https:\/\/objectsecurity.com\/objectsecurity_ot_ai_platform\/\"><span class=\"fusion-button-text\">BinLens<\/span><\/a><\/div><\/div><\/div><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-9 fusion_builder_column_1_3 1_3 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:33.333333333333%;--awb-margin-top-large:0px;--awb-spacing-right-large:5.76%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:5.76%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div style=\"text-align:center;\"><a class=\"fusion-button button-flat button-xlarge button-default fusion-button-default button-2 fusion-button-default-span fusion-button-default-type\" style=\"--button-border-radius-top-left:2px;--button-border-radius-top-right:2px;--button-border-radius-bottom-right:2px;--button-border-radius-bottom-left:2px;\" target=\"_self\" href=\"https:\/\/objectsecurity.com\/contact-us\/\"><span class=\"fusion-button-text\">Contact Us<\/span><\/a><\/div><\/div><\/div><div class=\"fusion-layout-column fusion_builder_column fusion-builder-column-10 fusion_builder_column_1_3 1_3 fusion-flex-column\" style=\"--awb-bg-size:cover;--awb-width-large:33.333333333333%;--awb-margin-top-large:0px;--awb-spacing-right-large:5.76%;--awb-margin-bottom-large:20px;--awb-spacing-left-large:5.76%;--awb-width-medium:100%;--awb-order-medium:0;--awb-spacing-right-medium:1.92%;--awb-spacing-left-medium:1.92%;--awb-width-small:100%;--awb-order-small:0;--awb-spacing-right-small:1.92%;--awb-spacing-left-small:1.92%;\"><div class=\"fusion-column-wrapper fusion-column-has-shadow fusion-flex-justify-content-flex-start fusion-content-layout-column\"><div style=\"text-align:center;\"><a class=\"fusion-button button-flat button-xlarge button-default fusion-button-default button-3 fusion-button-default-span fusion-button-default-type\" style=\"--button-border-radius-top-left:2px;--button-border-radius-top-right:2px;--button-border-radius-bottom-right:2px;--button-border-radius-bottom-left:2px;\" target=\"_self\" href=\"https:\/\/objectsecurity.com\/tech-blog\/#followblog\"><span class=\"fusion-button-text\">Follow Our Blog<\/span><\/a><\/div><\/div><\/div><\/div><\/div><\/p>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":8,"featured_media":4601,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[63,39,87],"tags":[],"class_list":["post-6361","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-binlens","category-ot-ics-cybersecurity","category-tech"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Detecting the xz-utils Backdoor with Automation - ObjectSecurity<\/title>\n<meta name=\"robots\" content=\"noindex, follow\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/\"},\"author\":{\"name\":\"ObjectSecurity LLC\",\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/#\\\/schema\\\/person\\\/b95c5e028381014293b246279d5006bb\"},\"headline\":\"Detecting the xz-utils Backdoor with Automation\",\"datePublished\":\"2024-04-08T21:34:18+00:00\",\"dateModified\":\"2024-11-15T23:06:15+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/\"},\"wordCount\":8712,\"image\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/objectsecurity.com\\\/wp-content\\\/uploads\\\/2024\\\/04\\\/Untitled-design-1.png?fit=600%2C337&ssl=1\",\"articleSection\":[\"BinLens\",\"OT\\\/ICS Cybersecurity\",\"Technical\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/\",\"url\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/\",\"name\":\"Detecting the xz-utils Backdoor with Automation - ObjectSecurity\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/objectsecurity.com\\\/wp-content\\\/uploads\\\/2024\\\/04\\\/Untitled-design-1.png?fit=600%2C337&ssl=1\",\"datePublished\":\"2024-04-08T21:34:18+00:00\",\"dateModified\":\"2024-11-15T23:06:15+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/#\\\/schema\\\/person\\\/b95c5e028381014293b246279d5006bb\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/#primaryimage\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/objectsecurity.com\\\/wp-content\\\/uploads\\\/2024\\\/04\\\/Untitled-design-1.png?fit=600%2C337&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/objectsecurity.com\\\/wp-content\\\/uploads\\\/2024\\\/04\\\/Untitled-design-1.png?fit=600%2C337&ssl=1\",\"width\":600,\"height\":337},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/xz-utils-backdoor\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/objectsecurity.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Detecting the xz-utils Backdoor with Automation\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/#website\",\"url\":\"https:\\\/\\\/objectsecurity.com\\\/\",\"name\":\"ObjectSecurity\",\"description\":\"OT\\\/ICS Asset Binary Vulnerability Analysis and Reporting\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/objectsecurity.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/objectsecurity.com\\\/#\\\/schema\\\/person\\\/b95c5e028381014293b246279d5006bb\",\"name\":\"ObjectSecurity LLC\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/be2a06226a4b21354a1205403b77c97bbc16034deb14ef458f64ac034957bf3a?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/be2a06226a4b21354a1205403b77c97bbc16034deb14ef458f64ac034957bf3a?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/be2a06226a4b21354a1205403b77c97bbc16034deb14ef458f64ac034957bf3a?s=96&d=mm&r=g\",\"caption\":\"ObjectSecurity LLC\"},\"description\":\"ObjectSecurity LLC is a leader in solving complex, evolving defense and industrial cybersecurity and supply chain risk challenges that threaten national security and production downtime.\",\"sameAs\":[\"https:\\\/\\\/objectsecurity.com\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Detecting the xz-utils Backdoor with Automation - ObjectSecurity","robots":{"index":"noindex","follow":"follow"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/#article","isPartOf":{"@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/"},"author":{"name":"ObjectSecurity LLC","@id":"https:\/\/objectsecurity.com\/#\/schema\/person\/b95c5e028381014293b246279d5006bb"},"headline":"Detecting the xz-utils Backdoor with Automation","datePublished":"2024-04-08T21:34:18+00:00","dateModified":"2024-11-15T23:06:15+00:00","mainEntityOfPage":{"@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/"},"wordCount":8712,"image":{"@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Untitled-design-1.png?fit=600%2C337&ssl=1","articleSection":["BinLens","OT\/ICS Cybersecurity","Technical"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/","url":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/","name":"Detecting the xz-utils Backdoor with Automation - ObjectSecurity","isPartOf":{"@id":"https:\/\/objectsecurity.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/#primaryimage"},"image":{"@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Untitled-design-1.png?fit=600%2C337&ssl=1","datePublished":"2024-04-08T21:34:18+00:00","dateModified":"2024-11-15T23:06:15+00:00","author":{"@id":"https:\/\/objectsecurity.com\/#\/schema\/person\/b95c5e028381014293b246279d5006bb"},"breadcrumb":{"@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/objectsecurity.com\/xz-utils-backdoor\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/#primaryimage","url":"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Untitled-design-1.png?fit=600%2C337&ssl=1","contentUrl":"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Untitled-design-1.png?fit=600%2C337&ssl=1","width":600,"height":337},{"@type":"BreadcrumbList","@id":"https:\/\/objectsecurity.com\/xz-utils-backdoor\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/objectsecurity.com\/"},{"@type":"ListItem","position":2,"name":"Detecting the xz-utils Backdoor with Automation"}]},{"@type":"WebSite","@id":"https:\/\/objectsecurity.com\/#website","url":"https:\/\/objectsecurity.com\/","name":"ObjectSecurity","description":"OT\/ICS Asset Binary Vulnerability Analysis and Reporting","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/objectsecurity.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/objectsecurity.com\/#\/schema\/person\/b95c5e028381014293b246279d5006bb","name":"ObjectSecurity LLC","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/be2a06226a4b21354a1205403b77c97bbc16034deb14ef458f64ac034957bf3a?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/be2a06226a4b21354a1205403b77c97bbc16034deb14ef458f64ac034957bf3a?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/be2a06226a4b21354a1205403b77c97bbc16034deb14ef458f64ac034957bf3a?s=96&d=mm&r=g","caption":"ObjectSecurity LLC"},"description":"ObjectSecurity LLC is a leader in solving complex, evolving defense and industrial cybersecurity and supply chain risk challenges that threaten national security and production downtime.","sameAs":["https:\/\/objectsecurity.com"]}]}},"jetpack_featured_media_url":"https:\/\/i0.wp.com\/objectsecurity.com\/wp-content\/uploads\/2024\/04\/Untitled-design-1.png?fit=600%2C337&ssl=1","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/posts\/6361","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/comments?post=6361"}],"version-history":[{"count":2,"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/posts\/6361\/revisions"}],"predecessor-version":[{"id":6596,"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/posts\/6361\/revisions\/6596"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/media\/4601"}],"wp:attachment":[{"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/media?parent=6361"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/categories?post=6361"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/objectsecurity.com\/wp-json\/wp\/v2\/tags?post=6361"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}