Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
KLabエキスパートキャンプ成果発表
Search
teru0x1
August 29, 2019
Technology
67
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
KLabエキスパートキャンプ成果発表
teru0x1
August 29, 2019
Transcript
14 slides
KLAB EXPERT CAMP Ռൃද খ ً
ࣗݾհ • ւಓେֶ ใΤϨΫτϩχΫεֶՊ 4 • དྷ͠·͢ • seccamp(2018), SecHack365(2017)
খ ً @teru0x1
ࢲͷςʔϚ RustͰTCPͷ࣮
ͳͥRUST͔ • CݴޠฒΈͷߴ͍ύϑΥʔϚϯε • ܕ҆શੑɺϝϞϦ҆શੑ - ະఆٛಈ࡞͕ൃੜ͠ͳ͍ - ແޮͳϙΠϯλ࡞͞Εͳ͍ʢ͔ؔΒϩʔΧϧมͷϙΠ ϯλΛฦ͢ͳͲʣ
- ίϯύΠϧ௨ͬͨ࣌ͷ҆৺ײ͕͍͢͝ • ߴ͍දݱྗ(ΫϩʔδϟɺΠςϨʔλ) • ॆ࣮ͨ͠ඪ४ϥΠϒϥϦʢϋογϡςʔϒϧɺλϓϧʣ
༷ͳͲ • TCPͷιέοτϥΠϒϥϦͱͯ͠ΞϓϦέʔγϣϯ͔Βར༻Ͱ͖Δ Α͏ʹͨ͠ • ࣮ͨ͠API - connect(): 3-way-handshakeΛߦ͍ଓΛཱ֬͢Δ -
bind(): Ϧεχϯάιέοτͷੜɺࢦఆͨ͠ΞυϨεͰϦοεϯ - accept(): ଓࡁΈιέοτΛฦ͢ - read(): ଓࡁΈιέοτ͔ΒಡΈࠐΉ - write(): ଓࡁΈιέοτॻ͖ࠐΉ • ࠶ૹ੍ޚ
࣮ʹ͍ͭͯ • TCP/IPࣗ࡞ຊɺmicropsͷ࣮Λ͔ͳΓࢀߟʹͨ͠ɻ • l3·ͰpnetΫϨʔτΛར༻ʢνΣοΫαϜͳͲϥΠϒϥϦΛ ͏ʣ • ϥΠϒϥϦΛར༻͢ΔΞϓϦέʔγϣϯͱͯ͠echoαʔόɺΫϥ ΠΞϯτΛ࡞ͨ͠ɻ
8/26 • ඈߦػͰඈΜͰ͘Δ • ݐͷೖΓํ͕Θ͔Βͳ͔ͬͨ • ͓ण͓͍͍࢘͠ • APIͷܗΛ࡞Δ •
ઃܭʹۤ࿑͢ΔʢTCPͷཧςʔϒϧͲ͜ʹ࣋ͨͤΑ͏ʁʣ
8/27 • 3-way-handshakeୡ
8/28 • connect(), read(), write()Λ࣮ • TCPΫϥΠΞϯτͷػೳྃ • bind()Λ࣮ɺαʔόʔͬΆ͍͜ͱ͕Ͱ͖ΔΑ͏ʹͳͬͨ •
͜ͷ࣌1ϙʔτ1ଓͩͬͨ
8/29 • accept()Λ࣮ • ࠶ૹ੍ޚΛ࣮
σϞ • ಈ͍͍͓ͯͩ͘͞ئ͍͠·͢ • echoαʔόVMʢUbuntuʣ, ΫϥΠΞϯτmacOSͰ͢
େมͩͬͨͱ͜Ζ • ࣗ࡞TCP͕͍ͬͯΔVMͷΧʔωϧ͕֎෦͔ΒདྷͨSYNʹରͯ͠ RSTΛฦ͢ - iptablesͰ֎͖ͷRSTυϩοϓͨ͠ • RustͷίϯύΠϧΛ௨͢͜ͱ
͞Γ͛ͳ͘એ • ιέοτϓϩάϥϛϯά • ύέοτΩϟϓνϟ • ϙʔτεΩϟϯπʔϧ • non-blocking web
αʔό • DHCPαʔό
ײͳͲ • TCPશʹཧղͨ͠ งғؾ͕গ͠Θ͔ΔΑ͏ʹͳͬͨ - ίωΫγϣϯཧͷख๏͕Θ͔ͬͨ - ঢ়ଶΛ࣋ͭͱҰؾʹෳࡶʹͳΔ • 1ʹҰճσουϩοΫͰϋϚͬͨ
- ͰɺʮσουϩοΫͯ͠ΔΑʂʯͱॲཧܥ͕ڭ͑ͯ͘ΕΔ • ggͬͯग़ͯ͜ͳ͍ਂ͍ࣝʹ͍࣭ͭͯͰ͖ͯษڧʹͳͬͨɻ • ߨٛͷํฉ͍ͯΈ͔ͨͬͨ • Rust͍͍ͧʂʂʂʂʂʂʂʂʂ ϝϯλʔ͞Μɺνϡʔλʔ͞ΜɺӡӦ͞Μɺ͋Γ͕ͱ͏͍͟͝·ͨ͠ɻ
More Decks by teru0x1
See All by teru0x1
Slack上でインフラをトラブルシュートする! Agentic Platform Engineeringの第一歩
teru0x1
5
2.2k
開発効率と信頼性を両立する Ubieのプラットフォームエンジニアリング
teru0x1
0
750
マルチクラスタの認知負荷に立ち向かう! Ubieのプラットフォームエンジニアリング
teru0x1
4
5.1k
ブラウザの外側でWasmを使おう
teru0x1
0
410
スタブサーバ自動生成ツール 〜負荷試験をもっと楽に〜
teru0x1
0
2.2k
バッチシステムをクラウドネイティブにするために考えたこと
teru0x1
17
8.7k
クラウド環境をFargateに 移行して得た知見
teru0x1
0
1.7k
Goと定数 DMM.go #3
teru0x1
0
2.9k
はてなインターン2020成果発表
teru0x1
0
1.2k
Other Decks in Technology
See All in Technology
Claude Securityを使ってみた / claude-security-claude-code-meetup-nagoya
tnir
0
110
AI時代の組織作り:チーム開発から「個人×AI」への移行と、持続可能な「開発資本」の築き方
ham0215
3
840
Steering と Hook (チームの決まりを守らせる) | 目指せ Kiro マスター 06
inariku
PRO
2
120
JAWSコミュニティに 参加して1年経った結果
ssakita
0
150
[NW-JAWS DAY]「うちのAWS、インターネット出られないんで」― AWS外の自社サービスをPrivateLinkでシュッと公開する方法
ykimi
2
290
Claude Codeで作ったアプリを安全に公開する/Built with Claude Japan 2026
yoshidashingo
0
250
SREのためのFinOps入門
muziyoshiz
3
1.5k
うちなーぐちが認識できるなら、秋田弁もいけるはず!? Amazon Transcribe方言チューニング検証
ryouto715
1
170
An Introduction to Context Ontology Accelerator (teaching AI agents what your data means)
inariku
PRO
1
250
これからのデータエンジニアの役割について考える / Rethinking the Role of Data Engineers in the AI Era
okiyuki99
0
490
Context != Context: One window, many lifecycles (AI Native DevCon, Nov 2026)
birgitta410
0
140
81天的 AI Agent 軟體開發團隊治理實務分享
regionbbs
0
170
Featured
See All Featured
Leading Effective Engineering Teams in the AI Era
addyosmani
9
2.9k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
3.3k
Darren the Foodie - Storyboard
khoart
PRO
5
4.1k
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
750
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
33
5.7k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
232
55k
Site-Speed That Sticks
csswizardry
13
1.6k
Typedesign – Prime Four
hannesfritz
42
3.2k
HTML-Aware ERB: The Path to Reactive Rendering @ RubyCon 2026, Rimini, Italy
marcoroth
6
920
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
680
VelocityConf: Rendering Performance Case Studies
addyosmani
331
25k
HDC tutorial
michielstock
2
1k