t60_security.html 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1">
  6. <style type="text/css">
  7. @import url('../css/main.css');
  8. </style>
  9. <title>Libreboot documentation: Security on the ThinkPad T60</title>
  10. </head>
  11. <body>
  12. <div class="section">
  13. <h1>Security on the ThinkPad T60</h1>
  14. <p>Hardware modifications to enhance security on the ThinkPad T60. This tutorial is <b>incomplete</b> at the time of writing.</p>
  15. <p><a href="index.html">Back to previous index</a></p>
  16. </div>
  17. <div class="section">
  18. <h1>Table of Contents</h1>
  19. <ul>
  20. <li><a href="#hardware_requirements">Hardware Requirements</a></li>
  21. <li><a href="#software_requirements">Software Requirements</a></li>
  22. <li><a href="#procedure">The procedure</a></li>
  23. </ul>
  24. <h1 id="hardware_requirements">Hardware requirements</h1>
  25. <ul>
  26. <li>A T60</li>
  27. <li>screwdriver</li>
  28. <li>Rubbing or isopropyl alcohol, and thermal compound.</li>
  29. <li>(in a later version of this tutorial: soldering iron and scalpel)</li>
  30. </ul>
  31. <h1 id="software_requirements">Software requirements</h1>
  32. <ul>
  33. <li>none (at least in the scope of the article as-is)</li>
  34. <li>You probably want to encrypt your GNU/Linux install using LUKS</li>
  35. </ul>
  36. </div>
  37. <div class="section">
  38. <h1>
  39. Rationale
  40. </h1>
  41. <p>
  42. Most people think of security on the software side: the hardware is important aswell.
  43. </p>
  44. <p>
  45. This tutorial deals with reducing the number of devices that have direct memory access that
  46. could communicate with inputs/outputs that could be used to remotely
  47. command the system (or leak data). All of this is purely theoretical for the time being.
  48. </p>
  49. </div>
  50. <div class="section">
  51. <h1 id="procedure">Disassembly</h1>
  52. <p>
  53. Remove those screws and remove the HDD:<br/>
  54. <img src="../images/t60_dev/0001.JPG" alt="" /> <img src="../images/t60_dev/0002.JPG" alt="" />
  55. </p>
  56. <p>
  57. Lift off the palm rest:<br/>
  58. <img src="../images/t60_dev/0003.JPG" alt="" />
  59. </p>
  60. <p>
  61. Lift up the keyboard, pull it back a bit, flip it over like that and then disconnect it from the board:<br/>
  62. <img src="../images/t60_dev/0004.JPG" alt="" /> <img src="../images/t60_dev/0005.JPG" alt="" /> <img src="../images/t60_dev/0006.JPG" alt="" />
  63. </p>
  64. <p>
  65. Gently wedge both sides loose:<br/>
  66. <img src="../images/t60_dev/0007.JPG" alt="" /> <img src="../images/t60_dev/0008.JPG" alt="" />
  67. </p>
  68. <p>
  69. Remove that cable from the position:<br/>
  70. <img src="../images/t60_dev/0009.JPG" alt="" /> <img src="../images/t60_dev/0010.JPG" alt="" />
  71. </p>
  72. <p>
  73. Now remove that bezel. Remove wifi, nvram battery and speaker connector (also remove 56k modem, on the left of wifi):<br/>
  74. <img src="../images/t60_dev/0011.JPG" alt="" /><br/>
  75. Reason: has direct (and very fast) memory access, and could (theoretically) leak data over a side-channel.<br/>
  76. <b>Wifi:</b> The ath5k/ath9k cards might not have firmware at all. They might safe but could have
  77. access to the computer's RAM trough DMA. If people have an intel
  78. card(most T60 laptops come with Intel wifi by default, until you change it),then that card runs
  79. a non-free firwamre and has access to the computer's RAM trough DMA! So
  80. the risk-level is very high.
  81. </p>
  82. <p>
  83. Remove those screws:<br/>
  84. <img src="../images/t60_dev/0012.JPG" alt="" />
  85. </p>
  86. <p>
  87. Disconnect the power jack:<br/>
  88. <img src="../images/t60_dev/0013.JPG" alt="" />
  89. </p>
  90. <p>
  91. Remove nvram battery (we will put it back later):<br/>
  92. <img src="../images/t60_dev/0014.JPG" alt="" />
  93. </p>
  94. <p>
  95. Disconnect cable (for 56k modem) and disconnect the other cable:<br/>
  96. <img src="../images/t60_dev/0015.JPG" alt="" /> <img src="../images/t60_dev/0016.JPG" alt="" />
  97. </p>
  98. <p>
  99. Disconnect speaker cable:<br/>
  100. <img src="../images/t60_dev/0017.JPG" alt="" />
  101. </p>
  102. <p>
  103. Disconnect the other end of the 56k modem cable:<br/>
  104. <img src="../images/t60_dev/0018.JPG" alt="" />
  105. </p>
  106. <p>
  107. Make sure you removed it:<br/>
  108. <img src="../images/t60_dev/0019.JPG" alt="" />
  109. </p>
  110. <p>
  111. Unscrew those:<br/>
  112. <img src="../images/t60_dev/0020.JPG" alt="" />
  113. </p>
  114. <p>
  115. Make sure you removed those:<br/>
  116. <img src="../images/t60_dev/0021.JPG" alt="" />
  117. </p>
  118. <p>
  119. Disconnect LCD cable from board:<br/>
  120. <img src="../images/t60_dev/0022.JPG" alt="" />
  121. </p>
  122. <p>
  123. Remove those screws then remove the LCD assembly:<br/>
  124. <img src="../images/t60_dev/0023.JPG" alt="" /> <img src="../images/t60_dev/0024.JPG" alt="" /> <img src="../images/t60_dev/0025.JPG" alt="" />
  125. </p>
  126. <p>
  127. Once again, make sure you removed those:<br/>
  128. <img src="../images/t60_dev/0026.JPG" alt="" />
  129. </p>
  130. <p>
  131. Remove the shielding containing the motherboard, then flip it over. Remove these screws, placing them on a steady
  132. surface in the same layout as they were in before you removed them. Also, you should mark each screw hole after removing the
  133. screw (a permanent marker pen will do), this is so that you have a point of reference when re-assembling the system:<br/>
  134. <img src="../images/t60_dev/0027.JPG" alt="" /> <img src="../images/t60_dev/0028.JPG" alt="" /> <img src="../images/t60_dev/0029.JPG" alt="" />
  135. <img src="../images/t60_dev/0031.JPG" alt="" /> <img src="../images/t60_dev/0032.JPG" alt="" /> <img src="../images/t60_dev/0033.JPG" alt="" />
  136. </p>
  137. <p>
  138. Remove microphone (soldering iron not needed. Just wedge it out gently):<br/>
  139. <img src="../images/t60_dev/0039.JPG" alt="" /><br/>
  140. <b>Rationale:</b><br/>
  141. Another reason to remove the microphone: If your computer gets<a href="#ref1">[1]</a> compromised, it can
  142. record what you say, and use it to receive data from nearby devices if
  143. they're compromised too. Also, we do not know what the built-in microcode (in the CPU) is doing; it could theoretically
  144. be programmed to accept remote commands from some speaker somewhere (remote security hole). <b>In other words,
  145. the system could already be compromised from the factory.</b>
  146. </p>
  147. <p>
  148. Remove infrared:<br/>
  149. <img src="../images/t60_dev/0040.JPG" alt="" /> <img src="../images/t60_dev/0042.JPG" alt="" />
  150. </p>
  151. <p>
  152. Remove cardbus (it's in a socket, no need to disable. Just remove the port itself):<br/>
  153. <img src="../images/t60_dev/0041.JPG" alt="" /><br/>
  154. <b>Rationale:</b><br/>
  155. It has direct memory access and can be used to extract sensitive details (such as LUKS keys). See
  156. 'GoodBIOS' video linked at the end (speaker is Peter Stuge, a coreboot hacker). The video covers X60
  157. but the same topics apply to T60.
  158. </p>
  159. <p>
  160. Before re-installing the upper chassis, remove the speaker:<br/>
  161. <img src="../images/t60_dev/0043.JPG" alt="" /> <img src="../images/t60_dev/0044.JPG" alt="" /><br/>
  162. Reason: combined with the microphone issue, this could be used to leak data.<br/>
  163. If your computer gets<a href="#ref1">[1]</a> compromised, it can be used to
  164. transmit data to nearby compromised devices. It's unknown if it can be
  165. turned into a microphone<a href="#ref2">[2]</a>.<br/>
  166. Replacement: headphones/speakers (line-out) or external DAC (USB).
  167. </p>
  168. <p>
  169. Remove the wwan:<br/>
  170. <img src="../images/t60_dev/0045.JPG" alt="" /><br/>
  171. <b>Wwan (3g modem):</b> They run proprietary software! It's like AMT but over the GSM network which is
  172. probably even worse.<br/>
  173. Replacement: external USB wifi dongle. (or USB wwan/3g dongle; note, this has all the same privacy issues as mobile phones. wwan not recommended).
  174. </p>
  175. <p>
  176. This is where the simcard connector is soldered. See notes above about wwan. Remove simcard by removing battery
  177. and then it's accessible (so, remember to do this when you re-assemble. or you could do it now?)<br/>
  178. <img src="../images/t60_dev/0046.JPG" alt="" />
  179. </p>
  180. <p>
  181. Put those screws back:<br/>
  182. <img src="../images/t60_dev/0047.JPG" alt="" />
  183. </p>
  184. <p>
  185. Put it back into lower chassis:<br/>
  186. <img src="../images/t60_dev/0048.JPG" alt="" />
  187. </p>
  188. <p>
  189. Attach LCD and insert screws (also, attach the lcd cable to the board):<br/>
  190. <img src="../images/t60_dev/0049.JPG" alt="" />
  191. </p>
  192. <p>
  193. Insert those screws:<br/>
  194. <img src="../images/t60_dev/0050.JPG" alt="" />
  195. </p>
  196. <p>
  197. On the CPU (and there is another chip south-east to it, sorry forgot to take pic)
  198. clean off the old thermal paste (with the alcohol) and apply new (Artic Silver 5 is good, others are good too)
  199. you should also clean the heatsink the same way<br/>
  200. <img src="../images/t60_dev/0051.JPG" alt="" />
  201. </p>
  202. <p>
  203. Attach the heatsink and install the screws (also, make sure to install the AC jack as highlighted):<br/>
  204. <img src="../images/t60_dev/0052.JPG" alt="" />
  205. </p>
  206. <p>
  207. Reinstall that upper bezel:<br/>
  208. <img src="../images/t60_dev/0053.JPG" alt="" />
  209. </p>
  210. <p>
  211. Do that:<br/>
  212. <img src="../images/t60_dev/0054.JPG" alt="" /> <img src="../images/t60_dev/0055.JPG" alt="" />
  213. </p>
  214. <p>
  215. Attach keyboard and install nvram battery:<br/>
  216. <img src="../images/t60_dev/0056.JPG" alt="" /> <img src="../images/t60_dev/0057.JPG" alt="" />
  217. </p>
  218. <p>
  219. Place keyboard and (sorry, forgot to take pics) reinstall the palmrest and insert screws on the underside:<br/>
  220. <img src="../images/t60_dev/0058.JPG" alt="" />
  221. </p>
  222. <p>
  223. Remove those covers and unscrew:<br/>
  224. <img src="../images/t60_dev/0059.JPG" alt="" /> <img src="../images/t60_dev/0060.JPG" alt="" /> <img src="../images/t60_dev/0061.JPG" alt="" />
  225. </p>
  226. <p>
  227. Gently pry off the front bezel (sorry, forgot to take pics).
  228. </p>
  229. <p>
  230. Remove bluetooth module:<br/>
  231. <img src="../images/t60_dev/0062.JPG" alt="" /> <img src="../images/t60_dev/0063.JPG" alt="" />
  232. </p>
  233. <p>
  234. Re-attach the front bezel and re-insert the screws (sorry, forgot to take pics).
  235. </p>
  236. <p>
  237. It lives!<br/>
  238. <img src="../images/t60_dev/0071.JPG" alt="" /> <img src="../images/t60_dev/0072.JPG" alt="" /> <img src="../images/t60_dev/0073.JPG" alt="" />
  239. </p>
  240. <p>
  241. Always stress test ('stress -c 2' and xsensors. below 90C is ok) when replacing cpu paste/heatsink:<br/>
  242. <img src="../images/t60_dev/0074.JPG" alt="" />
  243. </p>
  244. </div>
  245. <div class="section">
  246. <h2>
  247. Not covered yet:
  248. </h2>
  249. <ul>
  250. <li>Disable flashing the ethernet firmware</li>
  251. <li>Disable SPI flash writes (can be re-enabled by unsoldering two parts)</li>
  252. <li>Disable use of xrandr/edid on external monitor (cut 2 pins on VGA)</li>
  253. <li>Disable docking station (might be possible to do it in software, in coreboot upstream as a Kconfig option)</li>
  254. </ul>
  255. <p>
  256. Go to <a href="http://media.ccc.de/browse/congress/2013/30C3_-_5529_-_en_-_saal_2_-_201312271830_-_hardening_hardware_and_choosing_a_goodbios_-_peter_stuge.html">http://media.ccc.de/browse/congress/2013/30C3_-_5529_-_en_-_saal_2_-_201312271830_-_hardening_hardware_and_choosing_a_goodbios_-_peter_stuge.html</a>
  257. or directly to the video: <a href="http://mirror.netcologne.de/CCC/congress/2013/webm/30c3-5529-en-Hardening_hardware_and_choosing_a_goodBIOS_webm.webm">http://mirror.netcologne.de/CCC/congress/2013/webm/30c3-5529-en-Hardening_hardware_and_choosing_a_goodBIOS_webm.webm</a>.
  258. </p>
  259. <p>
  260. A lot of this tutorial is based on that video. Look towards the second half of the video to see how to do the above.
  261. </p>
  262. </div>
  263. <div class="section">
  264. <h2>
  265. Also not covered yet:
  266. </h2>
  267. <ul>
  268. <li>
  269. Intrusion detection: randomized seal on screws<br/>
  270. Just put nail polish with lot of glider on the important screws, take
  271. some good pictures. Keep the pictueres and make sure of their integrity.
  272. Compare the nail polish with the pictures before powering on the laptop.
  273. </li>
  274. <li>
  275. Tips about preventing/mitigating risk of cold boot attack.
  276. <ul>
  277. <li>soldered RAM?</li>
  278. <li>wipe all RAM at boot/power-off/power-on? (patch in coreboot upstream?)</li>
  279. <li>ask gnutoo about fallback patches (counts number of boots)</li>
  280. </ul>
  281. </li>
  282. <li>
  283. General tips/advice and web links showing how to detect physical intrusions.
  284. </li>
  285. <li>
  286. For example: <a href="http://cs.tau.ac.il/~tromer/acoustic/">http://cs.tau.ac.il/~tromer/acoustic/</a>
  287. or <a href="http://cyber.bgu.ac.il/content/how-leak-sensitive-data-isolated-computer-air-gap-near-mobile-phone-airhopper">http://cyber.bgu.ac.il/content/how-leak-sensitive-data-isolated-computer-air-gap-near-mobile-phone-airhopper</a>.
  288. </li>
  289. <li>
  290. <a href="https://en.wikipedia.org/wiki/Tempest_%28codename%29">https://en.wikipedia.org/wiki/Tempest_%28codename%29</a>
  291. </li>
  292. <li>
  293. https://gitorious.org/gnutoo-for-coreboot/grub-assemble/source/a61f636797777a742f65f4c9c58032aa6a9b23c3:
  294. </li>
  295. </ul>
  296. </div>
  297. <div class="section">
  298. <h1>
  299. Extra notes
  300. </h1>
  301. <p>
  302. EC: Cannot be removed but can be mitigated: it contains non-free
  303. non-loadable code, but it has no access to the computer's RAM.
  304. It has access to the on-switch of the wifi, bluetooth, modem and some
  305. other power management features. The issue is that it has access to the
  306. keyboard, however if the software security howto <b>(not yet written)</b> is followed correctly,
  307. it won't be able to leak data to a local attacker. It has no network
  308. access but it may still be able to leak data remotely, but that
  309. requires someone to be nearby to recover the data with the help of an
  310. SDR and some directional antennas<a href="#ref3">[3]</a>.
  311. </p>
  312. <p>
  313. <a href="http://www.coreboot.org/Intel_82573_Ethernet_controller">Intel 82573 Ethernet controller</a>
  314. on the X60 seems safe, according to Denis.
  315. </p>
  316. <div class="subsection">
  317. <h2>
  318. Risk level
  319. </h2>
  320. <ul>
  321. <li>Modem (3g/wwan): highest</li>
  322. <li>Intel wifi: Near highest</li>
  323. <li>Atheros PCI wifi: unknown, but lower than intel wifi.</li>
  324. <li>Microphone: only problematic if the computer gets compromised.</li>
  325. <li>Speakers: only problematic if the computer gets compromised.</li>
  326. <li>EC: can be mitigated if following the guide on software security.</li>
  327. </ul>
  328. </div>
  329. </div>
  330. <div class="section">
  331. <h1>
  332. Further reading material (software security)
  333. </h1>
  334. <ul>
  335. <li><a href="../gnulinux/encrypted_trisquel.html">Installing Trisquel GNU/Linux with full disk encryption (including /boot)</a></li>
  336. <li><a href="../gnulinux/encrypted_parabola.html">Installing Parabola GNU/Linux with full disk encryption (including /boot)</a></li>
  337. <li><a href="dock.html">Notes about DMA access and the docking station</a></li>
  338. </ul>
  339. </div>
  340. <div class="section">
  341. <h1>
  342. References
  343. </h1>
  344. <div class="subsection">
  345. <h2 id="ref1">[1] physical access</h2>
  346. <p>
  347. Explain that black hats, TAO, and so on might use a 0day to get in,
  348. and explain that in this case it mitigates what the attacker can do.
  349. Also the TAO do some evaluation before launching an attack: they take
  350. the probability of beeing caught into account, along with the kind of
  351. target. A 0day costs a lot of money, I heard that it was from 100000$
  352. to 400000$, some other websites had prices 10 times lower but that
  353. but it was probably a typo. So if people increase their security it
  354. makes it more risky and more costly to attack people.
  355. </p>
  356. </div>
  357. <div class="subsection">
  358. <h2 id="ref2">[2] microphone</h2>
  359. <p>
  360. It's possible to turn headphones into a microphone, you could try
  361. yourself, however they don't record loud at all. Also intel cards have
  362. the capability to change a connector's function, for instance the
  363. microphone jack can now become a headphone plug, that's called
  364. retasking. There is some support for it in GNU/Linux but it's not very
  365. well known.
  366. </p>
  367. </div>
  368. <div class="subsection">
  369. <h2 id="ref3">[3] Video (CCC)</h2>
  370. <p>
  371. 30c3-5356-en-Firmware_Fat_Camp_webm.webm from the 30th CCC. While
  372. their demo is experimental(their hardware also got damaged during the
  373. transport), the spies probably already have that since a long time.
  374. <a href="http://berlin.ftp.media.ccc.de/congress/2013/webm/30c3-5356-en-Firmware_Fat_Camp_webm.webm">http://berlin.ftp.media.ccc.de/congress/2013/webm/30c3-5356-en-Firmware_Fat_Camp_webm.webm</a>
  375. </p>
  376. </div>
  377. </div>
  378. <div class="section">
  379. <p>
  380. Copyright &copy; 2014, 2015 Francis Rowe &lt;info@gluglug.org.uk&gt;<br/>
  381. Permission is granted to copy, distribute and/or modify this document
  382. under the terms of the GNU Free Documentation License, Version 1.3
  383. or any later version published by the Free Software Foundation;
  384. with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
  385. A copy of the license can be found at <a href="../gfdl-1.3.txt">../gfdl-1.3.txt</a>
  386. </p>
  387. <p>
  388. Updated versions of the license (when available) can be found at
  389. <a href="https://www.gnu.org/licenses/licenses.html">https://www.gnu.org/licenses/licenses.html</a>
  390. </p>
  391. <p>
  392. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE
  393. EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS
  394. AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF
  395. ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS,
  396. IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION,
  397. WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR
  398. PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS,
  399. ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT
  400. KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT
  401. ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU.
  402. </p>
  403. <p>
  404. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE
  405. TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION,
  406. NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT,
  407. INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES,
  408. COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR
  409. USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN
  410. ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR
  411. DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR
  412. IN PART, THIS LIMITATION MAY NOT APPLY TO YOU.
  413. </p>
  414. <p>
  415. The disclaimer of warranties and limitation of liability provided
  416. above shall be interpreted in a manner that, to the extent
  417. possible, most closely approximates an absolute disclaimer and
  418. waiver of all liability.
  419. </p>
  420. </div>
  421. </body>
  422. </html>