- æå·åã¹ã¤ã¼ãããã³ãããã³ã«ã®è¨å®
- æå·ã¯ã ãã ãå¼±ããªã
- é©åãªè¨å®ã¯ä½ã?
- crypto-policiesã«ããè¨å®
- crypt-policiesã«ããããã©ã«ãè¨å®ã¯ã©ãå®è£ ããã¦ããã®?
- crypto-policies ã®æ³¨æç¹
- ã¾ã¨ã
- é¢é£ãªã³ã¯
æå·åã¹ã¤ã¼ãããã³ãããã³ã«ã®è¨å®
TLSã«ããæå·åãsshã§ã®æå·åãã¹ãã¬ã¼ã¸ã®æå·å ãªã©ã RHELã®ä¸ã«ã¯ãæå·åããæ±ãå ´é¢ãå¤æ°ããã¾ãããããã§å©ç¨ãããæå·åã®ã¢ã«ã´ãªãºã ããããã³ã«ãã»ãã¥ãªãã£ããªã·ã¼ã«ãããã¦é©åã«è¨å®ããã«ã¯å°éç¥èãå¿ è¦ã«ãªãã¾ãã
ä¸è¨ã§ãæå·åãã¨è¨ãã¾ãããããã¨ãã°TLSã¯éä¿¡ç¸æã®èªè¨¼ãå«ããããéµäº¤æããã¼ã¿ã®æå·åãç½²åãããã·ã¥ã¨ãã£ãã¹ãããããããããããã«ã¢ã«ã´ãªãºã ã®é¸æè¢ãããã¾ããããããã¾ã¨ãããæå·åã¹ã¤ã¼ãããé©åãªãã®ã«è¨å®ããå¿ è¦ãããã¾ãã
åºæ¬çã«ã¯å¼·åº¦ãé«ã(ç§å¯ã®æ å ±ãç¥ããªã人ãçªç ´ããã®ãå°é£ãª)æå·åã¹ã¤ã¼ããæå®ãããã¨ã§å®å ¨æ§ãä¸ããã¾ããããã¤ã強度ãé«ãæå·åã¹ã¤ã¼ããé¸ã¹ãã¨ã¯éãã¾ããã強度ãä½ãæå·åã¹ã¤ã¼ãã使ããã¨ãå¿ è¦ã¨ãªãå ¸åçãªã±ã¼ã¹ã¯ããã£ã¼ãã£ã¼ãã³ãç¹å®ã®ã¢ãã©ã¤ã¢ã³ã¹ãªã©ã®å¤ãæå·åã¹ã¤ã¼ããããµãã¼ããã¦ããªãæ©å¨ã¨ã®éä¿¡ãå¿ è¦ãªå ´åã§ãã
TLSãªã©ã§ã¯ãå®éã®ãã¼ã¿ãããã¨ãããåã«ãäºãã«å©ç¨å¯è½ãªæå·åã¹ã¤ã¼ãã®ãªã¹ãã交æããä¸ã§ã両æ¹ãå©ç¨å¯è½ãªæå·åã¹ã¤ã¼ãããå®éã«å©ç¨ããæå·åã¹ã¤ã¼ããé¸æãã¾ãããã®é¸æã®åªå é ä½ãè¨å®ã«ãã決ã¾ãã¾ãã
æå·ã¯ã ãã ãå¼±ããªã
æå·ã®å¼·åº¦ã¯ããã¾ãã«è¨ã£ã¦ã解èªãããå½è£ ãããããããã«å¿ è¦ãªæéããç®å®ã«èãããã¾ãããã®ããæ»ææ¹æ³ã®ç 究ãé²ãã ããã³ã³ãã¥ã¼ã¿ã®è¨ç®è½åãåä¸ãã¦ãããã¨ã§æå·ã¯ã ãã ãã¨å¼±ããªã£ã¦ãããããã¦ã¯å®ç¨ä¸ã®æå³ããªããªãã¾ã(æå·å±æ®å)ãç¾å¨å©ç¨ããã¦ããæå·åæ¹å¼ãå±æ®åããåã«ãããå¼·ãæå·åæ¹å¼ãèæ¡ãè©ä¾¡ãæ¨æºåãã¦ä¸è¬ã«å©ç¨ã§ããããã«ããããä¸æã®åªåãéãããã¦ãã¾ãã
ãã¨ãã°éçºå½æã«ç¥ããã¦ããæ»æææ³ã¨æ¨æºçãªè¨ç®æ©ã使ã£ã¦æ»æããã¨è§£èªã«100ä¸å¹´ãããã¨ãããæå·åæ¹å¼ã§ãã£ã¦ããå¹´æã¨ã¨ãã«å¹æçãªæ»ææ¹æ³ãã¿ã¤ãã£ããè¨ç®æ©ãé«éåãããã¨ã§1000å¹´ã§è§£èªã§ããããã«ãªããã¨ã¯ããæ®éã«èãããã¾ãããã®å¼±ããªã£ãæå·ãæ°åå°ã®ã¯ã©ã¹ã¿ã§æ»æããã¨æ°ã¶æç¨åº¦ã§æ»æãæåãããããå®éçã«æå·åã®æå³ããªããªãã¾ãã
強度ãé«ãæå·åã¹ã¤ã¼ãã¯å¤ãã®å ´åæå·åã»å¾©å·åã«ãããè¨ç®æéãå¢ãã¾ãã®ã§ãè¨ç®æéã¨å¼·åº¦ã®ãã©ã³ã¹ãå©ç¨ããã¹ãæå·åã¹ã¤ã¼ãã®é¸æã«å½±é¿ãã¾ãã
é©åãªè¨å®ã¯ä½ã?
ç¸äºéç¨æ§ã¨ã»ãã¥ãªãã£å¼·åº¦ã®ãã©ã³ã¹ãã©ã調æ´ããã¹ããã¯ç¶æ³ã«ããç°ãªãã¾ãã NISTãªã©ã®æ©é¢ã§ã¯å®éçãªæ»æãã©ã®ç¨åº¦å®¹æã§ããããèæ ®ãã¦ãç¹å®ã®æ¹å¼ãå«ãæå·åã¹ã¤ã¼ãã®å©ç¨ç¦æ¢ã宣è¨ããããã·ã¹ãã ã®ç¹æ§ã«ããå©ç¨ããã¹ãæå·åã¹ã¤ã¼ãã®ã¬ã¤ããå ¬éããããã¦ãã¾ããåã·ã¹ãã ã®éç¨ç®¡çè ãåå¥ã«æå·åã¹ã¤ã¼ãã«ã¤ãã¦åæ¨é¸æããããªããã¨ã¯å°é£ã§ãã®ã§ãå¤ãã®å ´åã¯ã¬ã¤ãã«ãããã¦è¨å®ãããã¨ã«ãªãã¾ãã
crypto-policiesã«ããè¨å®
RHEL 8 ã§ã¯æå·åã¹ã¤ã¼ãã®è¨å®ä½æ¥ãç°¡åã«ãããã crypto-policies ã¨ããä»çµã¿ãå°å ¥ããã¾ããã以ä¸ã®ã½ããã¦ã§ã¢ã«ã¤ãã¦ãå©ç¨å¯è½ãªæå·åã¹ã¤ã¼ãã®ããã©ã«ãè¨å®ãã¾ã¨ãã¦è¡ãã¾ããæ®å¿µãªããæå·åãæ±ãå ¨ã¦ã®å ´é¢ããµãã¼ãã§ãã¦ã¯ãã¾ãã(dm-cryptoã§ã®ã¹ãã¬ã¼ã¸æå·åãªã©)ãã主è¦ãªã©ã¤ãã©ãªãã«ãã¼ãã¦ãã¾ãã
- GnuTLS library
- OpenSSL library
- NSS library
- OpenJDK
- Libkrb5
- BIND
- OpenSSH
- Libreswan
RHEL 8.1ãªãªã¼ã¹ã®ã¿ã¤ãã³ã°ã§ goè¨èªããã³ libsshã«ã対å¿ããäºå®ã§ãã
crypto-policiesã®å©ç¨æ¹æ³ã¯é常ã«ã·ã³ãã«ã§ãã
RHEL 8 betaã®crypto-policiesã§ã¯ LEGACY, DEFAULT, FUTURE, FIPS ã®4種é¡ã®ãããã¡ã¤ã«ãç¨æããã¦ãã¾ãã/etc/crypto-policies/config ã«å¸æã®ãããã¡ã¤ã«åãæå®ãã¦ã update-crypto-policies
ã³ãã³ããrootã§å®è¡ãã¾ããããã§ä¸è¨ã®ã½ããã¦ã§ã¢ç¾¤ã«ã¤ãã¦ãããã©ã«ãã®æå·åã¹ã¤ã¼ããè¨å®ã§ãã¾ãã
/etc/crypto-policies/config
# be applied by default to applications. The available policies are # restricted to the following profiles. # # * LEGACY: Ensures maximum compatibility with legacy systems (64-bit # security) # # * DEFAULT: A reasonable default for today's standards (112-bit security). # # * FUTURE: A level that will provide security on a conservative level that is # believed to withstand any near-term future attacks (128-bit security). # # * FIPS: Policy that enables only FIPS 140-2 approved or allowed algorithms. # # After modifying this file, you need to run update-crypto-policies # for the changes to propagate. # DEFAULT
é常ã¯ãDEFAULTãããã¡ã¤ã«ã®ã¾ã¾ã§ç¹ã«ä½ãããå©ç¨ããã®ãããããã§ããå¤ãæ©å¨ã¨ã®æ¥ç¶ãå¿ è¦ãªå ´åããé«ãã»ãã¥ãªãã£ãå¿ è¦ãªå ´åã«ã¯ããããLEGACY, FUTUREãããã¡ã¤ã«ããå©ç¨ãã ããã
crypt-policiesã«ããããã©ã«ãè¨å®ã¯ã©ãå®è£ ããã¦ããã®?
crypto-policiesããã±ã¼ã¸ã¯ãããã¡ã¤ã«æ¯ã«åã½ããã¦ã§ã¢ç¨ã®è¨å®ããããããæã£ã¦ãã¾ããupdate-crypto-policiesã³ãã³ãã¯ãããã¡ã¤ã«è¨å®ã«å¾ã£ã¦ã·ã³ããªãã¯ãªã³ã¯ãåãæ¿ããã ãã®åç´ãªãã®ã§ãã
rpmããã±ã¼ã¸ã«ã¯çææ¸ã¿ã®è¨å®ã¨ãããã¡ã¤ã«åãæ¿ãã®ã·ã§ã«ã¹ã¯ãªããã ããå«ã¾ãã¾ããããã®è¨å®ã¯ããªã·ã¼ããã¨ã«ã¹ã¯ãªããããçæããã¦ãã¾ããsrc.rpmãgitlabã§ãã¹ãããã¦ããupsreamããã¸ã§ã¯ããã確èªã§ãã¾ããç¬èªã«ãããã¡ã¤ã«ãä½æãããå ´åãªã©ã¯ãã¡ãã調æ»ããã®ãè¯ãã§ããããä¸è¬çã«ãµãã¼ããããã¨ãããããªãããã¡ã¤ã«ãããã°ããµãã¼ãçªå£ã¾ã§æ©è½æ¡å¼µãªã¯ã¨ã¹ããéã£ã¦ããã ããã°ã¨æãã¾ãã
åã½ããã¦ã§ã¢ã®ããã±ã¼ã¸ãcrypto-policiesãå©ç¨ãã¦æå·åã¹ã¤ã¼ãã®è¨å®ããããªã£ã¦ãã¾ããã©ã®ããã«è¨å®ãåæ ãããã®è©³ç´°ã¯åã½ããã¦ã§ã¢ã«ããå¤ãããããã©ã«ãã®è¨å®ãã¡ã¤ã«ã§includeãããã®ããµã¼ãèµ·åæã®ãªãã·ã§ã³ãå¤ãããã®ãªã©ãããã¾ãã
openssh serverã®å ´å
systemdã®sshd.serviceå
ã§ç°å¢å¤æ°ã¨ãã¦crypto-policiesã®è¨å®ãã¨ããã¿ãsshdå®è¡æã®ã³ãã³ãã©ã¤ã³ãªãã·ã§ã³ã¨ãã¦æ¸¡ãã¦ãã¾ããã³ãã³ãã©ã¤ã³ãªãã·ã§ã³ã¯è¨å®ãã¡ã¤ã«ããåªå
ããããããä»ã¾ã§ã¨åãè¨å®ã/etc/ssh/sshd_config
ã«æ¸ãã¦ãã¦ãåä½ã¸ã®å½±é¿ãããã¾ããã /etc/sysconfig/sshd
ã« CRYPTO_POLICY=
ã¨ç©ºæååãæå®ãããã¨ã§crypto-policiesã®ããã©ã«ãè¨å®ãç¡è¦ãããã¨ãã§ãã¾ãã
/usr/lib/systemd/system/sshd.service ãã
[Service] Type=notify EnvironmentFile=-/etc/crypto-policies/back-ends/opensshserver.config EnvironmentFile=-/etc/sysconfig/sshd ExecStart=/usr/sbin/sshd -D $OPTIONS $CRYPTO_POLICY ExecReload=/bin/kill -HUP $MAINPID KillMode=process Restart=on-failure RestartSec=42s
openssl ã®å ´å
/etc/pki/tls/openssl.cnf å ã§ãcrypto-policiesã®ããªã·ã¼ãincludeãã¦ãã¾ãã
[ crypto_policy ] .include /etc/crypto-policies/back-ends/opensslcnf.config
crypto-policies ã®æ³¨æç¹
ãRHEL 8ã§crypto-policiesã使ããªããã¨ããé¸æè¢ã¯åå¨ãã¾ãããåè¿°ã®ã¨ãããæå·åãæ±ãåã½ããã¦ã§ã¢ã®ããã©ã«ãè¨å®ã§crypto-policiesãåç §ãã¦ãã¾ããOpenSSH Serverãã®ããã°ä¸è¬çãªè¨å®æé ã§ãªã¼ãã¼ã©ã¤ããå¯è½ã§ãã®ã§ãå¿ è¦ãªå ´åã¯åå¥ã«ã½ããã¦ã§ã¢ãè¨å®ãã¾ãã
ã¾ã¨ã
- çµç¹ã®ããªã·ã¼ã«ãããã¦æå·åã®å¼·åº¦ãèæ ®ããè¨å®ããããã¨ãããã¾ãã
- RHEL 8 ã§ã¯crypto-policiesãå©ç¨ãããã¨ã§ãã·ã¹ãã å ¨ä½ã®æå·åã®å¼·åº¦ãç°¡åã«èª¿æ´ã§ãã¾ãã
- RHEL 7 ã¾ã§ã¨åãæé ã§æ§ç¯ãã¦ãå©ç¨ããæå·åã¹ã¤ã¼ãã®è¨å®ãåä¸ã«ãªããªãå ´åãããã¾ããå¿ è¦ã«å¿ãã¦é©å®ãªã¼ãã¼ã©ã¤ããã¦ãå©ç¨ãã ããã