Blog > 2018 > May

Vision for blockchain in Africa is becoming a reality

Ethiopia and Rwanda keen to realise promise of the technology

29 May 2018 John O'Connor 7 mins read

Vision for blockchain in Africa is becoming a reality - Input Output

The hope of bringing the benefits of blockchain to Africa has been around even longer than IOHK itself. Founder Charles Hoskinson talked about the promise of the technology driving financial inclusion on the continent in a TEDx speech in 2014. The vision encouraged me to join the Cardano project. This month, IOHK signed an MoU with the Ethiopian government to train and hire junior software developers and use Cardano in its agriculture industry, a step towards this promise being realised. Now the real work begins, as we look to use Cardano to solve real problems in Ethiopia and beyond.

The IOHK team flew into Addis Ababa, the capital, on May 3 for Ethiopia’s first blockchain forum, which we jointly organised with the Ethiopian Ministry of Science and Technology. As Director of African Operations, my last two months in Ethiopia have been a whirlwind of interaction with government, universities and the local technology scene. It was a pleasure to have those that I’ve met join us on stage to discuss what blockchain can do for Ethiopia.

We did not arrive with solutions, but with a commitment to find them. IOHK’s Alan McSherry who leads the Cardano Enterprise team, came out to gather business requirements for permissioned applications of Cardano, as did 13 other members of the IOHK team. Seeing the ideas that emerged from the dialogue between IOHK and the ministry validated our launch in Ethiopia, and our belief in a productive and mutually beneficial relationship. This belief is enshrined in the MoU Charles signed with the Minister of Science and Technology, Dr Getahun.

MoU’s are non-binding but are taken seriously in Ethiopia, because they represent a required first step before entering into contractual obligations. In the MoU, we stated our intent to train and hire Haskell developers from a new office in Addis Ababa. The Ethiopian government stated its intent to help us to deploy Cardano in Ethiopian agriculture. This training course is the first of its kind in Africa. We expect to start in September 2018 with an inaugural class of 30 women developers. All of our trainees will leave with the ability to create blockchain applications to help drive tech-enabled growth in Ethiopia. Those who excel will be hired by IOHK and not only contribute to Cardano code, but help build the blockchain agriculture applications we are exploring in partnership with the government. With 80 million Ethiopians working in this industry, the opportunity for blockchain to make an impact is huge. Coffee is Ethiopia’s largest export, and there are many sophisticated companies along the supply chain who have a deep understanding of the product.

We are in active discussions with many such companies to develop, refine, and implement the technology. Proving the origin of coffee is one such application. I’m also excited about using smart contracts to incentivise smallholder coffee farmers to adopt more productive farming practices (I’ll be writing more about some of our projects like this in the coming weeks). Some 80% of Ethiopia’s population is under the age of 30, and GDP growth is 10% a year. With the right support from government, Ethiopia could transform into an incredibly powerful, technology-enabled economy. Ethiopia’s national animal is the lion, and if that lion has been sleeping, it is now waking up.

Community day

The day after the conference IOHK spent time with many of Ethiopia’s most promising entrepreneurs and the tech community. IOHK worked with Ethiopian accelerators ICE Addis and Bluemoon to have local startups pitch their existing startups, and how they were planning on leveraging blockchain technology. The judge was, of course, Charles.

Charles meeting entrepreneurs in Addis

This was a highlight of the trip for me. After a pitch Charles would mischievously state that he had a few questions, before delivering a grilling that would have a Harvard MBA looking for the nearest exit. The startups held up fantastically.

S­­ince I began talking to local entrepreneurs in Addis two months ago I’ve received many messages from local companies interested in learning more about the technology. The first Cardano Addis meetup was the beginning of a process of fostering understanding and adoption of the technology. The pitches showed me that these startups have not only begun looking at blockchain, but have puzzled out how it can add value to their businesses. Our colleagues in Cardano’s commercial entity Emurgo shared my view, and are in discussions about investing in a cohort of blockchain-enabled Ethiopian technology startups.

Rwanda

The next leg of the trip for the IOHK team took us to Kigali, Rwanda, where Charles was talking at the Transform Africa Summit.

Charles speaking at the Transform Africa Summit in Kigali

The summit aimed to bring together global and regional leaders from government, business and international organizations to collaborate on new ways of shaping, accelerating and sustaining Africa’s digital revolution. Blockchain was a key focus for the conference organisers, and we were honoured to have been invited and recognised for the efforts we are beginning to make in the region. Rwanda is truly a miraculous example of what can be accomplished when a country is united in its purpose and its government has embraced the principles of accountability, efficiency and openness.

The opportunity for IOHK to help enable this transformation is incredibly exciting. There are many countries where the promise of a technology that can bring transparency to government processes would be met with trepidation. It is huge credit to Rwanda that they seek to not only participate, but promote the technology’s adoption through the Transform Africa Summit.

