Contract 0xE5E8506a590766d738D80aFfc6b5e538C4B92F82

 
Ad
Ad
Txn Hash Method
Block
From
To
Value
0x7c3d658daf35115f8106e92f3d5e99866329ec8b6a36f4941c219bcb5d0d529bZap In132568482021-09-19 15:07:551 hr 59 mins ago0xcb7e52eec8858b343760a9b0fb790217b053629b IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.01 Ether0.008503443 39
0xc341ba4cfa983430df016505c2324d9b40e54a59895b0c17ca0be0afdaea7368Zap In132557972021-09-19 11:08:485 hrs 58 mins agoENS Name cyberfinance.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.009214432 32
0x86f1b3837fcd0cf43bd88abf64e39309bae16441dad47683fba7591a08fd394eZap Out132544992021-09-19 6:22:1810 hrs 44 mins ago0xdeb9553eed4a1e9896000071e50a19ec83301574 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.0257728835
0x8ee37959e8cab0fad78803f44ec84a8a824f58d6f7dfa2e44c8051f953bafaf6Zap In132480702021-09-18 6:29:021 day 10 hrs ago0x86dec815354a483d925c0b78e3907bfae50d0b13 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.011201658 39
0x79630076b38365758edc39cf01254da14cf236c4731eefcf110cf3226e5b0dbdZap In132416362021-09-17 6:32:292 days 10 hrs ago0x8a022d00760047f939a023036f1d925e02cc0bac IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.05 Ether0.013954368 64
0xf50f54eb2caf92c97f7c313a2f63537b6002a45617c64eef761fad30f963f1f4Zap In132282152021-09-15 4:47:184 days 12 hrs ago0x6216b9c052adf9e3e6f6192284467ee825698c4c IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.01 Ether0.009593628 44
0x36741dc9e9eb391a94e7b4457618e1ed3dfcaefdff2937c3727ce660c6a351a7Zap Out132226702021-09-14 8:06:435 days 9 hrs agoENS Name jack888.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.0112239 45
0xdcc4fc80985999dd0884e76fe6be5cb1b2cfeb8aaa697a35992bc0ea1c942d1aZap In132225782021-09-14 7:46:555 days 9 hrs ago0xf67b002c318f66f704215f49a03dabd599f81e2c IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.5 Ether0.01133854852
0x21f0db76d781312cc9ef6e7ea74adfd3199859f2f871acf9942c78c59ac37d32Zap In132219352021-09-14 5:25:535 days 11 hrs agoENS Name jack888.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.01 Ether0.03079514494 83.604534199
0x84554dd23c1dc98cfc139313dae20b4184265f421c5a9dc45cb0f2b29aa95ebdZap In132205632021-09-14 0:16:335 days 16 hrs ago0x1c78e6d8fb6e83d289a3cd89940f1108724b055e IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.02 Ether0.01090185 50
0x12f897984e998150eeef69be6df77ef59a57320bd2f5dbcf39fe253c5dd5f28cZap In132119292021-09-12 16:06:427 days 1 hr ago0x933d1c07296b9d216c9fa156eaa79cf6e1af1a9a IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.01 Ether0.01351829462
0xa267fc15780e6353349367284caaa921588eae14efeca501af07b513c82395bdZap In132094412021-09-12 6:54:067 days 10 hrs ago0x3636379722b82c44b3129884da1369cfe81c9fa8 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.11 Ether0.010248303 47
0x5523c3905a1c2254cf11ea0280fec955fc389aa98228765147f6d80e956e5d30Zap In132084222021-09-12 3:10:067 days 13 hrs ago0x0d3ef306e7d258152db2c658272bc438db33e9d1 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.1 Ether0.01452457057966.615164306
0xc5ae9c914cf57825ce96bbed5489f1b1bef54d76ed2a520b7a2950bffbe73e4bZap In132079332021-09-12 1:24:357 days 15 hrs ago0xc6fbba5a63827eb163261902aca0cd2700b5e7a8 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.00000027 Ether0.00733460436
0xe19a7a40eb5c42b7a962d7b74bc6b87f949531a518620f7f26c21611bc2262acZap Out131883782021-09-09 0:36:4210 days 16 hrs ago0x2a9d15df3c3722fdb0a15b2fea55d2b50ae2a154 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.03121545 105
0x5c344d85cc24e0dac0009c89c03d477b4722d1d60a2e1cf86e0eacbad7d52d30Zap In131650232021-09-05 9:52:2814 days 7 hrs agoENS Name mohican.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.006 Ether0.01351829462
0xfdf17570b4f175ea1c165fbdc0aadd3f89456f1537a59f1e01e801a8519255acZap In131572132021-09-04 5:00:5715 days 12 hrs ago0x2a9d15df3c3722fdb0a15b2fea55d2b50ae2a154 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.025136626 89
0x8a7156b71aa96db9a3a32472cca7afd9ec3e4a9eb6109d090972d38105ca2981Zap In131361872021-08-31 23:06:0418 days 18 hrs ago0xc155f76132f6e9a215a386a9daecd2a4f2fcc98b IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.02 Ether0.033141624 152
0xa5f02857f64c1be35034344c34406c8dbd6e621398ba5d6f0217572a405e10c3Zap In130860562021-08-24 5:12:2226 days 11 hrs ago0x4188c4cd0d7cd95fe54e8c55ccd2d057b9d01980 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.41 Ether0.020462999 61
0xf4da7368452363df4b6c51ba52c4323696e4cb3e2f8775cf268976f5d3961371Zap Out130741342021-08-22 9:02:5728 days 8 hrs agoENS Name *qi-dao.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.00754922 35
0x1deb046b66ab5a5b4a01769d31a7171709206e3f0b3b71349318f3f350c5f14dZap Out130721342021-08-22 1:26:0828 days 15 hrs ago0xb153d4c31ae85c8591f1b80a0e068cf8d08714e2 IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.00494578 20
0x5e92fe146857b979df2b4d2c5938921019e56d336275257718c64ab275950362Zap Out130720022021-08-22 0:58:0028 days 16 hrs agoENS Name mroysterhead.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.0065083 25
0x0774bbd77bdd8f7ed088c097e859a4bcc25b6028f442fda848574907a6e41a13Zap In130680562021-08-21 10:24:1329 days 6 hrs agoENS Name fommes.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820.6 Ether0.004579029 21
0x9c6258886c9812343e5d782f4637a73082727facf1f04a5a3c0a6c00132d10fdZap Out130643282021-08-20 20:37:4029 days 20 hrs agoENS Name hodlgod.eth IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.006990373 37
0x27929abed108289e2e1d02621ca4da40ba69699fcc550c3595ddea82c9e407f1Zap Out130585782021-08-19 22:56:2530 days 18 hrs ago0xf725cc2b6ec42fc500f85e82a4ba6289f65354fb IN  0xe5e8506a590766d738d80affc6b5e538c4b92f820 Ether0.006381764 23
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0x7c3d658daf35115f8106e92f3d5e99866329ec8b6a36f4941c219bcb5d0d529b132568482021-09-19 15:07:551 hr 59 mins ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.01 Ether
0x86f1b3837fcd0cf43bd88abf64e39309bae16441dad47683fba7591a08fd394e132544992021-09-19 6:22:1810 hrs 44 mins ago 0xe5e8506a590766d738d80affc6b5e538c4b92f820xdeb9553eed4a1e9896000071e50a19ec833015740.056818845294737524 Ether
0x86f1b3837fcd0cf43bd88abf64e39309bae16441dad47683fba7591a08fd394e132544992021-09-19 6:22:1810 hrs 44 mins ago 0x22f9dcf4647084d6c31b2765f6910cd85c178c18 0xe5e8506a590766d738d80affc6b5e538c4b92f820.056818845294737524 Ether
0x79630076b38365758edc39cf01254da14cf236c4731eefcf110cf3226e5b0dbd132416362021-09-17 6:32:292 days 10 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.05 Ether
0xf50f54eb2caf92c97f7c313a2f63537b6002a45617c64eef761fad30f963f1f4132282152021-09-15 4:47:184 days 12 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.01 Ether
0xdcc4fc80985999dd0884e76fe6be5cb1b2cfeb8aaa697a35992bc0ea1c942d1a132225782021-09-14 7:46:555 days 9 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.5 Ether
0x21f0db76d781312cc9ef6e7ea74adfd3199859f2f871acf9942c78c59ac37d32132219352021-09-14 5:25:535 days 11 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 0x: Exchange Proxy0.01 Ether
0x84554dd23c1dc98cfc139313dae20b4184265f421c5a9dc45cb0f2b29aa95ebd132205632021-09-14 0:16:335 days 16 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.02 Ether
0x12f897984e998150eeef69be6df77ef59a57320bd2f5dbcf39fe253c5dd5f28c132119292021-09-12 16:06:427 days 1 hr ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.01 Ether
0xa267fc15780e6353349367284caaa921588eae14efeca501af07b513c82395bd132094412021-09-12 6:54:067 days 10 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.11 Ether
0x5523c3905a1c2254cf11ea0280fec955fc389aa98228765147f6d80e956e5d30132084222021-09-12 3:10:067 days 13 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.1 Ether
0xc5ae9c914cf57825ce96bbed5489f1b1bef54d76ed2a520b7a2950bffbe73e4b132079332021-09-12 1:24:357 days 15 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.00000027 Ether
0x5c344d85cc24e0dac0009c89c03d477b4722d1d60a2e1cf86e0eacbad7d52d30131650232021-09-05 9:52:2814 days 7 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.006 Ether
0x8a7156b71aa96db9a3a32472cca7afd9ec3e4a9eb6109d090972d38105ca2981131361872021-08-31 23:06:0418 days 18 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.02 Ether
0xa5f02857f64c1be35034344c34406c8dbd6e621398ba5d6f0217572a405e10c3130860562021-08-24 5:12:2226 days 11 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 0x: Exchange Proxy0.41 Ether
0xf4da7368452363df4b6c51ba52c4323696e4cb3e2f8775cf268976f5d3961371130741342021-08-22 9:02:5728 days 8 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82ENS Name *qi-dao.eth0.196373225087779106 Ether
0xf4da7368452363df4b6c51ba52c4323696e4cb3e2f8775cf268976f5d3961371130741342021-08-22 9:02:5728 days 8 hrs ago Compound: cETH Token 0xe5e8506a590766d738d80affc6b5e538c4b92f820.196373225087779106 Ether
0x5e92fe146857b979df2b4d2c5938921019e56d336275257718c64ab275950362130720022021-08-22 0:58:0028 days 16 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82ENS Name mroysterhead.eth0.029003386953549992 Ether
0x5e92fe146857b979df2b4d2c5938921019e56d336275257718c64ab275950362130720022021-08-22 0:58:0028 days 16 hrs ago Compound: cETH Token 0xe5e8506a590766d738d80affc6b5e538c4b92f820.029003386953549992 Ether
0x0774bbd77bdd8f7ed088c097e859a4bcc25b6028f442fda848574907a6e41a13130680562021-08-21 10:24:1329 days 6 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.6 Ether
0x9c6258886c9812343e5d782f4637a73082727facf1f04a5a3c0a6c00132d10fd130643282021-08-20 20:37:4029 days 20 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82ENS Name hodlgod.eth0.210023709267344227 Ether
0x9c6258886c9812343e5d782f4637a73082727facf1f04a5a3c0a6c00132d10fd130643282021-08-20 20:37:4029 days 20 hrs ago Compound: cETH Token 0xe5e8506a590766d738d80affc6b5e538c4b92f820.210023709267344227 Ether
0x27929abed108289e2e1d02621ca4da40ba69699fcc550c3595ddea82c9e407f1130585782021-08-19 22:56:2530 days 18 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f820xf725cc2b6ec42fc500f85e82a4ba6289f65354fb1.001947590054241953 Ether
0x27929abed108289e2e1d02621ca4da40ba69699fcc550c3595ddea82c9e407f1130585782021-08-19 22:56:2530 days 18 hrs ago Compound: cETH Token 0xe5e8506a590766d738d80affc6b5e538c4b92f821.001947590054241953 Ether
0x88ad57c4185781afaffdcd1e1a36715139ec2b130e1b71ca470bcb8ccfaa9a6c130450502021-08-17 20:57:3532 days 20 hrs ago 0xe5e8506a590766d738d80affc6b5e538c4b92f82 Compound: cETH Token0.08 Ether
[ Download CSV Export 
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Compound_Zap_V1

Compiler Version
v0.8.4+commit.c7e474f2

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, GNU GPLv2 license
File 1 of 11 : CompoundInterface.sol
// SPDX-License-Identifier: GPL-2.0
pragma solidity ^0.8.0;

interface ICompoundToken {
    function underlying() external view returns (address);

    function mint(uint256 mintAmount) external returns (uint256);

    function mint() external payable;

    function redeem(uint256 redeemTokens) external returns (uint256);

    function exchangeRateStored() external view returns (uint256);
}

File 2 of 11 : Compound_Zap_V1.sol
// ███████╗░█████╗░██████╗░██████╗░███████╗██████╗░░░░███████╗██╗
// ╚════██║██╔══██╗██╔══██╗██╔══██╗██╔════╝██╔══██╗░░░██╔════╝██║
// ░░███╔═╝███████║██████╔╝██████╔╝█████╗░░██████╔╝░░░█████╗░░██║
// ██╔══╝░░██╔══██║██╔═══╝░██╔═══╝░██╔══╝░░██╔══██╗░░░██╔══╝░░██║
// ███████╗██║░░██║██║░░░░░██║░░░░░███████╗██║░░██║██╗██║░░░░░██║
// ╚══════╝╚═╝░░╚═╝╚═╝░░░░░╚═╝░░░░░╚══════╝╚═╝░░╚═╝╚═╝╚═╝░░░░░╚═╝
// Copyright (C) 2021 zapper

// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as published by
// the Free Software Foundation, either version 2 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU Affero General Public License for more details.
//

///@author Zapper
///@notice This contract deposits and withdraws assets to/from Compound
// SPDX-License-Identifier: GPL-2.0

pragma solidity ^0.8.0;
import "../_base/ZapInBaseV3_1.sol";
import "../_base/ZapOutBaseV3_1.sol";
import "./CompoundInterface.sol";

interface IWETH {
    function deposit() external payable;

    function withdraw(uint256 wad) external;
}

contract Compound_Zap_V1 is ZapInBaseV3_1, ZapOutBaseV3_1 {
    using SafeERC20 for IERC20;

    address private constant wethTokenAddress =
        0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2;

    address private constant cETH = 0x4Ddc2D193948926D02f9B1fE9e1daa0718270ED5;

    constructor(uint256 _goodwill, uint256 _affiliateSplit)
        ZapBaseV2_1(_goodwill, _affiliateSplit)
    {
        approvedTargets[0xDef1C0ded9bec7F1a1670819833240f027b25EfF] = true;
    }

    event zapIn(address sender, address token, uint256 tokensRec);
    event zapOut(address sender, address token, uint256 tokensRec);

    /**
    @notice This function deposits assets into Compound with ETH or ERC20 tokens
    @param fromToken The token used for entry (address(0) if ether)
    @param amountIn The amount of fromToken to invest
    @param cToken Address of the cToken
    @param minCtokens The minimum acceptable quantity cTokens to receive. Reverts otherwise
    @param swapTarget Excecution target for the swap or zap
    @param swapData DEX or Zap data. Must swap to cToken underlying address
    @param affiliate Affiliate address
    @return cTokensRec Quantity of cTokens received
     */
    function ZapIn(
        address fromToken,
        uint256 amountIn,
        address cToken,
        uint256 minCtokens,
        address swapTarget,
        bytes calldata swapData,
        address affiliate
    ) external payable stopInEmergency returns (uint256 cTokensRec) {
        uint256 toInvest = _pullTokens(fromToken, amountIn, affiliate, true);

        address toToken = getUnderlyingToken(cToken);

        uint256 tokensBought =
            _fillQuote(fromToken, toToken, toInvest, swapTarget, swapData);

        (cTokensRec) = enterCompound(cToken, toToken, tokensBought);
        require(cTokensRec > minCtokens, "High Slippage");

        IERC20(cToken).safeTransfer(msg.sender, cTokensRec);

        emit zapIn(msg.sender, cToken, cTokensRec);
    }

    function enterCompound(
        address cToken,
        address underlyingToken,
        uint256 underlyingAmount
    ) internal returns (uint256 cTokensRec) {
        uint256 initialBalance = _getBalance(cToken);

        if (underlyingToken == address(0)) {
            ICompoundToken(cToken).mint{ value: underlyingAmount }();
        } else {
            _approveToken(underlyingToken, cToken, underlyingAmount);
            ICompoundToken(cToken).mint(underlyingAmount);
        }

        cTokensRec = _getBalance(cToken) - initialBalance;
    }

    /**
    @notice This function withdraws assets from Compound, receiving tokens or ETH
    @param fromToken The cToken being withdrawn
    @param amountIn The quantity of fromToken to withdraw
    @param toToken Address of the token to receive (0 address if ETH)
    @param minToTokens The minimum acceptable quantity tokens to receive. Reverts otherwise
    @param swapTarget Excecution target for the swap or zap
    @param swapData DEX or Zap data
    @param affiliate Affiliate address
    @return tokensRec Quantity of aTokens received
     */
    function ZapOut(
        address fromToken,
        uint256 amountIn,
        address toToken,
        uint256 minToTokens,
        address swapTarget,
        bytes calldata swapData,
        address affiliate
    ) public stopInEmergency returns (uint256 tokensRec) {
        amountIn = _pullTokens(fromToken, amountIn);

        address underlyingToken = getUnderlyingToken(fromToken);

        uint256 underlyingRec =
            exitCompound(fromToken, amountIn, underlyingToken);

        tokensRec = _fillQuote(
            underlyingToken,
            toToken,
            underlyingRec,
            swapTarget,
            swapData
        );

        require(tokensRec >= minToTokens, "High Slippage");

        uint256 totalGoodwillPortion;

        if (toToken == address(0)) {
            totalGoodwillPortion = _subtractGoodwill(
                ETHAddress,
                tokensRec,
                affiliate,
                true
            );

            payable(msg.sender).transfer(tokensRec - totalGoodwillPortion);
        } else {
            totalGoodwillPortion = _subtractGoodwill(
                toToken,
                tokensRec,
                affiliate,
                true
            );

            IERC20(toToken).safeTransfer(
                msg.sender,
                tokensRec - totalGoodwillPortion
            );
        }

        tokensRec = tokensRec - totalGoodwillPortion;

        emit zapOut(msg.sender, toToken, tokensRec);
    }

    function exitCompound(
        address cToken,
        uint256 cTokenAmount,
        address underlyingToken
    ) internal returns (uint256 underlyingRec) {
        uint256 initialBalance = _getBalance(underlyingToken);

        ICompoundToken(cToken).redeem(cTokenAmount);

        underlyingRec = _getBalance(underlyingToken) - initialBalance;
    }

    function _fillQuote(
        address fromToken,
        address toToken,
        uint256 _amount,
        address swapTarget,
        bytes memory swapData
    ) internal returns (uint256 amountBought) {
        if (fromToken == toToken) {
            return _amount;
        }

        if (fromToken == address(0) && toToken == wethTokenAddress) {
            IWETH(wethTokenAddress).deposit{ value: _amount }();
            return _amount;
        }

        if (fromToken == wethTokenAddress && toToken == address(0)) {
            IWETH(wethTokenAddress).withdraw(_amount);
            return _amount;
        }

        uint256 valueToSend;
        if (fromToken == address(0)) {
            valueToSend = _amount;
        } else {
            _approveToken(fromToken, swapTarget);
        }

        uint256 initialBalance = _getBalance(toToken);

        require(approvedTargets[swapTarget], "Target not Authorized");
        (bool success, ) = swapTarget.call{ value: valueToSend }(swapData);
        require(success, "Error Swapping Tokens");

        amountBought = _getBalance(toToken) - initialBalance;

        require(amountBought > 0, "Swapped To Invalid Intermediate");
    }

    function getUnderlyingToken(address cToken) public view returns (address) {
        return
            cToken == cETH ? address(0) : ICompoundToken(cToken).underlying();
    }

    function removeLiquidityReturn(address cToken, uint256 cTokenAmt)
        external
        view
        returns (uint256 underlyingRec)
    {
        return
            (cTokenAmt * ICompoundToken(cToken).exchangeRateStored()) / 10**18;
    }
}

File 3 of 11 : ZapBaseV2_1.sol
// SPDX-License-Identifier: GPL-2.0
pragma solidity ^0.8.0;

import "../oz/0.8.0/access/Ownable.sol";
import "../oz/0.8.0/token/ERC20/utils/SafeERC20.sol";
import "../oz/0.8.0/token/ERC20/extensions/IERC20Metadata.sol";

abstract contract ZapBaseV2_1 is Ownable {
    using SafeERC20 for IERC20;
    bool public stopped = false;

    // if true, goodwill is not deducted
    mapping(address => bool) public feeWhitelist;

    uint256 public goodwill;
    // % share of goodwill (0-100 %)
    uint256 affiliateSplit;
    // restrict affiliates
    mapping(address => bool) public affiliates;
    // affiliate => token => amount
    mapping(address => mapping(address => uint256)) public affiliateBalance;
    // token => amount
    mapping(address => uint256) public totalAffiliateBalance;
    // swapTarget => approval status
    mapping(address => bool) public approvedTargets;

    address internal constant ETHAddress =
        0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;

    address internal constant ZapperAdmin =
        0x3CE37278de6388532C3949ce4e886F365B14fB56;

    constructor(uint256 _goodwill, uint256 _affiliateSplit) {
        goodwill = _goodwill;
        affiliateSplit = _affiliateSplit;
    }

    // circuit breaker modifiers
    modifier stopInEmergency {
        if (stopped) {
            revert("Paused");
        } else {
            _;
        }
    }

    function _getBalance(address token)
        internal
        view
        returns (uint256 balance)
    {
        if (token == address(0)) {
            balance = address(this).balance;
        } else {
            balance = IERC20(token).balanceOf(address(this));
        }
    }

    function _approveToken(address token, address spender) internal {
        IERC20 _token = IERC20(token);
        if (_token.allowance(address(this), spender) > 0) return;
        else {
            _token.safeApprove(spender, type(uint256).max);
        }
    }

    function _approveToken(
        address token,
        address spender,
        uint256 amount
    ) internal {
        IERC20(token).safeApprove(spender, 0);
        IERC20(token).safeApprove(spender, amount);
    }

    // - to Pause the contract
    function toggleContractActive() public onlyOwner {
        stopped = !stopped;
    }

    function set_feeWhitelist(address zapAddress, bool status)
        external
        onlyOwner
    {
        feeWhitelist[zapAddress] = status;
    }

    function set_new_goodwill(uint256 _new_goodwill) public onlyOwner {
        require(
            _new_goodwill >= 0 && _new_goodwill <= 100,
            "GoodWill Value not allowed"
        );
        goodwill = _new_goodwill;
    }

    function set_new_affiliateSplit(uint256 _new_affiliateSplit)
        external
        onlyOwner
    {
        require(
            _new_affiliateSplit <= 100,
            "Affiliate Split Value not allowed"
        );
        affiliateSplit = _new_affiliateSplit;
    }

    function set_affiliate(address _affiliate, bool _status)
        external
        onlyOwner
    {
        affiliates[_affiliate] = _status;
    }

    ///@notice Withdraw goodwill share, retaining affilliate share
    function withdrawTokens(address[] calldata tokens) external onlyOwner {
        for (uint256 i = 0; i < tokens.length; i++) {
            uint256 qty;

            if (tokens[i] == ETHAddress) {
                qty = address(this).balance - totalAffiliateBalance[tokens[i]];

                Address.sendValue(payable(owner()), qty);
            } else {
                qty =
                    IERC20(tokens[i]).balanceOf(address(this)) -
                    totalAffiliateBalance[tokens[i]];
                IERC20(tokens[i]).safeTransfer(owner(), qty);
            }
        }
    }

    ///@notice Withdraw affilliate share, retaining goodwill share
    function affilliateWithdraw(address[] calldata tokens) external {
        uint256 tokenBal;
        for (uint256 i = 0; i < tokens.length; i++) {
            tokenBal = affiliateBalance[msg.sender][tokens[i]];
            affiliateBalance[msg.sender][tokens[i]] = 0;
            totalAffiliateBalance[tokens[i]] =
                totalAffiliateBalance[tokens[i]] -
                tokenBal;

            if (tokens[i] == ETHAddress) {
                Address.sendValue(payable(msg.sender), tokenBal);
            } else {
                IERC20(tokens[i]).safeTransfer(msg.sender, tokenBal);
            }
        }
    }

    function setApprovedTargets(
        address[] calldata targets,
        bool[] calldata isApproved
    ) external onlyOwner {
        require(targets.length == isApproved.length, "Invalid Input length");

        for (uint256 i = 0; i < targets.length; i++) {
            approvedTargets[targets[i]] = isApproved[i];
        }
    }

    function _subtractGoodwill(
        address token,
        uint256 amount,
        address affiliate,
        bool enableGoodwill
    ) internal returns (uint256 totalGoodwillPortion) {
        bool whitelisted = feeWhitelist[msg.sender];
        if (enableGoodwill && !whitelisted && goodwill > 0) {
            totalGoodwillPortion = (amount * goodwill) / 10000;

            if (affiliates[affiliate]) {
                if (token == address(0)) {
                    token = ETHAddress;
                }

                uint256 affiliatePortion =
                    (totalGoodwillPortion * affiliateSplit) / 100;
                affiliateBalance[affiliate][token] += affiliatePortion;
                totalAffiliateBalance[token] += affiliatePortion;
            }
        }
    }

    receive() external payable {
        require(msg.sender != tx.origin, "Do not send ETH directly");
    }
}

File 4 of 11 : ZapInBaseV3_1.sol
// SPDX-License-Identifier: GPL-2.0

pragma solidity ^0.8.0;
import "./ZapBaseV2_1.sol";

abstract contract ZapInBaseV3_1 is ZapBaseV2_1 {
    using SafeERC20 for IERC20;

    /**
    @dev Transfer tokens (including ETH) from msg.sender to this contract
    @param token The ERC20 token to transfer to this contract (0 address if ETH)
    @return Quantity of tokens transferred to this contract
     */
    function _pullTokens(
        address token,
        uint256 amount,
        address affiliate,
        bool enableGoodwill
    ) internal returns (uint256) {
        uint256 totalGoodwillPortion;

        if (token == address(0)) {
            require(msg.value > 0, "No eth sent");

            // subtract goodwill
            totalGoodwillPortion = _subtractGoodwill(
                ETHAddress,
                msg.value,
                affiliate,
                enableGoodwill
            );

            return msg.value - totalGoodwillPortion;
        }

        require(amount > 0, "Invalid token amount");
        require(msg.value == 0, "Eth sent with token");

        //transfer token

        IERC20(token).safeTransferFrom(msg.sender, address(this), amount);

        // subtract goodwill
        totalGoodwillPortion = _subtractGoodwill(
            token,
            amount,
            affiliate,
            enableGoodwill
        );

        return amount - totalGoodwillPortion;
    }
}

File 5 of 11 : ZapOutBaseV3_1.sol
// SPDX-License-Identifier: GPL-2.0

pragma solidity ^0.8.0;
import "./ZapBaseV2_1.sol";

abstract contract ZapOutBaseV3_1 is ZapBaseV2_1 {
    using SafeERC20 for IERC20;

    /**
    @dev Transfer tokens from msg.sender to this contract
    @param token The ERC20 token to transfer to this contract
    @return Quantity of tokens transferred to this contract
     */
    function _pullTokens(address token, uint256 amount)
        internal
        returns (uint256)
    {
        IERC20(token).safeTransferFrom(msg.sender, address(this), amount);

        return amount;
    }
}

File 6 of 11 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(
        address indexed previousOwner,
        address indexed newOwner
    );

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        emit OwnershipTransferred(_owner, address(0));
        _owner = address(0);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(
            newOwner != address(0),
            "Ownable: new owner is the zero address"
        );
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

File 7 of 11 : IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount)
        external
        returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender)
        external
        view
        returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address sender,
        address recipient,
        uint256 amount
    ) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(
        address indexed owner,
        address indexed spender,
        uint256 value
    );
}

