Connect with us

Blockchain

Beware the impossible smart contract

The three most common smart contract misconceptions As the developers of a popular blockchain platform, we sometimes get asked whether Ethereum-like smart contracts are on the MultiChain roadmap. The answer I always give is: no, or at least not yet. But in the hype-filled world of blockchains, smart contracts are all the rage, so why… Read more »

Republished by Plato

Published

on

The three most common smart contract misconceptions

As the developers of a popular blockchain platform, we sometimes get asked whether Ethereum-like smart contracts are on the MultiChain roadmap. The answer I always give is: no, or at least not yet.

But in the hype-filled world of blockchains, smart contracts are all the rage, so why ever not? Well, the problem is, while we now know of three strong use cases for permissioned Bitcoin-style blockchains (provenance, inter-company records and lightweight finance), we’re yet to find the equivalent for Ethereum-style smart contracts.

It’s not that people lack ideas of what they want smart contracts to do. Rather, it’s that so many of these ideas are simply impossible. You see, when smart people hear the term “smart contracts”, their imaginations tend to run wild. They conjure up dreams of autonomous intelligent software, going off into the world, taking its data along for the ride.

Unfortunately the reality of smart contracts is far more mundane than all that:

A smart contract is a piece of code which is stored on an blockchain, triggered by blockchain transactions, and which reads and writes data in that blockchain’s database.

That’s it. Really. A smart contract is just a fancy name for code which runs on a blockchain, and interacts with that blockchain’s state. And what is code? It’s Pascal, it’s Python, it’s PHP. It’s Java, it’s Fortran, it’s C++. If we’re talking databases, it’s stored procedures written in an extension of SQL. All of these languages are fundamentally equivalent, solving the same sorts of problems in the same sorts of ways. Of course, each has its strengths and weaknesses – you’d be crazy to build a website in C or compress HD video in Ruby. But in principle at least, you could if you wanted to. You’d just pay a heavy price in terms of convenience, performance, and quite probably your hair.

The problem with smart contracts isn’t just that people’s expectations are overblown. It’s that these expectations are leading many to spend time and money on ideas that cannot possibly be implemented. It seems large companies have sufficient resources to travel a lengthy path – from the moment when senior management encounters a new technology, to when that technology’s advantages and limitations are truly understood. Perhaps our own experience can help shorten this time.

Over the past nine months, we’ve been pitched many smart contract use cases, and have found ourselves responding, time and again, that they simply cannot be done. As a result, we’ve identified the three smart contract misconceptions that are most commonly held. These ideas aren’t wrong because the technology is immature, or the tools are not yet available. Rather, they misunderstand the fundamental properties of code which lives in a database and runs in a decentralized way.

Contacting external services

Often, the first use case proposed is a smart contract which changes its behavior in response to some external event. For example, an agricultural insurance policy which pays out conditionally based on the quantity of rainfall in a given month. The imagined process goes something like this: the smart contract waits until the predetermined time, retrieves the weather report from an external service, and behaves appropriately based on the data received.

This all sounds simple enough, but it’s also impossible. Why? Because a blockchain is a consensus-based system, meaning that it only works if every node reaches an identical state after processing every transaction and block. Everything that takes place on a blockchain must be completely deterministic, with no possible way for differences to creep in. The moment that two honest nodes disagree about the chain’s state, the entire system becomes worthless.

Now recall that smart contracts are executed independently by every node on a chain. Therefore, if a smart contract retrieves some information from an external source, this retrieval is performed repeatedly and separately by each node. But because this source is outside of the blockchain, there is no guarantee that every node will receive the same answer. Perhaps the source will change its response in the time between requests from different nodes, or perhaps it will become temporarily unavailable. Either way, consensus is broken and the entire blockchain dies.

So what’s the workaround? Actually, it’s rather simple. Instead of a smart contract initiating the retrieval of external data, one or more trusted parties (“oracles”) creates a transaction which embeds that data in the chain. Every node will have an identical copy of this data, so it can be safely used in a smart contract computation. In other words, an oracle pushes the data onto the blockchain rather than a smart contract pulling it in.

