Share
Embed
Transcript
47 slides
-
prototypal.com Building Dapps with Generalized State Channels Erik Bryn Counterfactual
core team Founder, Prototypal An introduction & my lessons learned -
prototypal.com About me • Founder of Prototypal • Ember.js &
Counterfactual core teams • Recently moved to Austin from SF • Relatively new to the blockchain ecosystem -
prototypal.com A connection, or channel, between two or more parties
that facilitates the transmission of signed commitments What are State Channels? -
prototypal.com These signed commitments can be deployed on-chain, but don’t
have to be What are State Channels? -
prototypal.com State Channels facilitate off-chain interactions with the safety &
guarantees of the blockchain What are State Channels? -
prototypal.com State Channels are an evolution of Payment Channels State
Channels are to Payment Channels, as Ethereum is to Bitcoin Payment channels -
prototypal.com Raiden & the Lightning are examples of payment channel
networks. Payment channels -
prototypal.com Why should you care about State Channels? Blockchain (on-chain)
interactions will always be expensive The blockchain is a resource that you will always have to pay for -
prototypal.com Not every interaction between parties needs to be published
on-chain into an immutable database that lives forever Why should you care about State Channels? -
prototypal.com State Channels might be a better default for many
types of Dapps. That said, they’re not a silver bullet. Why should you care about State Channels? -
prototypal.com State Channels scale! State Channels give you instant, private,
free, trust-less transactions. State Channels are built with standard off the shelf technologies and can be as scalable as your typical centralized web applications. -
prototypal.com … but what about Sharding/Plasma/Casper? It turns out all
these Ethereum scaling technologies are complementary However, with on-chain scaling, you’ll always have to pay gas, wait for block confirmations, etc. -
prototypal.com What are Generalized State Channels? A technique for creating
State Channels with a minimal on-chain footprint for both privacy and gas efficiency, while being secure and game theoretically sound -
prototypal.com At the core, a Generalized State Channel is built
upon a multisignature wallet. The multisig acts as an escrow for assets being used within State Channel Dapps. What are Generalized State Channels? -
prototypal.com Counterfactual instantiation is an important concept that enables us
to sign commitments in State Channels that can build upon Smart Contract logic without actually needing those contracts to be deployed or invoked What are Generalized State Channels? -
prototypal.com Our white paper was recently released: https://counterfactual.com/statechannels What are
Generalized State Channels? -
prototypal.com How can you use State Channels today? There’s been
a lot of talk and research published over the past few years, but it’s difficult to get started today -
prototypal.com How can you use State Channels today? A recently
released paper detailing a technique called Force Move Games is a great place to start: https://medium.com/statechannels/introducing-the- force-move-games-framework-for-state-channels- b32dd953c13f -
prototypal.com It’s really hard to use State Channels today, but
we’d like to change that -
prototypal.com We want to see Generalized State Channels exist in
the world, so we’re building the Counterfactual framework. It’s an open source, holistic GSC implementation targeted towards everyday Dapp developers. -
prototypal.com And no… we’re not doing an ICO This is
just good ol’ fashioned open source -
prototypal.com The scope of our work spans from core research
all the way to the user experience of Dapp developers and their users The Counterfactual framework -
prototypal.com In my experience, the best way to build a
framework is to build applications and extract the framework from them -
prototypal.com We’ve been exploring what the Counterfactual framework should provide
by building example Dapps -
prototypal.com Ethmo: our first GSC Dapp Ember.js counterfactual-client Ethers.js Ember
Data ember-ethereum counterfactual-contracts gnosis-safe-contracts Ethmo ganache-cli Node.js Websocket Relay -
prototypal.com Lessons learned Both of these GSC example Dapps used
their own WebSocket relays for communication between parties We’re interested in exploring using libp2p / Whisper -
prototypal.com Lessons learned The most important thing for user’s safety
while using State Channels is to ensure their channel state is retained. In our example apps, we simply used the browser’s localStorage, this isn’t quite good enough for production use. -
prototypal.com Lessons learned To avoid every State Channel interaction requiring
user signing, our Dapps create ephemeral keys which are the owners of the underlying multisig. These ephemeral keys are also important to retain. -
prototypal.com Lessons learned For these reasons, and more, we strongly
believe the success of State Channels is dependent upon their adoption / integration with wallets. -
prototypal.com We're trying to experiment and build a holistic understanding
of the system before we starting promoting any particular implementation details outside of the paper What’s next? -
prototypal.com Working towards our first public release in the coming
months What’s next? -
prototypal.com If you’re interested in this space, we’d love
to have you work with us! If you’re building an app that could utilize state channels today or in the very near future, reach out! What’s next?