-
- Deepdive into DFNS and CaaS. Assets, account management, signing arbitrary, policies, more. Crosschain, security, multi-tenancy, split of onchain vs offchain.
- Swagger can autogenerate clients in many languages from openapi specs: https://editor.swagger.io/.
- Remember these used to be called swagger specs, now openapi.
- DSA = Digital Signature Algorithm.
- ECDSA = Elliptic Curve DSA.
- EdDSA = Edwards Curve DSA.
- TSS = Threshold Signature Scheme.
- Miro is a whiteboarding solution. Can use for presentations, any browser collab.
- Monzo is like Mint. Manage your money. Check all transactions, set budgets, get notifications, etc.
- Omnibus account, omnibus wallet.
- Many people have access. Usually used for business. Like a treasury. Also everything is in the omnibus’ name, so the multiple parties behind it remain private.
- 2 models for crypto custody specifically:
- Segregated: every individual has their own keypair(s).
- Omnibus: there’s a single keypair (account) with all the combined assets and then bookkeeping for individuals is held in a secondary (centralized) service/db (offchain).
- Imagine Bank of America. Segregated means I hold my money in a savings account with them. Omnibus means there’s a single account holding all USD for people named Brian, and I have a claim for a certain amount of it.
- “Custodian” is basically synonymous with “depository”.
- While omnibus in its purest form means 1 keypair, you can also have an omnibus hierarchy. One master key, but then subkeys (and subkeys and subkeys..) give access as well. Even onchain.
- Omnibus is basically giving your ownership over to the custodian, rather than holding yourself (but you have a claim for return, of course; just not an individual account).
- Omnibus is more efficient: imagine you ran all of sushiswap with an omnibus account. The only gas transactions you’d have to pay would be new people joining/leaving with their wallets. All swaps on the dex would be managed offchain in the individual service, not written to eth mainnet, because the omnibus account holds the funds always.
- Omnibus is harder for compliance/regulation. Obv more obscure. You have to augment with a custom system.
- Aave released Lens on polygon. A social media protocol.
- Your wallet has an NFT, your profile. You can then use metamask (or another) to login to dapps, and the dapps use the NFT to establish your profile.
- Many dApps already support this on polygon.
-
- Solana 1.10 upgrade.
- Nodes can use QUIC instead of UDP. Quick UDP Internet Connection, it has asynchronous capability. It’s a multiplex transport on top of udp.
- Instead of first-come-first-serve resulting in spamming nodes to get transactions in, they’re adding stake-weighted transaction processing. With a fee structure. Like a standard mempool of other chains.
- Block/Dorsey.
- They already have the Cash app, venmo equivalent.
- They bought Tidal from Jayz, so there’s music connection. May sell tickets in Cash app, making it an ecosystem, not just a simple payment service.
- They bought Afterpay, BNPL (buy now pay later) app. It’s like a shorter, limited credit card. You pay in regular installments some time after the purchase. Interest free! Klarna and Affirm are other options.
- They’re also building a wallet.
- They’re also building devtools.
- They’re also running miners.
- Sidechain vs rollup.
- Sidechain is completely independent. There’s a smart contract that bridges it with other chains, but comes with no guarantees. It uses its own verification. Polygon is a sidechain.
- A rollup uses another L1 as the settlement network. So you get ALL the security guarantees of the first network; you get all the balances and original verifications (like arbitrum and optimism on eth) – the L2 is just a cheaper side network for subtransactions.
- A zk rollup is a subset of other rollups. More efficient. Loopring is an eth zkrollup.
- That’s what bridges are for. They lock one asset on one network then notify the other network to mint the other asset.
- Good overview: https://np.reddit.com/r/ethfinance/comments/jiuicy/widespread_understanding_of_l2_scaling_tradeoffs/
- A fork is even different. Used the same tech, but has now become something else (like changing consensus to PoA, as in eth->bnb).
- Polygon Nightfall mainnet is released. It’s a private polygon.
- Consensus.
- Fundamental problem is the byzantine generals problem. Distributed nodes. How to agree when messages can be fraudulent or missing?
- Just a voting system. All nodes have the chance to vote once. The majority (could be >50% or >66.6% or whatever threshold you want) outcome is executed. The leader (changing everytime) collects/aggregates/submits/etc.
- Related but not identical to the actual algorithm: your “vote” could be proportional to cpu power, held stake, or any other metric. This is how we have PoW, PoS, dPoS, PoA, and one.
- Actual process: preprepare, prepare, commit.
- Preprepare: The client’s request makes it to the primary node (leader). The leader sends it to every secondary node in the network.
- Prepare: Every active node that got the new request from the leader then does additional checks on it, and EACH sends it back out to EVERY other node.
- Commit: Every node then checks for final validity, and if they approve, sends a confirmation back to the client. Once the client has received the threshold of approvals, the request is finalized.
- Solana’s Tower BFT uses Proof of History (PoH) as well, which cryptographically affirms chronology. Like a clock for blockchain (rather than just sequence of block 1 then block 2 then block 3 etc).
- PoA and PoSA, authority and staked authority.
- For PoA, it’s more efficient (and less decentralized).
- You can even configure PoA to not require gas, if you control (or trust) all the nodes to the point where you don’t need to have incentivized mining. The validators just validate without reward bc you own them.
- Very common in private networks, private blockchains (like for enterprise supply chains) bc you can optimize for performance more than decentralization.
- VeChain is PoA.
- PoSA is a hybrid between PoS and PoA. Proof of Authority confirms the identity of approved validators, and then voting is among that approved pool and voting is proportional to stake. BNB Chain (formerly Binance Smart Chain, BSC) is PoSA (21 validators).
- Clique is a common PoA algorithm (I’ve set this up before). It came from EIP225: https://eips.ethereum.org/EIPS/eip-225.
- Paxos is an old and robust consensus mechanism.
- It handles fail-stop, missing messages, wrong order, and other node failures; it does NOT handle malicious messages (like BFT does).
- Paxos is the basis for zookeeper.
- Raft.
- An evolution of paxos. Basically the same algo, but a bit simpler.
- https://raft.github.io/
- Good visualization: http://thesecretlivesofdata.com/raft/
- Each node has one of 3 states: leader, follower, candidate.
- If a node doesn’t hear from a leader, it identifies itself as a candidate. It then sends a message to all nodes to vote. The first node to receive majority becomes the leader. This is leader election.
- Consensus works just like log replication in DBs. The leader receives a state change. He sends it to the other nodes as a proposal. The nodes reply if they can successfully verify that state. Once the leader receives majority votes on the proposal, it sends a message to all nodes that the new value has been committed by the leader. Once majority nodes confirm they’ve committed as well, the leader sends a message back to the client.