{
    "address": "0xC82e22B0Ef5808DE0F7E9CeB265499e29012b02c",
    "abi": [
        {
            "inputs": [
                {
                    "internalType": "address",
                    "name": "_mastercopy",
                    "type": "address"
                },
                {
                    "internalType": "uint256",
                    "name": "_chainId",
                    "type": "uint256"
                }
            ],
            "stateMutability": "nonpayable",
            "type": "constructor"
        },
        {
            "anonymous": false,
            "inputs": [
                {
                    "indexed": false,
                    "internalType": "address",
                    "name": "channel",
                    "type": "address"
                }
            ],
            "name": "ChannelCreation",
            "type": "event"
        },
        {
            "inputs": [
                {
                    "internalType": "address",
                    "name": "alice",
                    "type": "address"
                },
                {
                    "internalType": "address",
                    "name": "bob",
                    "type": "address"
                }
            ],
            "name": "createChannel",
            "outputs": [
                {
                    "internalType": "address",
                    "name": "channel",
                    "type": "address"
                }
            ],
            "stateMutability": "nonpayable",
            "type": "function"
        },
        {
            "inputs": [
                {
                    "internalType": "address",
                    "name": "alice",
                    "type": "address"
                },
                {
                    "internalType": "address",
                    "name": "bob",
                    "type": "address"
                },
                {
                    "internalType": "address",
                    "name": "assetId",
                    "type": "address"
                },
                {
                    "internalType": "uint256",
                    "name": "amount",
                    "type": "uint256"
                }
            ],
            "name": "createChannelAndDepositAlice",
            "outputs": [
                {
                    "internalType": "address",
                    "name": "channel",
                    "type": "address"
                }
            ],
            "stateMutability": "payable",
            "type": "function"
        },
        {
            "inputs": [],
            "name": "getChainId",
            "outputs": [
                {
                    "internalType": "uint256",
                    "name": "_chainId",
                    "type": "uint256"
                }
            ],
            "stateMutability": "view",
            "type": "function"
        },
        {
            "inputs": [
                {
                    "internalType": "address",
                    "name": "alice",
                    "type": "address"
                },
                {
                    "internalType": "address",
                    "name": "bob",
                    "type": "address"
                }
            ],
            "name": "getChannelAddress",
            "outputs": [
                {
                    "internalType": "address",
                    "name": "",
                    "type": "address"
                }
            ],
            "stateMutability": "view",
            "type": "function"
        },
        {
            "inputs": [],
            "name": "getMastercopy",
            "outputs": [
                {
                    "internalType": "address",
                    "name": "",
                    "type": "address"
                }
            ],
            "stateMutability": "view",
            "type": "function"
        },
        {
            "inputs": [],
            "name": "getProxyCreationCode",
            "outputs": [
                {
                    "internalType": "bytes",
                    "name": "",
                    "type": "bytes"
                }
            ],
            "stateMutability": "view",
            "type": "function"
        },
        {
            "inputs": [],
            "name": "getStoredChainId",
            "outputs": [
                {
                    "internalType": "uint256",
                    "name": "",
                    "type": "uint256"
                }
            ],
            "stateMutability": "view",
            "type": "function"
        }
    ],
    "transactionHash": "0x30caf26d69bae07b0481da0ef8bb11efbc7e73e43d4121d81af5075bd0137055",
    "receipt": {
        "to": null,
        "from": "0x627306090abaB3A6e1400e9345bC60c78a8BEf57",
        "contractAddress": "0xC82e22B0Ef5808DE0F7E9CeB265499e29012b02c",
        "transactionIndex": 9,
        "gasUsed": "677196",
        "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
        "blockHash": "0xd092c79a916bc139f19bc45422f5897be062050277ddbde387af715060ada489",
        "transactionHash": "0x30caf26d69bae07b0481da0ef8bb11efbc7e73e43d4121d81af5075bd0137055",
        "logs": [],
        "blockNumber": 7772114,
        "cumulativeGasUsed": "3111286",
        "status": 1,
        "byzantium": true
    },
    "args": [
        "0xb837e7F32d964469dfB4e9A0652fE2c101bce422",
        "0"
    ],
    "solcInputHash": "89c55d5a88f10637860a9ea31a1daad3",
    "metadata": "{\"compiler\":{\"version\":\"0.7.1+commit.f4a555be\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_mastercopy\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_chainId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"channel\",\"type\":\"address\"}],\"name\":\"ChannelCreation\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"alice\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"bob\",\"type\":\"address\"}],\"name\":\"createChannel\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"channel\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"alice\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"bob\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"assetId\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"createChannelAndDepositAlice\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"channel\",\"type\":\"address\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getChainId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"_chainId\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"alice\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"bob\",\"type\":\"address\"}],\"name\":\"getChannelAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMastercopy\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProxyCreationCode\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getStoredChainId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"author\":\"Connext <support@connext.network>\",\"kind\":\"dev\",\"methods\":{\"constructor\":{\"details\":\"Creates a new `ChannelFactory`\",\"params\":{\"_chainId\":\"the chain identifier when generating the CREATE2 salt. If zero, the chain identifier used in the proxy salt will be the result of the opcode\",\"_mastercopy\":\"the address of the `ChannelMastercopy` (channel logic)\"}},\"createChannel(address,address)\":{\"details\":\"Allows us to create new channel contract and get it all set up in one transaction\",\"params\":{\"alice\":\"address of the high fidelity channel participant\",\"bob\":\"address of the other channel participant\"}},\"createChannelAndDepositAlice(address,address,address,uint256)\":{\"details\":\"Allows us to create a new channel contract and fund it in one transaction\",\"params\":{\"bob\":\"address of the other channel participant\"}},\"getChainId()\":{\"details\":\"Allows us to get the chainId that this factory will use in the create2 salt\"},\"getChannelAddress(address,address)\":{\"details\":\"Allows us to get the address for a new channel contract created via `createChannel`\",\"params\":{\"alice\":\"address of the igh fidelity channel participant\",\"bob\":\"address of the other channel participant\"}},\"getMastercopy()\":{\"details\":\"Allows us to get the mastercopy that this factory will deploy channels against\"},\"getProxyCreationCode()\":{\"details\":\"Returns the proxy code used to both calculate the CREATE2 address and deploy the channel proxy pointed to the `ChannelMastercopy`\"},\"getStoredChainId()\":{\"details\":\"Allows us to get the chainId that this factory has stored\"}},\"title\":\"ChannelFactory\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"notice\":\"Creates and sets up a new channel proxy contract\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"src.sol/ChannelFactory.sol\":\"ChannelFactory\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.7.0;\\n\\n/**\\n * @dev Interface of the ERC20 standard as defined in the EIP.\\n */\\ninterface IERC20 {\\n    /**\\n     * @dev Returns the amount of tokens in existence.\\n     */\\n    function totalSupply() external view returns (uint256);\\n\\n    /**\\n     * @dev Returns the amount of tokens owned by `account`.\\n     */\\n    function balanceOf(address account) external view returns (uint256);\\n\\n    /**\\n     * @dev Moves `amount` tokens from the caller's account to `recipient`.\\n     *\\n     * Returns a boolean value indicating whether the operation succeeded.\\n     *\\n     * Emits a {Transfer} event.\\n     */\\n    function transfer(address recipient, uint256 amount) external returns (bool);\\n\\n    /**\\n     * @dev Returns the remaining number of tokens that `spender` will be\\n     * allowed to spend on behalf of `owner` through {transferFrom}. This is\\n     * zero by default.\\n     *\\n     * This value changes when {approve} or {transferFrom} are called.\\n     */\\n    function allowance(address owner, address spender) external view returns (uint256);\\n\\n    /**\\n     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.\\n     *\\n     * Returns a boolean value indicating whether the operation succeeded.\\n     *\\n     * IMPORTANT: Beware that changing an allowance with this method brings the risk\\n     * that someone may use both the old and the new allowance by unfortunate\\n     * transaction ordering. One possible solution to mitigate this race\\n     * condition is to first reduce the spender's allowance to 0 and set the\\n     * desired value afterwards:\\n     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\\n     *\\n     * Emits an {Approval} event.\\n     */\\n    function approve(address spender, uint256 amount) external returns (bool);\\n\\n    /**\\n     * @dev Moves `amount` tokens from `sender` to `recipient` using the\\n     * allowance mechanism. `amount` is then deducted from the caller's\\n     * allowance.\\n     *\\n     * Returns a boolean value indicating whether the operation succeeded.\\n     *\\n     * Emits a {Transfer} event.\\n     */\\n    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);\\n\\n    /**\\n     * @dev Emitted when `value` tokens are moved from one account (`from`) to\\n     * another (`to`).\\n     *\\n     * Note that `value` may be zero.\\n     */\\n    event Transfer(address indexed from, address indexed to, uint256 value);\\n\\n    /**\\n     * @dev Emitted when the allowance of a `spender` for an `owner` is set by\\n     * a call to {approve}. `value` is the new allowance.\\n     */\\n    event Approval(address indexed owner, address indexed spender, uint256 value);\\n}\\n\",\"keccak256\":\"0xbd74f587ab9b9711801baf667db1426e4a03fd2d7f15af33e0e0d0394e7cef76\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Address.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.7.0;\\n\\n/**\\n * @dev Collection of functions related to the address type\\n */\\nlibrary Address {\\n    /**\\n     * @dev Returns true if `account` is a contract.\\n     *\\n     * [IMPORTANT]\\n     * ====\\n     * It is unsafe to assume that an address for which this function returns\\n     * false is an externally-owned account (EOA) and not a contract.\\n     *\\n     * Among others, `isContract` will return false for the following\\n     * types of addresses:\\n     *\\n     *  - an externally-owned account\\n     *  - a contract in construction\\n     *  - an address where a contract will be created\\n     *  - an address where a contract lived, but was destroyed\\n     * ====\\n     */\\n    function isContract(address account) internal view returns (bool) {\\n        // According to EIP-1052, 0x0 is the value returned for not-yet created accounts\\n        // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned\\n        // for accounts without code, i.e. `keccak256('')`\\n        bytes32 codehash;\\n        bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;\\n        // solhint-disable-next-line no-inline-assembly\\n        assembly { codehash := extcodehash(account) }\\n        return (codehash != accountHash && codehash != 0x0);\\n    }\\n\\n    /**\\n     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to\\n     * `recipient`, forwarding all available gas and reverting on errors.\\n     *\\n     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\\n     * of certain opcodes, possibly making contracts go over the 2300 gas limit\\n     * imposed by `transfer`, making them unable to receive funds via\\n     * `transfer`. {sendValue} removes this limitation.\\n     *\\n     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\\n     *\\n     * IMPORTANT: because control is transferred to `recipient`, care must be\\n     * taken to not create reentrancy vulnerabilities. Consider using\\n     * {ReentrancyGuard} or the\\n     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].\\n     */\\n    function sendValue(address payable recipient, uint256 amount) internal {\\n        require(address(this).balance >= amount, \\\"Address: insufficient balance\\\");\\n\\n        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value\\n        (bool success, ) = recipient.call{ value: amount }(\\\"\\\");\\n        require(success, \\\"Address: unable to send value, recipient may have reverted\\\");\\n    }\\n\\n    /**\\n     * @dev Performs a Solidity function call using a low level `call`. A\\n     * plain`call` is an unsafe replacement for a function call: use this\\n     * function instead.\\n     *\\n     * If `target` reverts with a revert reason, it is bubbled up by this\\n     * function (like regular Solidity function calls).\\n     *\\n     * Returns the raw returned data. To convert to the expected return value,\\n     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\\n     *\\n     * Requirements:\\n     *\\n     * - `target` must be a contract.\\n     * - calling `target` with `data` must not revert.\\n     *\\n     * _Available since v3.1._\\n     */\\n    function functionCall(address target, bytes memory data) internal returns (bytes memory) {\\n      return functionCall(target, data, \\\"Address: low-level call failed\\\");\\n    }\\n\\n    /**\\n     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with\\n     * `errorMessage` as a fallback revert reason when `target` reverts.\\n     *\\n     * _Available since v3.1._\\n     */\\n    function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {\\n        return _functionCallWithValue(target, data, 0, errorMessage);\\n    }\\n\\n    /**\\n     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\\n     * but also transferring `value` wei to `target`.\\n     *\\n     * Requirements:\\n     *\\n     * - the calling contract must have an ETH balance of at least `value`.\\n     * - the called Solidity function must be `payable`.\\n     *\\n     * _Available since v3.1._\\n     */\\n    function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {\\n        return functionCallWithValue(target, data, value, \\\"Address: low-level call with value failed\\\");\\n    }\\n\\n    /**\\n     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but\\n     * with `errorMessage` as a fallback revert reason when `target` reverts.\\n     *\\n     * _Available since v3.1._\\n     */\\n    function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) {\\n        require(address(this).balance >= value, \\\"Address: insufficient balance for call\\\");\\n        return _functionCallWithValue(target, data, value, errorMessage);\\n    }\\n\\n    function _functionCallWithValue(address target, bytes memory data, uint256 weiValue, string memory errorMessage) private returns (bytes memory) {\\n        require(isContract(target), \\\"Address: call to non-contract\\\");\\n\\n        // solhint-disable-next-line avoid-low-level-calls\\n        (bool success, bytes memory returndata) = target.call{ value: weiValue }(data);\\n        if (success) {\\n            return returndata;\\n        } else {\\n            // Look for revert reason and bubble it up if present\\n            if (returndata.length > 0) {\\n                // The easiest way to bubble the revert reason is using memory via assembly\\n\\n                // solhint-disable-next-line no-inline-assembly\\n                assembly {\\n                    let returndata_size := mload(returndata)\\n                    revert(add(32, returndata), returndata_size)\\n                }\\n            } else {\\n                revert(errorMessage);\\n            }\\n        }\\n    }\\n}\\n\",\"keccak256\":\"0x698f929f1097637d051976b322a2d532c27df022b09010e8d091e2888a5ebdf8\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Create2.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.7.0;\\n\\n/**\\n * @dev Helper to make usage of the `CREATE2` EVM opcode easier and safer.\\n * `CREATE2` can be used to compute in advance the address where a smart\\n * contract will be deployed, which allows for interesting new mechanisms known\\n * as 'counterfactual interactions'.\\n *\\n * See the https://eips.ethereum.org/EIPS/eip-1014#motivation[EIP] for more\\n * information.\\n */\\nlibrary Create2 {\\n    /**\\n     * @dev Deploys a contract using `CREATE2`. The address where the contract\\n     * will be deployed can be known in advance via {computeAddress}.\\n     *\\n     * The bytecode for a contract can be obtained from Solidity with\\n     * `type(contractName).creationCode`.\\n     *\\n     * Requirements:\\n     *\\n     * - `bytecode` must not be empty.\\n     * - `salt` must have not been used for `bytecode` already.\\n     * - the factory must have a balance of at least `amount`.\\n     * - if `amount` is non-zero, `bytecode` must have a `payable` constructor.\\n     */\\n    function deploy(uint256 amount, bytes32 salt, bytes memory bytecode) internal returns (address) {\\n        address addr;\\n        require(address(this).balance >= amount, \\\"Create2: insufficient balance\\\");\\n        require(bytecode.length != 0, \\\"Create2: bytecode length is zero\\\");\\n        // solhint-disable-next-line no-inline-assembly\\n        assembly {\\n            addr := create2(amount, add(bytecode, 0x20), mload(bytecode), salt)\\n        }\\n        require(addr != address(0), \\\"Create2: Failed on deploy\\\");\\n        return addr;\\n    }\\n\\n    /**\\n     * @dev Returns the address where a contract will be stored if deployed via {deploy}. Any change in the\\n     * `bytecodeHash` or `salt` will result in a new destination address.\\n     */\\n    function computeAddress(bytes32 salt, bytes32 bytecodeHash) internal view returns (address) {\\n        return computeAddress(salt, bytecodeHash, address(this));\\n    }\\n\\n    /**\\n     * @dev Returns the address where a contract will be stored if deployed via {deploy} from a contract located at\\n     * `deployer`. If `deployer` is this contract's address, returns the same value as {computeAddress}.\\n     */\\n    function computeAddress(bytes32 salt, bytes32 bytecodeHash, address deployer) internal pure returns (address) {\\n        bytes32 _data = keccak256(\\n            abi.encodePacked(bytes1(0xff), deployer, salt, bytecodeHash)\\n        );\\n        return address(uint256(_data));\\n    }\\n}\\n\",\"keccak256\":\"0x539295edd21ad514c0b1a0d1c89ada0831942f379ea83b6eb85769211fc7937e\",\"license\":\"MIT\"},\"src.sol/ChannelFactory.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\nimport \\\"@openzeppelin/contracts/utils/Create2.sol\\\";\\n\\nimport \\\"./interfaces/IChannelFactory.sol\\\";\\nimport \\\"./interfaces/IVectorChannel.sol\\\";\\nimport \\\"./lib/LibAsset.sol\\\";\\nimport \\\"./lib/LibERC20.sol\\\";\\n\\n/// @title ChannelFactory\\n/// @author Connext <support@connext.network>\\n/// @notice Creates and sets up a new channel proxy contract\\ncontract ChannelFactory is IChannelFactory {\\n    // Creation code constants taken from EIP1167\\n    bytes private constant proxyCreationCodePrefix =\\n        hex\\\"3d602d80600a3d3981f3_363d3d373d3d3d363d73\\\";\\n    bytes private constant proxyCreationCodeSuffix =\\n        hex\\\"5af43d82803e903d91602b57fd5bf3\\\";\\n\\n    bytes32 private creationCodeHash;\\n    address private immutable mastercopy;\\n    uint256 private immutable chainId;\\n\\n    /// @dev Creates a new `ChannelFactory`\\n    /// @param _mastercopy the address of the `ChannelMastercopy` (channel logic)\\n    /// @param _chainId the chain identifier when generating the CREATE2 salt. If zero, the chain identifier used in the proxy salt will be the result of the opcode\\n    constructor(address _mastercopy, uint256 _chainId) {\\n        mastercopy = _mastercopy;\\n        chainId = _chainId;\\n        creationCodeHash = keccak256(_getProxyCreationCode(_mastercopy));\\n    }\\n\\n    ////////////////////////////////////////\\n    // Public Methods\\n\\n    /// @dev Allows us to get the mastercopy that this factory will deploy channels against\\n    function getMastercopy() external view override returns (address) {\\n        return mastercopy;\\n    }\\n\\n    /// @dev Allows us to get the chainId that this factory will use in the create2 salt\\n    function getChainId() public view override returns (uint256 _chainId) {\\n        // Hold in memory to reduce sload calls\\n        uint256 chain = chainId;\\n        if (chain == 0) {\\n            assembly {\\n                _chainId := chainid()\\n            }\\n        } else {\\n            _chainId = chain;\\n        }\\n    }\\n\\n    /// @dev Allows us to get the chainId that this factory has stored\\n    function getStoredChainId() external view override returns (uint256) {\\n        return chainId;\\n    }\\n\\n    /// @dev Returns the proxy code used to both calculate the CREATE2 address and deploy the channel proxy pointed to the `ChannelMastercopy`\\n    function getProxyCreationCode()\\n        public\\n        view\\n        override\\n        returns (bytes memory)\\n    {\\n        return _getProxyCreationCode(mastercopy);\\n    }\\n\\n    /// @dev Allows us to get the address for a new channel contract created via `createChannel`\\n    /// @param alice address of the igh fidelity channel participant\\n    /// @param bob address of the other channel participant\\n    function getChannelAddress(address alice, address bob)\\n        external\\n        view\\n        override\\n        returns (address)\\n    {\\n        return\\n            Create2.computeAddress(\\n                generateSalt(alice, bob),\\n                creationCodeHash\\n            );\\n    }\\n\\n    /// @dev Allows us to create new channel contract and get it all set up in one transaction\\n    /// @param alice address of the high fidelity channel participant\\n    /// @param bob address of the other channel participant\\n    function createChannel(address alice, address bob)\\n        public\\n        override\\n        returns (address channel)\\n    {\\n        channel = deployChannelProxy(alice, bob);\\n        IVectorChannel(channel).setup(alice, bob);\\n        emit ChannelCreation(channel);\\n    }\\n\\n    /// @dev Allows us to create a new channel contract and fund it in one transaction\\n    /// @param bob address of the other channel participant\\n    function createChannelAndDepositAlice(\\n        address alice,\\n        address bob,\\n        address assetId,\\n        uint256 amount\\n    ) external payable override returns (address channel) {\\n        channel = createChannel(alice, bob);\\n        // Deposit funds (if a token) must be approved for the\\n        // `ChannelFactory`, which then claims the funds and transfers\\n        // to the channel address. While this is inefficient, this is\\n        // the safest/clearest way to transfer funds\\n        if (!LibAsset.isEther(assetId)) {\\n            require(\\n                LibERC20.transferFrom(\\n                    assetId,\\n                    msg.sender,\\n                    address(this),\\n                    amount\\n                ),\\n                \\\"ChannelFactory: ERC20_TRANSFER_FAILED\\\"\\n            );\\n            require(\\n                LibERC20.approve(assetId, address(channel), amount),\\n                \\\"ChannelFactory: ERC20_APPROVE_FAILED\\\"\\n            );\\n        }\\n        IVectorChannel(channel).depositAlice{value: msg.value}(assetId, amount);\\n    }\\n\\n    ////////////////////////////////////////\\n    // Internal Methods\\n\\n    function _getProxyCreationCode(address _mastercopy) internal pure returns (bytes memory) {\\n      return abi.encodePacked(\\n                proxyCreationCodePrefix,\\n                _mastercopy,\\n                proxyCreationCodeSuffix\\n            );\\n    }\\n\\n    /// @dev Allows us to create new channel contact using CREATE2\\n    /// @param alice address of the high fidelity participant in the channel\\n    /// @param bob address of the other channel participant\\n    function deployChannelProxy(address alice, address bob)\\n        internal\\n        returns (address)\\n    {\\n        bytes32 salt = generateSalt(alice, bob);\\n        return Create2.deploy(0, salt, getProxyCreationCode());\\n    }\\n\\n    /// @dev Generates the unique salt for calculating the CREATE2 address of the channel proxy\\n    function generateSalt(address alice, address bob)\\n        internal\\n        view\\n        returns (bytes32)\\n    {\\n        return keccak256(abi.encodePacked(alice, bob, getChainId()));\\n    }\\n}\\n\",\"keccak256\":\"0x9b30b13dd79eea72eadd2bec3eba0f515929259a21d2ece6b982703c280e532a\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/ICMCAdjudicator.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\nimport \\\"./Types.sol\\\";\\n\\ninterface ICMCAdjudicator {\\n    struct CoreChannelState {\\n        address channelAddress;\\n        address alice;\\n        address bob;\\n        address[] assetIds;\\n        Balance[] balances;\\n        uint256[] processedDepositsA;\\n        uint256[] processedDepositsB;\\n        uint256[] defundNonces;\\n        uint256 timeout;\\n        uint256 nonce;\\n        bytes32 merkleRoot;\\n    }\\n\\n    struct CoreTransferState {\\n        address channelAddress;\\n        bytes32 transferId;\\n        address transferDefinition;\\n        address initiator;\\n        address responder;\\n        address assetId;\\n        Balance balance;\\n        uint256 transferTimeout;\\n        bytes32 initialStateHash;\\n    }\\n\\n    struct ChannelDispute {\\n        bytes32 channelStateHash;\\n        uint256 nonce;\\n        bytes32 merkleRoot;\\n        uint256 consensusExpiry;\\n        uint256 defundExpiry;\\n    }\\n\\n    struct TransferDispute {\\n        bytes32 transferStateHash;\\n        uint256 transferDisputeExpiry;\\n        bool isDefunded;\\n    }\\n\\n    event ChannelDisputed(\\n        address disputer,\\n        CoreChannelState state,\\n        ChannelDispute dispute\\n    );\\n\\n    event ChannelDefunded(\\n        address defunder,\\n        CoreChannelState state,\\n        ChannelDispute dispute,\\n        address[] assetIds\\n    );\\n\\n    event TransferDisputed(\\n        address disputer,\\n        CoreTransferState state,\\n        TransferDispute dispute\\n    );\\n\\n    event TransferDefunded(\\n        address defunder,\\n        CoreTransferState state,\\n        TransferDispute dispute,\\n        bytes encodedInitialState,\\n        bytes encodedResolver,\\n        Balance balance\\n    );\\n\\n    function getChannelDispute() external view returns (ChannelDispute memory);\\n\\n    function getDefundNonce(address assetId) external view returns (uint256);\\n\\n    function getTransferDispute(bytes32 transferId)\\n        external\\n        view\\n        returns (TransferDispute memory);\\n\\n    function disputeChannel(\\n        CoreChannelState calldata ccs,\\n        bytes calldata aliceSignature,\\n        bytes calldata bobSignature\\n    ) external;\\n\\n    function defundChannel(\\n        CoreChannelState calldata ccs,\\n        address[] calldata assetIds,\\n        uint256[] calldata indices\\n    ) external;\\n\\n    function disputeTransfer(\\n        CoreTransferState calldata cts,\\n        bytes32[] calldata merkleProofData\\n    ) external;\\n\\n    function defundTransfer(\\n        CoreTransferState calldata cts,\\n        bytes calldata encodedInitialTransferState,\\n        bytes calldata encodedTransferResolver,\\n        bytes calldata responderSignature\\n    ) external;\\n}\\n\",\"keccak256\":\"0x88522bb51c2b9991b24ef33a3c776ac76d96060ebbc33cd5b2b14513fb21d237\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/ICMCAsset.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\ninterface ICMCAsset {\\n    function getTotalTransferred(address assetId)\\n        external\\n        view\\n        returns (uint256);\\n\\n    function getExitableAmount(address assetId, address owner)\\n        external\\n        view\\n        returns (uint256);\\n\\n    function exit(\\n        address assetId,\\n        address owner,\\n        address payable recipient\\n    ) external;\\n}\\n\",\"keccak256\":\"0x895d89536e8ca469afe642b7001f0dfff497ce29d5d73f862b07a1cdc483f3f7\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/ICMCCore.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\ninterface ICMCCore {\\n    function setup(address _alice, address _bob) external;\\n\\n    function getAlice() external view returns (address);\\n\\n    function getBob() external view returns (address);\\n}\\n\",\"keccak256\":\"0x8e8da2d8fb5198441ba6cdff018dff9e4145b07d575647c990659adad637ec8c\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/ICMCDeposit.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\ninterface ICMCDeposit {\\n    event AliceDeposited(address assetId, uint256 amount);\\n    \\n    function getTotalDepositsAlice(address assetId)\\n        external\\n        view\\n        returns (uint256);\\n\\n    function getTotalDepositsBob(address assetId)\\n        external\\n        view\\n        returns (uint256);\\n\\n    function depositAlice(address assetId, uint256 amount) external payable;\\n}\\n\",\"keccak256\":\"0xdf6f284e44d88013cf9d51220315fb37e63086e470442685891c90aadd138295\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/ICMCWithdraw.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\nstruct WithdrawData {\\n    address channelAddress;\\n    address assetId;\\n    address payable recipient;\\n    uint256 amount;\\n    uint256 nonce;\\n    address callTo;\\n    bytes callData;\\n}\\n\\ninterface ICMCWithdraw {\\n    function getWithdrawalTransactionRecord(WithdrawData calldata wd)\\n        external\\n        view\\n        returns (bool);\\n\\n    function withdraw(\\n        WithdrawData calldata wd,\\n        bytes calldata aliceSignature,\\n        bytes calldata bobSignature\\n    ) external;\\n}\\n\",\"keccak256\":\"0x097dfe95ad19096f9a3dd0138b4a51680c26e665d1639278a7c0a5c9f7fc5c78\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/IChannelFactory.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\ninterface IChannelFactory {\\n    event ChannelCreation(address channel);\\n\\n    function getMastercopy() external view returns (address);\\n\\n    function getChainId() external view returns (uint256);\\n\\n    function getStoredChainId() external view returns (uint256);\\n\\n    function getProxyCreationCode() external view returns (bytes memory);\\n\\n    function getChannelAddress(address alice, address bob)\\n        external\\n        view\\n        returns (address);\\n\\n    function createChannel(address alice, address bob)\\n        external\\n        returns (address);\\n\\n    function createChannelAndDepositAlice(\\n        address alice,\\n        address bob,\\n        address assetId,\\n        uint256 amount\\n    ) external payable returns (address);\\n}\\n\",\"keccak256\":\"0x2330bd554f878feb2494fb9dd830a1707865b63cfd6471a8dad1e5912ebf72ea\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/IVectorChannel.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\nimport \\\"./ICMCCore.sol\\\";\\nimport \\\"./ICMCAsset.sol\\\";\\nimport \\\"./ICMCDeposit.sol\\\";\\nimport \\\"./ICMCWithdraw.sol\\\";\\nimport \\\"./ICMCAdjudicator.sol\\\";\\n\\ninterface IVectorChannel is\\n    ICMCCore,\\n    ICMCAsset,\\n    ICMCDeposit,\\n    ICMCWithdraw,\\n    ICMCAdjudicator\\n{}\\n\",\"keccak256\":\"0x9e21e3b6510bb5aecab999bfcbefe6184bd2be5a80179ef8ecadb63ddd2c8d53\",\"license\":\"UNLICENSED\"},\"src.sol/interfaces/Types.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\nstruct Balance {\\n    uint256[2] amount; // [alice, bob] in channel, [initiator, responder] in transfer\\n    address payable[2] to; // [alice, bob] in channel, [initiator, responder] in transfer\\n}\\n\",\"keccak256\":\"0xf8c71b155b630cde965f5d1db5f0d2751a9763f5a797f15d946613e9224f1046\",\"license\":\"UNLICENSED\"},\"src.sol/lib/LibAsset.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\nimport \\\"./LibERC20.sol\\\";\\nimport \\\"./LibUtils.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC20/IERC20.sol\\\";\\n\\n\\n/// @title LibAsset\\n/// @author Connext <support@connext.network>\\n/// @notice This library contains helpers for dealing with onchain transfers\\n///         of in-channel assets. It is designed to safely handle all asset\\n///         transfers out of channel in the event of an onchain dispute. Also\\n///         safely handles ERC20 transfers that may be non-compliant\\nlibrary LibAsset {\\n    address constant ETHER_ASSETID = address(0);\\n\\n    function isEther(address assetId) internal pure returns (bool) {\\n        return assetId == ETHER_ASSETID;\\n    }\\n\\n    function getOwnBalance(address assetId) internal view returns (uint256) {\\n        return\\n            isEther(assetId)\\n                ? address(this).balance\\n                : IERC20(assetId).balanceOf(address(this));\\n    }\\n\\n    function transferEther(address payable recipient, uint256 amount)\\n        internal\\n        returns (bool)\\n    {\\n        (bool success, bytes memory returnData) =\\n            recipient.call{value: amount}(\\\"\\\");\\n        LibUtils.revertIfCallFailed(success, returnData);\\n        return true;\\n    }\\n\\n    function transferERC20(\\n        address assetId,\\n        address recipient,\\n        uint256 amount\\n    ) internal returns (bool) {\\n        return LibERC20.transfer(assetId, recipient, amount);\\n    }\\n\\n    // This function is a wrapper for transfers of Ether or ERC20 tokens,\\n    // both standard-compliant ones as well as tokens that exhibit the\\n    // missing-return-value bug.\\n    // Although it behaves very much like Solidity's `transfer` function\\n    // or the ERC20 `transfer` and is, in fact, designed to replace direct\\n    // usage of those, it is deliberately named `unregisteredTransfer`,\\n    // because we need to register every transfer out of the channel.\\n    // Therefore, it should normally not be used directly, with the single\\n    // exception of the `transferAsset` function in `CMCAsset.sol`,\\n    // which combines the \\\"naked\\\" unregistered transfer given below\\n    // with a registration.\\n    // USING THIS FUNCTION SOMEWHERE ELSE IS PROBABLY WRONG!\\n    function unregisteredTransfer(\\n        address assetId,\\n        address payable recipient,\\n        uint256 amount\\n    ) internal returns (bool) {\\n        return\\n            isEther(assetId)\\n                ? transferEther(recipient, amount)\\n                : transferERC20(assetId, recipient, amount);\\n    }\\n}\\n\",\"keccak256\":\"0x02e7b660846ad2f56f8005f786e0e2eb1d625c83f4cfcf9fc07a9566ca86195c\",\"license\":\"UNLICENSED\"},\"src.sol/lib/LibERC20.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\nimport \\\"./LibUtils.sol\\\";\\nimport \\\"@openzeppelin/contracts/utils/Address.sol\\\";\\n\\n/// @title LibERC20\\n/// @author Connext <support@connext.network>\\n/// @notice This library provides several functions to safely handle\\n///         noncompliant tokens (i.e. does not return a boolean from\\n///         the transfer function)\\n\\nlibrary LibERC20 {\\n    function wrapCall(address assetId, bytes memory callData)\\n        internal\\n        returns (bool)\\n    {\\n        require(Address.isContract(assetId), \\\"LibERC20: NO_CODE\\\");\\n        (bool success, bytes memory returnData) = assetId.call(callData);\\n        LibUtils.revertIfCallFailed(success, returnData);\\n        return returnData.length == 0 || abi.decode(returnData, (bool));\\n    }\\n\\n    function approve(\\n        address assetId,\\n        address spender,\\n        uint256 amount\\n    ) internal returns (bool) {\\n        return\\n            wrapCall(\\n                assetId,\\n                abi.encodeWithSignature(\\n                    \\\"approve(address,uint256)\\\",\\n                    spender,\\n                    amount\\n                )\\n            );\\n    }\\n\\n    function transferFrom(\\n        address assetId,\\n        address sender,\\n        address recipient,\\n        uint256 amount\\n    ) internal returns (bool) {\\n        return\\n            wrapCall(\\n                assetId,\\n                abi.encodeWithSignature(\\n                    \\\"transferFrom(address,address,uint256)\\\",\\n                    sender,\\n                    recipient,\\n                    amount\\n                )\\n            );\\n    }\\n\\n    function transfer(\\n        address assetId,\\n        address recipient,\\n        uint256 amount\\n    ) internal returns (bool) {\\n        return\\n            wrapCall(\\n                assetId,\\n                abi.encodeWithSignature(\\n                    \\\"transfer(address,uint256)\\\",\\n                    recipient,\\n                    amount\\n                )\\n            );\\n    }\\n}\\n\",\"keccak256\":\"0x5bad1474c93a295939c23f976786f0d086abc063f19ff9c8c1d069759c4a7ff5\",\"license\":\"UNLICENSED\"},\"src.sol/lib/LibUtils.sol\":{\"content\":\"// SPDX-License-Identifier: UNLICENSED\\npragma solidity ^0.7.1;\\npragma experimental ABIEncoderV2;\\n\\n/// @title LibUtils\\n/// @author Connext <support@connext.network>\\n/// @notice Contains a helper to revert if a call was not successfully\\n///         made\\nlibrary LibUtils {\\n    // If success is false, reverts and passes on the revert string.\\n    function revertIfCallFailed(bool success, bytes memory returnData)\\n        internal\\n        pure\\n    {\\n        if (!success) {\\n            assembly {\\n                revert(add(returnData, 0x20), mload(returnData))\\n            }\\n        }\\n    }\\n}\\n\",\"keccak256\":\"0xf31897ed92b88739ca9c6e74d089e01c5dbf432183d2ab0b959b539842374ccd\",\"license\":\"UNLICENSED\"}},\"version\":1}",
    "bytecode": "0x60c060405234801561001057600080fd5b50604051610c8f380380610c8f83398101604081905261002f916100eb565b6001600160601b0319606083901b1660805260a081905261004f82610062565b8051602090910120600055506101909050565b60606040518060400160405280601481526020017f3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000815250826040518060400160405280600f81526020016e5af43d82803e903d91602b57fd5bf360881b8152506040516020016100d59392919061015c565b6040516020818303038152906040529050919050565b600080604083850312156100fd578182fd5b82516001600160a01b0381168114610113578283fd5b6020939093015192949293505050565b60008151815b818110156101435760208185018101518683015201610129565b818111156101515782828601525b509290920192915050565b60006101688286610123565b606085901b6001600160601b03191681526101866014820185610123565b9695505050505050565b60805160601c60a051610acf6101c06000398061017e52806101a452508061015352806102a65250610acf6000f3fe6080604052600436106100705760003560e01c806335a1ba6f1161004e57806335a1ba6f146100d7578063e617aaac14610104578063efe4369314610124578063fe4545011461013957610070565b806315727e911461007557806332a130c9146100a05780633408e470146100c2575b600080fd5b34801561008157600080fd5b5061008a61014c565b60405161009791906108d6565b60405180910390f35b3480156100ac57600080fd5b506100b561017c565b6040516100979190610a60565b3480156100ce57600080fd5b506100b56101a0565b3480156100e357600080fd5b506100f76100f2366004610703565b6101d8565b604051610097919061086b565b34801561011057600080fd5b506100f761011f366004610703565b610284565b34801561013057600080fd5b506100f76102a4565b6100f7610147366004610737565b6102c8565b60606101777f00000000000000000000000000000000000000000000000000000000000000006103a5565b905090565b7f000000000000000000000000000000000000000000000000000000000000000090565b60007f0000000000000000000000000000000000000000000000000000000000000000806101d0574691506101d4565b8091505b5090565b60006101e48383610425565b604051632d34ba7960e01b81529091506001600160a01b03821690632d34ba7990610215908690869060040161087f565b600060405180830381600087803b15801561022f57600080fd5b505af1158015610243573d6000803e3d6000fd5b505050507fa79ba8cc5fdc29196c8d65701a02433c92328f38f0ffbea3908335b80d81409d81604051610276919061086b565b60405180910390a192915050565b600061029b610293848461044f565b60005461048b565b90505b92915050565b7f000000000000000000000000000000000000000000000000000000000000000090565b60006102d485856101d8565b90506102df83610498565b61033b576102ef833330856104a5565b6103145760405162461bcd60e51b815260040161030b906109e4565b60405180910390fd5b61031f8382846104f8565b61033b5760405162461bcd60e51b815260040161030b906109a0565b60405163635ae90160e01b81526001600160a01b0382169063635ae90190349061036b90879087906004016108bd565b6000604051808303818588803b15801561038457600080fd5b505af1158015610398573d6000803e3d6000fd5b5050505050949350505050565b6060604051806040016040528060148152602001733d602d80600a3d3981f3363d3d373d3d3d363d7360601b815250826040518060400160405280600f81526020016e5af43d82803e903d91602b57fd5bf360881b81525060405160200161040f93929190610824565b6040516020818303038152906040529050919050565b600080610432848461044f565b905061044760008261044261014c565b610540565b949350505050565b6000828261045b6101a0565b60405160200161046d939291906107ab565b60405160208183030381529060405280519060200120905092915050565b600061029b8383306105b2565b6001600160a01b03161590565b60006104ef858585856040516024016104c093929190610899565b60408051601f198184030181529190526020810180516001600160e01b03166323b872dd60e01b1790526105f1565b95945050505050565b60006104478484846040516024016105119291906108bd565b60408051601f198184030181529190526020810180516001600160e01b031663095ea7b360e01b1790526105f1565b600080844710156105635760405162461bcd60e51b815260040161030b90610a29565b82516105815760405162461bcd60e51b815260040161030b90610909565b8383516020850187f590506001600160a01b0381166104475760405162461bcd60e51b815260040161030b9061093e565b60008060ff60f81b8386866040516020016105d094939291906107d4565b60408051808303601f19018152919052805160209091012095945050505050565b60006105fc836106a2565b6106185760405162461bcd60e51b815260040161030b90610975565b60006060846001600160a01b0316846040516106349190610808565b6000604051808303816000865af19150503d8060008114610671576040519150601f19603f3d011682016040523d82523d6000602084013e610676565b606091505b509150915061068582826106db565b805115806104ef5750808060200190518101906104ef9190610784565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470818114801590610447575050151592915050565b816106e857805160208201fd5b5050565b80356001600160a01b038116811461029e57600080fd5b60008060408385031215610715578182fd5b61071f84846106ec565b915061072e84602085016106ec565b90509250929050565b6000806000806080858703121561074c578182fd5b61075686866106ec565b935061076586602087016106ec565b925061077486604087016106ec565b9396929550929360600135925050565b600060208284031215610795578081fd5b815180151581146107a4578182fd5b9392505050565b6001600160601b0319606094851b811682529290931b9091166014830152602882015260480190565b6001600160f81b031994909416845260609290921b6001600160601b03191660018401526015830152603582015260550190565b6000825161081a818460208701610a69565b9190910192915050565b60008451610836818460208901610a69565b606085901b6001600160601b031916908301908152835161085e816014840160208801610a69565b0160140195945050505050565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b03929092168252602082015260400190565b60006020825282518060208401526108f5816040850160208701610a69565b601f01601f19169190910160400192915050565b6020808252818101527f437265617465323a2062797465636f6465206c656e677468206973207a65726f604082015260600190565b60208082526019908201527f437265617465323a204661696c6564206f6e206465706c6f7900000000000000604082015260600190565b6020808252601190820152704c696245524332303a204e4f5f434f444560781b604082015260600190565b60208082526024908201527f4368616e6e656c466163746f72793a2045524332305f415050524f56455f46416040820152631253115160e21b606082015260800190565b60208082526025908201527f4368616e6e656c466163746f72793a2045524332305f5452414e534645525f46604082015264105253115160da1b606082015260800190565b6020808252601d908201527f437265617465323a20696e73756666696369656e742062616c616e6365000000604082015260600190565b90815260200190565b60005b83811015610a84578181015183820152602001610a6c565b83811115610a93576000848401525b5050505056fea26469706673582212206b46714e4e157ca4fcef5f14f882cae62cdcfb5e301602c8361ab37a1daaf2ab64736f6c63430007010033",
    "deployedBytecode": "0x6080604052600436106100705760003560e01c806335a1ba6f1161004e57806335a1ba6f146100d7578063e617aaac14610104578063efe4369314610124578063fe4545011461013957610070565b806315727e911461007557806332a130c9146100a05780633408e470146100c2575b600080fd5b34801561008157600080fd5b5061008a61014c565b60405161009791906108d6565b60405180910390f35b3480156100ac57600080fd5b506100b561017c565b6040516100979190610a60565b3480156100ce57600080fd5b506100b56101a0565b3480156100e357600080fd5b506100f76100f2366004610703565b6101d8565b604051610097919061086b565b34801561011057600080fd5b506100f761011f366004610703565b610284565b34801561013057600080fd5b506100f76102a4565b6100f7610147366004610737565b6102c8565b60606101777f00000000000000000000000000000000000000000000000000000000000000006103a5565b905090565b7f000000000000000000000000000000000000000000000000000000000000000090565b60007f0000000000000000000000000000000000000000000000000000000000000000806101d0574691506101d4565b8091505b5090565b60006101e48383610425565b604051632d34ba7960e01b81529091506001600160a01b03821690632d34ba7990610215908690869060040161087f565b600060405180830381600087803b15801561022f57600080fd5b505af1158015610243573d6000803e3d6000fd5b505050507fa79ba8cc5fdc29196c8d65701a02433c92328f38f0ffbea3908335b80d81409d81604051610276919061086b565b60405180910390a192915050565b600061029b610293848461044f565b60005461048b565b90505b92915050565b7f000000000000000000000000000000000000000000000000000000000000000090565b60006102d485856101d8565b90506102df83610498565b61033b576102ef833330856104a5565b6103145760405162461bcd60e51b815260040161030b906109e4565b60405180910390fd5b61031f8382846104f8565b61033b5760405162461bcd60e51b815260040161030b906109a0565b60405163635ae90160e01b81526001600160a01b0382169063635ae90190349061036b90879087906004016108bd565b6000604051808303818588803b15801561038457600080fd5b505af1158015610398573d6000803e3d6000fd5b5050505050949350505050565b6060604051806040016040528060148152602001733d602d80600a3d3981f3363d3d373d3d3d363d7360601b815250826040518060400160405280600f81526020016e5af43d82803e903d91602b57fd5bf360881b81525060405160200161040f93929190610824565b6040516020818303038152906040529050919050565b600080610432848461044f565b905061044760008261044261014c565b610540565b949350505050565b6000828261045b6101a0565b60405160200161046d939291906107ab565b60405160208183030381529060405280519060200120905092915050565b600061029b8383306105b2565b6001600160a01b03161590565b60006104ef858585856040516024016104c093929190610899565b60408051601f198184030181529190526020810180516001600160e01b03166323b872dd60e01b1790526105f1565b95945050505050565b60006104478484846040516024016105119291906108bd565b60408051601f198184030181529190526020810180516001600160e01b031663095ea7b360e01b1790526105f1565b600080844710156105635760405162461bcd60e51b815260040161030b90610a29565b82516105815760405162461bcd60e51b815260040161030b90610909565b8383516020850187f590506001600160a01b0381166104475760405162461bcd60e51b815260040161030b9061093e565b60008060ff60f81b8386866040516020016105d094939291906107d4565b60408051808303601f19018152919052805160209091012095945050505050565b60006105fc836106a2565b6106185760405162461bcd60e51b815260040161030b90610975565b60006060846001600160a01b0316846040516106349190610808565b6000604051808303816000865af19150503d8060008114610671576040519150601f19603f3d011682016040523d82523d6000602084013e610676565b606091505b509150915061068582826106db565b805115806104ef5750808060200190518101906104ef9190610784565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470818114801590610447575050151592915050565b816106e857805160208201fd5b5050565b80356001600160a01b038116811461029e57600080fd5b60008060408385031215610715578182fd5b61071f84846106ec565b915061072e84602085016106ec565b90509250929050565b6000806000806080858703121561074c578182fd5b61075686866106ec565b935061076586602087016106ec565b925061077486604087016106ec565b9396929550929360600135925050565b600060208284031215610795578081fd5b815180151581146107a4578182fd5b9392505050565b6001600160601b0319606094851b811682529290931b9091166014830152602882015260480190565b6001600160f81b031994909416845260609290921b6001600160601b03191660018401526015830152603582015260550190565b6000825161081a818460208701610a69565b9190910192915050565b60008451610836818460208901610a69565b606085901b6001600160601b031916908301908152835161085e816014840160208801610a69565b0160140195945050505050565b6001600160a01b0391909116815260200190565b6001600160a01b0392831681529116602082015260400190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b03929092168252602082015260400190565b60006020825282518060208401526108f5816040850160208701610a69565b601f01601f19169190910160400192915050565b6020808252818101527f437265617465323a2062797465636f6465206c656e677468206973207a65726f604082015260600190565b60208082526019908201527f437265617465323a204661696c6564206f6e206465706c6f7900000000000000604082015260600190565b6020808252601190820152704c696245524332303a204e4f5f434f444560781b604082015260600190565b60208082526024908201527f4368616e6e656c466163746f72793a2045524332305f415050524f56455f46416040820152631253115160e21b606082015260800190565b60208082526025908201527f4368616e6e656c466163746f72793a2045524332305f5452414e534645525f46604082015264105253115160da1b606082015260800190565b6020808252601d908201527f437265617465323a20696e73756666696369656e742062616c616e6365000000604082015260600190565b90815260200190565b60005b83811015610a84578181015183820152602001610a6c565b83811115610a93576000848401525b5050505056fea26469706673582212206b46714e4e157ca4fcef5f14f882cae62cdcfb5e301602c8361ab37a1daaf2ab64736f6c63430007010033",
    "devdoc": {
        "author": "Connext <support@connext.network>",
        "kind": "dev",
        "methods": {
            "constructor": {
                "details": "Creates a new `ChannelFactory`",
                "params": {
                    "_chainId": "the chain identifier when generating the CREATE2 salt. If zero, the chain identifier used in the proxy salt will be the result of the opcode",
                    "_mastercopy": "the address of the `ChannelMastercopy` (channel logic)"
                }
            },
            "createChannel(address,address)": {
                "details": "Allows us to create new channel contract and get it all set up in one transaction",
                "params": {
                    "alice": "address of the high fidelity channel participant",
                    "bob": "address of the other channel participant"
                }
            },
            "createChannelAndDepositAlice(address,address,address,uint256)": {
                "details": "Allows us to create a new channel contract and fund it in one transaction",
                "params": {
                    "bob": "address of the other channel participant"
                }
            },
            "getChainId()": {
                "details": "Allows us to get the chainId that this factory will use in the create2 salt"
            },
            "getChannelAddress(address,address)": {
                "details": "Allows us to get the address for a new channel contract created via `createChannel`",
                "params": {
                    "alice": "address of the igh fidelity channel participant",
                    "bob": "address of the other channel participant"
                }
            },
            "getMastercopy()": {
                "details": "Allows us to get the mastercopy that this factory will deploy channels against"
            },
            "getProxyCreationCode()": {
                "details": "Returns the proxy code used to both calculate the CREATE2 address and deploy the channel proxy pointed to the `ChannelMastercopy`"
            },
            "getStoredChainId()": {
                "details": "Allows us to get the chainId that this factory has stored"
            }
        },
        "title": "ChannelFactory",
        "version": 1
    },
    "userdoc": {
        "kind": "user",
        "methods": {},
        "notice": "Creates and sets up a new channel proxy contract",
        "version": 1
    },
    "storageLayout": {
        "storage": [
            {
                "astId": 3100,
                "contract": "src.sol/ChannelFactory.sol:ChannelFactory",
                "label": "creationCodeHash",
                "offset": 0,
                "slot": "0",
                "type": "t_bytes32"
            }
        ],
        "types": {
            "t_bytes32": {
                "encoding": "inplace",
                "label": "bytes32",
                "numberOfBytes": "32"
            }
        }
    }
}