File 8 of 11 : IERC20Metadata.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC20.sol";

/**
 * @dev Interface for the optional metadata functions from the ERC20 standard.
 *
 * _Available since v4.1._
 */
interface IERC20Metadata is IERC20 {
    /**
     * @dev Returns the name of the token.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the symbol of the token.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the decimals places of the token.
     */
    function decimals() external view returns (uint8);
}

File 9 of 11 : SafeERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../../../utils/Address.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(
            token,
            abi.encodeWithSelector(token.transfer.selector, to, value)
        );
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(
            token,
            abi.encodeWithSelector(token.transferFrom.selector, from, to, value)
        );
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        // solhint-disable-next-line max-line-length
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(
            token,
            abi.encodeWithSelector(token.approve.selector, spender, value)
        );
    }

    function safeIncreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(
            token,
            abi.encodeWithSelector(
                token.approve.selector,
                spender,
                newAllowance
            )
        );
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(
                oldAllowance >= value,
                "SafeERC20: decreased allowance below zero"
            );
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(
                token,
                abi.encodeWithSelector(
                    token.approve.selector,
                    spender,
                    newAllowance
                )
            );
        }
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata =
            address(token).functionCall(
                data,
                "SafeERC20: low-level call failed"
            );
        if (returndata.length > 0) {
            // Return data is optional
            // solhint-disable-next-line max-line-length
            require(
                abi.decode(returndata, (bool)),
                "SafeERC20: ERC20 operation did not succeed"
            );
        }
    }
}