And so on to strategy. Whilst we expect to have operations across many African countries in the future, focusing our initial efforts on Ethiopia and Rwanda will be a powerful start. Ethiopia has a government that is eager to engage in digital transformation and though early in that process, has the ability to deploy the technology across the country. The applications we are discussing could benefit tens of millions of people. Rwanda on the other hand has a population a tenth the size of Ethiopia. However they are leading Africa in their commitment to support innovative technologies. Ideas can be tried and tested. If they fail, lessons will be learnt and the next attempt will be better. This principle is the central driver of innovation, and Rwanda has embraced it.

Charles and John with Dr Getahun, Minister of Science and Technology

After a whirlwind few weeks I’d like to thank everyone who has allowed us to reach this point. I thank ICE Addis, Bluemoon capital, as well as Impact hub in Kigali for hosting events with us and connecting me with the local entrepreneurship. I thank the IOHK and Emurgo teams who flew out to be on the ground and help us establish our work. But most importantly, I’d like to thank Yodahe Zemichael from the Science Technology and Information Centre and Dr Getahun Mekuria, Minister of Science and Technology. You have been more agile, proactive, and enthusiastic partners than we could have hoped for. We look forward to working with you.

First Cardano smart contracts testnet launches

KEVM software supports applications that run on Ethereum Virtual Machine

28 May 2018 Gerard Moroney 3 mins read

The first Cardano smart contracts testnet launches today, the KEVM testnet, a correct by construction version of the Ethereum Virtual Machine (EVM) specified in the K framework. This technology, produced by Runtime Verification with the support of IOHK, is the first time that a complete formal semantics of the EVM have been produced. This is an important first in cryptocurrency that is a necessary step towards the promise of third-generation blockchains. A smart contract allows you to exchange something of value - money, property, shares - by means of a software protocol. The terms of exchange are agreed upon by the parties involved in the same way as a traditional contract, and the contract is executed automatically on the blockchain.

Developers will be able to take any application that runs on the EVM and execute it on the KEVM, which can also be used to rigorously prove that smart contracts work correctly. This is done by formally specifying a contract's desired properties in K, combining the contract with the KEVM specification, and then using the K framework to verify those properties.

Our second Cardano testnet to launch will be IELE, which is a new virtual machine for Cardano. IELE will be launched in July and is a register-based virtual machine similar to LLVM with an unbounded number of registers, that supports unbounded integers. With IELE, developers can write, compile and execute smart contracts, with improved security and performance compared to the KEVM testnet.

For now, we recommend that developers use the Solidity language on both testnets. However, the vision is that eventually smart contracts will be written in high-level languages that translate to IELE, such as new languages like Plutus (being developed by IOHK), but also existing languages such as Java or Python, and then IELE-to-IELE translators ensure the resulting code is optimal.

Cardano Testnets Website Cardano Testnets Website

K was developed by Runtime Verification in collaboration with Professor Grigore Rosu's Formal Systems Laboratory at the University of Illinois at Urbana-Champaign during the past 15 years, and incorporates the state of the art in language design, semantics and formal methods. Read more about the K framework in this blog from Prof Rosu, founder of Runtime Verification. A blog about formal verification and what this means for smart contracts will follow soon.

Smart contracts must be formally verified, so they run exactly as specified and are free from bugs or flaws. Only then can they be widely adopted as financial infrastructure that can be relied upon by billions of people.

We look forward to receiving your valuable feedback about using the testnets which will help us make Cardano best in class.

Ouroboros Praos presented at leading cryptography conference, Eurocrypt

Proof-of-stake protocol offers same security guarantees as Bitcoin

17 May 2018 Jane Wild 4 mins read

In the area of blockchain research proof of stake has long posed many questions for cryptographers and the subject has been of primary importance for IOHK researchers over the past two years. Professor Aggelos Kiayias, Chief Scientist at IOHK, has led work with a team of cryptographers to formalise a family of protocols called Ouroboros. It is a great distinction for their efforts that their paper describing the protocol was accepted to Crypto 2017, the foremost cryptographic event, and another paper was heard this month at sister event Eurocrypt. Eurocrypt is the flagship European conference of the main international community of cryptographers, the International Association for Cryptologic Research. About 370 delegates from countries worldwide arrived in Tel Aviv, Israel, to hear cutting edge research being presented from across the spectrum of cryptography. In all, there were about 70 presentations across four days.

This year, blockchain was more prominent than it had ever been at Eurocrypt. There were four papers presented during a dedicated blockchain morning session on the second day. The following day there was a talk on the 30-year history of cryptocurrencies, given by Matthew Green, a cryptographer at Johns Hopkins Information Security Institute. Three best papers were selected for an award at Eurocrypt, and one of them was on blockchain, Simple Proofs of Sequential Work by Bram Cohen and Krzysztof Pietrzak.

