Skip to content

Commit

Permalink
Merge PR cosmos#192: Update PDF; fix images & sections
Browse files Browse the repository at this point in the history
  • Loading branch information
cwgoes authored Aug 13, 2019
1 parent f2ed6cf commit 370d1dd
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 21 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,6 @@
# agda interpreter state

*.agdai

# temporary files created during pdf preprocessing
*.md.xfm
5 changes: 5 additions & 0 deletions scripts/make_pdf.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,9 @@

set -xe

DIR=./spec
find $DIR -type f -name "*.md" -exec cp {} {}.xfm \;
find $DIR -type f -name "*.md.xfm" -exec awk -i inplace '/## Backwards Compatibility/ {exit} {print}' {} \;
find $DIR -type f -name "*.png" -exec cp {} . \;
pandoc --pdf-engine=xelatex --template eisvogel --filter pandoc-include --mathjax --toc --number-sections -o spec.pdf spec.pdc
rm *.png
22 changes: 11 additions & 11 deletions spec.pdc
Original file line number Diff line number Diff line change
Expand Up @@ -33,44 +33,44 @@ header-includes:

# ICS 001 - ICS Standard

!include spec/ics-001-ics-standard/README.md
!include spec/ics-001-ics-standard/README.md.xfm

# ICS 023 - Vector Commitments

!include spec/ics-023-vector-commitments/README.md
!include spec/ics-023-vector-commitments/README.md.xfm

# ICS 024 - Host Requirements

!include spec/ics-024-host-requirements/README.md
!include spec/ics-024-host-requirements/README.md.xfm

# ICS 002 - Consensus Verification

!include spec/ics-002-consensus-verification/README.md
!include spec/ics-002-consensus-verification/README.md.xfm

# ICS 003 - Connection Semantics

!include spec/ics-003-connection-semantics/README.md
!include spec/ics-003-connection-semantics/README.md.xfm

# ICS 005 - Port Allocation

!include spec/ics-005-port-allocation/README.md
!include spec/ics-005-port-allocation/README.md.xfm

# ICS 004 - Channel & Packet Semantics

!include spec/ics-004-channel-and-packet-semantics/README.md
!include spec/ics-004-channel-and-packet-semantics/README.md.xfm

# ICS 025 - Handler Interface

!include spec/ics-025-handler-interface/README.md
!include spec/ics-025-handler-interface/README.md.xfm

# ICS 026 - Relayer Module

!include spec/ics-026-relayer-module/README.md
!include spec/ics-026-relayer-module/README.md.xfm

# ICS 018 - Relayer Algorithms

!include spec/ics-018-relayer-algorithms/README.md
!include spec/ics-018-relayer-algorithms/README.md.xfm

# ICS 020 - Fungible Token Transfer

!include spec/ics-020-fungible-token-transfer/README.md
!include spec/ics-020-fungible-token-transfer/README.md.xfm
Binary file modified spec.pdf
Binary file not shown.
20 changes: 10 additions & 10 deletions spec/ics-023-vector-commitments/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,11 +167,11 @@ If batch verification is possible and more efficient than individual verificatio
### Properties & Invariants
Commitments MUST be *complete*, *sound*, and *position binding*. These properties are defined with respect to a security parameter `λ`, which MUST be agreed upon by the manager, prover, and verifier (and often will be constant for the commitment algorithm).
Commitments MUST be *complete*, *sound*, and *position binding*. These properties are defined with respect to a security parameter `k`, which MUST be agreed upon by the manager, prover, and verifier (and often will be constant for the commitment algorithm).
#### Completeness
Commitment proofs MUST be *complete*: key => value mappings which have been added to the commitment can always be proved to have been included, and keys which have not been included can always be proved to have been excluded, except with probability negligible in `λ`.
Commitment proofs MUST be *complete*: key => value mappings which have been added to the commitment can always be proved to have been included, and keys which have not been included can always be proved to have been excluded, except with probability negligible in `k`.
For any key `key` last set to a value `value` in the commitment `acc`,
Expand All @@ -181,7 +181,7 @@ proof = createMembershipProof(acc, key, value)
```
```
Pr(verifyMembership(root, proof, key, value) === false) negligible in λ
Pr(verifyMembership(root, proof, key, value) === false) negligible in k
```
For any key `key` not set in the commitment `acc`, for all values of `proof` and all values of `value`,
Expand All @@ -192,28 +192,28 @@ proof = createNonMembershipProof(acc, key)
```
```
Pr(verifyNonMembership(root, proof, key) === false) negligible in λ
Pr(verifyNonMembership(root, proof, key) === false) negligible in k
```
#### Soundness
Commitment proofs MUST be *sound*: key => value mappings which have not been added to the commitment cannot be proved to have been included, or keys which have been added to the commitment excluded, except with probability negligible in a configurable security parameter `λ`.
Commitment proofs MUST be *sound*: key => value mappings which have not been added to the commitment cannot be proved to have been included, or keys which have been added to the commitment excluded, except with probability negligible in a configurable security parameter `k`.
For any key `key` last set to a value `value` in the commitment `acc`, for all values of `proof`,
```
Pr(verifyNonMembership(root, proof, key) === true) negligible in λ
Pr(verifyNonMembership(root, proof, key) === true) negligible in k
```
For any key `key` not set in the commitment `acc`, for all values of `proof` and all values of `value`,
```
Pr(verifyMembership(root, proof, key, value) === true) negligible in λ
Pr(verifyMembership(root, proof, key, value) === true) negligible in k
```
#### Position binding
Commitment proofs MUST be *position binding*: a given key can only map to one value, and an commitment proof cannot prove that the same key opens to a different value except with probability negligible in λ.
Commitment proofs MUST be *position binding*: a given key can only map to one value, and an commitment proof cannot prove that the same key opens to a different value except with probability negligible in k.
For any key `key` set in the commitment `acc`, there is one `value` for which:
Expand All @@ -223,13 +223,13 @@ proof = createMembershipProof(acc, key, value)
```
```
Pr(verifyMembership(root, proof, key, value) === false) negligible in λ
Pr(verifyMembership(root, proof, key, value) === false) negligible in k
```
For all other values `otherValue` where `value /= otherValue`, for all values of `proof`,
```
Pr(verifyMembership(root, proof, key, otherValue) === true) negligible in λ
Pr(verifyMembership(root, proof, key, otherValue) === true) negligible in k
```
## Backwards Compatibility
Expand Down

0 comments on commit 370d1dd

Please sign in to comment.