Trustwave Unveils New Offerings to Maximize Value of Microsoft Security Investments. Learn More

Trustwave Unveils New Offerings to Maximize Value of Microsoft Security Investments. Learn More

Managed Detection & Response

Eliminate active threats with 24/7 threat detection, investigation, and response.

Co-Managed SOC (SIEM)

Maximize your SIEM investment, stop alert fatigue, and enhance your team with hybrid security operations support.

Advisory & Diagnostics

Advance your cybersecurity program and get expert guidance where you need it most.

Penetration Testing

Test your physical locations and IT infrastructure to shore up weaknesses before exploitation.

Database Security

Prevent unauthorized access and exceed compliance requirements.

Email Security

Stop email threats others miss and secure your organization against the #1 ransomware attack vector.

Digital Forensics & Incident Response

Prepare for the inevitable with 24/7 global breach response in-region and available on-site.

Firewall & Technology Management

Mitigate risk of a cyberattack with 24/7 incident and health monitoring and the latest threat intelligence.

Offensive Security
Solutions to maximize your security ROI
Microsoft Exchange Server Attacks
Stay protected against emerging threats
Rapidly Secure New Environments
Security for rapid response situations
Securing the Cloud
Safely navigate and stay protected
Securing the IoT Landscape
Test, monitor and secure network objects
Why Trustwave
About Us
Awards and Accolades
Trustwave SpiderLabs Team
Trustwave Fusion Security Operations Platform
Trustwave Security Colony
Technology Alliance Partners
Key alliances who align and support our ecosystem of security offerings
Trustwave PartnerOne Program
Join forces with Trustwave to protect against the most advance cybersecurity threats
SpiderLabs Blog

Attacking SCADA Part III: Hardcoded Salt in Schneider Electric EcoStruxure Machine Expert (CVE-2020-28214)

This is part three of our Schneider Electric series. You can read part one here and part two here.


When the engineer activates the passwords for application protection, the passwords are hashed and stored in the local project file, which ends with the extension smbp. If we open this file in a notepad, we can find the hashed passwords in this section.

Image001Figure 1: Password hashes in the project file


Machine Expert main application is developed with .NET framework. This can be reversed by using dnSpy or any equivalent .NET disassembler.

We were able to find the hard-coded salt in this file:

  • SoMachineBasic.CommonUtility.dll.

In this file, there is a class called EncryptionHelper found in  “SchneiderElectric.Automation.SoMachineBasic.Common.CommonUtility.Cryptography”. This class contains two functions – EncryptSha256 and EncryptSha256Salted.

EncryptSha256 is used to hash the plaintext password. EncryptSha256Salted is used to hash the hashed password again with a hard-coded salt as shown in Figure 2. EncryptSha256Salted appends a hard-coded value to password before hashing it again using EncryptSha256. Since the function uses a hard-coded salt, the same input will always yield the same output. This makes it possible for the attacker to brute force and identify the plaintext password.

Image002Figure 2: These two functions are used to hash the plaintext passwords that are used in the application protections

We wrote a proof-of-concept code in python to demonstrate this vulnerability. This code can be executed using this command: python3 <password to hash>.


This is the result from running the POC code.

The output from the script is shown in Figure 3. The plaintext password is “password” and it outputs to “0f55c2a5f886d612ad7f919918a49b4af2390f00222600ccdbec10c836c9b2c8”. This output is identical to what we have shown in Figure 2.

Image004Figure 3: Output from the POC code. The hashed password is exactly the same as the one shown in Figure 2 as the plaintext password used in both cases is “password”


It will be possible for the attacker to build a rainbow table and run brute-force attack to identify the plaintext password used to activate the application protection. This attack does not require the attacker to have any access to network traffic. The attacker can run this POC code offline and do a match to the hashed passwords found in the project files. Once the attacker has the plaintext passwords, he will have sufficient privilege to make changes to the protected application on the controller.


Trustwave Advisory TWSL2020-007

Latest SpiderLabs Blogs

Search & Spoof: Abuse of Windows Search to Redirect to Malware

Trustwave SpiderLabs has detected a sophisticated malware campaign that leverages the Windows search functionality embedded in HTML code to deploy malware. We found the threat actors utilizing a...

Read More

The Sentinel’s Watch: Building a Security Reporting Framework

Imagine being on shift as the guard of a fortress. Your job is to identify threats as they approach the perimeter. The more methods you have for detecting those threats, the better your chances of...

Read More

Fake Advanced IP Scanner Installer Delivers Dangerous CobaltStrike Backdoor

During a recent client investigation, Trustwave SpiderLabs found a malicious version of the Advanced IP Scanner installer, which contained a backdoored DLL module. Our client had been searching for...

Read More