ãã¼ãPCã®TPMã/dev/randomã®ä¹±æ°çæå¨ã¨ãã¦ä½¿ã
ååã®Gnukã§GPGéµãçæããéã«ã/dev/randomããã¨ã³ãããã¼ãåãåºãã®ãé ãåé¡ã®å¯¾çã調ã¹ã¦ããã¨ãããTPM(Trusted Platform Module)ãä¹±æ°çæå¨ã¨ãã¦ä½¿ãããã¨ãåãã£ãã®ã§è©¦ãã¦ã¿ãã
TPMã¨ã¯
Wikipediaã®Trusted Platform Moduleããä¸é¨æç²
æ¦è¦
RSAæå·æ¼ç®ãSHA-1ããã·ã¥æ¼ç®ã¨ãã£ãæ©è½ãæãã¦ããããããå ã§æå·åã»å¾©å·ããã¸ã¿ã«ç½²åã®çæã»æ¤è¨¼ããã©ãããã©ã¼ã ã®å®å ¨æ§æ¤è¨¼ãè¡ããã¨ãã§ãããã¾ããTPMã®å é¨ã§RSAã®éµãã¢(å ¬ééµã¨ç§å¯éµ)ãçæãããã¨ãã§ããã
TPMã®ä»æ§ã¯TCG (= Trusted Computing Group)ã¨ããå½éçãªæ¥çå£ä½ã§çå®ããã¦ãããææ°ã®ãã¼ã¸ã§ã³ã¯1.2ã§ããã
ãã¼ãPCã ãã§ã¯ãªãããã¹ã¯ãããPCã«ãTPMã¯æè¼ããã¦ãããWindows OSã¨ãã¦ã¯Windows Vistaãåãã¦æ£å¼ã«ãµãã¼ããããIntelããããæè¼ããåæã®Macintoshã«ãTPMããããæè¼ãããã®ãããã
ãã®æè¡ã¯ãããã«çºå±ãéãã¦ããããããã»ããçã®é£æºãå¼·åããæè¡ã¨ãã¦ãIntel Trusted Execution Technology ããããã¾ããä»®æ³æ©æ¢°ããã®å½ä»¤ä»æ§æ¡å¼µãææ¡ããã¦ããã
TPMã®æ©è½
TPMã¯ä»¥ä¸ã®æ©è½ãæä¾ããã
- RSA
- æ¼ç®
- éµçæ
- éµæ ¼ç´
- SHA-1ããã·ã¥
- ããã·ã¥å¤è¨ç®
- ããã·ã¥å¤ä¿ç®¡
- ä¹±æ°çæ
ã¾ããTPM1.2ãã以ä¸ã®æ©è½ã追å ãããã
- ã«ã¦ã³ã¿
- åç´å¢å ã«ã¦ã³ã¿
- ãã£ãã¯ã«ã¦ã³ã¿
- ãªã¼ãã¼æ¨©å§ä»» (ãã¹ã¯ã¼ãã¯å ¬éããªã)
- ä¸æ®çºæ§ã¹ãã¬ã¼ã¸ä¿åæ©è½
ãã¸ãã¹ç¨éã®ãã¼ããã½ã³ã³ã«ã¯TPMãæè¼ããã¦ãããã¨ãå¤ã模æ§ãç§ã®ã¡ã¤ã³ãã·ã³Panasonic Let's note(CF-Y7)ã«ã¯ãã®TPMãè¼ã£ã¦ããããããã¨ããããä¹±æ°çæã«ä½¿ã£ã¦ã¿ã¾ãããã
äºåæºå
ã¾ãBIOSãªã©ã§TPMãæå¹ã«ããå¿ è¦ããããTPMãæå¹ã«ããæ¹æ³ã¯ã¡ã¼ã«ã¼ã«ãã£ã¦ç°ãªãããLet's noteã§ããã°取扱説明書ダウンロードã®内蔵セキュリティチップ(TPM)ご利用の手引きãåç §ã
ã«ã¼ãã«ã®è¨å®
Linuxã«ã¼ãã«ã§å¿ è¦ãªã¢ã¸ã¥ã¼ã«ã追å ãç§ã®ãã¼ãã ã¨TCG_INFINEONã ã£ããã¢ãã«ãã£ã¦ã¯TCG_NSCãTCG_ATMELãããããªãã
Device Drivers ---> Character devices ---> <M> TPM Hardware Support ---> <M> TPM Interface Specification 1.2 Interface <M> National Semiconductor TPM Interface <M> Atmel TPM Interface <M> Infineon Technologies TPM Interface
FedoraãUbuntuãDebianãªã©ã®ä¸è¬çãªLinuxãã£ã¹ããªãã¥ã¼ã·ã§ã³ãªãæ¢ã«ã¢ã¸ã¥ã¼ã«åããã¦ããããæªç¢ºèªã
ã¢ã¸ã¥ã¼ã«ãèªã¿è¾¼ãã/dev/tpm0ãçæããããã¨ã確èªã
# modprobe tpm_infineon # ls -l /dev/tpm* lrwxrwxrwx 1 root root 4 2010-11-16 11:44 /dev/tpm -> tpm0 crw-rw---- 1 tss tss 10, 224 2010-11-16 11:44 /dev/tpm0
ãããªæãã§è¡¨ç¤ºããããokã
tpm0ãçæãããªãå ´åããã©ã¤ããç°ãªãã®ãããä¸è¨ã®National SemiconductorãAtmelã試ãã¦ã¿ãã
rngdã®ã¤ã³ã¹ãã¼ã«ã¨è¨å®
ãã¼ãã¦ã§ã¢ä¹±æ°çæå¨ã¨/dev/randomãã¤ãªãrngdãç¨æããããrng-toolsãã¤ã³ã¹ãã¼ã«ã
rngdã¯--no-tpm=1ã¨æå®ããªããã°TPMã/dev/tpm0ãèªåã§ã¿ã«è¡ãã®ã§ç¹ã«è¨å®ã¯ãããªãã
Gentooã§ããã°rng-toolsãã¤ã³ã¹ãã¼ã«ãDebian/Ubuntuãrng-toolsãFedoraãrng-toolsã ã£ãã¨æãã
# emerge rng-tools # /etc/init.d/rngd start
ãã³ããã¼ã¯
ãããã24.5kB/sç¨åº¦çæããã模æ§ããã®ãããã«ã¯çãã®ã§ããããéãã®ãé
ãã®ãããããã
ãã¼ãã¼ãããã¦ã¹ãåããã¦ã¨ã³ãããã¼ãå½¢æããããã¯éãã«éãã
dd if=/dev/random of=/dev/null count=1000 bs=1024 0+1000 records in 0+1000 records out 124823 bytes (125 kB) copied, 5.07053 s, 24.6 kB/s
ã¡ãªã¿ã«åããã·ã³ã®/dev/urandomã¯3.9MB/sã ã£ãã
$ dd if=/dev/urandom of=/dev/null count=1000 bs=1024 1000+0 records in 1000+0 records out 1024000 bytes (1.0 MB) copied, 0.262949 s, 3.9 MB/s
ãã©ãã«ã·ã¥ã¼ãã£ã³ã°
ç§ã®ãã·ã³ã«ã¯TPMãæè¼ãã¦ãªããããªãã§ãã
intel i8*0ããããAMD/VIAæ§æã§ããã°ãä¹±æ°çæå¨ãç¬èªã«ç¨æããã¦ããããã詳ããã¯kernelã®RNGå¨ããman rngdãåç §ã
rngdãèµ·åã§ããªã
/dev/tpm0ã«ã¢ã¯ã»ã¹ã§ããã確èªãããç§ãããã£ãã®ã¯ãtcsd(trousers)ãåãã¦ããã¨/dev/tpm0ãbusyã«ãªã£ã¦ã¢ã¯ã»ã¹ã§ããrngdãèµ·åã§ããªãã£ãã
/dev/randomããåå¾ã§ããªã
/var/log/messagesã®ãã°ã確èªãã«æ¬¡ã®ãããªãã°ãè¨é²ããç¶ããå ´åTPMå¨ãã§ä½ãåé¡ãããããã
2010-11-16T02:41:57.068718+09:00 lets rngd: failed fips test 2010-11-16T02:41:57.117682+09:00 lets rngd: failed fips test ...
TPMãè¼ã£ã¦ãã¯ããªã®ã«BIOSã«TPMé¢é£ã®é ç®ããªã
tpm-toolsã使ãã°Linuxä¸ã§ãTPMã®å¶å¾¡ã¯å¯è½ããã ãowner passwordãããããªãã¨ãã¡ãowner passwordã¯èªåã§èª¿ã¹ã¦ãã ããã
tpm-toolsããTPMãæå¹ã«ããã«ã¯æ¬¡ã®ã³ãã³ãã§ãããã¯ãã
# /etc/init.d/tcsd start # /usr/sbin/tpm_setenable -e
tcsd(trousers)ãåä½ãã¦ããã¨rngdã/dev/tpm0ã«ã¢ã¯ã»ã¹ã§ããRNGãå©ç¨ã§ããªãã®ã§ãä¸è¨ãçµãã£ããtcsdã¯æ¢ãã¦ããã
# /etc/init.d/tcsd stop