When it comes to smart contracts causing events in the outside world, a similar problem appears. For example, many like the idea of a smart contract which calls a bank’s API in order to transfer money. But if every node is independently executing the code in the chain, who is responsible for calling this API? If the answer is just one node, what happens if that particular node malfunctions, deliberately or not? And if the answer is every node, can we trust every node with that API’s password? And do we really want the API called hundreds of times? Even worse, if the smart contract needs to know whether the API call was successful, we’re right back to the problem of depending on external data.

As before, a simple workaround is available. Instead of the smart contract calling an external API, we use a trusted service which monitors the blockchain’s state and performs certain actions in response. For example, a bank could proactively watch a blockchain, and perform money transfers which mirror the on-chain transactions. This presents no risk to the blockchain’s consensus because the chain plays an entirely passive role.

Looking at these two workarounds, we can make some observations. First, they both require a trusted entity to manage the interactions between the blockchain and the outside world. While this is technically possible, it undermines the goal of a decentralized system. Second, the mechanisms used in these workarounds are straightforward examples of reading and writing a database. An oracle which provides external information is simply writing that information into the chain. And a service which mirrors the blockchain’s state in the real world is doing nothing more than reading from that chain. In other words, any interaction between a blockchain and the outside world is restricted to regular database operations. We’ll talk more about this fact later on.

Enforcing on-chain payments

Here’s another proposal that we tend to hear a lot: using a smart contract to automate the payment of coupons for a so-called “smart bond”. The idea is for the smart contract code to automatically initiate the payments at the appropriate times, avoiding manual processes and guaranteeing that the issuer cannot default.

Of course, in order for this to work, the funds used to make the payments must live inside the blockchain as well, otherwise a smart contract could not possibly guarantee their payment. Now recall that a blockchain is just a database, in this case a financial ledger containing the issued bond and some cash. So when we talk about coupon payments, what we’re actually talking about are database operations which take place automatically at an agreed time.

While this automation is technically feasible, it suffers from a financial difficulty. If the funds used for coupon payments are controlled by the bond’s smart contract, then those payments can indeed be guaranteed. But this also means those funds cannot be used by the bond issuer for anything else. And if those funds aren’t under the control of the smart contract, then there is no way in which payment can be guaranteed.

In other words, a smart bond is either pointless for the issuer, or pointless for the investor. And if you think about it, this is a completely obvious outcome. From an investor’s perspective, the whole point of a bond is its attractive rate of return, at the cost of some risk of default. And for the issuer, a bond’s purpose is to raise funds for a productive but somewhat risky activity, such as building a new factory. There is no way for the bond issuer to make use of the funds raised, while simultaneously guaranteeing that the investor will be repaid. It should not come as a surprise that the connection between risk and return is not a problem that blockchains can solve.

Hiding confidential data

As I’ve written about previously, the biggest challenge in deploying blockchains is the radical transparency which they provide. For example, if ten banks set up a blockchain together, and two conduct a bilateral transaction, this will be immediately visible to the other eight. While there are various strategies for mitigating this problem, none beat the simplicity and efficiency of a centralized database, in which a trusted administrator has full control over who can see what.

Some people think that smart contracts can solve this problem. They start with the fact that each smart contract contains its own miniature database, over which it has full control. All read and write operations on this database are mediated by the contract’s code, making it impossible for one contract to read another’s data directly. (This tight coupling between data and code is called encapsulation, and is the foundation of the popular object-oriented programming paradigm.)

So if one smart contract can’t access another’s data, have we solved the problem of blockchain confidentiality? Does it make sense to talk of hiding information in a smart contract? Unfortunately, the answer is no. Because even if one smart contract can’t read another’s data, that data is still stored on every single node in the chain. For each blockchain participant, it’s in the memory or disk of a system which that participant completely controls. And there’s nothing to stop them reading the information from their own system, if and when they choose to do so.

