cosmos-sdk/x/ibc/spec
colin axner 5dfc4a2ec9
Standardize connection versioning + channel versioning docs (#6640)
* update connection versions with feature set flag

* make connection version modular to support channel versioning and registering

* revert IBCVersion renaming, add channel versioning logic

* fix channel version flag

* remove unnecessary godoc

* remove unused func

* fix lint and version test

* add test and fix error

* revert changes

* update docs

* remove unnecessary godoc

* Apply suggestions from code review

Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>

* update doc

* add test cases for unchecked lines

* go fmt

* begin migration to standardized version

* revert proto changes

* restructure versioning to go from string to proto

* update versionStr to encodedVersion naming

* fix version test build

* fix keeper tests

* fix various tests

* fixes from self review

* update docs

* fix lint

* add more code cov

* rename ToString funcs to Encode/DecodeVersion + GetCompatibleEncodedVersions renaming

* update spec docs

Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>
2020-07-14 08:43:26 +00:00
..
01_concepts.md Standardize connection versioning + channel versioning docs (#6640) 2020-07-14 08:43:26 +00:00
02_state.md x/ibc: IBC alpha (#5277) 2020-04-08 20:57:52 -04:00
04_messages.md Update ibc proof to be bytes (#6393) 2020-06-12 00:19:25 +02:00
05_callbacks.md move packet executed call to ibc handler (#6312) 2020-06-04 11:24:21 +00:00
06_events.md x/ibc: IBC alpha (#5277) 2020-04-08 20:57:52 -04:00
README.md docs: IBC Application guide (#6464) 2020-06-19 08:23:45 -04:00

README.md

ibc

Abstract

This paper defines the implementation of the IBC protocol on the Cosmos SDK, the changes made to the specification and where to find each specific ICS spec within the module.

For the general specification please refer to the Interchain Standards.

Contents

  1. Concepts
  2. State
  3. State Transitions
  4. Messages
  5. Callbacks
  6. Events

Implementation Details

As stated above, the IBC implementation on the Cosmos SDK introduces some changes to the general specification, in order to avoid code duplication and to take advantage of the SDK architectural components such as the AnteHandler and transaction routing through Handlers.

Interchain Standards reference

The following list is a mapping from each Interchain Standard to their implementation in the SDK's x/ibc module:

Architecture Decision Records (ADR)

The following ADR provide the design and architecture decision of IBC-related components.

SDK Modules

IBC module architecture

NOTE for auditors: If you're not familiar with the overall module structure from the SDK modules, please check this document as prerequisite reading.

For ease of auditing, every Interchain Standard has been developed in its own package. The development team separated the IBC TAO (Transport, Authentication, Ordering) ICS specifications from the IBC application level specification. The following tree describes the architecture of the directories that the ibc (TAO) and ibc-transfer (ICS20) modules:

x/
├── ibc/
│  ├── 02-client/
│  ├── 03-connection/
│  ├── 04-channel/
│  ├── 05-port/
│  ├── 06-solo/
│  ├── 07-tendermint/
│  ├── 09-localhost/
│  ├── 23-commitment/
│  ├── 24-host/
│  ├── ante
│  │   └── ante.go
│  ├── client
│  │   ├── cli
│  │   │   └── cli.go
│  │   └── rest
│  │       └── rest.go
│  ├── keeper
│  │   ├── keeper.go
│  │   └── querier.go
│  ├── types
│  │   ├── errors.go
│  │   └── keys.go
│  ├── handler.go
│  └── module.go
└── ibc-transfer/