> For the complete documentation index, see [llms.txt](https://learn.cypherock.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://learn.cypherock.com/security-overview/physical-attacks/side-channel-attack.md).

# Side Channel Attack

A side-channel attack is a type of attack that targets the physical implementation of a cryptographic system, such as a hardware wallet, rather than the underlying mathematical algorithms. The attack works by exploiting information that is leaked by the device through side-channels (SCA), such as power consumption, electromagnetic radiation, or timing information.

Side-channel attacks can be used to extract sensitive information, such as cryptographic keys or other secret data, from the device, even if the device itself is otherwise secure. These attacks are often difficult to detect and can be performed with relatively simple equipment, such as power analysis tools or oscilloscopes.

{% tabs %}
{% tab title="Cypherock X1" %}
There are multiple layers of protection that Cypherock employs when it comes to protecting against side-channel attacks:

1. Wallet PIN verification is SCA protected as it is done inside the X1 card environment which is EAL 6+ certified. There is no PIN verification on the device.
2. X1 Vault stores only 1/5 Shamir's secret share, which is optionally encrypted with the wallet PIN if the user has set a PIN.
3. X1 Card data (including wallet's Shamir's secret share) from the X1 card is always padded with random IV generated on the card itself, and is encrypted by the pairing key, therefore, adversaries cannot reverse engineer any communication between the X1 Vault and the X1 card.
4. The private key is regenerated on the device only when a transaction is being done. The private key is wiped out from the local buffers as soon as it is no longer needed that is immediately once the transactions are signed. They are in temporary memory for a very brief period of time.
5. Time-invariant implementation of memory comparison software logic in the X1 Vault bootloader prevents any SCA vulnerabilities during the firmware boot.
   {% endtab %}

{% tab title="Cypherock X0" %}
There are multiple layers of protection that Cypherock employs when it comes to protecting Cypherock X0 against side-channel attacks:

1. Wallet PIN verification is SCA protected as it is done inside the X0 Card environment which is EAL6+ certified. There is no PIN verification on the smartphone.
2. The smartphone stores only 1/5 Shamir's secret share, which is always encrypted with a key derived from the wallet PIN.
3. Data exchanged between the X0 Wallet App and the X0 Card is encrypted and authenticated with fresh session keys derived at the start of every session, and shards that move between X0 Cards travel inside a dedicated card-to-card secure channel. Therefore, adversaries cannot reverse engineer any communication between the smartphone and the X0 Card.
4. The private key is regenerated only inside the secure element of the X0 Card, and only when a transaction is being signed. It is wiped from the card's memory immediately once the transaction is signed. The smartphone never reconstructs the wallet, derives keys or signs.
5. Since a key derived from the PIN is needed to decrypt the shards, disturbing the PIN verification alone does not give an attacker access to the wallet.
   {% endtab %}
   {% endtabs %}
