
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
@axelar-network/axelar-cgp-solidity
Advanced tools
Axelar is a decentralized interoperability network connecting all blockchains, assets and apps through a universal set of protocols and APIs. It is built on top off the Cosmos SDK. Users/Applications can use Axelar network to send tokens between any Cosmos and EVM chains. They can also send arbitrary messages between EVM chains.
Axelar network's decentralized validators confirm events emitted on EVM chains (such as deposit confirmation and message send), and sign off on commands submitted (by automated services) to the gateway smart contracts (such as minting token, and approving message on the destination).
See this doc for more design info.
We recommend using the current Node.js LTS version for satisfying the hardhat compiler
Run in your terminal
npm ci
npm run build
npm run test
See Axelar examples for concrete examples.
A
is deployed (AxelarGateway.deployToken()
)
on each non-native EVM chain as an ERC-20 token (BurnableMintableCappedERC20.sol
).DepositHandler.sol
is deployed,
BurnableMintableCappedERC20.depositAddress()
) on source EVM chain.A
at that address, and the deposit contract locks the token at the gateway (or burns them for wrapped tokens).Transfer
event using their RPC nodes for the source chain (using majority voting).AxelarGateway.execute()
.mint
's the specified amount of the wrapped Token A
to the destination address.AxelarDepositService.addressForNativeUnwrap()
.AxelarDepositService.addressForTokenDeposit()
with using the un-wrap address as a destination.AxelarDepositService.sendTokenDeposit()
.AxelarDepositService
deploys DepositReceiver
to that generated address which will call AxelarGateway.sendToken()
.AxelarDepositService.nativeUnwrap()
.AxelarDepositService
deploys DepositReceiver
which will call IWETH9.withdraw()
and transfer native currency to the recipient address.IAxelarExecutable.sol
interface to receive the message.ERC20.approve()
beforehand to allow the gateway contract
to transfer the specified amount
on behalf of the sender/source contract.AxelarGateway.callContractWithToken()
with the destination chain/address, payload
and token.payload
in a regular database, keyed by the hash(payload)
, that anyone can query by.ContractCallWithToken
event.AxelarGateway.approveContractCallWithMint()
command, signed by the validators.payload hash
and emits the event ContractCallApprovedWithMint
.IAxelarExecutable.executeWithToken()
on the destination contract, with the payload
and other data as params.executeWithToken
of the destination contract verifies that the contract call was indeed approved by calling AxelarGateway.validateContractCallAndMint()
on the gateway contract.payload
for it's own application.Network resources: https://docs.axelar.dev/resources
Deployed contracts: https://docs.axelar.dev/resources/mainnet
General Message Passing Usage: https://docs.axelar.dev/dev/gmp
Example cross-chain token swap app: https://app.squidrouter.com
EVM module of the Axelar network that prepares commands for the gateway: https://github.com/axelarnetwork/axelar-core/blob/main/x/evm/keeper/msg_server.go
FAQs
EVM Smart Contracts for Axelar Network
We found that @axelar-network/axelar-cgp-solidity demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.