Cointime

Download App
iOS & Android

zkSync Assists Gemholic with Smart Contract Issue, Ensures Safe Funds and Unfreezes Contract

Cointime Official

zkSync has given support to Gemholic, a multi-product platform that faced an issue with their smart contract on zkSync Era. 

Gemholic deployed their token contract and conducted a pre-sale launch on zkSync Era, but faced a problem due to the usage of the .transfer() function. The contracts were deployed on Era mainnet without prior testing on a testnet or local node, which could have identified the issue earlier.

"Funds are safe. We found an elegant solution how to unfreeze the contract.", zkSync stated in a tweet. The team said a solution to unfreeze the contract has been found, which will entail minimal changes to gas metering in the protocol but will allow for complete fund recovery. 

Smart contracts using transfer() or send() rely heavily on gas costs, as these functions forward a hardcoded amount of 2300 gas. However, this isn't guaranteed to work on Ethereum, since the fallback() function can consume more than 2300 gas, and opcode gas pricing may change in future Ethereum versions.

zkSync also highlights that zkSync Era is not EVM equivalent. zkSync Era's deliberate design choice to diverge from EVM equivalence results in dynamic gas metering, allowing some transactions to be 10x to 1000x cheaper than on other EVM rollups.

Read full thread:

@GemholicECO is a multi-product platform that recently deployed their token contract and performed a pre-sale launch on zkSync Era. After deployment they encountered an issue with their contract due to the usage of the .transfer() function.

Unfortunately, the contracts were deployed on Era mainnet without having been tried on the testnet or local node, which would have immediately caught the problem.

Any smart contract that uses transfer() or send() is taking a hard dependency on gas costs, because this functions forward a hardcoded amount of 2300 gas.

This is not guaranteed to work on Ethereum!

1) fallback() function can consume more than 2300 gas,

2) opcode gas pricing can change in future version of Ethereum, and your contract will break.

Developers have been warned about this 3 years ago:  Stop Using Solidity's transfer() Now

@zksync Era is not EVM equivalent. This is a deliberate design choice. Era has a diverging, dynamic gas metering, which allows some transaction types to be 10x to 1000x cheaper than on any other EVM rollup! 

At the current gas pricing levels of Era mainnet, ETH transfers will cost more than 2300 gas. Which is why any .transfer() call without explicit gas stipend will currently fail.

It was clear to us that this problem could arise, so we added a warning about .transfer() directly to the compiler:

We took one more extra step and checked the source code of dozens of popular crypto projects. We didn't find a single one not following the 3 year old warning of not using .transfer(). We concluded that the dev community has since long closed this issue.

However, the GemholicECO situation has demonstrated that this is not the case. We took their problem extremely seriously. We will always do our best to provide support and guidance to developers and communities building on @zksync.

In this case, we identified an elegant solution which can solve a broader class of gas-related problems. It will require minimal changes in the gas metering of the protocol, but will allow for full recovery of the funds. We will publish more details on it tomorrow.

zkEVMs are complex systems that are in the process of maturing. Even though zkSync Era is still in Alpha, we’ve already got a thriving ecosystem.

We’ve seen a tremendous spike in activity, the most any scaling solution has ever undergone in such a short period of time; it’s been two weeks since our launch and we've risen to the 4th highest TVL and 3rd highest usage of all L2s.

With this comes great responsibility and inevitably the occasional friction and today was one of these instances. When there are problems our team will continue to be on alert and be relentless in resolving issues.

Comments

All Comments

Recommended for you

  • The US FDIC plans to establish an application process for regulated institutions seeking to issue payment stablecoins.

    U.S. Federal Deposit Insurance Corporation (FDIC) announced the approval of a proposed rule to establish an application process for institutions seeking to issue payment stablecoins and regulated by the FDIC. A 60-day public comment period has now been opened. It is reported that this is the first formal rulemaking proposal following the passage of the "GENIUS Act" - the "American Stablecoin Innovation Act."

  • BTC breaks through $88,000

     market shows BTC breaking through $88,000, currently at $88,002.21, a 24-hour increase of 1.34%. The market is highly volatile, please manage your risk accordingly.

  • Bitwise believes 2026 will be a bull market for cryptocurrencies and has released ten predictions.

    Bitwise believes 2026 will be a year of a cryptocurrency bull market. From institutional adoption to regulatory progress, the current positive trends in cryptocurrency are too strong to be suppressed for a long time. Here are Bitwise's top ten predictions for the coming year.

  • China Properties Investment plans to purchase and hold BNB as a strategic reserve asset.

    China Real Estate Investment (00736) announced that in order to promote the diversification of the company's asset allocation and seize the opportunities of digital economy development, the company has resolved to use its own funds to purchase and hold BNB (Binance Coin) and other suitable digital assets in the open market, under the premise of complying with relevant laws, regulations, and risk control, as the company's strategic reserve assets. The company is optimistic about the long-term development prospects of the digital asset industry and has full confidence in the operating entity behind BNB, its technology research and development, ecological layout, and industry competitiveness, recognizing its long-term development potential and value growth space in the blockchain field.

  • Payment infrastructure company Speed1 raises $8 million in funding, led by Tether.

    payment infrastructure company Speed1 announced the completion of an $8 million financing round, led by Tether and participated by Ego Death Capital. The company is committed to building instant global settlement channels using the Bitcoin Lightning Network and stablecoins.

  • Visa begins supporting US financial institutions to settle transactions using USDC on Solana.

    Visa has started supporting U.S. financial institutions to use USDC on Solana for transaction settlements. Cross River Bank and Lead Bank are the first institutions to use this service. As a partner of the Circle Arc blockchain, Visa will also provide support after Arc goes live.

  • Bank of America survey: Kevin Hassett expected to lead the Federal Reserve

     Bank of America's December Global Fund Manager Survey shows that most investors expect U.S. President Trump to nominate White House economic advisor Kevin Hassett as the next Federal Reserve Chair. About 69% expect Hassett to be nominated, while only 4% mentioned Federal Reserve Governor Christopher Waller, and another 4% expect former Fed Governor Kevin Warsh. The survey was conducted before Trump told the media he preferred Hassett or Warsh to lead the Fed. Current Federal Reserve Chair Jerome Powell's term will end in May.

  • Singapore-based digital trade platform Olea completes $30 million Series A funding round.

    Singapore digital trade platform Olea has completed a $30 million Series A funding round, with investors including Banco Bilbao Vizcaya Argentaria (BBVA), XDC Network, theDOCK, and SC Ventures, a subsidiary of Standard Chartered Bank. The funds will be used to accelerate the deployment of AI and Web3 solutions in high-growth markets, strengthening embedded finance, risk analysis, and other products. Since its establishment in 2022, the Olea platform has been licensed by the Monetary Authority of Singapore (MAS) CMS and has provided over $3 billion in financing to more than 1,000 enterprises across more than 70 trade corridors.

  • BTC breaks through $87,000

    market shows BTC breaking through $87,000, currently at $86,986.63, with a 24-hour decline of 3.19%. The market is highly volatile, please manage your risk accordingly.

  • MEXC now supports USD1 (AB Core network).

    On December 16, AB DAO announced that MEXC has officially supported the deposit of USD1 (World Liberty Financial USD) on the AB Core network, and withdrawals will be opened after liquidity meets the platform requirements, further promoting the cross-platform circulation and use of USD1 within the AB ecosystem.