7

I would like to hear your opinions and how effective would my proposed defense is against power analysis. It is one of the nastiest side channel attacks because it's undetectable and passive, but assuming that your power strip can be trusted it should work:

We take a power strip with 7-8 slots, we plug in the 2 cables that the PC has (usually monitor + power unit) and we put other devices into the other 6 slots. Whenever we perform a sensitie crypto operation like signing keys or decrypting, we just turn on the other devices, to create interference in the power consumption. Therefore it will become undetectable from poweranalysis, because the power waves overlapse and the spikes (caused by crypto operation) will become undetectable from the spikes other devices do. Especially if you plug in your fridge or washing machine in the same power strip, because these devices consume power cyclicaly do power spikes that will hide the crypto operations from your PC.

Would this work?

  • Online double-conversion UPS. Bonus points if it's NATO SDIP-27 certified. – forest Jun 20 '18 at 13:05
  • If an attcker is in a position where they have access to plug into the same power strip as you, haven't you got bigger access control problems to worry about? – Simkill Aug 14 '18 at 9:55
  • @Simkill Not necessarily. It's easier and less risky to sneak a small power analysis device in your toaster than it is to hold you down and grab your computer. – forest Aug 14 '18 at 21:53
5

You should not plug a washing machine into the same power strip as your computer or put a large number of switches in series unless you want to burn down your house. With that said...

Mitigating power analysis attacks can be easy or hard depending on the adversary. If they are simply measuring power usage, you can mitigate it by using an online double-conversion UPS. That is a UPS which simultaneously charges and discharges a single cell to ensure zero latency during blackouts or brownouts. They are less efficient than standard line-interactive UPSes (which simply pass through power from the wall and switch to internal power when the voltage drops below a threshold), but they will mitigate simple power analysis attacks because the power you are getting comes directly from the inverter, not mains. If your adversary is outside of your house, it's unlikely that this is necessary anyway, as sensitive power usage information tends not to pass through the first large transformer, if memory serves. Even abusing a compromised smart meter right outside of the building is quite unlikely to be useful for power analysis.

If your adversary is particularly advanced or will have a probe connected very close to the computer, you will unfortunately not be able to mitigate a sophisticated attack with COTS hardware. You would need to have special hardware designed for EMSEC. In particular, you would likely need to have a NATO SDIP-27 (TEMPEST) certification for any hardware you are using in order to ensure that no compromising emanations are released.

Therefore it will become undetectable from poweranalysis, because the power waves overlapse and the spikes (caused by crypto operation) will become undetectable from the spikes other devices do.

This unfortunately does not work. It's the high frequency domain (300 MHz and above, typically) that is relevant for EMSEC. It will not at all become undetectable simply by turning on other devices. In fact, it might actually make it worse by effectively creating antennas. Even a dozen other computers using the same power source can't mask a single 8051 microprocessor in a cheap PS/2 keyboard when subject to power analysis attacks. EMSEC is complicated. You can't mitigate it just by plugging in other devices and simply hoping they mask the high frequency domains.

Fourier transform

The above animation demonstrates how the addition of multiple sine waves in different frequency domains can add up to a seemingly chaotic pattern. In truth, it's easy to analyze such a waveform and extract each and every frequency domain. Plugging in other machines adds to the low frequency domain. It's then a simple matter of performing Fourier analysis on the waveform to extract the completely undamaged high-frequency information being leaked.

Even when you have absolute control over the frequency you add, it is still extremely difficult to mask an existing signal. Just ask anyone who has tried to jam a DSSS signal without being able to predict the sequence. And in your case, you aren't even creating high-amplitude interference. You are turning on another machine which is designed not to cause interference and undoubtedly does not send a strong jamming signal in all the right frequencies!

1

No. The reason is that power analysis when it comes to cryptography, relies on certain signatures, like a specific frequency of signals, so theres still possible to detect even if you have large devices running.

Your "defense" is more like trying to mask morse code using white noise. Yeah, the morse code may be indistinguishable for a human, but with technology, you could dig out the morse code out of the garbled sound signal.

A better defense is to use a UPS. Assuming the location of the computer is "secure", as your original defense assumes, you can in other words place a UPS there. Of course, the UPS should be a "online" one, eg not relay based, but a UPS with a battery, charger and inverter, constantly connected.

Such a UPS, will smooth out both current consumption, and voltage spikes and inpurities, both at input and output, since there is transformers that will smooth out the AC.


If you want to go ultra-ultra secure, you could arrange for this, note that UPSA and UPSB must be extremely large ones that can drive your PC for several hours or even days. UPSB must also be larger than UPSA, and also be able to supply more power than UPSA, and also UPSB must charge to full faster than UPSA consumes:

Computer --> UPSA --> SwitchA --> UPSB --> SwitchB --> Wall socket.

  • Initial state SwitchA off, SwitchB on.
  • When UPSA start to get discharged, you first turn off SwitchB, and then turn on SwitchA. Now UPSB will charge UPSA. After a while, you will end up with a discharged UPSB and a charged UPSA.
  • Now, turn off SwitchA and turn on SwitchB. Now UPSA will consume to your computer, while UPSB will charge.
  • When UPSA have discharged, your UPSB should have enough charge so you can turn off SwitchB and then turn on SwitchA. And so on, and so on.