Academic interest in the area has nowhere near matched the rapid proliferation of blockchain projects during the past few years, and the increased focus of cryptographers at events like Eurocrypt brings a welcome professionalisation to the industry.

To be heard at the conference, papers must be submitted for consideration in a process called peer review. This notoriously tough sifting process can typically involve three or four people reviewing the paper, and it passing a programme committee of three dozen or more people, to ensure it makes a novel contribution to the scientific literature that advances computer science. Most papers are rejected. A double-blind admission procedure where both authors and reviewers are anonymous adds objectivity.

The novel feature of Ouroboros Praos is that it is the first proof-of-stake blockchain to be able to scale for widespread use and provide security against adaptive attackers. These are attackers that can instantly corrupt protocol participants, and the only restriction is that only a minority of the total stake can be in corrupted hands. A Distributed Denial of Service (DDoS) attack is a real-world example of such an instant attack.

Ouroboros Praos offers the same security guarantees as Bitcoin in that it can withstand attacks from stronger adversaries in harsh network conditions, such as where an attacker has some control over network delays affecting messages sent by all participants.

No other proof-of-stake protocol that has been peer reviewed at this level can provably offer this level of security guarantee under these conditions.

Peter Gaži, who presented: “Eurocrypt is one of the premier venues for presenting cryptoglogic research and it’s an honour for us to present our work here. The fact that we were invited serves as evidence the broader academic community is showing more interest in this topic.”

Aside from Peter and Aggelos, the other researchers on the Ouroboros team are Bernardo David, Alexander Russell, Roman Oliynykov, Christian Badertscher, and Vassilis Zikas. The previous Ouroboros paper, first in this line of research, is the first proof-of-stake protocol to be provably secure and peer reviewed at a leading cryptographic event. Ouroboros has a real-world implementation in Cardano, the top 10 cryptocurrency built by IOHK.

A Cardano technical talk in Hamburg

Philipp Kant and Lars Brünjes explain incentives, stake pools and formal methods

14 May 2018 Jane Wild 8 mins read

Cardano is a project that is unique in its vision, scope and design, and its world-class team is working at the frontier of computer science. As development progresses we're contacted on a daily basis by people from all around the world who want to learn more, and so IOHK was pleased to make its first trip to Germany recently to talk about Cardano. Dr Lars Brünjes and Dr Philipp Kant are senior members of the Cardano team and they were invited to the monthly Hamburg meetup Blockchain Mania last month to give a technical talk. Lars is Director of Education at IOHK and leads work on incentives, a key part of Cardano, while Philipp is Director of Formal Methods, the robust development approach that is the gold standard for IOHK development.

In the year since this Hamburg meetup launched its audience numbers have blossomed from 20 to well over 100 under the direction of founders Omri Erez, an android developer by background who now has a blockchain startup, and Kiriakos Krastillis, who is Head of Software Engineering at PwC Digispace in Hamburg. The crowd was keen and knowledgeable, including entrepreneurs and developers (and some Haskellers). They wanted a deep dive into technical aspects of Cardano, with a Q&A after each presentation.

Philipp took the audience through an introduction to Cardano, highlighting a few of the key features in development. Plutus and the IELE Virtual Machine are essential components of smart contracts, while sidechains will help the system scale. A treasury will secure future development by giving users a mechanism to decide upon and pay for changes. At the heart of Cardano is Ouroboros, the algorithm that underpins the Ada cryptocurrency. Developed by a team of researchers led by Professor Aggelos Kiayias of the University of Edinburgh, Ouroboros is the first proof-of-stake algorithm to be provably secure and was accepted to the leading cryptography conference, Crypto 2017. It is an efficient alternative to the energy-intensive proof-of-work protocol that underpins Bitcoin.

Producing excellent research is the first objective. The next is to take that cryptographic research, which is expressed in academic language, mathematical formulae and proofs, and turn it into another language – Haskell code that a computer can understand. Additionally, the research papers will not account for factors that arise during real-world operation, issues relating to databases or networking for example.

Turning the papers into machine-executable code is a lengthy and precise process, and one it is highly desirable to conduct carefully. IOHK is adopting formal methods in its development process to create software that is robust and reliable. This is an approach used in areas such as medicine and aerospace, where improperly implemented code could result in casualties. In the area of cryptocurrency, we've repeatedly seen flaws in code exploited and losses in the hundreds of millions of dollars.

The process of moving from paper to code is done in a series of small steps, rather than any big leap, Philipp explained.

The first step is transcribing the paper into an executable specification, and further steps refine this specification, adding all the necessary details.

