SlideShare ist ein Scribd-Unternehmen logo
1 von 39
Downloaden Sie, um offline zu lesen
公開 暗号方式を利用した通信
@oroponya
暗号
暗号
• アリスがボブにメッセージを送る
• キャロルには内容を見られたくない
ボブアリス
キャロル
暗号
• 第三者(キャロル)にバレないでメッセージ
のやり取りを行なう方法が「暗号」
ボブアリス
キャロル
シーザー暗号
シーザー暗号
• 文字をズラす暗号方式

ボブアリス キャロル
えおそにわ えおそにわ えおそにわ
?あいしてる あいしてる
暗号化 解読
3文字ズラすとき
あ → え
い → お
て → に
ん → う
シーザー暗号の弱点
• 暗号方式(何文字ズラすか)をボブとアリス
が知らないといけない
キャロル
えおそにわ えおそにわ えおそにわ
?あいしてる あいしてる
暗号化 解読
3文字
ズラしとくね
OK
3文字戻すよ
ボブアリス
シーザー暗号の弱点
• 暗号方式(何文字ズラすか)をボブとアリス
が知らないといけない
キャロル
えおそにわ えおそにわ えおそにわ
?あいしてる あいしてる
暗号化 解読
3文字
ズラしとくね
OK
3文字戻すよ
ボブアリス
シーザー暗号の弱点
• 暗号方式(何文字ズラすか)をボブとアリス
が知らないといけない
キャロル
えおそにわ えおそにわ えおそにわ
?あいしてる あいしてる
暗号化 解読
ボブとアリスの間で
ルールの共有が必要
3文字
ズラしとくね
OK
3文字戻すよ
ボブアリス
シーザー暗号の弱点
• 暗号方式(何文字ズラすか)をボブとアリス
が知らないといけない
キャロル
えおそにわ えおそにわ えおそにわ
?あいしてる あいしてる
暗号化 解読
ルールがキャロルにバレたらオシマイ
(解読されて通信が漏れてしまう)
3文字
ズラしとくね
OK
3文字戻すよ
ボブアリス
シーザー暗号の弱点
• 暗号方式(何文字ズラすか)をボブとアリス
が知らないといけない
キャロル
えおそにわ えおそにわ えおそにわ
?あいしてる あいしてる
暗号化 解読
それ、「公開 暗号方式」
なら大丈夫!
3文字
ズラしとくね
OK
3文字戻すよ
ボブアリス
公開 暗号
突然ですが、南京錠の説明です
南京錠
• 南京錠と、開けられる はペアになっている
南京錠
• だれでも「南京錠をロックする」ことは出来
る( を持っていなくてもよい)
ロック
南京錠
• 「南京錠を解除する」には、 が必要
解除
公開 暗号
• ボブは、「南京錠と のペア」を持っている
ボブアリス キャロル
公開 暗号
• 南京錠のコピーをバラまく

( はダメ!)
ボブアリス キャロル
好きに
使っていいよ
公開 暗号
• 南京錠はみんな持っている
• はボブだけが持っている
ボブアリス キャロル
公開 暗号 STEP 1
• アリスはメッセージを南京錠でロックする
ボブアリス キャロル
あいしてる
あいしてる
ロック
公開 暗号 STEP 2
• ロックされたメッセージをボブに届ける
ボブアリス キャロル
あいしてる
?あいしてる
ロック
あいしてる あいしてる
公開 暗号 STEP 3
• ボブは自分だけの でロックを解除する
ボブアリス キャロル
あいしてる
?あいしてる あいしてる
ロック 解除
あいしてる あいしてる
公開 暗号 FINISHED!
• キャロルにバレずに、メッセージを送れた!
ボブアリス キャロル
あいしてる
?あいしてる あいしてる
ロック 解除
あいしてる あいしてる
公開 と秘密
• 「南京錠」が公開 、「南京錠の 」が秘密
に相当する
公開 秘密
公開 と秘密
• バレてもいい公開 と、

絶対に漏らしてはいけない秘密
公開 秘密
サーバーへのログイン
• 公開 暗号方式は、サーバーにログインもで
きるスグレモノ
サーバーへのログイン STEP 0
• ログインする前に、