Here, a automatic switchover and charge management can also be done so UPSA/UPSB never fully charges/discharges, to save on the lifespan of the batteries.

Note, that in the above solution, the computer is never ever directly connected to the wall socket, there is at least one open/off Switch, either SwitchA or SwitchB, between both. This will also cause significant wear on the UPSes, so you need to weight if you really want to go ultra-ultra secure.


A simpler approach, that still is ultra-ultra secure, is to use a single UPS that you unplug from the wall socket when you are "going secure". You can also implement this idea with a laptop, where the laptop becomes the "second" UPS.

  • That is too paranoid approach and its not required in my opinion. How is it possible to detect the spikes if the additional waves overlapse. The more waves you overlapse the more random it gets. It's like multiplying AxB, if you know the result then its plausible to guess A and B, but if you multiply AxBxCxDxExF, then it becomes exponentially harder to guess each viariable from the result. I don't think a simple AES encryption will create huge powerspikes that is too different from the ambient power usage, and even if it doest it's searching for a needle in a haystack with all that noise. – Jensen68 Aug 7 '16 at 15:30
  • And if it's a differential attack, if the PC is measured before the attack and in the crypto state, then obviously if you add more ambient sources, the ambient signature will differ greatly, making this attack impossible. This is just my opinion, I await your reponse ,sir. – Jensen68 Aug 7 '16 at 15:32
  • Regarding your UPS-A and UPS-B example: you don't need super big batteries at all. You take two standard UPSs, replace the battery with super capacitors (16V, 500F should do), and connect their (the UPS's) low battery indicators to a microcontroller (e.g. an arduino). The arduino is then in charge of connecting/disconnecting switch-A and -B as needed. Depending on power consumption this switchover will happen every 10s, but you get rid of the batteries life-cycle problem. – andresgongora May 31 '17 at 14:12
  • @andresgongora Agreed. Provided that the UPS can take a supercap instead of a battery. Some UPS models are "kinky" with what you connect on the battery connector. – sebastian nielsen Jun 1 '17 at 13:15
  • @jensen68 (I am very late to the party, I know). You ask ". How is it possible to detect the spikes if the additional waves overlapse. The more waves you overlapse the more random it gets". I ask you: have you ever listened the radio or watched the TV? Noise always overlaps with the signal carrying information. There are lots of techniques to extract a signal from noise, and the fact that you can't recognize the original waveform looking at an oscilloscope doesn't mean much. – A. Darwin Jun 20 '18 at 14:05
0

The best choice of placement for the Power Analysis measuring device is directly at the machine power supply, or possibly inline with the cable coming directly out of the machine's power supply. I don't think the attack would work as well if the measuring device was placed on the other side of the outlet, which is what your suggestion would be attempting to interfere with. Even if the attack would work from beyond the outlet, if the measuring device is at or near the power supply of the machine, then that is where the interference would need to occur. So based on that I'd guess your suggestion would not work well against a measurement device placed closer to the power supply.

Diclaimer: Most of this answer is supposition, and could very well be wrong. I hope that someone who knows more about Power Analysis and/or electricity in general will chime in here.

  • Yes that is the most feasable, but not very covert, it's obvious if there is a spectrometer attached to your powercable. But in an office with multiple floors and serially connected devices, it becomes very hard if the spectrometer is connected to a relay. – Jensen68 Aug 7 '16 at 15:34
  • @Jensen68 - I agree, but I can't find any published papers where someone claims to have successfully used power analysis with their tool on the other side of the outlet. It seems like they are all connecting directly to the internal parts of the computer. – TTT Aug 7 '16 at 20:09
  • they had, try reading these papers: A. G. Bayrak, F. Regazzoni et al., A first step towards automatic application of power analysis countermeasures ;;; T.S. Messerges, E.A. Dabbish, R.H. Sloan: Examining smart-card security under the threat of power analysis attacks – Jensen68 Aug 7 '16 at 22:02
  • @Jensen68 - I can't find a public link to the first paper, though I did find the 2nd. I don't think the 2nd is relevant though, as they seem to be using their own contraption on a smart card they have in their possession. I only skimmed it and still couldn't find anything measuring the power after the outlet. The only thing I found is on page 3 section 2 where they discuss monitoring particular pins of the smart card. – TTT Aug 8 '16 at 14:28
-1

It might work. But it would also be complete overkill to do a load of laundry every time you decrypt a drive. Especially considering that algorithms like AES are still practically impossible to brute-force even with a side-channel attack. There's a reason you don't see washing machines in the middle of server rooms and data-centers. I'm interested to see if someone with more knowledge in terms of hardware security has another answer, but in the mean time I figured I'd take a shot at it and thank you for the entertaining question.

  • The washing machine example is more for personal computing. In an office enviroment it's enough if you connect multiple PC's to the same power strip and leave them all on, while one of them does crypto operation. If the power consumption will aggregate and overlapse the small spikes, so the signal-to-noise ratio will decrease significantly, making this attack unfeasable, unless you put a bug inside the power strip, but that is another issue. Certainly if the power strips are serially connected, and not paralelly, across multiple floors, the electric company cant spy on the computers. – Jensen68 Aug 5 '16 at 18:08
  • 3
    "...practically impossible to brute-force even with a side-channel attack." - This is not correct – Ella Rose Aug 5 '16 at 18:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.