Hiding data in a smart contract is about as secure as hiding it in the HTML code of a web page. Sure, regular web users won’t see it, because it’s not displayed in their browser window. But all it takes is for a web browser to add a ‘View Source’ function (as they all have), and the hidden information becomes universally visible. Similarly, for data hidden in smart contracts, all it takes is for someone to modify their blockchain software to display the contract’s full state, and all semblance of secrecy is lost. A half-decent programmer could do that in an hour or so.

What smart contracts are for

With so many things that smart contracts cannot do, one might ask what they’re actually for. But in order to answer this question, we need to go back to the fundamentals of blockchains themselves. To recap, a blockchain enables a database to be directly and safely shared by entities who do not trust each other, without requiring a central administrator. Blockchains enable data disintermediation, and this can lead to significant savings in complexity and cost.

Any database is modified via “transactions”, which contain a set of changes to that database which must succeed or fail as a whole. For example, in a financial ledger, a payment from Alice to Bob is represented by a transaction that (a) checks if Alice has sufficient funds, (b) deducts a quantity from Alice’s account, and (c) adds the same quantity to Bob’s.

In a regular centralized database, these transactions are created by a single trusted authority. By contrast, in a blockchain-driven shared database, transactions can be created by any of that blockchain’s users. And since these users do not fully trust each other, the database has to contain rules which restrict the transactions performed. For example, in a peer-to-peer financial ledger, each transaction must preserve the total quantity of funds, otherwise participants could freely give themselves as much money as they liked.

One can imagine various ways of expressing these rules, but for now there are two dominant paradigms, inspired by Bitcoin and Ethereum respectively. The Bitcoin method, which we might call “transaction constraints”, evaluates each transaction in terms of: (a) the database entries deleted by that transaction, and (b) the entries created. In a financial ledger, the rule states that the total quantity of funds in the deleted entries has to match the total in those created. (We consider the modification of an existing entry to be equivalent to deleting that entry and creating a new one in its place.)

The second paradigm, which comes from Ethereum, is smart contracts. This states that all modifications to a contract’s data must be performed by its code. (In the context of traditional databases, we can think of this as an enforced stored procedure.) To modify a contract’s data, blockchain users send requests to its code, which determines whether and how to fulfill those requests. As in this example, the smart contract for a financial ledger performs the same three tasks as the administrator of a centralized database: checking for sufficient funds, deducting from one account, and adding to another.

Both of these paradigms are effective, and each has its advantages and disadvantages, as I’ve discussed in depth previously. To summarize, Bitcoin-style transaction constraints provide superior concurrency and performance, while Ethereum-style smart contracts offer greater flexibility. So to return to the question of what smart contracts are for:

Smart contracts are for blockchain use cases which can’t be implemented with transaction constraints.

Given this criterion for using smart contracts, I’m yet to see a strong use case for permissioned blockchains which qualifies. All the compelling blockchain applications I know can be implemented with Bitcoin-style transactions, which can handle permissioning and general data storage, as well as asset creation, transfer, escrow, exchange and destruction. Nonetheless, new use cases are still appearing, and I wouldn’t be surprised if some do require the power of smart contracts. Or, at the very least, an extension of the Bitcoin paradigm.

Whatever the answer turns out to be, the key to remember is that smart contracts are simply one method for restricting the transactions performed in a database. This is undoubtedly a useful thing, and is essential to making that database safe for sharing. But smart contracts cannot do anything else, and they certainly cannot escape the boundaries of the database in which they reside.

Please post any comments at LinkedIn.

Source: https://www.multichain.com/blog/2016/04/beware-impossible-smart-contract/

Blockchain

DeFi summer 2.0? ‘Gen 2’ tokens on a tear amid wider market slump

Republished by Plato

Published

on