公開 をサーバーに設置しておく
あなたサーバー
サーバーへのログイン STEP 1
• サーバーでランダムな文字列を作ってロックする
あなたサーバー
ロック
サーバーへのログイン STEP 2
• あなたはロックされた文字列を受け取る
あなたサーバー
ロック
サーバーへのログイン STEP 3
• 秘密 でロックを解除する
あなたサーバー
ロック 解除
サーバーへのログイン STEP 4
• 解除した文字列をサーバーに送る
あなたサーバー
ロック 解除
サーバーへのログイン
• 解除した文字列をサーバーに送る
あなたサーバー
ロック 解除
この二つが同じものなら
ログイン成功
サーバーへのログイン
• 解除した文字列をサーバーに送る
あなたサーバー
ロック 解除
なぜなら
文字列のロックを正しく解除できるのは
秘密 を持っている人だけ
公開 ・秘密 の使い回し
• 秘密 さえしっかり守れば使い回しOK
その他
ATTENTION
• 公開 をもとに秘密 を割り出すことは「不可能ではない」が、十分な
強度があれば「不可能に近い」

(非現実的な時間がかかる)
• 十分な強度がないと、公開 から秘密 を割り出されてしまう
• 基本的に 強度= の長さ
• 現状では、2048bit を使っていればよいみたい

(作るときに長さを選べる)
• さらに秘密 にパスワードをかけると、より安全

(秘密 を使うときにパスワードの入力を要求されるようになる)
FURTHER INFORMATION
• 公開 と秘密 のペアは、手元のパソコンで簡単に作れる
• Windows: PuTTYgen
• Mac/Linux: Terminal
• GitHubに公開 を登録しておくと、APIからだれでも公開 を
取得できる
• 新規サーバーにログインしたいとき、サーバーの管理者に
「公開 はGitHubにおいてあるから設置しといて」とか頼
めて楽
FURTHER INFORMATION
• SSHとかSSLも大体似たようなかんじ
• 公開 暗号では一般にRSA暗号がよく使用される
• RSA暗号では、公開 で暗号化して秘密 で復号するだけ
でなく、秘密 で暗号化して公開 で復号化することも
できる

そのためデジタル署名にも使われる
• RSA暗号以外にも楕円曲線暗号とかある
CREDITS
• Icons made by Freepik from www.flaticon.com is licensed by CC BY 3.0
• Icon made by SimpleIcon from www.flaticon.com is licensed under CC BY 3.0
• Icon made by Elegant Themes from www.flaticon.com is licensed under CC BY 3.0
• 著者: @oroponya
この 作品 は クリエイティブ・コモンズ 表示 4.0
国際 ライセンスの下に提供されています。

Weitere ähnliche Inhalte

Kürzlich hochgeladen

業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)
業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)
業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)Hiroshi Tomioka
 
デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)
デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)
デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)UEHARA, Tetsutaro
 
クラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdf
クラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdfクラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdf
クラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdfFumieNakayama
 
CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?
CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?
CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?akihisamiyanaga1
 
自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineer
自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineer自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineer
自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineerYuki Kikuchi
 
モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察 ~Text-to-MusicとText-To-ImageかつImage-to-Music...
モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察  ~Text-to-MusicとText-To-ImageかつImage-to-Music...モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察  ~Text-to-MusicとText-To-ImageかつImage-to-Music...
モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察 ~Text-to-MusicとText-To-ImageかつImage-to-Music...博三 太田
 
NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)
NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)
NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)NTT DATA Technology & Innovation
 
AWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdf
AWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdfAWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdf
AWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdfFumieNakayama
 

Kürzlich hochgeladen (8)

業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)
業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)
業務で生成AIを活用したい人のための生成AI入門講座(社外公開版:キンドリルジャパン社内勉強会:2024年4月発表)
 
デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)
デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)
デジタル・フォレンジックの最新動向(2024年4月27日情洛会総会特別講演スライド)
 
クラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdf
クラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdfクラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdf
クラウドネイティブなサーバー仮想化基盤 - OpenShift Virtualization.pdf
 
CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?
CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?
CTO, VPoE, テックリードなどリーダーポジションに登用したくなるのはどんな人材か?
 
自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineer
自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineer自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineer
自分史上一番早い2024振り返り〜コロナ後、仕事は通常ペースに戻ったか〜 by IoT fullstack engineer
 
モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察 ~Text-to-MusicとText-To-ImageかつImage-to-Music...
モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察  ~Text-to-MusicとText-To-ImageかつImage-to-Music...モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察  ~Text-to-MusicとText-To-ImageかつImage-to-Music...
モーダル間の変換後の一致性とジャンル表を用いた解釈可能性の考察 ~Text-to-MusicとText-To-ImageかつImage-to-Music...
 
NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)
NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)
NewSQLの可用性構成パターン(OCHaCafe Season 8 #4 発表資料)
 
AWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdf
AWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdfAWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdf
AWS の OpenShift サービス (ROSA) を使った OpenShift Virtualizationの始め方.pdf
 

Empfohlen

PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...DevGAMM Conference
 

Empfohlen (20)

Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 
More than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike RoutesMore than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike Routes
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
 

楽しく学ぼう公開鍵暗号方式