Attention is paid to each design decision, and each step can be tested to make sure the code is correct. IOHK does this by using psi calculus. This is a family of process calculi that is a toolbox we are using to formulate Ouroboros Praos. We can embed psi calculus into Haskell, which allows us to run simulations and export code to a proof assistant such as Coq or Isabelle so proofs can be checked.

It is important that we have a good handle on the performance of the system. Before the launch of Cardano, Philipp oversaw benchmarking, tuning the parameters of the system to ensure it could perform well under various conditions. While this process is helpful to ensure the system is set up in a way that ensures stable operation, it is preferable to have a method for predicting the performance early on.

To achieve this, we use the Delta Q formalism, where each atomic operation carries is assigned a probability distribution for delay and failure. Those can be combined, either through simulation, or algebraically, to determine the expected overall performance of the system. Adding Delta Q annotations to the executable specification right at the start of the development process will show performance impacts of design decisions, and also provide a baseline for the benchmarks: instead of just measuring the performance, and trying optimisations to improve it, we can compare the results of benchmarks against a prediction, and tell whether we have a performance bug. If we additionally measure the Delta Q of individual parts of the program, we can even see which parts behave unexpectedly and should be optimised.

Lars and Philipp after the presentation Philipp Kant (left) and Lars Brünjes (right) at the Hamburg event

Incentives are core to the design of Cardano and the related topic of staking has been one of the most keenly discussed among the community. Lars is leading work on Incentives, and the team includes Professor Aggelos Kiayias and Professor Elias Koutsoupias, at Edinburgh and Oxford universities respectively. Lars explained how well-designed incentives shepherd users through the system and encourage them to make choices that are not only in their best interests but lead to the smooth operation of the cryptocurrency as a whole.

In Cardano it is important that stake holders are online so they can be part of the election for who gets to create the next block in the blockchain, and to create that block if they win. The incentive for taking part in Cardano is Ada, as a reward for being part of the process and creating a block. By comparison, in Bitcoin's proof-of-work system, stakeholders compete to solve cryptographic puzzles, with one winner taking a reward for creating a block. However, in Cardano, users may not have the time to be online or take part in the election process, so they can delegate their stake to others who can do it for them. Those who do take part then pay a share of the reward back to the users who did not participate. Simply holding Ada gives you stake, and if you delegate your stake, you still retain the monetary value of Ada and can spend it as you wish.

Lars Brünjes presenting on delegation in Cardano
Lars Brünjes on incentives in Cardano

Lars explained that about 80% of stake should be delegated to stake pools, that optimally number about 100. Stake pools must be online, and provide infrastructure for the network in the form of relay nodes. The leftover 20% of stake would belong to small stakeholders who either participate on their own or decide not to.

There are three types of address in staking, each associated with two cryptographic key pairs: one for payment, one for staking. A base address has a staking key linked directly to it; a pointer address links to a delegation certificate on the blockchain, and an enterprise address is for exchanges, who may not use the funds entrusted to them to stake.

Delegation of staking rights from one staking key to another is done by means of a delegation certificate, which can be published on the blockchain as part of the metadata of a transaction, in which case a pointer address can refer to it. Such a published certificate is called a heavyweight. In case of conflicting certificates, later in the blockchain wins. The fees for creating a heavyweight delegation certificate are the transaction fees for the contained transaction. A lightweight certificate is not published on the blockchain, but instead included in block headers to prove staking rights for the address that was elected slot leader. It also contains a "serial number" to break ties.

To set up a stake pool a registration certificate is created and embedded in a transaction that pays the pool registration fees to a special address. The certificate contains the staking key of the pool leader. People wishing to delegate to the pool must create (heavyweight) delegation certificates delegating their stake to that key. And using combinations of base and pointer addresses and "chains" of delegation certificates, a large number of scenarios can be covered, including: regular user wallets; offline user wallets with cold staking; wallets with enhanced privacy; staking pool wallets, and enterprise wallets for exchanges.

Transaction fees are an important part of Cardano's incentive scheme. When Ada is sent, a small fee is paid for the transition, to validate it. These fees help prevent Distributed Denial of Service (DDoS) attacks by imposing a financial barrier for any adversary intending to flood the network with spam transactions. The fees also provide funds for Cardano's incentives.

Incentives are distributed each epoch, the operation of Cardano's Ouroboros algorithm being divided into epochs that each last five days. Transaction fees are collected for the blocks created during each epoch, pooled along with Ada from monetary expansion, and the total is distributed to stakeholders, according to the stake they own.

For more details on incentives, transaction fees and staking, Lars' presentation is available in full: Incentives in Cardano.

Follow IOHK online for more details of progress on Cardano development, and watch out for a forthcoming video from the first Cardano developer meetup in London.