Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
3分でわかる WebRTCのP2P通信
Search
koz
July 21, 2021
Technology
0
70
3分でわかる WebRTCのP2P通信
3分間LTで発表した資料
WebRTCのP2Pについて調べたので作成した
koz
July 21, 2021
Tweet
Share
More Decks by koz
See All by koz
Angularの雰囲気を伝えたい
koz
0
48
TypeScriptに興味を持って欲しいスライド
koz
0
230
Other Decks in Technology
See All in Technology
EMConf JP 2025 懇親会LT / EMConf JP 2025 social gathering
sugamasao
2
190
Raycast AI APIを使ってちょっと便利な拡張機能を作ってみた / created-a-handy-extension-using-the-raycast-ai-api
kawamataryo
0
210
What's new in Go 1.24?
ciarana
1
110
OPENLOGI Company Profile
hr01
0
60k
MIMEと文字コードの闇
hirachan
2
1.4k
入門 PEAK Threat Hunting @SECCON
odorusatoshi
0
150
役員・マネージャー・著者・エンジニアそれぞれの立場から見たAWS認定資格
nrinetcom
PRO
3
5.8k
IAMポリシーのAllow/Denyについて、改めて理解する
smt7174
2
200
株式会社Awarefy(アウェアファイ)会社説明資料 / Awarefy-Company-Deck
awarefy
3
11k
Pwned Labsのすゝめ
ken5scal
1
380
Raycast Favorites × Script Command で実現するお手軽情報チェック
smasato
1
140
AWSではじめる Web APIテスト実践ガイド / A practical guide to testing Web APIs on AWS
yokawasa
7
650
Featured
See All Featured
A Tale of Four Properties
chriscoyier
158
23k
Into the Great Unknown - MozCon
thekraken
35
1.6k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
7k
What's in a price? How to price your products and services
michaelherold
244
12k
Scaling GitHub
holman
459
140k
Writing Fast Ruby
sferik
628
61k
Become a Pro
speakerdeck
PRO
26
5.2k
Keith and Marios Guide to Fast Websites
keithpitt
411
22k
The Cult of Friendly URLs
andyhume
78
6.2k
Practical Orchestrator
shlominoach
186
10k
The World Runs on Bad Software
bkeepers
PRO
67
11k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
Transcript
3分でわかる WebRTCのP2P通信
自己紹介 kozです。
WebRTCについて
WebRTC とは ブラウザ同士でリアルタイムに通信を行う仕組みのこと。 WebRTCのP2P通信の仕組みを簡単に説明し、完全に理解します。
通信方式 - P2P(Peer To Peer) - クライアント同士が映像 /音声を通信する - 今回はこれの紹介
- SFU(Selective Forwarding Unit) - サーバが映像/音声を中継してくれる - MCU(Multi-point Control Unit) - サーバーが映像/音声の処理をしてから配信してくれる
用語整理
登場人物 • Peer • STUN • シグナリング
Peer クライアントのこと。 ここでは、ボブとアリスとする。 ボブ アリス
シグナリング P2Pに必要な情報をやり取りする仕組み。 シグナリングサーバーを経由する。 方式は問わない。
STUN PeerのIP/Portを知るためのもの。 NAT越えに必要。
通信の流れ
その1 - シグナリング準備
その2 - Offerを送る Offer Offer
その3 - Anserを受け取る Answer Answer
その4 - STUNに問い合わせる Who am I ? Who am I
?
その5 - STUNから情報を受け取る Your IP & Port Your IP &
Port
その6 - 経路情報を交換する Candi date Candi date
その7 - P2Pでの通信開始!!!🎉 Data
まとめ WebRTCのP2P通信の仕組みを簡単に説明しました。 P2Pするために実際には、サーバーを介しての情報をやりとりするという手順を踏む必 要があるというのがわかったと思います。 実際にはまだ登場人物がいたりするので、興味があれば調べてみてください。 おしまい。