As some brand-name decentralized finance (DeFi) tokens sputter, a crop of new projects have emerged that are catching strong bids on the back of aggressive yield farming programs, generous airdrops, and significant technical advances. 

It’s a set of outlier projects pushing forward on both price and fundamentals that has led one crypto analyst, eGirl Capital’s mewny, to brand them as DeFi’s “Gen 2.”

Mewny, who in an interview with Cointelegraph pitched eGirl Capital as “an org that takes itself as a very serious joke,” says that Gen 2 tokens have garnered attention due to their well-cultivated communities and clever token distribution models — both of which lead to a “recursive” price-and-sentiment loop. 

“I think in terms of market interest it’s more about seeking novelty and narrative at this stage in the cycle. Fundamental analysis will be more important when the market cools off and utility is the only backstop to valuations. Hot narratives tend to trend around grassroots projects that have carved out a category for themselves in the market,” they said.

While investors might be eager to ape into these fast-rising new tokens, it’s worth asking what the projects are doing, whether they’re sustainable, and if not how much farther they have to run.

Pumpamentals or fundamentals?

The Gen 2 phenomena echoes the “DeFi summer” of last year, filled with “DeFi stimulus check” airdrops, fat farming APYs, and soaring token prices — as well as a harrowing spate of hacks, heists, and rugpulls

However, mewny says that there’s a population of investors that emerged from that period continuously looking for technical progress as opposed to shooting stars. 

“There are less quick “me too” projects in defi. An investor may think that those projects never attracted much liquidity in the first place but they overestimate the wisdom of the market if that’s the case. They did and do pull liquidity, especially from participants who felt priced out or late to the first movers.This has given the floor to legitimate projects that have not stopped building despite the market’s shift in focus. ”

One such Gen 2 riser pulling liquidity is Inverse Finance. After the launch of a yield farming program for a forthcoming synthetic stablecoin protocol, the Inverse Finance DAO narrowly voted to make the INV governance token tradable. As a result, the formerly valueless token airdrop of 80 INV is now priced at over $100,000, likely the most lucrative airdrop in Defi history. 

Another Gen 2 star is Alchemix — one of eGirl Capital’s first announced investments. Alchemix’s protocol also centers on a synthetic stablecoin, alUSD, but generates the stablecoin via collateral deposited into Yearn.Finance’s yield-bearing vaults. The result is a token-based stablecoin loan that pays for itself — a new model that eGirl thinks could become a standard.

“eGirl thinks trading yield-bearing interest will be an important primitive in DeFi. Quantifying and valuing future yield unlocks a lot of usable value that can be reinvested in the market,” they said.

The wider markets appears to agree with eGirl’s thesis, as Alchemix recently announced that the protocol has eclipsed half a billion in total value locked:

Staying power?

By contrast, governance tokens for many of the top names in DeFi, such as Aave and Yearn.Finance, are in the red on a 30-day basis. But even with flagship names stalling out, DeFi’s closely-watched aggregate TVL figure is up on the month, rising over $8.4 billion to $56.8 billion per DeFi Llama — progress carried in part on the back of Gen 2 projects. 

The comparatively wrinkled, desiccated dinosaurs of DeFi may have some signs of life left in them, however. Multiple major projects have significant updates in the works, including Uniswap’s version 3, Sushiswap’s Bentobox lending platform, a liquidity mining proposal working through Aave’s governance process, and Balancer’s version 2.

These developments could mean that DeFi’s “Gen 2” phenomena is simply a temporary, intra-sector rotation, and that the “majors” are soon to roar back. It would be a predictable move in mewny’s view, who says “every defi protocol needs at least 1 bear market to prove technical soundness.”

What’s more, according to mewny some of the signs of market irrationality around both Gen 2 tokens as well as the wider DeFi space — such as triple and even quadruple-digit farming yields — may be gone sooner rather than later.

“I don’t think it’s sustainable for any project in regular market conditions. We are not in regular conditions at the moment. Speculators have propped up potentially unsustainable DeFi protocols for a while now.”

