Connect with us

Published

on

Every day this week we’re highlighting one genuine, no bullsh*t, hype free use case for AI in crypto. Today it’s the potential for using AI for smart contract auditing and cybersecurity, we’re so near and yet so far.

TurboToad
AI artwork for the ChatGPT written TurboToad memecoin. (Twitter)

One of the big use cases for AI and crypto in the future is in auditing smart contracts and identifying cybersecurity holes. There’s only one problem — at the moment, GPT-4 sucks at it.

Coinbase tried out ChatGPT’s capabilities for automated token security reviews earlier this year, and in 25% of cases, it wrongly classified high-risk tokens as low-risk.
James Edwards, the lead maintainer for cybersecurity investigator Librehash, believes OpenAI isn’t keen on having the bot used for tasks like this.

“I strongly believe that OpenAI has quietly nerfed some of the bot’s capabilities when it comes to smart contracts for the sake of not having folks rely on their bot explicitly to draw up a deployable smart contract,” he says, explaining that OpenAI likely doesn’t want to be held responsible for any vulnerabilities or exploits.

This isn’t to say AI has zero capabilities when it comes to smart contracts. AI Eye spoke with Melbourne digital artist Rhett Mankind back in May. He knew nothing at all about creating smart contracts, but through trial and error and numerous rewrites, was able to get ChatGPT to create a memecoin called Turbo that went on to hit a $100 million market cap.

But as CertiK Chief Security Officer Kang Li points out, while you might get something working with ChatGPT’s help, it’s likely to be full of logical code bugs and potential exploits:

“You write something and ChatGPT helps you build it but because of all these design flaws it may fail miserably when attackers start coming.”

So it’s definitely not good enough for solo smart contract auditing, in which a tiny mistake can see a project drained of tens of millions — though Li says it can be “a helpful tool for people doing code analysis.”

Richard Ma from blockchain security firm Quantstamp explains that a major issue at present with its ability to audit smart contracts is that GPT -4’s training data is far too general.

Also read: Real AI use cases in crypto, No. 1 — The best money for AI is crypto

“Because ChatGPT is trained on a lot of servers and there’s very little data about smart contracts, it’s better at hacking servers than smart contracts,” he explains.

So the race is on to train up models with years of data of smart contract exploits and hacks so it can learn to spot them. 

Read also


Features

North Korean crypto hacking: Separating fact from fiction


Features

An Investment in Knowledge Pays the Best Interest: The Parlous State of Financial Education

“There are newer models where you can put in your own data, and that’s partly what we’ve been doing,” he says.

“We have a really big internal database of all the different types of exploits. I started a company more than six years ago, and we’ve been tracking all the different types of hacks. And so this data is a valuable thing to be able to train AI.”

Race is on to create AI smart contract auditor

Edwards is working on a similar project and has almost finished building an open-source WizardCoder AI model that incorporates the Mando Project repository of smart contract vulnerabilities. It also uses Microsoft’s CodeBert pretrained programming languages model to help spot problems.

According to Edwards, in testing so far, the AI has been able to “audit contracts with an unprecedented amount of accuracy that far surpasses what one could expect and would receive from GPT-4.”

The bulk of the work has been in creating a custom data set of smart contract exploits that identify the vulnerability down to the lines of code responsible. The next big trick is training the model to spot patterns and similarities. 

“Ideally you want the model to be able to piece together connections between functions, variables, context etc, that maybe a human being might not draw when looking across the same data.”

While he concedes it’s not as good as a human auditor just yet, it can already do a strong first pass to speed up the auditor’s work and make it more comprehensive.

“Sort of help in the way LexisNexis helps a lawyer. Except even more effective,” he says. 

Don’t believe the hype

Illia
Near founder Illia Polushkin is an expert in both AI and blockchain.

Near co-founder Illia Polushkin explains that smart contract exploits are often bizarrely niche edge cases, that one in a billion chance that results in a smart contract behaving in unexpected ways.

But LLMs, which are based on predicting the next word, approach the problem from the opposite direction, Polushkin says.

“The current models are trying to find the most statistically possible outcome, right? And when you think of smart contracts or like protocol engineering, you need to think about all the edge cases,” he explains.

Polushkin says that his competitive programming background means that when Near was focused on AI, the team developed procedures to try to identify these rare occurrences.

“It was more formal search procedures around the output of the code. So I don’t think it’s completely impossible, and there are startups now that are really investing in working with code and the correctness of that,” he says.

But Polushkin doesn’t think AI will be as good as humans at auditing for “the next couple of years. It’s gonna take a little bit longer.”

Also read: Real AI use cases in crypto, No. 2 — AIs can run DAOs

Andrew Fenton

Andrew Fenton

Based in Melbourne, Andrew Fenton is a journalist and editor covering cryptocurrency and blockchain. He has worked as a national entertainment writer for News Corp Australia, on SA Weekend as a film journalist, and at The Melbourne Weekly.

Continue Reading

Politics

Chancellor Rachel Reeves says she is ‘totally’ up for the job of chancellor in first comments since tearful PMQs

Published

on

By

Chancellor Rachel Reeves says she is 'totally' up for the job of chancellor in first comments since tearful PMQs

The chancellor has said she was having a “tough day” yesterday in her first public comments since appearing tearful at Prime Minister’s Questions – but insisted she is “totally” up for the job.

