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
cris (supplementary material)
Search
ktr
January 11, 2018
Programming
0
55
cris (supplementary material)
supplementary material
ktr
January 11, 2018
Tweet
Share
More Decks by ktr
See All by ktr
Designing libraries in Go way
ktr_0731
6
1.4k
Go Modules and Proxy Walkthrough
ktr_0731
8
26k
ソフトウェアの複雑さに立ち向かう技術 / Tackling software complexity
ktr_0731
0
160
Fuzzy finder as a Go library
ktr_0731
3
5.3k
つよくてニューゲーム / NewGame++
ktr_0731
0
890
やはり俺の Go アプリケーション設計はまちがっている。 / My Go Application Design Is Wrong, As I Expected
ktr_0731
13
3.4k
GopherCon2018
ktr_0731
2
1.7k
Evans: more expressive gRPC client
ktr_0731
2
410
自作 CLI ツールのワークフローとそれを支える技術 / the workflow of my CLI tool and technologies which supports it
ktr_0731
0
1.7k
Other Decks in Programming
See All in Programming
dbtのドメイン分割による データ基盤の改善とDigdagとの連携
sakama
0
320
はてなにおける CSS Modules、及び CSS Modules に足りないもの / CSS Modules in Hatena, and CSS Modules missing parts
mizdra
7
930
Git Lint
bkuhlmann
4
750
Changed Rules: Architectures with Lightweight Stores
manfredsteyer
PRO
0
240
今、知っておきたい! 生成AIエージェントの世界
elith
3
360
Rethinking UI building strategies @ SFI 2024
letelete
0
270
SIMD Parallel Programming with the Vector API
josepaumard
0
170
Rubyでたのしむクリエイティブコーディング/Enjoy Creative coding with Ruby
chobishiba
1
180
1BRC--Nerd Sniping the Java Community
gunnarmorling
0
340
見た目から始める生産性向上
ikumatadokoro
7
840
検証も兼ねて個人開発でHonoとかと向き合った話
hanetsuki
1
920
R言語の環境構築と基礎 Tokyo.R 112
bob3bob3
0
270
Featured
See All Featured
Side Projects
sachag
451
41k
The Invisible Customer
myddelton
114
12k
Fireside Chat
paigeccino
21
2.6k
What’s in a name? Adding method to the madness
productmarketing
PRO
16
2.6k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
352
28k
How to train your dragon (web standard)
notwaldorf
73
5.2k
The Cost Of JavaScript in 2023
addyosmani
16
3.9k
Embracing the Ebb and Flow
colly
80
4.1k
KATA
mclloyd
15
12k
Keith and Marios Guide to Fast Websites
keithpitt
408
22k
Bootstrapping a Software Product
garrettdimon
PRO
302
110k
Designing Experiences People Love
moore
136
23k
Transcript
Blockchain を 利用したファイル改竄検知 !LUS@
ファイルの完全性の検証 ハッシュアルゴリズムによる検証
ファイルの完全性の検証 ハッシュアルゴリズムによる検証 hash := H(content) md5('hello') = b1946ac92492d2347c6235b4d2611184
ファイルの完全性の検証 ハッシュアルゴリズムによる検証 hash := H(content) md5('hello') = b1946ac92492d2347c6235b4d2611184 'hello' b1946ac92492d2347c6235b4d2611184
ファイルの完全性の検証 ハッシュアルゴリズムによる検証 hash := H(content) md5('hello') = b1946ac92492d2347c6235b4d2611184 'hello' b1946ac92492d2347c6235b4d2611184
hash := H(received_content) md5('hello') = b1946ac92492d2347c6235b4d2611184
ファイルの完全性の検証 ハッシュアルゴリズムによる検証 hash := H(content) md5('hello') = b1946ac92492d2347c6235b4d2611184 'bad hello'
b1946ac92492d2347c6235b4d2611184 hash := H(received_content) md5('hello') = b1946ac92492d2347c6235b4d2611184
ファイルの完全性の検証 ハッシュアルゴリズムによる検証 hash := H(content) md5('hello') = b1946ac92492d2347c6235b4d2611184 'bad hello'
b1946ac92492d2347c6235b4d2611184 hash := H(received_content) md5('bad hello') = 842dc2b34384799a1f1a3a1315ab1f5b
ファイルの完全性の検証 署名 + ハッシュアルゴリズムによる検証 hash := H(content) signature := SignByPrivateKey(hash)
ファイルの完全性の検証 署名 + ハッシュアルゴリズムによる検証 hash := H(content) signature := SignByPrivateKey(hash)
content public key signature
ファイルの完全性の検証 署名 + ハッシュアルゴリズムによる検証 hash := H(content) signature := SignByPrivateKey(hash)
content public key signature expectedHash := decodeByPublicKey(signature) actualHash := H(content) check expectedHash == actualHash
ファイルの完全性の検証 ファイル自体が改竄されると検出できない hash := H(badContent) signature := SignByPrivateKey(hash) content public
key signature expectedHash := decodeByPublicKey(signature) actualHash := H(content) check expectedHash == actualHash
Blockchain • bitcoin のコアを支える技術 • P2P のシステム • 記録された情報への改竄を検出でき、復元可能
Blockchain
Ethereum • bitcoin の Blockchain をベースにした派生 • スマートコントラクトを実装している
スマートコントラクト • Blockchain ネットワーク上で動くアプリケーション • アプリケーションの状態を変更する様なアクション (command) は Blockchain に記録される
• アプリケーションの保有するデータを改竄できない
今回のアプリのアーキテクチャ 1. generate keypair Upload File
今回のアプリのアーキテクチャ 1. generate keypair 2. create Ethereum account Upload File
今回のアプリのアーキテクチャ 1. generate keypair 3. store H(content) and own account
address 2. create Ethereum account Upload File
今回のアプリのアーキテクチャ 1. generate keypair 4. upload content with signature and
public key 3. store H(content) and own account address 2. create Ethereum account Upload File
今回のアプリのアーキテクチャ 1. generate keypair 4. upload content with signature and
public key 3. store H(content) and own account address 5. verify content by signature 2. create Ethereum account Upload File
今回のアプリのアーキテクチャ 1. generate keypair 4. upload content with signature and
public key 3. store H(content) and own account address 5. verify content by signature 2. create Ethereum account Upload File 6. store the content
今回のアプリのアーキテクチャ Share / Download File 1. generate shared URL
今回のアプリのアーキテクチャ Share / Download File 1. generate shared URL 2.
share the URL https://example.com/{hash}
今回のアプリのアーキテクチャ Share / Download File 1. generate shared URL 2.
share the URL https://example.com/{hash} 3. open the URL
今回のアプリのアーキテクチャ Share / Download File 1. generate shared URL 2.
share the URL https://example.com/{hash} 3. open the URL 4. verify hash and it's owner
今回のアプリのアーキテクチャ Share / Download File 1. generate shared URL 2.
share the URL https://example.com/{hash} 3. open the URL 5. verify hash and it's owner 4. verify hash and it's owner
今回のアプリのアーキテクチャ Share / Download File 1. generate shared URL 2.
share the URL https://example.com/{hash} 3. open the URL 5. verify hash and it's owner 6. return shared content 4. verify hash and it's owner
demo
応用 • KYC (Known Your Customer)
KYC (例: GMO グローバルサイン)