Pentest Chronicles
An attacker with physical access to the machine can attach a hardware device or use specialized tools to monitor the SPI bus traffic between the TPM and the CPU. If the attacker successfully captures the communication between the TPM and Clevis, they may be able to extract the encryption key or other sensitive data involved in unlocking the LUKS-encrypted disk. To avoid damaging the supplied equipment, the attack was carried out on an alternative device equipped with dTPM. However, the encryption configuration was preserved. The equipment used is MiniPC MSI Cubi N ADL-001BEU N200, equipped with a OPTIGA TPM SLB 9672 module.
At the very bottom of the page is the code snippet that needs to be written to the pd.py and __init__.py files. These files should then be moved to the following location:
Step 2. Connecting a logic analyzer To intercept the communication between the TPM and the processor, it is first necessary to identify the model of the module being used. This can be done in two ways:
2. Having physical access to the device, read the model directly from the module. Due to its size, this usually requires the use of a magnifying glass:
3. Then find the datasheet of the module on the manufacturer's website, in this case it is:
4. Next, find the module's footprint and identify the following pins relatively to small white dot:
5. Knowing the position of the pins, it is now necessary to connect the logic analyzer probe to these pins:
6. In addition, it is worth finding information about the voltage used by the module. Usually this is the supply voltage. It will be needed to properly set the sensitivity of the device.
4. Sample rate configuration. In this case, select the highest possible frequency offered. Note, some devices limit the maximum frequency depending on the number of sampled channels:
5. Configuration of the amount of sample collection.
Software and hardware are now ready to launch an SPI Sniffing attack.
2. Select the densest period of the waveform, where Chip Select is zero and data are transferred:
3. Save this waveform to a file via “Save Selected Range As...”:
4. Open the newly created file.
d. Click on the TPM waveform.
6. When the plug-in analyzes the waveform, the data obtained in the “TPM2.0: FIFO Read” line should be exported to a .txt file.
8. Then execute the script, where the path to the exported .txt file should be given as an argument:
9. One by one, this script cleans up the data from the time tags, converts the contents of the .txt file into a continuous hex record, and then searches for the 00000072 bytes that mark the start of the JWK in communication with the TPM. It then takes the next two bytes that mark the size of the JWK and extracts its contents.
11. Then run the following script to get the password. This script combines the JWK (encryption key) and JWE (ciphertext), and then decrypts the disk password using the jose tool:
12. Finally, to unlock the drive, run the following command:
The penetration test demonstrated that SPI Sniffing is a viable attack vector, allowing an attacker with physical access to intercept communication between the TPM and processor, ultimately compromising the encryption keys used by Clevis or BitLocker. This vulnerability stems from the lack of secure communication protocols on the SPI bus, exposing sensitive data during the decryption process. Summary To mitigate this risk, systems should implement encrypted communication on the SPI bus or alternative secure methods for key exchange. Additionally, physical access to devices must be restricted through stronger physical security measures. Ensuring firmware is up-to-date and adopting hardware with enhanced protection mechanisms, such as Secure Boot, can further safeguard against such attacks. These measures collectively enhance the resilience of encryption systems against physical compromise. 
In today's world, ensuring the security of our accounts is more crucial than ever. Just as keys protect the doors to our homes, passwords serve as the first line of defense for our data and assets. It's easy to assume that technical individuals, such as developers and IT professionals, always use strong, unique passwords to keep ...

SOCMINT is the process of gathering and analyzing the information collected from various social networks, channels and communication groups in order to track down an object, gather as much partial data as possible, and potentially to understand its operation. All this in order to analyze the collected information and to achieve that goal by making …

PyScript – or rather Python in your browser + what can be done with it? A few days ago, the Anaconda project announced the PyScript framework, which allows Python code to be executed directly in the browser. Additionally, it also covers its integration with HTML and JS code. An execution of the Python code in …