Rachel Reeves told broadcasters: “Clearly I was upset yesterday and everyone could see that. It was a personal issue and I’m not going to go into the details of that.

“My job as chancellor at 12 o’clock on a Wednesday is to be at PMQs next to the prime minister, supporting the government, and that’s what I tried to do.

“I guess the thing that maybe is a bit different between my job and many of your viewers’ is that when I’m having a tough day it’s on the telly and most people don’t have to deal with that.”

Politics latest: PM sets out 10-year NHS plan

She declined to give a reason behind the tears, saying “it was a personal issue” and “it wouldn’t be right” to divulge it.

“People saw I was upset, but that was yesterday. Today’s a new day and I’m just cracking on with the job,” she added.

More on Rachel Reeves

Ms Reeves also said she is “totally” up for the job of chancellor, saying: “This is the job that I’ve always wanted to do. I’m proud of what I’ve delivered as chancellor.”

Pic: PA
Image:
Reeves was seen wiping away tears during PMQs. Pic: PA

Asked if she was surprised that Sir Keir Starmer did not back her more strongly during PMQs, she reiterated that she and the prime minister are a “team”, saying: “We fought the election together, we changed the Labour Party together so that we could be in the position to return to power, and over the past year, we’ve worked in lockstep together.”

PM: ‘I was last to appreciate’ that Reeves was crying

The chancellor’s comments come after the prime minister told Sky News’ political editor Beth Rigby that he “didn’t appreciate” that she was crying behind him at Prime Minister’s Questions yesterday because the weekly sessions are “pretty wild”, which is why he did not offer her any support while in the chamber.

He added: “It wasn’t just yesterday – no prime minister ever has had side conversations during PMQs. It does happen in other debates when there’s a bit more time, but in PMQs, it is bang, bang, bang. That’s what it was yesterday.

“And therefore, I was probably the last to appreciate anything else going on in the chamber, and that’s just a straightforward human explanation, common sense explanation.”

Please use Chrome browser for a more accessible video player

Starmer explains to Beth Rigby his reaction to Reeves crying in PMQs

During PMQs, Tory leader Kemi Badenoch branded the chancellor the “human shield” for the prime minister’s “incompetence” just hours after he was forced to perform a humiliating U-turn over his controversial welfare bill, leaving a “black hole” in the public finances.

The prime minister’s watered-down Universal Credit and Personal Independent Payment Bill was backed by a majority of 75 in a tense vote on Tuesday evening – but a total of 49 Labour MPs voted against the bill, which was the largest rebellion in a prime minister’s first year in office since 47 MPs voted against Tony Blair’s lone parent benefit in 1997, according to Professor Phil Cowley from Queen Mary University.

Reeves looks transformed – but this has been a disastrous week for the PM

It is a Rachel Reeves transformed that appears in front of the cameras today, nearly 24 hours since one of the most extraordinary PMQs.

Was there a hint of nervousness as she started, aware of the world watching for any signs of human emotion? Was there a touch of feeling in her face as the crowds applauded her?

People will speculate. But Ms Reeves has got through her first public appearance, and can now, she hopes, move on.

The prime minister embraced her as he walked on stage, the health secretary talked her up: “Thanks to her leadership, we have seen wages rising faster than the cost of living.”

A show of solidarity at the top of government, a prime minister and chancellor trying to get on with business.

But be in no doubt today’s speech on a 10-year-plan for the NHS has been overshadowed. Not just by a chancellor in tears, but what that image represents.

A PM who, however assured he appeared today, has marked his first year this week, as Sky News’ political editor Beth Rigby put to him, with a “self-inflicted shambles”.

She asked: “How have you got this so wrong? How can you rebuild trust? Are you just in denial?”

They are questions Starmer will be grappling with as he tries to move past a disastrous week.

Ms Reeves has borne a lot of the criticism over the handling of the vote, with some MPs believing that her strict approach to fiscal rules has meant she has approached the ballooning welfare bill from the standpoint of trying to make savings, rather than getting people into work.

Ms Badenoch also said the chancellor looked “absolutely miserable”, and questioned whether she would remain in post until the next election.

Sir Keir did not explicitly say that she will, and Ms Badenoch interjected to say: “How awful for the chancellor that he couldn’t confirm that she would stay in place.”

Downing Street scrambled to make clear to journalists that Ms Reeves was “going nowhere”, and the prime minister has since stated publicly that she will remain as chancellor “for many years to come”.

Continue Reading

Politics

Bitcoin Suisse legal chief flags gaps in EU, Swiss stablecoin rules

Published

on

By

Bitcoin Suisse legal chief flags gaps in EU, Swiss stablecoin rules

Bitcoin Suisse legal chief flags gaps in EU, Swiss stablecoin rules

Peter Märkl, general counsel at Bitcoin Suisse, criticized both EU and Swiss stablecoin regulations as inadequate and burdensome.

Continue Reading

Politics

Tether narrows USDC’s lead on BitPay payment transactions in 2025

Published

on

By

Tether narrows USDC’s lead on BitPay payment transactions in 2025

Tether narrows USDC’s lead on BitPay payment transactions in 2025

BitPay’s USDC stablecoin transactions accounted for almost double that of USDT in 2024, but the trend has shifted in favor of Tether this year.

Continue Reading

Trending