File 10 of 11 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // solhint-disable-next-line no-inline-assembly
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(
            address(this).balance >= amount,
            "Address: insufficient balance"
        );

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (bool success, ) = recipient.call{ value: amount }("");
        require(
            success,
            "Address: unable to send value, recipient may have reverted"
        );
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain`call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data)
        internal
        returns (bytes memory)
    {
        return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return
            functionCallWithValue(
                target,
                data,
                value,
                "Address: low-level call with value failed"
            );
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(
            address(this).balance >= value,
            "Address: insufficient balance for call"
        );
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) =
            target.call{ value: value }(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data)
        internal
        view
        returns (bytes memory)
    {
        return
            functionStaticCall(
                target,
                data,
                "Address: low-level static call failed"
            );
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.staticcall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data)
        internal
        returns (bytes memory)
    {
        return
            functionDelegateCall(
                target,
                data,
                "Address: low-level delegate call failed"
            );
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) private pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 11 of 11 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/*
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}

Settings
{
  "evmVersion": "istanbul",
  "libraries": {},
  "metadata": {
    "bytecodeHash": "ipfs",
    "useLiteralContent": true
  },
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "remappings": [],
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"uint256","name":"_goodwill","type":"uint256"},{"internalType":"uint256","name":"_affiliateSplit","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokensRec","type":"uint256"}],"name":"zapIn","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokensRec","type":"uint256"}],"name":"zapOut","type":"event"},{"inputs":[{"internalType":"address","name":"fromToken","type":"address"},{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"address","name":"cToken","type":"address"},{"internalType":"uint256","name":"minCtokens","type":"uint256"},{"internalType":"address","name":"swapTarget","type":"address"},{"internalType":"bytes","name":"swapData","type":"bytes"},{"internalType":"address","name":"affiliate","type":"address"}],"name":"ZapIn","outputs":[{"internalType":"uint256","name":"cTokensRec","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"fromToken","type":"address"},{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"address","name":"toToken","type":"address"},{"internalType":"uint256","name":"minToTokens","type":"uint256"},{"internalType":"address","name":"swapTarget","type":"address"},{"internalType":"bytes","name":"swapData","type":"bytes"},{"internalType":"address","name":"affiliate","type":"address"}],"name":"ZapOut","outputs":[{"internalType":"uint256","name":"tokensRec","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"affiliateBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"affiliates","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"tokens","type":"address[]"}],"name":"affilliateWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"approvedTargets","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"feeWhitelist","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"cToken","type":"address"}],"name":"getUnderlyingToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"goodwill","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"cToken","type":"address"},{"internalType":"uint256","name":"cTokenAmt","type":"uint256"}],"name":"removeLiquidityReturn","outputs":[{"internalType":"uint256","name":"underlyingRec","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"targets","type":"address[]"},{"internalType":"bool[]","name":"isApproved","type":"bool[]"}],"name":"setApprovedTargets","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_affiliate","type":"address"},{"internalType":"bool","name":"_status","type":"bool"}],"name":"set_affiliate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"zapAddress","type":"address"},{"internalType":"bool","name":"status","type":"bool"}],"name":"set_feeWhitelist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_new_affiliateSplit","type":"uint256"}],"name":"set_new_affiliateSplit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_new_goodwill","type":"uint256"}],"name":"set_new_goodwill","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stopped","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"toggleContractActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"totalAffiliateBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"tokens","type":"address[]"}],"name":"withdrawTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

60806040526000805460ff60a01b1916905534801561001d57600080fd5b506040516200260d3803806200260d83398101604081905261003e916100dc565b600080546001600160a01b03191633908117825560405184928492918291907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a350600291909155600355505073def1c0ded9bec7f1a1670819833240f027b25eff60005260076020527ff6019cd1944dc466e824190b288e5a63528dd4c9a6d8cbd707956fd30d2f1e0d805460ff191660011790556100ff565b600080604083850312156100ee578182fd5b505080516020909101519092909150565b6124fe806200010f6000396000f3fe6080604052600436106101395760003560e01c8063691bcc88116100ab5780638da5cb5b1161006f5780638da5cb5b146103de5780639735a634146103fc5780639779d1a61461041c578063d408f6571461044c578063f2fde38b1461047c578063fbec27bf1461049c57600080fd5b8063691bcc881461033d57806369a7e57b14610375578063715018a61461038857806375f12b211461039d5780637ee99283146103be57600080fd5b80633ff428c7116100fd5780633ff428c71461026757806346d4b548146102875780634f51e294146102a7578063550bfa56146102e75780635de0398e146103075780635ecb16cd1461031d57600080fd5b806301e980d41461019a5780630dc9de85146101ba5780631385d24c146101da5780631781261f146101ef57806318b135e31461023a57600080fd5b3661019557333214156101935760405162461bcd60e51b815260206004820152601860248201527f446f206e6f742073656e6420455448206469726563746c79000000000000000060448201526064015b60405180910390fd5b005b600080fd5b3480156101a657600080fd5b506101936101b5366004612323565b6104bc565b3480156101c657600080fd5b506101936101d5366004612242565b610546565b3480156101e657600080fd5b506101936107a1565b3480156101fb57600080fd5b5061022761020a3660046120e9565b600560209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b34801561024657600080fd5b506102276102553660046120b1565b60066020526000908152604090205481565b34801561027357600080fd5b50610193610282366004612121565b6107ec565b34801561029357600080fd5b506102276102a2366004612179565b610841565b3480156102b357600080fd5b506102d76102c23660046120b1565b60046020526000908152604090205460ff1681565b6040519015158152602001610231565b3480156102f357600080fd5b50610193610302366004612323565b610a35565b34801561031357600080fd5b5061022760025481565b34801561032957600080fd5b50610193610338366004612242565b610ab5565b34801561034957600080fd5b5061035d6103583660046120b1565b610d26565b6040516001600160a01b039091168152602001610231565b610227610383366004612179565b610dcb565b34801561039457600080fd5b50610193610f1a565b3480156103a957600080fd5b506000546102d790600160a01b900460ff1681565b3480156103ca57600080fd5b506102276103d936600461214e565b610f8e565b3480156103ea57600080fd5b506000546001600160a01b031661035d565b34801561040857600080fd5b50610193610417366004612282565b611025565b34801561042857600080fd5b506102d76104373660046120b1565b60076020526000908152604090205460ff1681565b34801561045857600080fd5b506102d76104673660046120b1565b60016020526000908152604090205460ff1681565b34801561048857600080fd5b506101936104973660046120b1565b61114f565b3480156104a857600080fd5b506101936104b7366004612121565b611239565b6000546001600160a01b031633146104e65760405162461bcd60e51b815260040161018a906123a2565b60648111156105415760405162461bcd60e51b815260206004820152602160248201527f416666696c696174652053706c69742056616c7565206e6f7420616c6c6f77656044820152601960fa1b606482015260840161018a565b600355565b6000805b8281101561079b573360009081526005602052604081209085858481811061058257634e487b7160e01b600052603260045260246000fd5b905060200201602081019061059791906120b1565b6001600160a01b031681526020808201929092526040908101600090812054338252600590935290812091935090818686858181106105e657634e487b7160e01b600052603260045260246000fd5b90506020020160208101906105fb91906120b1565b6001600160a01b03166001600160a01b0316815260200190815260200160002081905550816006600086868581811061064457634e487b7160e01b600052603260045260246000fd5b905060200201602081019061065991906120b1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054610684919061242e565b600660008686858181106106a857634e487b7160e01b600052603260045260246000fd5b90506020020160208101906106bd91906120b1565b6001600160a01b0316815260208101919091526040016000205573eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee84848381811061070c57634e487b7160e01b600052603260045260246000fd5b905060200201602081019061072191906120b1565b6001600160a01b0316141561073f5761073a338361128e565b610789565b610789338386868581811061076457634e487b7160e01b600052603260045260246000fd5b905060200201602081019061077991906120b1565b6001600160a01b031691906113a7565b8061079381612471565b91505061054a565b50505050565b6000546001600160a01b031633146107cb5760405162461bcd60e51b815260040161018a906123a2565b6000805460ff60a01b198116600160a01b9182900460ff1615909102179055565b6000546001600160a01b031633146108165760405162461bcd60e51b815260040161018a906123a2565b6001600160a01b03919091166000908152600460205260409020805460ff1916911515919091179055565b60008054600160a01b900460ff16156108855760405162461bcd60e51b815260206004820152600660248201526514185d5cd95960d21b604482015260640161018a565b61088f898961140a565b9750600061089c8a610d26565b905060006108ab8b8b84611427565b90506108f0828a838a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506114ce92505050565b9250878310156109325760405162461bcd60e51b815260206004820152600d60248201526c4869676820536c69707061676560981b604482015260640161018a565b60006001600160a01b038a166109a15761096373eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee858760016117e5565b9050336108fc610973838761242e565b6040518115909202916000818181858888f1935050505015801561099b573d6000803e3d6000fd5b506109cf565b6109ae8a858760016117e5565b90506109cf336109be838761242e565b6001600160a01b038d1691906113a7565b6109d9818561242e565b604080513381526001600160a01b038d1660208201529081018290529094507fa51973a21dd19abaad8194f70440e180b7c5784c9828663e69dcbb57d7575bea906060015b60405180910390a150505098975050505050505050565b6000546001600160a01b03163314610a5f5760405162461bcd60e51b815260040161018a906123a2565b6064811115610ab05760405162461bcd60e51b815260206004820152601a60248201527f476f6f6457696c6c2056616c7565206e6f7420616c6c6f776564000000000000604482015260640161018a565b600255565b6000546001600160a01b03163314610adf5760405162461bcd60e51b815260040161018a906123a2565b60005b81811015610d2157600073eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee848484818110610b2157634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610b3691906120b1565b6001600160a01b03161415610bc45760066000858585818110610b6957634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610b7e91906120b1565b6001600160a01b03168152602081019190915260400160002054610ba2904761242e565b9050610bbf610bb96000546001600160a01b031690565b8261128e565b610d0e565b60066000858585818110610be857634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610bfd91906120b1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054848484818110610c3e57634e487b7160e01b600052603260045260246000fd5b9050602002016020810190610c5391906120b1565b6040516370a0823160e01b81523060048201526001600160a01b0391909116906370a082319060240160206040518083038186803b158015610c9457600080fd5b505afa158015610ca8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ccc919061233b565b610cd6919061242e565b9050610d0e610ced6000546001600160a01b031690565b8286868681811061076457634e487b7160e01b600052603260045260246000fd5b5080610d1981612471565b915050610ae2565b505050565b60006001600160a01b038216734ddc2d193948926d02f9b1fe9e1daa0718270ed514610dc257816001600160a01b0316636f307dc36040518163ffffffff1660e01b815260040160206040518083038186803b158015610d8557600080fd5b505afa158015610d99573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dbd91906120cd565b610dc5565b60005b92915050565b60008054600160a01b900460ff1615610e0f5760405162461bcd60e51b815260206004820152600660248201526514185d5cd95960d21b604482015260640161018a565b6000610e1e8a8a856001611910565b90506000610e2b89610d26565b90506000610e728c83858b8b8b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506114ce92505050565b9050610e7f8a8383611a57565b9350888411610ec05760405162461bcd60e51b815260206004820152600d60248201526c4869676820536c69707061676560981b604482015260640161018a565b610ed46001600160a01b038b1633866113a7565b604080513381526001600160a01b038c1660208201529081018590527f7f31d76771556dce5ab39ba5b60664743da2629a75c474e9445734b7ad34087d90606001610a1e565b6000546001600160a01b03163314610f445760405162461bcd60e51b815260040161018a906123a2565b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000670de0b6b3a7640000836001600160a01b031663182df0f56040518163ffffffff1660e01b815260040160206040518083038186803b158015610fd257600080fd5b505afa158015610fe6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061100a919061233b565b611014908461240f565b61101e91906123ef565b9392505050565b6000546001600160a01b0316331461104f5760405162461bcd60e51b815260040161018a906123a2565b8281146110955760405162461bcd60e51b8152602060048201526014602482015273092dcecc2d8d2c84092dce0eae840d8cadccee8d60631b604482015260640161018a565b60005b83811015611148578282828181106110c057634e487b7160e01b600052603260045260246000fd5b90506020020160208101906110d591906122eb565b600760008787858181106110f957634e487b7160e01b600052603260045260246000fd5b905060200201602081019061110e91906120b1565b6001600160a01b031681526020810191909152604001600020805460ff19169115159190911790558061114081612471565b915050611098565b5050505050565b6000546001600160a01b031633146111795760405162461bcd60e51b815260040161018a906123a2565b6001600160a01b0381166111de5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161018a565b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146112635760405162461bcd60e51b815260040161018a906123a2565b6001600160a01b03919091166000908152600160205260409020805460ff1916911515919091179055565b804710156112de5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e6365000000604482015260640161018a565b6000826001600160a01b03168260405160006040518083038185875af1925050503d806000811461132b576040519150601f19603f3d011682016040523d82523d6000602084013e611330565b606091505b5050905080610d215760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d61792068617665207265766572746564000000000000606482015260840161018a565b6040516001600160a01b038316602482015260448101829052610d2190849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152611b5d565b60006114216001600160a01b038416333085611c2f565b50919050565b60008061143383611c67565b60405163db006a7560e01b8152600481018690529091506001600160a01b0386169063db006a7590602401602060405180830381600087803b15801561147857600080fd5b505af115801561148c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114b0919061233b565b50806114bb84611c67565b6114c5919061242e565b95945050505050565b6000846001600160a01b0316866001600160a01b031614156114f15750826114c5565b6001600160a01b03861615801561152457506001600160a01b03851673c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2145b156115995773c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b031663d0e30db0856040518263ffffffff1660e01b81526004016000604051808303818588803b15801561157857600080fd5b505af115801561158c573d6000803e3d6000fd5b50505050508390506114c5565b6001600160a01b03861673c02aaa39b223fe8d0a0e5c4f27ead9083c756cc21480156115cc57506001600160a01b038516155b1561163e57604051632e1a7d4d60e01b81526004810185905273c02aaa39b223fe8d0a0e5c4f27ead9083c756cc290632e1a7d4d90602401600060405180830381600087803b15801561161e57600080fd5b505af1158015611632573d6000803e3d6000fd5b505050508390506114c5565b60006001600160a01b03871661165557508361165f565b61165f8785611cfa565b600061166a87611c67565b6001600160a01b03861660009081526007602052604090205490915060ff166116cd5760405162461bcd60e51b815260206004820152601560248201527415185c99d95d081b9bdd08105d5d1a1bdc9a5e9959605a1b604482015260640161018a565b6000856001600160a01b031683866040516116e89190612353565b60006040518083038185875af1925050503d8060008114611725576040519150601f19603f3d011682016040523d82523d6000602084013e61172a565b606091505b50509050806117735760405162461bcd60e51b81526020600482015260156024820152744572726f72205377617070696e6720546f6b656e7360581b604482015260640161018a565b8161177d89611c67565b611787919061242e565b9350600084116117d95760405162461bcd60e51b815260206004820152601f60248201527f5377617070656420546f20496e76616c696420496e7465726d65646961746500604482015260640161018a565b50505095945050505050565b3360009081526001602052604081205460ff16828015611803575080155b801561181157506000600254115b156119075761271060025486611827919061240f565b61183191906123ef565b6001600160a01b03851660009081526004602052604090205490925060ff1615611907576001600160a01b03861661187b5773eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee95505b600060646003548461188d919061240f565b61189791906123ef565b6001600160a01b038087166000908152600560209081526040808320938c168352929052908120805492935083929091906118d39084906123d7565b90915550506001600160a01b038716600090815260066020526040812080548392906119009084906123d7565b9091555050505b50949350505050565b6000806001600160a01b038616611993576000341161195f5760405162461bcd60e51b815260206004820152600b60248201526a139bc8195d1a081cd95b9d60aa1b604482015260640161018a565b61197f73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee3486866117e5565b905061198b813461242e565b915050611a4f565b600085116119da5760405162461bcd60e51b8152602060048201526014602482015273125b9d985b1a59081d1bdad95b88185b5bdd5b9d60621b604482015260640161018a565b3415611a1e5760405162461bcd60e51b815260206004820152601360248201527222ba341039b2b73a103bb4ba34103a37b5b2b760691b604482015260640161018a565b611a336001600160a01b038716333088611c2f565b611a3f868686866117e5565b9050611a4b818661242e565b9150505b949350505050565b600080611a6385611c67565b90506001600160a01b038416611acc57846001600160a01b0316631249c58b846040518263ffffffff1660e01b81526004016000604051808303818588803b158015611aae57600080fd5b505af1158015611ac2573d6000803e3d6000fd5b5050505050611b53565b611ad7848685611d9f565b60405163140e25ad60e31b8152600481018490526001600160a01b0386169063a0712d6890602401602060405180830381600087803b158015611b1957600080fd5b505af1158015611b2d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b51919061233b565b505b806114bb86611c67565b6000611bb2826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316611dc89092919063ffffffff16565b805190915015610d215780806020019051810190611bd09190612307565b610d215760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b606482015260840161018a565b6040516001600160a01b038085166024830152831660448201526064810182905261079b9085906323b872dd60e01b906084016113d3565b60006001600160a01b038216611c7e575047919050565b6040516370a0823160e01b81523060048201526001600160a01b038316906370a082319060240160206040518083038186803b158015611cbd57600080fd5b505afa158015611cd1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dc5919061233b565b919050565b604051636eb1769f60e11b81523060048201526001600160a01b038281166024830152839160009183169063dd62ed3e9060440160206040518083038186803b158015611d4657600080fd5b505afa158015611d5a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d7e919061233b565b1115611d8957505050565b610d216001600160a01b03821683600019611dd7565b611db46001600160a01b038416836000611dd7565b610d216001600160a01b0384168383611dd7565b6060611a4f8484600085611efb565b801580611e605750604051636eb1769f60e11b81523060048201526001600160a01b03838116602483015284169063dd62ed3e9060440160206040518083038186803b158015611e2657600080fd5b505afa158015611e3a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e5e919061233b565b155b611ecb5760405162461bcd60e51b815260206004820152603660248201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60448201527520746f206e6f6e2d7a65726f20616c6c6f77616e636560501b606482015260840161018a565b6040516001600160a01b038316602482015260448101829052610d2190849063095ea7b360e01b906064016113d3565b606082471015611f5c5760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161018a565b843b611faa5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161018a565b600080866001600160a01b03168587604051611fc69190612353565b60006040518083038185875af1925050503d8060008114612003576040519150601f19603f3d011682016040523d82523d6000602084013e612008565b606091505b5091509150612018828286612023565b979650505050505050565b6060831561203257508161101e565b8251156120425782518084602001fd5b8160405162461bcd60e51b815260040161018a919061236f565b8035611cf5816124a2565b60008083601f840112612078578182fd5b50813567ffffffffffffffff81111561208f578182fd5b6020830191508360208260051b85010111156120aa57600080fd5b9250929050565b6000602082840312156120c2578081fd5b813561101e816124a2565b6000602082840312156120de578081fd5b815161101e816124a2565b600080604083850312156120fb578081fd5b8235612106816124a2565b91506020830135612116816124a2565b809150509250929050565b60008060408385031215612133578182fd5b823561213e816124a2565b91506020830135612116816124ba565b60008060408385031215612160578182fd5b823561216b816124a2565b946020939093013593505050565b60008060008060008060008060e0898b031215612194578384fd5b883561219f816124a2565b97506020890135965060408901356121b6816124a2565b95506060890135945060808901356121cd816124a2565b935060a089013567ffffffffffffffff808211156121e9578485fd5b818b0191508b601f8301126121fc578485fd5b81358181111561220a578586fd5b8c602082850101111561221b578586fd5b60208301955080945050505061223360c08a0161205c565b90509295985092959890939650565b60008060208385031215612254578182fd5b823567ffffffffffffffff81111561226a578283fd5b61227685828601612067565b90969095509350505050565b60008060008060408587031215612297578384fd5b843567ffffffffffffffff808211156122ae578586fd5b6122ba88838901612067565b909650945060208701359150808211156122d2578384fd5b506122df87828801612067565b95989497509550505050565b6000602082840312156122fc578081fd5b813561101e816124ba565b600060208284031215612318578081fd5b815161101e816124ba565b600060208284031215612334578081fd5b5035919050565b60006020828403121561234c578081fd5b5051919050565b60008251612365818460208701612445565b9190910192915050565b602081526000825180602084015261238e816040850160208701612445565b601f01601f19169190910160400192915050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600082198211156123ea576123ea61248c565b500190565b60008261240a57634e487b7160e01b81526012600452602481fd5b500490565b60008160001904831182151516156124295761242961248c565b500290565b6000828210156124405761244061248c565b500390565b60005b83811015612460578181015183820152602001612448565b8381111561079b5750506000910152565b60006000198214156124855761248561248c565b5060010190565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b03811681146124b757600080fd5b50565b80151581146124b757600080fdfea2646970667358221220063204e59f8aa18f44deb1b2ac2b677aaf59d39a08ceb05e6e765f35bb6d6a5564736f6c6343000804003300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _goodwill (uint256): 0
Arg [1] : _affiliateSplit (uint256): 0

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000000


Block Transaction Difficulty Gas Used Reward
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.