Checkout PrimeXBT
Trade with the Official CFD Partners of AC Milan
The Easiest Way to Way To Trade Crypto.
Check out Nord
Make your Money Grow with Mintos
Source: https://cointelegraph.com/news/defi-summer-2-0-gen-2-tokens-on-a-tear-amid-wider-market-slump

Continue Reading

Blockchain

Fetch.ai (FET) hits a 2-year high after DeFi integration and Bosch partnership

Republished by Plato

Published

on

Artificial intelligence and machine learning are changing the face of commerce, computing and other technologies on a daily basis.

In its most basic form, the information gathered by artificial intelligence is really just data that can be used to make interpretations and blockchains are built for the storage and transmission of data.

Fetch.ai (FET) is a “Cambridge-based artificial intelligence lab” that has the goal of using distributed ledger technology to build a decentralized machine learning platform capable of securely transacting any form of data globally.

FET/USDT 4-hour chart. Source: TradingView

Data from Cointelegraph Markets and TradingView shows that the price of FET has surged 720% since the start of 2021 and this week the altcoin hit a new yearly high at $0.40.

Partnership announcements and DeFi integrations drive adoption

A scroll through the project’s Twitter feed shows that excitement began building at the end of January when Fetch.ai started tweeting about its Mettalex (MTLX) project, which is a decentralized exchange (DEX) for the Fetch.ai ecosystem that specializes in bringing “autonomous and intelligent oracles” to DeFi.

Given that DeFi is another rapidly emerging sector, FET’s inclusion in it was followed by a notable increase in trading volume.

As part of the Mettalex launch, FET tokenholders were given the option to stake their tokens on the platform for 3 months and earn a 10% yield which will be paid in MTLX tokens.

Momentum for the project continued to build throughout February following several high-profile partnerships, most notably a deal with Bosch Group to help the platform launch a multi-purpose blockchain project designed to enable Web 3.0.

While the blockchain project has been in a testnet since October 2020, the upcoming mid-March release appears to be on track based on the following tweet from the Fetch.ai team:

The follow-up release of the project’s first native application in the App store indicates that the expansion of the Fetch.ai ecosystem is just beginning, and record transaction and trading volumes signal that there is growing interest in the AI-focused protocol.

The views and opinions expressed here are solely those of the author and do not necessarily reflect the views of Cointelegraph.com. Every investment and trading move involves risk, you should conduct your own research when making a decision.

Checkout PrimeXBT
Trade with the Official CFD Partners of AC Milan
The Easiest Way to Way To Trade Crypto.
Check out Nord
Make your Money Grow with Mintos
Source: https://cointelegraph.com/news/fetch-ai-fet-hits-a-2-year-high-after-defi-integration-and-bosch-partnership

Continue Reading

Blockchain

What Ethereum killer? On-chain data shows competitor networks are still behind

Republished by Plato

Published

on

Ether (ETH) remains the second-largest cryptocurrency and it absolutely dominates the smart contract industry according to an array of network usage metrics. Even though the network has been overwhelmed by peak activity which is causing median fees to surpass $10, the network effect of its large user and developer base seems to be enough to sustain its position as the second ranked cryptocurrency by market capitalization.

Nevertheless, some key on-chain metrics are beginning to show a potential change in Etheruem’s supremacy, which raises the age old question of whether an “Ethereum killer” will be able to dethrone the top network?

Smart contracts Total Value Locked (TVL) ranking. Source: defillama.com

As shown above, the Ethereum network vastly dominates decentralized applications (dApps). Due to its high gas fees for transactions, when analyzing the number of active addresses, the Ethereum newtork appears to be at a disadvantage to its competitors.

Over the past week, FLOW blockchain’s NBA Top Shot had almost 80,000 active addresses which is five times larger than Ethereum’s Rarible NFT marketplace or even SushiSwap. Thus, the first data to analyze is the daily active addresses number across each blockchain.

