completed
Cardano development library in C++
Current Project Status
complete
Total
amount
Received
$10,000
Total
amount
Requested
$10,000
Total
Percentage
Received
100.00%
$10,000 Received out of $10,000
Solution

By developing an open-source C++ library for Cardano, we enable more developers to integrate Cardano with new and existing projects.

Problem

The Cardano ecosystem does not have a native C++ library which isolates Cardano from one of the largest open-source developer communities.

Addresses Challenge
Feasibility
Auditability

Team

1 member

This proposal was approved and funded by the Cardano Community via Project F8: Open Source Development Ecosystem Catalyst funding round.

  • download
  • download

[IMPACT]

Cardano+ +, A blazingly fast library of Cardano blockchain tools written in modern C+ +

This library seeks to provide an interface for open-source C++ projects to quickly integrate Cardano capabilities into their new or existing project. By enabling Cardano primitives to be easily integrated into C++ applications, the Cardano ecosystem will benefit from not only the rich C++ developer community, but also the high-performance capability of compiled code.

The current version of the library has the basic functionality for BIP32 HD key derivation and subsequent address creation. Additionally, the BECH32 encoding capability is already implemented. The efforts under this proposal will seek to further implement Cardano primitives focusing on wallet interactions: full BIP39 implementation, CBOR serialization, as well as transaction building and signing. Future work (not covered by this proposal) will build off of this foundation to implement Cardano protocol primitives to enable a C++ application to interface directly with on chain nodes.

This library will target modern C++ standards as much as possible. We are already implementing capabilities from standards as new as C++20.

This project impacts the key KPIs for the challenge:

- This project will increase the number and the quality of Cardano Open Source projects, since it is itself a new Cardano open source project as well as making it easier for additional open source projects to come to the Cardano ecosystem.

- This project can increase the number of contributors to the Cardano ecosystem by bringing in developers from the C++ developer community.

- This project will increase the amount of open source tools and frameworks from the community for the community since it is built by a team of long time community members for other developers in the community.

The project will be openly shared through social media channels and developer groups.

Some of the tasks represent a learning opportunity for the team. The available project documentation and example code in the IOHK repositories has proven in the past to provide the information needed to learn about the protocol.

[FEASIBILITY]

Q3 2022: Implementation of the BIP29 root key derivation from mnemonic phrase. CMake file for integrating the library with other applications.

Q4 2022: Implement basic transaction (P2P ADA transaction) building and key serialization (CBOR). Implement transaction signatures and transaction serialization (CBOR).

This project depends entirely on manual hours invested to implement the code.

We estimate the required effort to fall roughly at 55 hours per month. With a conservative estimate of hourly labor costs, the total comes to approximately $10,000.00 for the six month effort.

Team member 1: Dylan Crocker Ph.D.

Ph.D. in Electrical Engineering with a minor in Computer Science from Georgia Tech. Engineering professional with over 10 years of experience. Cardano stake pool operator since December 2019.

Team member 2: Willie Marchetto

Received a Bachelor of Science degree in Computer Engineering from Missouri University of Science and Technology and a Master of Science degree in Astronautical Engineering (with a focus in spacecraft electronics and software) from University of Southern California. I have 10 years experience in research and development of high-consequence, high-reliability space systems and have spent a great deal of time administrating Linux servers, much like the ones we use to operate our stake pools. Cardano stake pool operator since December 2019.

Both team members have previously had a project funded through Catalyst with successful completion.

[AUDITABILITY]

The project progress will be measured by a goal of 5 substantial git commits per month. This isn’t always the best method of measuring progress so we additionally measure implemented unit tests with the goal of one new unit test implemented and passing each month.

The project work defined under this proposal will be considered “done” when the following criteria are met:

1. The library can be integrated with another modern C++ project using CMake.

2. Unit tests are defined and successfully passed that derives spending and staking addresses from a mnemonic phrase.

3. Keys can be serialized to CBOR and this verified with a unit test.

4. Basic transaction building, signing, and serialization completed and verified with a test(s).

This is an entirely new project.

Community Reviews (1)

Comments

Monthly Reports

N/A

Disbursed to Date
$10,000
Status
Still in progress
Completion Target
12/31/2022
Comments 0

Login or Register to leave a comment!

Completed project milestone #1: CMake integration for projects using the library. Officially completed milestone #2: added specific unit tests for mnemonic to address derivation. Also, fixed a hard to find bug that only showed up on macOS (Clang) when decoding a Byron address due to reading the incorrect number of bytes as an integer.

Disbursed to Date
$10,000
Status
Still in progress
Completion Target
3. In the next 6 months
Attachment(s)
Comments 0

Login or Register to leave a comment!

Working on the final thrust of the project: transaction support. This requires a robust CBOR capability. To this end, we've added a comprehensive CBOR encode/decode capability which is essentially a wrapper around portable C code (QCBOR). The CBOR capability is almost complete.

Git commits: 7

Disbursed to Date
$10,000
Status
Still in progress
Completion Target
3. In the next 6 months
Comments 0

Login or Register to leave a comment!

Working on the final thrust of the project: transaction support. This requires a robust CBOR capability. The CBOR capability has been extended and as a unit test the CBOR code is used to decode an example Cardano transaction (stake pool registration). This was slow going but a significant step towards the end goal of simple transaction support.

Git commits: 4

Disbursed to Date
$10,000
Status
Still in progress
Completion Target
2. In the next 3 months
Comments 0

Login or Register to leave a comment!

The project is still on track; however, much of the work over the past month was spent researching Cardano ledger specs. There is only a single additional commit to the repository this month showing progress on the ledger implementation. We intend to close out the project by the end of the year.

Disbursed to Date
$10,000
Status
Still in progress
Completion Target
2. In the next 3 months
Comments 0

Login or Register to leave a comment!

All the talks laid out in our proposal have been completed. This month focused on the ability to generate, serialize, and sign valid cardano transactions. This capability was validated against real transactions generated by the cardano-cli in unit tests.

Disbursed to Date
$10,000
Status
Complete
Completion Target
1. In the next month
Comments 0

Login or Register to leave a comment!

close

Playlist

  • EP2: epoch_length

    Authored by: Darlington Kofa

    d. 3 se. 24
    Darlington Kofa
  • EP1: 'd' parameter

    Authored by: Darlington Kofa

    d. 4 se. 3
    Darlington Kofa
  • EP3: key_deposit

    Authored by: Darlington Kofa

    d. 3 se. 48
    Darlington Kofa
  • EP4: epoch_no

    Authored by: Darlington Kofa

    d. 2 se. 16
    Darlington Kofa
  • EP5: max_block_size

    Authored by: Darlington Kofa

    d. 3 se. 14
    Darlington Kofa
  • EP6: pool_deposit

    Authored by: Darlington Kofa

    d. 3 se. 19
    Darlington Kofa
  • EP7: max_tx_size

    Authored by: Darlington Kofa

    d. 4 se. 59
    Darlington Kofa
0:00
/
~0:00