Daily active addresses. Source: coinmetrics.io

The chart above shows that Tron (TRX) has recently surpassed Ethereum in daily active addresses, although this metric can be easily inflated. The Tron network has virtually zero fees for simple transactions which creates an unfair comparison.

By measuring effective transactions and transfers,it’s easier to exclude the addresses that are not contributing to the network.

Transactions and transfers, adjusted, USD. Source: coinmetrics.io

By doing this we can see that Tron doesn’t come even close to Ethereum’s numbers, although Cardano’s (ADA) recent price growth has led to a virtual tie between the two.

Oddly enough, the Tron network holds over 14.5 billion of the Tether (USDT) in circulation, which by itself should boost network usage metrics. Meanwhile, Cardano has 90% fewer daily active addresses than Ethereum, yet, both networks handle the same amount of transfers and transactions.

This is especially problematic as Ethereum handles 20 billion Tether tokens and also manages all the transactions of Chainlink (LINK), USD Coin (USDC), Wrapped ETH (WETH), and many others.

ETH, ADA, NEM, NEO, TRX market cap, USD million. Source: cointrader.pro

This data should, at least theoretically, be reflected in the market capitalization. Thus, it makes sense for Ethereum to dominate the ranking as no other network is even close to its decentralized applications.

Moreover, when analyzing the transfer and transactions’ value, Ethereum leads by 50 times if we exclude Cardano’s questionable figures discussed earlier.

For the time being, the data suggest that the four “Ethereum killers” analyzed above are unlikely to “flippen” the Ethereum network anytime soon.

The views and opinions expressed here are solely those of the author and do not necessarily reflect the views of Cointelegraph. Every investment and trading move involves risk. You should conduct your own research when making a decision.

Checkout PrimeXBT
Trade with the Official CFD Partners of AC Milan
The Easiest Way to Way To Trade Crypto.
Check out Nord
Make your Money Grow with Mintos
Source: https://cointelegraph.com/news/what-ethereum-killer-on-chain-data-shows-competitor-networks-are-still-behind

Continue Reading
Blockchain4 days ago

Amplifying Her Voice

Blockchain4 days ago

Bitcoin Halving: Definitive Guide (In Just 5 Minutes)

Blockchain4 days ago

Blockchain in Sports Betting

Blockchain2 days ago

How to Protect Yourself from the Cryptojacking Threat

Blockchain4 days ago

Libra Coin – A New Digital Currency Developed by FACEBOOK

Blockchain4 days ago

DeFi token CRV spikes after reports PayPal acquired unrelated custody firm Curv

Blockchain3 days ago

Will Netflix soon buy bitcoin?

Blockchain2 days ago

BitGo To Introduce Crypto Custodial Services To New York Clients

Blockchain2 days ago

Experts divided on BTC predictions: Bullish or super bullish?

Blockchain4 days ago

DEX aggregator 1inch integrates Bitquery’s API-powered crypto trading data

Blockchain2 days ago

Bitcoin “Cheat Sheet” Calls For Next Leg Up To $77K

Blockchain2 days ago

Analyst tells Tesla to dump Bitcoin for buybacks as shares plunge alongside MSTR’s

Blockchain2 days ago

Mark Cuban’s Dallas Mavericks to Accept Dogecoin Payments

Blockchain2 days ago

Ethereum gas fees drop as daily DEX and DeFi volumes decline

Blockchain3 days ago

3 key Ethereum price metrics show pro traders are aiming for $2K ETH

Blockchain2 days ago

Thailand’s largest movie theater chain accepts Bitcoin

Blockchain2 days ago

TA: Bitcoin Price Back Below 100 SMA, Why BTC Could Retest $45K

Blockchain2 days ago

Decentralized Companies Are the New Norm and It’s the DAO Revolution That’s Making It Possible

Blockchain2 days ago

XRP Price Analysis: 04 March

Blockchain2 days ago

Blockchain Association meeting with key Biden staff about regulations

Trending