From f87209ee9d368e7275811a55fc87127517b877c8 Mon Sep 17 00:00:00 2001 From: Santo Sinar Pandean Date: Tue, 23 Jan 2024 21:05:07 +0700 Subject: [PATCH] add MocIntegration deployment file testnet --- deployment/deploy/6_MocIntegration.ts | 2 +- .../rskSovrynTestnet/MocIntegration.json | 150 ++++++++++++++- .../MocIntegration_Implementation.json | 173 ++++++++++++++++-- 3 files changed, 301 insertions(+), 24 deletions(-) diff --git a/deployment/deploy/6_MocIntegration.ts b/deployment/deploy/6_MocIntegration.ts index 647c1fb..4879274 100644 --- a/deployment/deploy/6_MocIntegration.ts +++ b/deployment/deploy/6_MocIntegration.ts @@ -37,7 +37,7 @@ const func: DeployFunction = async ({ deployments, getNamedAccounts }) => { `${deploymentName}_Proxy`, "MyntAdminProxy", false, - [mocAddress, docAddress, dllrAddress, massetManagerAddress] + [mocAddress, docAddress, dllrAddress, massetManagerAddress, permit2Address] ); } else { await deploy(deploymentName, { diff --git a/deployment/deployments/rskSovrynTestnet/MocIntegration.json b/deployment/deployments/rskSovrynTestnet/MocIntegration.json index 4684a22..085b315 100644 --- a/deployment/deployments/rskSovrynTestnet/MocIntegration.json +++ b/deployment/deployments/rskSovrynTestnet/MocIntegration.json @@ -22,6 +22,11 @@ "internalType": "address", "name": "_massetManager", "type": "address" + }, + { + "internalType": "address", + "name": "_permit2", + "type": "address" } ], "stateMutability": "nonpayable", @@ -62,6 +67,12 @@ { "anonymous": false, "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, { "indexed": false, "internalType": "uint256", @@ -202,6 +213,72 @@ "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { + "components": [ + { + "components": [ + { + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct ISignatureTransfer.TokenPermissions", + "name": "permitted", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "nonce", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "deadline", + "type": "uint256" + } + ], + "internalType": "struct ISignatureTransfer.PermitTransferFrom", + "name": "permit", + "type": "tuple" + }, + { + "internalType": "bytes", + "name": "signature", + "type": "bytes" + } + ], + "name": "getDocFromDllrAndRedeemRbtcWithPermit2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_address", + "type": "address" + } + ], + "name": "getPermit2Nonce", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [], "name": "getProxyImplementation", @@ -280,6 +357,19 @@ "stateMutability": "view", "type": "function" }, + { + "inputs": [], + "name": "permit2", + "outputs": [ + { + "internalType": "contract IPermit2", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [], "name": "renounceOwnership", @@ -318,10 +408,10 @@ "type": "receive" } ], - "numDeployments": 4, - "bytecode": "0x61010060405234801561001157600080fd5b50604051610c80380380610c8083398101604081905261003091610119565b6001600160a01b0384161580159061005057506001600160a01b03831615155b801561006457506001600160a01b03821615155b801561007857506001600160a01b03811615155b6100db5760405162461bcd60e51b815260206004820152602a60248201527f4d6f63496e746567726174696f6e3a3a206e6f206e756c6c2061646472657373604482015269195cc8185b1b1bddd95960b21b606482015260840160405180910390fd5b6001600160a01b0393841660805291831660a052821660c0521660e05261016d565b80516001600160a01b038116811461011457600080fd5b919050565b6000806000806080858703121561012f57600080fd5b610138856100fd565b9350610146602086016100fd565b9250610154604086016100fd565b9150610162606086016100fd565b905092959194509250565b60805160a05160c05160e051610abf6101c1600039600081816101eb01526103ab01526000818160c90152610298015260008181610184015261037101526000818161013b01526104b00152610abf6000f3fe6080604052600436106100ab5760003560e01c806390e4b7201161006457806390e4b720146101c4578063b5c89bab146101d9578063c4d66de81461020d578063e50855171461022d578063f2fde38b1461024d578063fc1768191461026d57600080fd5b806333c507ae146100b7578063460f2de1146101075780635342825314610129578063715018a61461015d5780637a0a3ac5146101725780638da5cb5b146101a657600080fd5b366100b257005b600080fd5b3480156100c357600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b03909116815260200160405180910390f35b34801561011357600080fd5b5061012761012236600461096a565b61028d565b005b34801561013557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561016957600080fd5b5061012761061a565b34801561017e57600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101b257600080fd5b506033546001600160a01b03166100eb565b3480156101d057600080fd5b506100eb61062e565b3480156101e557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561021957600080fd5b506101276102283660046109b7565b610666565b34801561023957600080fd5b506101276102483660046109b7565b610781565b34801561025957600080fd5b506101276102683660046109b7565b610795565b34801561027957600080fd5b506097546100eb906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356102d26040890160208a016109db565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561034457600080fd5b505af1158015610358573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156103f5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061041991906109fe565b146104825760405162461bcd60e51b815260206004820152602e60248201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260448201526d1958dd08111bd0c8185b5bdd5b9d60921b60648201526084015b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156104f457600080fd5b505af1158015610508573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105249190610a17565b604051909150600090339083908381818185875af1925050503d8060008114610569576040519150601f19603f3d011682016040523d82523d6000602084013e61056e565b606091505b50509050806105d95760405162461bcd60e51b815260206004820152603160248201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604482015270696e672072656465656d6564205242544360781b6064820152608401610479565b60408051878152602081018490527f9d8e423b23af97e1b68e81e339269059cbacc1c8754155bf6f0fd3e5adf8abe8910160405180910390a1505050505050565b61062261080b565b61062c6000610865565b565b60006106617f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b600054610100900460ff16158080156106865750600054600160ff909116105b806106a05750303b1580156106a0575060005460ff166001145b6107035760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610479565b6000805460ff191660011790558015610726576000805461ff0019166101001790555b61072e6108b7565b610737826108e6565b801561077d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b61078961080b565b610792816108e6565b50565b61079d61080b565b6001600160a01b0381166108025760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610479565b61079281610865565b6033546001600160a01b0316331461062c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610479565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166108de5760405162461bcd60e51b815260040161047990610a3e565b61062c61093a565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff166109615760405162461bcd60e51b815260040161047990610a3e565b61062c33610865565b60008082840360a081121561097e57600080fd5b833592506080601f198201121561099457600080fd5b506020830190509250929050565b6001600160a01b038116811461079257600080fd5b6000602082840312156109c957600080fd5b81356109d4816109a2565b9392505050565b6000602082840312156109ed57600080fd5b813560ff811681146109d457600080fd5b600060208284031215610a1057600080fd5b5051919050565b81810381811115610a3857634e487b7160e01b600052601160045260246000fd5b92915050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea26469706673582212202a5366146f46faa5442344d8b38cb389baf682ed6006aecb0bc51ebfd3050eaa64736f6c63430008110033", - "deployedBytecode": "0x6080604052600436106100ab5760003560e01c806390e4b7201161006457806390e4b720146101c4578063b5c89bab146101d9578063c4d66de81461020d578063e50855171461022d578063f2fde38b1461024d578063fc1768191461026d57600080fd5b806333c507ae146100b7578063460f2de1146101075780635342825314610129578063715018a61461015d5780637a0a3ac5146101725780638da5cb5b146101a657600080fd5b366100b257005b600080fd5b3480156100c357600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b03909116815260200160405180910390f35b34801561011357600080fd5b5061012761012236600461096a565b61028d565b005b34801561013557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561016957600080fd5b5061012761061a565b34801561017e57600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101b257600080fd5b506033546001600160a01b03166100eb565b3480156101d057600080fd5b506100eb61062e565b3480156101e557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561021957600080fd5b506101276102283660046109b7565b610666565b34801561023957600080fd5b506101276102483660046109b7565b610781565b34801561025957600080fd5b506101276102683660046109b7565b610795565b34801561027957600080fd5b506097546100eb906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356102d26040890160208a016109db565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561034457600080fd5b505af1158015610358573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156103f5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061041991906109fe565b146104825760405162461bcd60e51b815260206004820152602e60248201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260448201526d1958dd08111bd0c8185b5bdd5b9d60921b60648201526084015b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156104f457600080fd5b505af1158015610508573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105249190610a17565b604051909150600090339083908381818185875af1925050503d8060008114610569576040519150601f19603f3d011682016040523d82523d6000602084013e61056e565b606091505b50509050806105d95760405162461bcd60e51b815260206004820152603160248201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604482015270696e672072656465656d6564205242544360781b6064820152608401610479565b60408051878152602081018490527f9d8e423b23af97e1b68e81e339269059cbacc1c8754155bf6f0fd3e5adf8abe8910160405180910390a1505050505050565b61062261080b565b61062c6000610865565b565b60006106617f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b600054610100900460ff16158080156106865750600054600160ff909116105b806106a05750303b1580156106a0575060005460ff166001145b6107035760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610479565b6000805460ff191660011790558015610726576000805461ff0019166101001790555b61072e6108b7565b610737826108e6565b801561077d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b61078961080b565b610792816108e6565b50565b61079d61080b565b6001600160a01b0381166108025760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610479565b61079281610865565b6033546001600160a01b0316331461062c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610479565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166108de5760405162461bcd60e51b815260040161047990610a3e565b61062c61093a565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff166109615760405162461bcd60e51b815260040161047990610a3e565b61062c33610865565b60008082840360a081121561097e57600080fd5b833592506080601f198201121561099457600080fd5b506020830190509250929050565b6001600160a01b038116811461079257600080fd5b6000602082840312156109c957600080fd5b81356109d4816109a2565b9392505050565b6000602082840312156109ed57600080fd5b813560ff811681146109d457600080fd5b600060208284031215610a1057600080fd5b5051919050565b81810381811115610a3857634e487b7160e01b600052601160045260246000fd5b92915050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea26469706673582212202a5366146f46faa5442344d8b38cb389baf682ed6006aecb0bc51ebfd3050eaa64736f6c63430008110033", - "implementation": "0x17DC9E96c814C041351EE07a9AA29A7Fe100d859", + "numDeployments": 5, + "bytecode": "0x6101206040523480156200001257600080fd5b506040516200132938038062001329833981016040819052620000359162000140565b6001600160a01b038516158015906200005657506001600160a01b03841615155b80156200006b57506001600160a01b03831615155b80156200008057506001600160a01b03821615155b80156200009557506001600160a01b03811615155b620000f95760405162461bcd60e51b815260206004820152602a60248201527f4d6f63496e746567726174696f6e3a3a206e6f206e756c6c2061646472657373604482015269195cc8185b1b1bddd95960b21b606482015260840160405180910390fd5b6001600160a01b0394851660805292841660a05290831660c052821660e0521661010052620001b0565b80516001600160a01b03811681146200013b57600080fd5b919050565b600080600080600060a086880312156200015957600080fd5b620001648662000123565b9450620001746020870162000123565b9350620001846040870162000123565b9250620001946060870162000123565b9150620001a46080870162000123565b90509295509295909350565b60805160a05160c05160e051610100516110fc6200022d6000396000818161010a01526106f80152600081816102af0152818161046f01526107dd01526000818161015b015261035c0152600081816102280152818161043501526107a40152600081816101b101528181610531015261089701526110fc6000f3fe6080604052600436106100ec5760003560e01c80638da5cb5b1161008a578063c4d66de811610059578063c4d66de8146102d1578063e5085517146102f1578063f2fde38b14610311578063fc1768191461033157600080fd5b80638da5cb5b1461024a57806390e4b720146102685780639b2633ae1461027d578063b5c89bab1461029d57600080fd5b806353428253116100c6578063534282531461019f57806366960ead146101d3578063715018a6146102015780637a0a3ac51461021657600080fd5b806312261ee7146100f857806333c507ae14610149578063460f2de11461017d57600080fd5b366100f357005b600080fd5b34801561010457600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b34801561015557600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561018957600080fd5b5061019d610198366004610cbf565b610351565b005b3480156101ab57600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101df57600080fd5b506101f36101ee366004610d0c565b610653565b604051908152602001610140565b34801561020d57600080fd5b5061019d610673565b34801561022257600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561025657600080fd5b506033546001600160a01b031661012c565b34801561027457600080fd5b5061012c610687565b34801561028957600080fd5b5061019d610298366004610dfc565b6106bf565b3480156102a957600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102dd57600080fd5b5061019d6102ec366004610d0c565b6109bb565b3480156102fd57600080fd5b5061019d61030c366004610d0c565b610ad6565b34801561031d57600080fd5b5061019d61032c366004610d0c565b610aea565b34801561033d57600080fd5b5060975461012c906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356103966040890160208a01610ebf565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561040857600080fd5b505af115801561041c573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156104b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104dd9190610ee2565b146105035760405162461bcd60e51b81526004016104fa90610efb565b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b15801561057557600080fd5b505af1158015610589573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105a59190610f49565b604051909150600090339083908381818185875af1925050503d80600081146105ea576040519150601f19603f3d011682016040523d82523d6000602084013e6105ef565b606091505b50509050806106105760405162461bcd60e51b81526004016104fa90610f6a565b604080518781526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a2505050505050565b6001600160a01b0381166000908152609860205260408120545b92915050565b61067b610b60565b6106856000610bba565b565b60006106ba7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b81516020908101516040805180820182526000808252908401528051808201825230808252938101839052905163187945bd60e11b81527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906330f28b7a9061073b908890859033908a90600401610fbb565b600060405180830381600087803b15801561075557600080fd5b505af1158015610769573d6000803e3d6000fd5b5050336000908152609860205260409020805460018101909155915061078c9050565b5060405163fb2c922360e01b81526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116600483015260248201849052848116604483015283917f00000000000000000000000000000000000000000000000000000000000000009091169063fb2c9223906064016020604051808303816000875af1158015610828573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061084c9190610ee2565b146108695760405162461bcd60e51b81526004016104fa90610efb565b60975460405163b7aa53e760e01b8152600481018490526001600160a01b03918216602482015284821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156108db57600080fd5b505af11580156108ef573d6000803e3d6000fd5b50505050600081856001600160a01b03163161090b9190610f49565b604051909150600090339083908381818185875af1925050503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b50509050806109765760405162461bcd60e51b81526004016104fa90610f6a565b604080518681526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a25050505050505050565b600054610100900460ff16158080156109db5750600054600160ff909116105b806109f55750303b1580156109f5575060005460ff166001145b610a585760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104fa565b6000805460ff191660011790558015610a7b576000805461ff0019166101001790555b610a83610c0c565b610a8c82610c3b565b8015610ad2576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b610ade610b60565b610ae781610c3b565b50565b610af2610b60565b6001600160a01b038116610b575760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016104fa565b610ae781610bba565b6033546001600160a01b031633146106855760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104fa565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16610c335760405162461bcd60e51b81526004016104fa9061107b565b610685610c8f565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff16610cb65760405162461bcd60e51b81526004016104fa9061107b565b61068533610bba565b60008082840360a0811215610cd357600080fd5b833592506080601f1982011215610ce957600080fd5b506020830190509250929050565b6001600160a01b0381168114610ae757600080fd5b600060208284031215610d1e57600080fd5b8135610d2981610cf7565b9392505050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610d6957610d69610d30565b60405290565b600082601f830112610d8057600080fd5b813567ffffffffffffffff80821115610d9b57610d9b610d30565b604051601f8301601f19908116603f01168101908282118183101715610dc357610dc3610d30565b81604052838152866020858801011115610ddc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b60008082840360a0811215610e1057600080fd5b6080811215610e1e57600080fd5b6040516060810167ffffffffffffffff8282108183111715610e4257610e42610d30565b816040526040841215610e5457600080fd5b610e5c610d46565b935086359150610e6b82610cf7565b8184526020870135602085015283835260408701356020840152606087013560408401528295506080870135935080841115610ea657600080fd5b505050610eb585828601610d6f565b9150509250929050565b600060208284031215610ed157600080fd5b813560ff81168114610d2957600080fd5b600060208284031215610ef457600080fd5b5051919050565b6020808252602e908201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260408201526d1958dd08111bd0c8185b5bdd5b9d60921b606082015260800190565b8181038181111561066d57634e487b7160e01b600052601160045260246000fd5b60208082526031908201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604082015270696e672072656465656d6564205242544360781b606082015260800190565b6000610100610fde83885180516001600160a01b03168252602090810151910152565b602080880151604085015260408801516060850152611013608085018880516001600160a01b03168252602090810151910152565b6001600160a01b03861660c085015260e0840182905284519184018290526000915b8083101561105457858301820151858401610120015291810191611035565b6101209250600083828701015282601f19601f830116860101935050505095945050505050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea2646970667358221220d3520caf24be1597c52a894253bc89ae96dd1ecde727f772f65c3be231572d2864736f6c63430008110033", + "deployedBytecode": "0x6080604052600436106100ec5760003560e01c80638da5cb5b1161008a578063c4d66de811610059578063c4d66de8146102d1578063e5085517146102f1578063f2fde38b14610311578063fc1768191461033157600080fd5b80638da5cb5b1461024a57806390e4b720146102685780639b2633ae1461027d578063b5c89bab1461029d57600080fd5b806353428253116100c6578063534282531461019f57806366960ead146101d3578063715018a6146102015780637a0a3ac51461021657600080fd5b806312261ee7146100f857806333c507ae14610149578063460f2de11461017d57600080fd5b366100f357005b600080fd5b34801561010457600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b34801561015557600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561018957600080fd5b5061019d610198366004610cbf565b610351565b005b3480156101ab57600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101df57600080fd5b506101f36101ee366004610d0c565b610653565b604051908152602001610140565b34801561020d57600080fd5b5061019d610673565b34801561022257600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561025657600080fd5b506033546001600160a01b031661012c565b34801561027457600080fd5b5061012c610687565b34801561028957600080fd5b5061019d610298366004610dfc565b6106bf565b3480156102a957600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102dd57600080fd5b5061019d6102ec366004610d0c565b6109bb565b3480156102fd57600080fd5b5061019d61030c366004610d0c565b610ad6565b34801561031d57600080fd5b5061019d61032c366004610d0c565b610aea565b34801561033d57600080fd5b5060975461012c906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356103966040890160208a01610ebf565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561040857600080fd5b505af115801561041c573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156104b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104dd9190610ee2565b146105035760405162461bcd60e51b81526004016104fa90610efb565b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b15801561057557600080fd5b505af1158015610589573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105a59190610f49565b604051909150600090339083908381818185875af1925050503d80600081146105ea576040519150601f19603f3d011682016040523d82523d6000602084013e6105ef565b606091505b50509050806106105760405162461bcd60e51b81526004016104fa90610f6a565b604080518781526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a2505050505050565b6001600160a01b0381166000908152609860205260408120545b92915050565b61067b610b60565b6106856000610bba565b565b60006106ba7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b81516020908101516040805180820182526000808252908401528051808201825230808252938101839052905163187945bd60e11b81527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906330f28b7a9061073b908890859033908a90600401610fbb565b600060405180830381600087803b15801561075557600080fd5b505af1158015610769573d6000803e3d6000fd5b5050336000908152609860205260409020805460018101909155915061078c9050565b5060405163fb2c922360e01b81526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116600483015260248201849052848116604483015283917f00000000000000000000000000000000000000000000000000000000000000009091169063fb2c9223906064016020604051808303816000875af1158015610828573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061084c9190610ee2565b146108695760405162461bcd60e51b81526004016104fa90610efb565b60975460405163b7aa53e760e01b8152600481018490526001600160a01b03918216602482015284821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156108db57600080fd5b505af11580156108ef573d6000803e3d6000fd5b50505050600081856001600160a01b03163161090b9190610f49565b604051909150600090339083908381818185875af1925050503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b50509050806109765760405162461bcd60e51b81526004016104fa90610f6a565b604080518681526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a25050505050505050565b600054610100900460ff16158080156109db5750600054600160ff909116105b806109f55750303b1580156109f5575060005460ff166001145b610a585760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104fa565b6000805460ff191660011790558015610a7b576000805461ff0019166101001790555b610a83610c0c565b610a8c82610c3b565b8015610ad2576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b610ade610b60565b610ae781610c3b565b50565b610af2610b60565b6001600160a01b038116610b575760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016104fa565b610ae781610bba565b6033546001600160a01b031633146106855760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104fa565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16610c335760405162461bcd60e51b81526004016104fa9061107b565b610685610c8f565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff16610cb65760405162461bcd60e51b81526004016104fa9061107b565b61068533610bba565b60008082840360a0811215610cd357600080fd5b833592506080601f1982011215610ce957600080fd5b506020830190509250929050565b6001600160a01b0381168114610ae757600080fd5b600060208284031215610d1e57600080fd5b8135610d2981610cf7565b9392505050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610d6957610d69610d30565b60405290565b600082601f830112610d8057600080fd5b813567ffffffffffffffff80821115610d9b57610d9b610d30565b604051601f8301601f19908116603f01168101908282118183101715610dc357610dc3610d30565b81604052838152866020858801011115610ddc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b60008082840360a0811215610e1057600080fd5b6080811215610e1e57600080fd5b6040516060810167ffffffffffffffff8282108183111715610e4257610e42610d30565b816040526040841215610e5457600080fd5b610e5c610d46565b935086359150610e6b82610cf7565b8184526020870135602085015283835260408701356020840152606087013560408401528295506080870135935080841115610ea657600080fd5b505050610eb585828601610d6f565b9150509250929050565b600060208284031215610ed157600080fd5b813560ff81168114610d2957600080fd5b600060208284031215610ef457600080fd5b5051919050565b6020808252602e908201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260408201526d1958dd08111bd0c8185b5bdd5b9d60921b606082015260800190565b8181038181111561066d57634e487b7160e01b600052601160045260246000fd5b60208082526031908201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604082015270696e672072656465656d6564205242544360781b606082015260800190565b6000610100610fde83885180516001600160a01b03168252602090810151910152565b602080880151604085015260408801516060850152611013608085018880516001600160a01b03168252602090810151910152565b6001600160a01b03861660c085015260e0840182905284519184018290526000915b8083101561105457858301820151858401610120015291810191611035565b6101209250600083828701015282601f19601f830116860101935050505095945050505050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea2646970667358221220d3520caf24be1597c52a894253bc89ae96dd1ecde727f772f65c3be231572d2864736f6c63430008110033", + "implementation": "0x70AF585169AAdafd36115d6404Db6597433C8E82", "devdoc": { "kind": "dev", "methods": { @@ -339,6 +429,21 @@ "_permitParams": "EIP-2612 permit params: _deadline Expiration time of the signature. _v Last 1 byte of ECDSA signature. _r First 32 bytes of ECDSA signature. _s 32 bytes after _r in ECDSA signature." } }, + "getDocFromDllrAndRedeemRbtcWithPermit2(((address,uint256),uint256,uint256),bytes)": { + "params": { + "permit": "permit data, in form of PermitTransferFrom struct.", + "signature": "of the permit data." + } + }, + "getPermit2Nonce(address)": { + "details": "getter for currernt nonce", + "params": { + "_address": "address of owner" + }, + "returns": { + "_0": "current nonce of the owner's address" + } + }, "getProxyImplementation()": { "details": "get the implementation logic address referring to ERC1967 standard.", "returns": { @@ -363,6 +468,9 @@ "getDocFromDllrAndRedeemRBTC(uint256,(uint256,uint8,bytes32,bytes32))": { "notice": "how getDocFromDllrAndRedeemRBTC function works: ------------------------------------------------------------------------------------------- | Mynt | Money On Chain | ------------------------------------------------------------------------------------------- | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user | -------------------------------------------------------------------------------------------" }, + "getDocFromDllrAndRedeemRbtcWithPermit2(((address,uint256),uint256,uint256),bytes)": { + "notice": "how getDocFromDllrAndRedeemRBTC function works: ------------------------------------------------------------------------------------------- | Mynt | Money On Chain | ------------------------------------------------------------------------------------------- | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user | -------------------------------------------------------------------------------------------" + }, "setMocVendorAccount(address)": { "notice": "Set MoC registered Vendor account to receive markup fees https://docs.moneyonchain.com/main-rbtc-contract/integration-with-moc-platform/vendors" } @@ -389,7 +497,7 @@ "type": "t_bool" }, { - "astId": 1094, + "astId": 1021, "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", "label": "__gap", "offset": 0, @@ -421,12 +529,20 @@ "type": "t_array(t_uint256)50_storage" }, { - "astId": 5786, + "astId": 3845, "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", "label": "mocVendorAccount", "offset": 0, "slot": "151", "type": "t_address" + }, + { + "astId": 3853, + "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", + "label": "_permit2Nonces", + "offset": 0, + "slot": "152", + "type": "t_mapping(t_address,t_struct(Counter)2121_storage)" } ], "types": { @@ -452,6 +568,28 @@ "label": "bool", "numberOfBytes": "1" }, + "t_mapping(t_address,t_struct(Counter)2121_storage)": { + "encoding": "mapping", + "key": "t_address", + "label": "mapping(address => struct Counters.Counter)", + "numberOfBytes": "32", + "value": "t_struct(Counter)2121_storage" + }, + "t_struct(Counter)2121_storage": { + "encoding": "inplace", + "label": "struct Counters.Counter", + "members": [ + { + "astId": 2120, + "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", + "label": "_value", + "offset": 0, + "slot": "0", + "type": "t_uint256" + } + ], + "numberOfBytes": "32" + }, "t_uint256": { "encoding": "inplace", "label": "uint256", diff --git a/deployment/deployments/rskSovrynTestnet/MocIntegration_Implementation.json b/deployment/deployments/rskSovrynTestnet/MocIntegration_Implementation.json index 25c754f..68cfadd 100644 --- a/deployment/deployments/rskSovrynTestnet/MocIntegration_Implementation.json +++ b/deployment/deployments/rskSovrynTestnet/MocIntegration_Implementation.json @@ -1,5 +1,5 @@ { - "address": "0x17DC9E96c814C041351EE07a9AA29A7Fe100d859", + "address": "0x70AF585169AAdafd36115d6404Db6597433C8E82", "abi": [ { "inputs": [ @@ -22,6 +22,11 @@ "internalType": "address", "name": "_massetManager", "type": "address" + }, + { + "internalType": "address", + "name": "_permit2", + "type": "address" } ], "stateMutability": "nonpayable", @@ -62,6 +67,12 @@ { "anonymous": false, "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, { "indexed": false, "internalType": "uint256", @@ -202,6 +213,72 @@ "stateMutability": "nonpayable", "type": "function" }, + { + "inputs": [ + { + "components": [ + { + "components": [ + { + "internalType": "address", + "name": "token", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "internalType": "struct ISignatureTransfer.TokenPermissions", + "name": "permitted", + "type": "tuple" + }, + { + "internalType": "uint256", + "name": "nonce", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "deadline", + "type": "uint256" + } + ], + "internalType": "struct ISignatureTransfer.PermitTransferFrom", + "name": "permit", + "type": "tuple" + }, + { + "internalType": "bytes", + "name": "signature", + "type": "bytes" + } + ], + "name": "getDocFromDllrAndRedeemRbtcWithPermit2", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_address", + "type": "address" + } + ], + "name": "getPermit2Nonce", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [], "name": "getProxyImplementation", @@ -280,6 +357,19 @@ "stateMutability": "view", "type": "function" }, + { + "inputs": [], + "name": "permit2", + "outputs": [ + { + "internalType": "contract IPermit2", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, { "inputs": [], "name": "renounceOwnership", @@ -318,19 +408,19 @@ "type": "receive" } ], - "transactionHash": "0xef7049a8bd389ffa58cbbd640c6b303ac1276cfbf6e6889d53b3216fc05d1720", + "transactionHash": "0xdf5f929470795686a7999c7c36be892db5ad8c859f2c5f9c6df91ba3a87e3ab9", "receipt": { "to": null, - "from": "0x8C9143221F2b72Fcef391893c3a02Cf0fE84f50b", - "contractAddress": "0x17DC9E96c814C041351EE07a9AA29A7Fe100d859", + "from": "0x13Be55487D37FE3C66EE7305e1e9C1ac85de75Ae", + "contractAddress": "0x70AF585169AAdafd36115d6404Db6597433C8E82", "transactionIndex": 0, - "gasUsed": "805011", + "gasUsed": "1228053", "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x86e95bbcabb27fbe6ccf10c18954a28b1d17006e3360e81ca3c04ca2b17c7126", - "transactionHash": "0xef7049a8bd389ffa58cbbd640c6b303ac1276cfbf6e6889d53b3216fc05d1720", + "blockHash": "0x94ce8f7e9f65eb52fe760f7b843c5870a5d5b4e751482c65e68aef471900cb62", + "transactionHash": "0xdf5f929470795686a7999c7c36be892db5ad8c859f2c5f9c6df91ba3a87e3ab9", "logs": [], - "blockNumber": 3955498, - "cumulativeGasUsed": "805011", + "blockNumber": 4732520, + "cumulativeGasUsed": "1228053", "status": 1, "byzantium": true }, @@ -338,13 +428,14 @@ "0x2820f6d4d199b8d8838a4b26f9917754b86a0c1f", "0xcb46c0ddc60d18efeb0e586c17af6ea36452dae0", "0x007b3AA69A846cB1f76b60b3088230A52D2A83AC", - "0xac2d05A148aB512EDEDc7280c00292ED33d31f1A" + "0xac2d05A148aB512EDEDc7280c00292ED33d31f1A", + "0x000000000022d473030f116ddee9f6b43ac78ba3" ], - "numDeployments": 4, - "solcInputHash": "5727992a5ffb924489d49e5c632b187c", - "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_moc\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_doc\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_dllr\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_massetManager\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"previousAdmin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newAdmin\",\"type\":\"address\"}],\"name\":\"AdminChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"beacon\",\"type\":\"address\"}],\"name\":\"BeaconUpgraded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fromDLLR\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"toRBTC\",\"type\":\"uint256\"}],\"name\":\"GetDocFromDllrAndRedeemRBTC\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newMocVendorAccount\",\"type\":\"address\"}],\"name\":\"MocVendorAccountSet\",\"type\":\"event\"},{\"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\":true,\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"name\":\"Upgraded\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"dllr\",\"outputs\":[{\"internalType\":\"contract IDLLR\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"doc\",\"outputs\":[{\"internalType\":\"contract IERC20\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_dllrAmount\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"deadline\",\"type\":\"uint256\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"internalType\":\"struct PermitParams\",\"name\":\"_permitParams\",\"type\":\"tuple\"}],\"name\":\"getDocFromDllrAndRedeemRBTC\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProxyImplementation\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"_mocVendorAccount\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"massetManager\",\"outputs\":[{\"internalType\":\"contract IMassetManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"moc\",\"outputs\":[{\"internalType\":\"contract IMocMintRedeemDoc\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"mocVendorAccount\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"newMocVedorAccount\",\"type\":\"address\"}],\"name\":\"setMocVendorAccount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"constructor\":{\"params\":{\"_dllr\":\"DLLR contract address\",\"_doc\":\"DoC contract address\",\"_massetManager\":\"MassetManager contract address\",\"_moc\":\"MoC main contract address\"}},\"getDocFromDllrAndRedeemRBTC(uint256,(uint256,uint8,bytes32,bytes32))\":{\"params\":{\"_dllrAmount\":\"The amount of the DLLR (mAsset) that will be burned in exchange for _toToken\",\"_permitParams\":\"EIP-2612 permit params: _deadline Expiration time of the signature. _v Last 1 byte of ECDSA signature. _r First 32 bytes of ECDSA signature. _s 32 bytes after _r in ECDSA signature.\"}},\"getProxyImplementation()\":{\"details\":\"get the implementation logic address referring to ERC1967 standard.\",\"returns\":{\"_0\":\"logic implementation address.\"}},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"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.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"getDocFromDllrAndRedeemRBTC(uint256,(uint256,uint8,bytes32,bytes32))\":{\"notice\":\"how getDocFromDllrAndRedeemRBTC function works: ------------------------------------------------------------------------------------------- | Mynt | Money On Chain | ------------------------------------------------------------------------------------------- | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user | -------------------------------------------------------------------------------------------\"},\"setMocVendorAccount(address)\":{\"notice\":\"Set MoC registered Vendor account to receive markup fees https://docs.moneyonchain.com/main-rbtc-contract/integration-with-moc-platform/vendors\"}},\"notice\":\"This contract provides compound functions with Money On Chain wrapping them in one transaction for convenience and to save on gas\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/integration/MoC/MocIntegration.sol\":\"MocIntegration\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../utils/ContextUpgradeable.sol\\\";\\nimport \\\"../proxy/utils/Initializable.sol\\\";\\n\\n/**\\n * @dev Contract module which provides a basic access control mechanism, where\\n * there is an account (an owner) that can be granted exclusive access to\\n * specific functions.\\n *\\n * By default, the owner account will be the one that deploys the contract. This\\n * can later be changed with {transferOwnership}.\\n *\\n * This module is used through inheritance. It will make available the modifier\\n * `onlyOwner`, which can be applied to your functions to restrict their use to\\n * the owner.\\n */\\nabstract contract OwnableUpgradeable is Initializable, ContextUpgradeable {\\n address private _owner;\\n\\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\\n\\n /**\\n * @dev Initializes the contract setting the deployer as the initial owner.\\n */\\n function __Ownable_init() internal onlyInitializing {\\n __Ownable_init_unchained();\\n }\\n\\n function __Ownable_init_unchained() internal onlyInitializing {\\n _transferOwnership(_msgSender());\\n }\\n\\n /**\\n * @dev Throws if called by any account other than the owner.\\n */\\n modifier onlyOwner() {\\n _checkOwner();\\n _;\\n }\\n\\n /**\\n * @dev Returns the address of the current owner.\\n */\\n function owner() public view virtual returns (address) {\\n return _owner;\\n }\\n\\n /**\\n * @dev Throws if the sender is not the owner.\\n */\\n function _checkOwner() internal view virtual {\\n require(owner() == _msgSender(), \\\"Ownable: caller is not the owner\\\");\\n }\\n\\n /**\\n * @dev Leaves the contract without owner. It will not be possible to call\\n * `onlyOwner` functions anymore. Can only be called by the current owner.\\n *\\n * NOTE: Renouncing ownership will leave the contract without an owner,\\n * thereby removing any functionality that is only available to the owner.\\n */\\n function renounceOwnership() public virtual onlyOwner {\\n _transferOwnership(address(0));\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Can only be called by the current owner.\\n */\\n function transferOwnership(address newOwner) public virtual onlyOwner {\\n require(newOwner != address(0), \\\"Ownable: new owner is the zero address\\\");\\n _transferOwnership(newOwner);\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Internal function without access restriction.\\n */\\n function _transferOwnership(address newOwner) internal virtual {\\n address oldOwner = _owner;\\n _owner = newOwner;\\n emit OwnershipTransferred(oldOwner, newOwner);\\n }\\n\\n /**\\n * @dev This empty reserved space is put in place to allow future versions to add new\\n * variables without shifting down storage in the inheritance chain.\\n * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps\\n */\\n uint256[49] private __gap;\\n}\\n\",\"keccak256\":\"0x247c62047745915c0af6b955470a72d1696ebad4352d7d3011aef1a2463cd888\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/interfaces/IERC1967Upgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.3) (interfaces/IERC1967.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev ERC-1967: Proxy Storage Slots. This interface contains the events defined in the ERC.\\n *\\n * _Available since v4.9._\\n */\\ninterface IERC1967Upgradeable {\\n /**\\n * @dev Emitted when the implementation is upgraded.\\n */\\n event Upgraded(address indexed implementation);\\n\\n /**\\n * @dev Emitted when the admin account has changed.\\n */\\n event AdminChanged(address previousAdmin, address newAdmin);\\n\\n /**\\n * @dev Emitted when the beacon is changed.\\n */\\n event BeaconUpgraded(address indexed beacon);\\n}\\n\",\"keccak256\":\"0xb8d68221343ed784c7b76edb6a686cb65e49c476d9e22bb89a5c0c3947ff14db\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/interfaces/draft-IERC1822Upgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.5.0) (interfaces/draft-IERC1822.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev ERC1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified\\n * proxy whose upgrades are fully controlled by the current implementation.\\n */\\ninterface IERC1822ProxiableUpgradeable {\\n /**\\n * @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation\\n * address.\\n *\\n * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\\n * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\\n * function revert if invoked through a proxy.\\n */\\n function proxiableUUID() external view returns (bytes32);\\n}\\n\",\"keccak256\":\"0x77c89f893e403efc6929ba842b7ccf6534d4ffe03afe31670b4a528c0ad78c0f\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/proxy/ERC1967/ERC1967UpgradeUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.3) (proxy/ERC1967/ERC1967Upgrade.sol)\\n\\npragma solidity ^0.8.2;\\n\\nimport \\\"../beacon/IBeaconUpgradeable.sol\\\";\\nimport \\\"../../interfaces/IERC1967Upgradeable.sol\\\";\\nimport \\\"../../interfaces/draft-IERC1822Upgradeable.sol\\\";\\nimport \\\"../../utils/AddressUpgradeable.sol\\\";\\nimport \\\"../../utils/StorageSlotUpgradeable.sol\\\";\\nimport \\\"../utils/Initializable.sol\\\";\\n\\n/**\\n * @dev This abstract contract provides getters and event emitting update functions for\\n * https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots.\\n *\\n * _Available since v4.1._\\n *\\n * @custom:oz-upgrades-unsafe-allow delegatecall\\n */\\nabstract contract ERC1967UpgradeUpgradeable is Initializable, IERC1967Upgradeable {\\n function __ERC1967Upgrade_init() internal onlyInitializing {\\n }\\n\\n function __ERC1967Upgrade_init_unchained() internal onlyInitializing {\\n }\\n // This is the keccak-256 hash of \\\"eip1967.proxy.rollback\\\" subtracted by 1\\n bytes32 private constant _ROLLBACK_SLOT = 0x4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143;\\n\\n /**\\n * @dev Storage slot with the address of the current implementation.\\n * This is the keccak-256 hash of \\\"eip1967.proxy.implementation\\\" subtracted by 1, and is\\n * validated in the constructor.\\n */\\n bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\\n\\n /**\\n * @dev Returns the current implementation address.\\n */\\n function _getImplementation() internal view returns (address) {\\n return StorageSlotUpgradeable.getAddressSlot(_IMPLEMENTATION_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new address in the EIP1967 implementation slot.\\n */\\n function _setImplementation(address newImplementation) private {\\n require(AddressUpgradeable.isContract(newImplementation), \\\"ERC1967: new implementation is not a contract\\\");\\n StorageSlotUpgradeable.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\\n }\\n\\n /**\\n * @dev Perform implementation upgrade\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeTo(address newImplementation) internal {\\n _setImplementation(newImplementation);\\n emit Upgraded(newImplementation);\\n }\\n\\n /**\\n * @dev Perform implementation upgrade with additional setup call.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeToAndCall(\\n address newImplementation,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n _upgradeTo(newImplementation);\\n if (data.length > 0 || forceCall) {\\n _functionDelegateCall(newImplementation, data);\\n }\\n }\\n\\n /**\\n * @dev Perform implementation upgrade with security checks for UUPS proxies, and additional setup call.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeToAndCallUUPS(\\n address newImplementation,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n // Upgrades from old implementations will perform a rollback test. This test requires the new\\n // implementation to upgrade back to the old, non-ERC1822 compliant, implementation. Removing\\n // this special case will break upgrade paths from old UUPS implementation to new ones.\\n if (StorageSlotUpgradeable.getBooleanSlot(_ROLLBACK_SLOT).value) {\\n _setImplementation(newImplementation);\\n } else {\\n try IERC1822ProxiableUpgradeable(newImplementation).proxiableUUID() returns (bytes32 slot) {\\n require(slot == _IMPLEMENTATION_SLOT, \\\"ERC1967Upgrade: unsupported proxiableUUID\\\");\\n } catch {\\n revert(\\\"ERC1967Upgrade: new implementation is not UUPS\\\");\\n }\\n _upgradeToAndCall(newImplementation, data, forceCall);\\n }\\n }\\n\\n /**\\n * @dev Storage slot with the admin of the contract.\\n * This is the keccak-256 hash of \\\"eip1967.proxy.admin\\\" subtracted by 1, and is\\n * validated in the constructor.\\n */\\n bytes32 internal constant _ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;\\n\\n /**\\n * @dev Returns the current admin.\\n */\\n function _getAdmin() internal view returns (address) {\\n return StorageSlotUpgradeable.getAddressSlot(_ADMIN_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new address in the EIP1967 admin slot.\\n */\\n function _setAdmin(address newAdmin) private {\\n require(newAdmin != address(0), \\\"ERC1967: new admin is the zero address\\\");\\n StorageSlotUpgradeable.getAddressSlot(_ADMIN_SLOT).value = newAdmin;\\n }\\n\\n /**\\n * @dev Changes the admin of the proxy.\\n *\\n * Emits an {AdminChanged} event.\\n */\\n function _changeAdmin(address newAdmin) internal {\\n emit AdminChanged(_getAdmin(), newAdmin);\\n _setAdmin(newAdmin);\\n }\\n\\n /**\\n * @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy.\\n * This is bytes32(uint256(keccak256('eip1967.proxy.beacon')) - 1)) and is validated in the constructor.\\n */\\n bytes32 internal constant _BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50;\\n\\n /**\\n * @dev Returns the current beacon.\\n */\\n function _getBeacon() internal view returns (address) {\\n return StorageSlotUpgradeable.getAddressSlot(_BEACON_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new beacon in the EIP1967 beacon slot.\\n */\\n function _setBeacon(address newBeacon) private {\\n require(AddressUpgradeable.isContract(newBeacon), \\\"ERC1967: new beacon is not a contract\\\");\\n require(\\n AddressUpgradeable.isContract(IBeaconUpgradeable(newBeacon).implementation()),\\n \\\"ERC1967: beacon implementation is not a contract\\\"\\n );\\n StorageSlotUpgradeable.getAddressSlot(_BEACON_SLOT).value = newBeacon;\\n }\\n\\n /**\\n * @dev Perform beacon upgrade with additional setup call. Note: This upgrades the address of the beacon, it does\\n * not upgrade the implementation contained in the beacon (see {UpgradeableBeacon-_setImplementation} for that).\\n *\\n * Emits a {BeaconUpgraded} event.\\n */\\n function _upgradeBeaconToAndCall(\\n address newBeacon,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n _setBeacon(newBeacon);\\n emit BeaconUpgraded(newBeacon);\\n if (data.length > 0 || forceCall) {\\n _functionDelegateCall(IBeaconUpgradeable(newBeacon).implementation(), data);\\n }\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\\n * but performing a delegate call.\\n *\\n * _Available since v3.4._\\n */\\n function _functionDelegateCall(address target, bytes memory data) private returns (bytes memory) {\\n require(AddressUpgradeable.isContract(target), \\\"Address: delegate call to non-contract\\\");\\n\\n // solhint-disable-next-line avoid-low-level-calls\\n (bool success, bytes memory returndata) = target.delegatecall(data);\\n return AddressUpgradeable.verifyCallResult(success, returndata, \\\"Address: low-level delegate call failed\\\");\\n }\\n\\n /**\\n * @dev This empty reserved space is put in place to allow future versions to add new\\n * variables without shifting down storage in the inheritance chain.\\n * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps\\n */\\n uint256[50] private __gap;\\n}\\n\",\"keccak256\":\"0x1599637b52d20dc3954cea44914b2a4a9a8a5caade58d9da947e0b6c9acc07ba\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/proxy/beacon/IBeaconUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (proxy/beacon/IBeacon.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev This is the interface that {BeaconProxy} expects of its beacon.\\n */\\ninterface IBeaconUpgradeable {\\n /**\\n * @dev Must return an address that can be used as a delegate call target.\\n *\\n * {BeaconProxy} will check that this address is a contract.\\n */\\n function implementation() external view returns (address);\\n}\\n\",\"keccak256\":\"0x24b86ac8c005b8c654fbf6ac34a5a4f61580d7273541e83e013e89d66fbf0908\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.1) (proxy/utils/Initializable.sol)\\n\\npragma solidity ^0.8.2;\\n\\nimport \\\"../../utils/AddressUpgradeable.sol\\\";\\n\\n/**\\n * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed\\n * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an\\n * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer\\n * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.\\n *\\n * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be\\n * reused. This mechanism prevents re-execution of each \\\"step\\\" but allows the creation of new initialization steps in\\n * case an upgrade adds a module that needs to be initialized.\\n *\\n * For example:\\n *\\n * [.hljs-theme-light.nopadding]\\n * ```\\n * contract MyToken is ERC20Upgradeable {\\n * function initialize() initializer public {\\n * __ERC20_init(\\\"MyToken\\\", \\\"MTK\\\");\\n * }\\n * }\\n * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {\\n * function initializeV2() reinitializer(2) public {\\n * __ERC20Permit_init(\\\"MyToken\\\");\\n * }\\n * }\\n * ```\\n *\\n * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as\\n * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.\\n *\\n * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure\\n * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.\\n *\\n * [CAUTION]\\n * ====\\n * Avoid leaving a contract uninitialized.\\n *\\n * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation\\n * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke\\n * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:\\n *\\n * [.hljs-theme-light.nopadding]\\n * ```\\n * /// @custom:oz-upgrades-unsafe-allow constructor\\n * constructor() {\\n * _disableInitializers();\\n * }\\n * ```\\n * ====\\n */\\nabstract contract Initializable {\\n /**\\n * @dev Indicates that the contract has been initialized.\\n * @custom:oz-retyped-from bool\\n */\\n uint8 private _initialized;\\n\\n /**\\n * @dev Indicates that the contract is in the process of being initialized.\\n */\\n bool private _initializing;\\n\\n /**\\n * @dev Triggered when the contract has been initialized or reinitialized.\\n */\\n event Initialized(uint8 version);\\n\\n /**\\n * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,\\n * `onlyInitializing` functions can be used to initialize parent contracts.\\n *\\n * Similar to `reinitializer(1)`, except that functions marked with `initializer` can be nested in the context of a\\n * constructor.\\n *\\n * Emits an {Initialized} event.\\n */\\n modifier initializer() {\\n bool isTopLevelCall = !_initializing;\\n require(\\n (isTopLevelCall && _initialized < 1) || (!AddressUpgradeable.isContract(address(this)) && _initialized == 1),\\n \\\"Initializable: contract is already initialized\\\"\\n );\\n _initialized = 1;\\n if (isTopLevelCall) {\\n _initializing = true;\\n }\\n _;\\n if (isTopLevelCall) {\\n _initializing = false;\\n emit Initialized(1);\\n }\\n }\\n\\n /**\\n * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the\\n * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be\\n * used to initialize parent contracts.\\n *\\n * A reinitializer may be used after the original initialization step. This is essential to configure modules that\\n * are added through upgrades and that require initialization.\\n *\\n * When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`\\n * cannot be nested. If one is invoked in the context of another, execution will revert.\\n *\\n * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in\\n * a contract, executing them in the right order is up to the developer or operator.\\n *\\n * WARNING: setting the version to 255 will prevent any future reinitialization.\\n *\\n * Emits an {Initialized} event.\\n */\\n modifier reinitializer(uint8 version) {\\n require(!_initializing && _initialized < version, \\\"Initializable: contract is already initialized\\\");\\n _initialized = version;\\n _initializing = true;\\n _;\\n _initializing = false;\\n emit Initialized(version);\\n }\\n\\n /**\\n * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the\\n * {initializer} and {reinitializer} modifiers, directly or indirectly.\\n */\\n modifier onlyInitializing() {\\n require(_initializing, \\\"Initializable: contract is not initializing\\\");\\n _;\\n }\\n\\n /**\\n * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.\\n * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized\\n * to any version. It is recommended to use this to lock implementation contracts that are designed to be called\\n * through proxies.\\n *\\n * Emits an {Initialized} event the first time it is successfully executed.\\n */\\n function _disableInitializers() internal virtual {\\n require(!_initializing, \\\"Initializable: contract is initializing\\\");\\n if (_initialized < type(uint8).max) {\\n _initialized = type(uint8).max;\\n emit Initialized(type(uint8).max);\\n }\\n }\\n\\n /**\\n * @dev Returns the highest version that has been initialized. See {reinitializer}.\\n */\\n function _getInitializedVersion() internal view returns (uint8) {\\n return _initialized;\\n }\\n\\n /**\\n * @dev Returns `true` if the contract is currently initializing. See {onlyInitializing}.\\n */\\n function _isInitializing() internal view returns (bool) {\\n return _initializing;\\n }\\n}\\n\",\"keccak256\":\"0x037c334add4b033ad3493038c25be1682d78c00992e1acb0e2795caff3925271\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/utils/AddressUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)\\n\\npragma solidity ^0.8.1;\\n\\n/**\\n * @dev Collection of functions related to the address type\\n */\\nlibrary AddressUpgradeable {\\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 * [IMPORTANT]\\n * ====\\n * You shouldn't rely on `isContract` to protect against flash loan attacks!\\n *\\n * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets\\n * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract\\n * constructor.\\n * ====\\n */\\n function isContract(address account) internal view returns (bool) {\\n // This method relies on extcodesize/address.code.length, which returns 0\\n // for contracts in construction, since the code is only stored at the end\\n // of the constructor execution.\\n\\n return account.code.length > 0;\\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 (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 functionCallWithValue(target, data, 0, \\\"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(\\n address target,\\n bytes memory data,\\n string memory errorMessage\\n ) 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(\\n address target,\\n bytes memory data,\\n uint256 value\\n ) 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(\\n address target,\\n bytes memory data,\\n uint256 value,\\n string memory errorMessage\\n ) internal returns (bytes memory) {\\n require(address(this).balance >= value, \\\"Address: insufficient balance for call\\\");\\n (bool success, bytes memory returndata) = target.call{value: value}(data);\\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\\n * but performing a static call.\\n *\\n * _Available since v3.3._\\n */\\n function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {\\n return functionStaticCall(target, data, \\\"Address: low-level static call failed\\\");\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\\n * but performing a static call.\\n *\\n * _Available since v3.3._\\n */\\n function functionStaticCall(\\n address target,\\n bytes memory data,\\n string memory errorMessage\\n ) internal view returns (bytes memory) {\\n (bool success, bytes memory returndata) = target.staticcall(data);\\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\\n }\\n\\n /**\\n * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling\\n * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.\\n *\\n * _Available since v4.8._\\n */\\n function verifyCallResultFromTarget(\\n address target,\\n bool success,\\n bytes memory returndata,\\n string memory errorMessage\\n ) internal view returns (bytes memory) {\\n if (success) {\\n if (returndata.length == 0) {\\n // only check isContract if the call was successful and the return data is empty\\n // otherwise we already know that it was a contract\\n require(isContract(target), \\\"Address: call to non-contract\\\");\\n }\\n return returndata;\\n } else {\\n _revert(returndata, errorMessage);\\n }\\n }\\n\\n /**\\n * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the\\n * revert reason or using the provided one.\\n *\\n * _Available since v4.3._\\n */\\n function verifyCallResult(\\n bool success,\\n bytes memory returndata,\\n string memory errorMessage\\n ) internal pure returns (bytes memory) {\\n if (success) {\\n return returndata;\\n } else {\\n _revert(returndata, errorMessage);\\n }\\n }\\n\\n function _revert(bytes memory returndata, string memory errorMessage) private pure {\\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 /// @solidity memory-safe-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\",\"keccak256\":\"0x2edcb41c121abc510932e8d83ff8b82cf9cdde35e7c297622f5c29ef0af25183\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)\\n\\npragma solidity ^0.8.0;\\nimport \\\"../proxy/utils/Initializable.sol\\\";\\n\\n/**\\n * @dev Provides information about the current execution context, including the\\n * sender of the transaction and its data. While these are generally available\\n * via msg.sender and msg.data, they should not be accessed in such a direct\\n * manner, since when dealing with meta-transactions the account sending and\\n * paying for execution may not be the actual sender (as far as an application\\n * is concerned).\\n *\\n * This contract is only required for intermediate, library-like contracts.\\n */\\nabstract contract ContextUpgradeable is Initializable {\\n function __Context_init() internal onlyInitializing {\\n }\\n\\n function __Context_init_unchained() internal onlyInitializing {\\n }\\n function _msgSender() internal view virtual returns (address) {\\n return msg.sender;\\n }\\n\\n function _msgData() internal view virtual returns (bytes calldata) {\\n return msg.data;\\n }\\n\\n /**\\n * @dev This empty reserved space is put in place to allow future versions to add new\\n * variables without shifting down storage in the inheritance chain.\\n * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps\\n */\\n uint256[50] private __gap;\\n}\\n\",\"keccak256\":\"0x963ea7f0b48b032eef72fe3a7582edf78408d6f834115b9feadd673a4d5bd149\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/utils/StorageSlotUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (utils/StorageSlot.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Library for reading and writing primitive types to specific storage slots.\\n *\\n * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.\\n * This library helps with reading and writing to such slots without the need for inline assembly.\\n *\\n * The functions in this library return Slot structs that contain a `value` member that can be used to read or write.\\n *\\n * Example usage to set ERC1967 implementation slot:\\n * ```\\n * contract ERC1967 {\\n * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\\n *\\n * function _getImplementation() internal view returns (address) {\\n * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\\n * }\\n *\\n * function _setImplementation(address newImplementation) internal {\\n * require(Address.isContract(newImplementation), \\\"ERC1967: new implementation is not a contract\\\");\\n * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\\n * }\\n * }\\n * ```\\n *\\n * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._\\n */\\nlibrary StorageSlotUpgradeable {\\n struct AddressSlot {\\n address value;\\n }\\n\\n struct BooleanSlot {\\n bool value;\\n }\\n\\n struct Bytes32Slot {\\n bytes32 value;\\n }\\n\\n struct Uint256Slot {\\n uint256 value;\\n }\\n\\n /**\\n * @dev Returns an `AddressSlot` with member `value` located at `slot`.\\n */\\n function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `BooleanSlot` with member `value` located at `slot`.\\n */\\n function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `Bytes32Slot` with member `value` located at `slot`.\\n */\\n function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `Uint256Slot` with member `value` located at `slot`.\\n */\\n function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n}\\n\",\"keccak256\":\"0x09864aea84f01e39313375b5610c73a3c1c68abbdc51e5ccdd25ff977fdadf9a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/access/Ownable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../utils/Context.sol\\\";\\n\\n/**\\n * @dev Contract module which provides a basic access control mechanism, where\\n * there is an account (an owner) that can be granted exclusive access to\\n * specific functions.\\n *\\n * By default, the owner account will be the one that deploys the contract. This\\n * can later be changed with {transferOwnership}.\\n *\\n * This module is used through inheritance. It will make available the modifier\\n * `onlyOwner`, which can be applied to your functions to restrict their use to\\n * the owner.\\n */\\nabstract contract Ownable is Context {\\n address private _owner;\\n\\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\\n\\n /**\\n * @dev Initializes the contract setting the deployer as the initial owner.\\n */\\n constructor() {\\n _transferOwnership(_msgSender());\\n }\\n\\n /**\\n * @dev Throws if called by any account other than the owner.\\n */\\n modifier onlyOwner() {\\n _checkOwner();\\n _;\\n }\\n\\n /**\\n * @dev Returns the address of the current owner.\\n */\\n function owner() public view virtual returns (address) {\\n return _owner;\\n }\\n\\n /**\\n * @dev Throws if the sender is not the owner.\\n */\\n function _checkOwner() internal view virtual {\\n require(owner() == _msgSender(), \\\"Ownable: caller is not the owner\\\");\\n }\\n\\n /**\\n * @dev Leaves the contract without owner. It will not be possible to call\\n * `onlyOwner` functions anymore. Can only be called by the current owner.\\n *\\n * NOTE: Renouncing ownership will leave the contract without an owner,\\n * thereby removing any functionality that is only available to the owner.\\n */\\n function renounceOwnership() public virtual onlyOwner {\\n _transferOwnership(address(0));\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Can only be called by the current owner.\\n */\\n function transferOwnership(address newOwner) public virtual onlyOwner {\\n require(newOwner != address(0), \\\"Ownable: new owner is the zero address\\\");\\n _transferOwnership(newOwner);\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Internal function without access restriction.\\n */\\n function _transferOwnership(address newOwner) internal virtual {\\n address oldOwner = _owner;\\n _owner = newOwner;\\n emit OwnershipTransferred(oldOwner, newOwner);\\n }\\n}\\n\",\"keccak256\":\"0xa94b34880e3c1b0b931662cb1c09e5dfa6662f31cba80e07c5ee71cd135c9673\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/ERC20.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/ERC20.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./IERC20.sol\\\";\\nimport \\\"./extensions/IERC20Metadata.sol\\\";\\nimport \\\"../../utils/Context.sol\\\";\\n\\n/**\\n * @dev Implementation of the {IERC20} interface.\\n *\\n * This implementation is agnostic to the way tokens are created. This means\\n * that a supply mechanism has to be added in a derived contract using {_mint}.\\n * For a generic mechanism see {ERC20PresetMinterPauser}.\\n *\\n * TIP: For a detailed writeup see our guide\\n * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How\\n * to implement supply mechanisms].\\n *\\n * We have followed general OpenZeppelin Contracts guidelines: functions revert\\n * instead returning `false` on failure. This behavior is nonetheless\\n * conventional and does not conflict with the expectations of ERC20\\n * applications.\\n *\\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\\n * This allows applications to reconstruct the allowance for all accounts just\\n * by listening to said events. Other implementations of the EIP may not emit\\n * these events, as it isn't required by the specification.\\n *\\n * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}\\n * functions have been added to mitigate the well-known issues around setting\\n * allowances. See {IERC20-approve}.\\n */\\ncontract ERC20 is Context, IERC20, IERC20Metadata {\\n mapping(address => uint256) private _balances;\\n\\n mapping(address => mapping(address => uint256)) private _allowances;\\n\\n uint256 private _totalSupply;\\n\\n string private _name;\\n string private _symbol;\\n\\n /**\\n * @dev Sets the values for {name} and {symbol}.\\n *\\n * The default value of {decimals} is 18. To select a different value for\\n * {decimals} you should overload it.\\n *\\n * All two of these values are immutable: they can only be set once during\\n * construction.\\n */\\n constructor(string memory name_, string memory symbol_) {\\n _name = name_;\\n _symbol = symbol_;\\n }\\n\\n /**\\n * @dev Returns the name of the token.\\n */\\n function name() public view virtual override returns (string memory) {\\n return _name;\\n }\\n\\n /**\\n * @dev Returns the symbol of the token, usually a shorter version of the\\n * name.\\n */\\n function symbol() public view virtual override returns (string memory) {\\n return _symbol;\\n }\\n\\n /**\\n * @dev Returns the number of decimals used to get its user representation.\\n * For example, if `decimals` equals `2`, a balance of `505` tokens should\\n * be displayed to a user as `5.05` (`505 / 10 ** 2`).\\n *\\n * Tokens usually opt for a value of 18, imitating the relationship between\\n * Ether and Wei. This is the value {ERC20} uses, unless this function is\\n * overridden;\\n *\\n * NOTE: This information is only used for _display_ purposes: it in\\n * no way affects any of the arithmetic of the contract, including\\n * {IERC20-balanceOf} and {IERC20-transfer}.\\n */\\n function decimals() public view virtual override returns (uint8) {\\n return 18;\\n }\\n\\n /**\\n * @dev See {IERC20-totalSupply}.\\n */\\n function totalSupply() public view virtual override returns (uint256) {\\n return _totalSupply;\\n }\\n\\n /**\\n * @dev See {IERC20-balanceOf}.\\n */\\n function balanceOf(address account) public view virtual override returns (uint256) {\\n return _balances[account];\\n }\\n\\n /**\\n * @dev See {IERC20-transfer}.\\n *\\n * Requirements:\\n *\\n * - `to` cannot be the zero address.\\n * - the caller must have a balance of at least `amount`.\\n */\\n function transfer(address to, uint256 amount) public virtual override returns (bool) {\\n address owner = _msgSender();\\n _transfer(owner, to, amount);\\n return true;\\n }\\n\\n /**\\n * @dev See {IERC20-allowance}.\\n */\\n function allowance(address owner, address spender) public view virtual override returns (uint256) {\\n return _allowances[owner][spender];\\n }\\n\\n /**\\n * @dev See {IERC20-approve}.\\n *\\n * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on\\n * `transferFrom`. This is semantically equivalent to an infinite approval.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n */\\n function approve(address spender, uint256 amount) public virtual override returns (bool) {\\n address owner = _msgSender();\\n _approve(owner, spender, amount);\\n return true;\\n }\\n\\n /**\\n * @dev See {IERC20-transferFrom}.\\n *\\n * Emits an {Approval} event indicating the updated allowance. This is not\\n * required by the EIP. See the note at the beginning of {ERC20}.\\n *\\n * NOTE: Does not update the allowance if the current allowance\\n * is the maximum `uint256`.\\n *\\n * Requirements:\\n *\\n * - `from` and `to` cannot be the zero address.\\n * - `from` must have a balance of at least `amount`.\\n * - the caller must have allowance for ``from``'s tokens of at least\\n * `amount`.\\n */\\n function transferFrom(\\n address from,\\n address to,\\n uint256 amount\\n ) public virtual override returns (bool) {\\n address spender = _msgSender();\\n _spendAllowance(from, spender, amount);\\n _transfer(from, to, amount);\\n return true;\\n }\\n\\n /**\\n * @dev Atomically increases the allowance granted to `spender` by the caller.\\n *\\n * This is an alternative to {approve} that can be used as a mitigation for\\n * problems described in {IERC20-approve}.\\n *\\n * Emits an {Approval} event indicating the updated allowance.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n */\\n function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {\\n address owner = _msgSender();\\n _approve(owner, spender, allowance(owner, spender) + addedValue);\\n return true;\\n }\\n\\n /**\\n * @dev Atomically decreases the allowance granted to `spender` by the caller.\\n *\\n * This is an alternative to {approve} that can be used as a mitigation for\\n * problems described in {IERC20-approve}.\\n *\\n * Emits an {Approval} event indicating the updated allowance.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n * - `spender` must have allowance for the caller of at least\\n * `subtractedValue`.\\n */\\n function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {\\n address owner = _msgSender();\\n uint256 currentAllowance = allowance(owner, spender);\\n require(currentAllowance >= subtractedValue, \\\"ERC20: decreased allowance below zero\\\");\\n unchecked {\\n _approve(owner, spender, currentAllowance - subtractedValue);\\n }\\n\\n return true;\\n }\\n\\n /**\\n * @dev Moves `amount` of tokens from `from` to `to`.\\n *\\n * This internal function is equivalent to {transfer}, and can be used to\\n * e.g. implement automatic token fees, slashing mechanisms, etc.\\n *\\n * Emits a {Transfer} event.\\n *\\n * Requirements:\\n *\\n * - `from` cannot be the zero address.\\n * - `to` cannot be the zero address.\\n * - `from` must have a balance of at least `amount`.\\n */\\n function _transfer(\\n address from,\\n address to,\\n uint256 amount\\n ) internal virtual {\\n require(from != address(0), \\\"ERC20: transfer from the zero address\\\");\\n require(to != address(0), \\\"ERC20: transfer to the zero address\\\");\\n\\n _beforeTokenTransfer(from, to, amount);\\n\\n uint256 fromBalance = _balances[from];\\n require(fromBalance >= amount, \\\"ERC20: transfer amount exceeds balance\\\");\\n unchecked {\\n _balances[from] = fromBalance - amount;\\n // Overflow not possible: the sum of all balances is capped by totalSupply, and the sum is preserved by\\n // decrementing then incrementing.\\n _balances[to] += amount;\\n }\\n\\n emit Transfer(from, to, amount);\\n\\n _afterTokenTransfer(from, to, amount);\\n }\\n\\n /** @dev Creates `amount` tokens and assigns them to `account`, increasing\\n * the total supply.\\n *\\n * Emits a {Transfer} event with `from` set to the zero address.\\n *\\n * Requirements:\\n *\\n * - `account` cannot be the zero address.\\n */\\n function _mint(address account, uint256 amount) internal virtual {\\n require(account != address(0), \\\"ERC20: mint to the zero address\\\");\\n\\n _beforeTokenTransfer(address(0), account, amount);\\n\\n _totalSupply += amount;\\n unchecked {\\n // Overflow not possible: balance + amount is at most totalSupply + amount, which is checked above.\\n _balances[account] += amount;\\n }\\n emit Transfer(address(0), account, amount);\\n\\n _afterTokenTransfer(address(0), account, amount);\\n }\\n\\n /**\\n * @dev Destroys `amount` tokens from `account`, reducing the\\n * total supply.\\n *\\n * Emits a {Transfer} event with `to` set to the zero address.\\n *\\n * Requirements:\\n *\\n * - `account` cannot be the zero address.\\n * - `account` must have at least `amount` tokens.\\n */\\n function _burn(address account, uint256 amount) internal virtual {\\n require(account != address(0), \\\"ERC20: burn from the zero address\\\");\\n\\n _beforeTokenTransfer(account, address(0), amount);\\n\\n uint256 accountBalance = _balances[account];\\n require(accountBalance >= amount, \\\"ERC20: burn amount exceeds balance\\\");\\n unchecked {\\n _balances[account] = accountBalance - amount;\\n // Overflow not possible: amount <= accountBalance <= totalSupply.\\n _totalSupply -= amount;\\n }\\n\\n emit Transfer(account, address(0), amount);\\n\\n _afterTokenTransfer(account, address(0), amount);\\n }\\n\\n /**\\n * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.\\n *\\n * This internal function is equivalent to `approve`, and can be used to\\n * e.g. set automatic allowances for certain subsystems, etc.\\n *\\n * Emits an {Approval} event.\\n *\\n * Requirements:\\n *\\n * - `owner` cannot be the zero address.\\n * - `spender` cannot be the zero address.\\n */\\n function _approve(\\n address owner,\\n address spender,\\n uint256 amount\\n ) internal virtual {\\n require(owner != address(0), \\\"ERC20: approve from the zero address\\\");\\n require(spender != address(0), \\\"ERC20: approve to the zero address\\\");\\n\\n _allowances[owner][spender] = amount;\\n emit Approval(owner, spender, amount);\\n }\\n\\n /**\\n * @dev Updates `owner` s allowance for `spender` based on spent `amount`.\\n *\\n * Does not update the allowance amount in case of infinite allowance.\\n * Revert if not enough allowance is available.\\n *\\n * Might emit an {Approval} event.\\n */\\n function _spendAllowance(\\n address owner,\\n address spender,\\n uint256 amount\\n ) internal virtual {\\n uint256 currentAllowance = allowance(owner, spender);\\n if (currentAllowance != type(uint256).max) {\\n require(currentAllowance >= amount, \\\"ERC20: insufficient allowance\\\");\\n unchecked {\\n _approve(owner, spender, currentAllowance - amount);\\n }\\n }\\n }\\n\\n /**\\n * @dev Hook that is called before any transfer of tokens. This includes\\n * minting and burning.\\n *\\n * Calling conditions:\\n *\\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\\n * will be transferred to `to`.\\n * - when `from` is zero, `amount` tokens will be minted for `to`.\\n * - when `to` is zero, `amount` of ``from``'s tokens will be burned.\\n * - `from` and `to` are never both zero.\\n *\\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\\n */\\n function _beforeTokenTransfer(\\n address from,\\n address to,\\n uint256 amount\\n ) internal virtual {}\\n\\n /**\\n * @dev Hook that is called after any transfer of tokens. This includes\\n * minting and burning.\\n *\\n * Calling conditions:\\n *\\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\\n * has been transferred to `to`.\\n * - when `from` is zero, `amount` tokens have been minted for `to`.\\n * - when `to` is zero, `amount` of ``from``'s tokens have been burned.\\n * - `from` and `to` are never both zero.\\n *\\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\\n */\\n function _afterTokenTransfer(\\n address from,\\n address to,\\n uint256 amount\\n ) internal virtual {}\\n}\\n\",\"keccak256\":\"0x4ffc0547c02ad22925310c585c0f166f8759e2648a09e9b489100c42f15dd98d\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Interface of the ERC20 standard as defined in the EIP.\\n */\\ninterface IERC20 {\\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 /**\\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 `to`.\\n *\\n * Returns a boolean value indicating whether the operation succeeded.\\n *\\n * Emits a {Transfer} event.\\n */\\n function transfer(address to, 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 `from` to `to` 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(\\n address from,\\n address to,\\n uint256 amount\\n ) external returns (bool);\\n}\\n\",\"keccak256\":\"0x9750c6b834f7b43000631af5cc30001c5f547b3ceb3635488f140f60e897ea6b\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../IERC20.sol\\\";\\n\\n/**\\n * @dev Interface for the optional metadata functions from the ERC20 standard.\\n *\\n * _Available since v4.1._\\n */\\ninterface IERC20Metadata is IERC20 {\\n /**\\n * @dev Returns the name of the token.\\n */\\n function name() external view returns (string memory);\\n\\n /**\\n * @dev Returns the symbol of the token.\\n */\\n function symbol() external view returns (string memory);\\n\\n /**\\n * @dev Returns the decimals places of the token.\\n */\\n function decimals() external view returns (uint8);\\n}\\n\",\"keccak256\":\"0x8de418a5503946cabe331f35fe242d3201a73f67f77aaeb7110acb1f30423aca\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/extensions/draft-ERC20Permit.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/extensions/draft-ERC20Permit.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./draft-IERC20Permit.sol\\\";\\nimport \\\"../ERC20.sol\\\";\\nimport \\\"../../../utils/cryptography/ECDSA.sol\\\";\\nimport \\\"../../../utils/cryptography/EIP712.sol\\\";\\nimport \\\"../../../utils/Counters.sol\\\";\\n\\n/**\\n * @dev Implementation of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in\\n * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].\\n *\\n * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by\\n * presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't\\n * need to send a transaction, and thus is not required to hold Ether at all.\\n *\\n * _Available since v3.4._\\n */\\nabstract contract ERC20Permit is ERC20, IERC20Permit, EIP712 {\\n using Counters for Counters.Counter;\\n\\n mapping(address => Counters.Counter) private _nonces;\\n\\n // solhint-disable-next-line var-name-mixedcase\\n bytes32 private constant _PERMIT_TYPEHASH =\\n keccak256(\\\"Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)\\\");\\n /**\\n * @dev In previous versions `_PERMIT_TYPEHASH` was declared as `immutable`.\\n * However, to ensure consistency with the upgradeable transpiler, we will continue\\n * to reserve a slot.\\n * @custom:oz-renamed-from _PERMIT_TYPEHASH\\n */\\n // solhint-disable-next-line var-name-mixedcase\\n bytes32 private _PERMIT_TYPEHASH_DEPRECATED_SLOT;\\n\\n /**\\n * @dev Initializes the {EIP712} domain separator using the `name` parameter, and setting `version` to `\\\"1\\\"`.\\n *\\n * It's a good idea to use the same `name` that is defined as the ERC20 token name.\\n */\\n constructor(string memory name) EIP712(name, \\\"1\\\") {}\\n\\n /**\\n * @dev See {IERC20Permit-permit}.\\n */\\n function permit(\\n address owner,\\n address spender,\\n uint256 value,\\n uint256 deadline,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) public virtual override {\\n require(block.timestamp <= deadline, \\\"ERC20Permit: expired deadline\\\");\\n\\n bytes32 structHash = keccak256(abi.encode(_PERMIT_TYPEHASH, owner, spender, value, _useNonce(owner), deadline));\\n\\n bytes32 hash = _hashTypedDataV4(structHash);\\n\\n address signer = ECDSA.recover(hash, v, r, s);\\n require(signer == owner, \\\"ERC20Permit: invalid signature\\\");\\n\\n _approve(owner, spender, value);\\n }\\n\\n /**\\n * @dev See {IERC20Permit-nonces}.\\n */\\n function nonces(address owner) public view virtual override returns (uint256) {\\n return _nonces[owner].current();\\n }\\n\\n /**\\n * @dev See {IERC20Permit-DOMAIN_SEPARATOR}.\\n */\\n // solhint-disable-next-line func-name-mixedcase\\n function DOMAIN_SEPARATOR() external view override returns (bytes32) {\\n return _domainSeparatorV4();\\n }\\n\\n /**\\n * @dev \\\"Consume a nonce\\\": return the current value and increment.\\n *\\n * _Available since v4.1._\\n */\\n function _useNonce(address owner) internal virtual returns (uint256 current) {\\n Counters.Counter storage nonce = _nonces[owner];\\n current = nonce.current();\\n nonce.increment();\\n }\\n}\\n\",\"keccak256\":\"0xd2dd6003a2dc02ab905fd405938322e510429d19ae6c07c2c683d70f13ab2f36\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/extensions/draft-IERC20Permit.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in\\n * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].\\n *\\n * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by\\n * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't\\n * need to send a transaction, and thus is not required to hold Ether at all.\\n */\\ninterface IERC20Permit {\\n /**\\n * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,\\n * given ``owner``'s signed approval.\\n *\\n * IMPORTANT: The same issues {IERC20-approve} has related to transaction\\n * ordering also apply here.\\n *\\n * Emits an {Approval} event.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n * - `deadline` must be a timestamp in the future.\\n * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`\\n * over the EIP712-formatted function arguments.\\n * - the signature must use ``owner``'s current nonce (see {nonces}).\\n *\\n * For more information on the signature format, see the\\n * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP\\n * section].\\n */\\n function permit(\\n address owner,\\n address spender,\\n uint256 value,\\n uint256 deadline,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) external;\\n\\n /**\\n * @dev Returns the current nonce for `owner`. This value must be\\n * included whenever a signature is generated for {permit}.\\n *\\n * Every successful call to {permit} increases ``owner``'s nonce by one. This\\n * prevents a signature from being used multiple times.\\n */\\n function nonces(address owner) external view returns (uint256);\\n\\n /**\\n * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.\\n */\\n // solhint-disable-next-line func-name-mixedcase\\n function DOMAIN_SEPARATOR() external view returns (bytes32);\\n}\\n\",\"keccak256\":\"0xf41ca991f30855bf80ffd11e9347856a517b977f0a6c2d52e6421a99b7840329\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Context.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Provides information about the current execution context, including the\\n * sender of the transaction and its data. While these are generally available\\n * via msg.sender and msg.data, they should not be accessed in such a direct\\n * manner, since when dealing with meta-transactions the account sending and\\n * paying for execution may not be the actual sender (as far as an application\\n * is concerned).\\n *\\n * This contract is only required for intermediate, library-like contracts.\\n */\\nabstract contract Context {\\n function _msgSender() internal view virtual returns (address) {\\n return msg.sender;\\n }\\n\\n function _msgData() internal view virtual returns (bytes calldata) {\\n return msg.data;\\n }\\n}\\n\",\"keccak256\":\"0xe2e337e6dde9ef6b680e07338c493ebea1b5fd09b43424112868e9cc1706bca7\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Counters.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (utils/Counters.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @title Counters\\n * @author Matt Condon (@shrugs)\\n * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number\\n * of elements in a mapping, issuing ERC721 ids, or counting request ids.\\n *\\n * Include with `using Counters for Counters.Counter;`\\n */\\nlibrary Counters {\\n struct Counter {\\n // This variable should never be directly accessed by users of the library: interactions must be restricted to\\n // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add\\n // this feature: see https://github.com/ethereum/solidity/issues/4637\\n uint256 _value; // default: 0\\n }\\n\\n function current(Counter storage counter) internal view returns (uint256) {\\n return counter._value;\\n }\\n\\n function increment(Counter storage counter) internal {\\n unchecked {\\n counter._value += 1;\\n }\\n }\\n\\n function decrement(Counter storage counter) internal {\\n uint256 value = counter._value;\\n require(value > 0, \\\"Counter: decrement overflow\\\");\\n unchecked {\\n counter._value = value - 1;\\n }\\n }\\n\\n function reset(Counter storage counter) internal {\\n counter._value = 0;\\n }\\n}\\n\",\"keccak256\":\"0xf0018c2440fbe238dd3a8732fa8e17a0f9dce84d31451dc8a32f6d62b349c9f1\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Strings.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./math/Math.sol\\\";\\n\\n/**\\n * @dev String operations.\\n */\\nlibrary Strings {\\n bytes16 private constant _SYMBOLS = \\\"0123456789abcdef\\\";\\n uint8 private constant _ADDRESS_LENGTH = 20;\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` decimal representation.\\n */\\n function toString(uint256 value) internal pure returns (string memory) {\\n unchecked {\\n uint256 length = Math.log10(value) + 1;\\n string memory buffer = new string(length);\\n uint256 ptr;\\n /// @solidity memory-safe-assembly\\n assembly {\\n ptr := add(buffer, add(32, length))\\n }\\n while (true) {\\n ptr--;\\n /// @solidity memory-safe-assembly\\n assembly {\\n mstore8(ptr, byte(mod(value, 10), _SYMBOLS))\\n }\\n value /= 10;\\n if (value == 0) break;\\n }\\n return buffer;\\n }\\n }\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.\\n */\\n function toHexString(uint256 value) internal pure returns (string memory) {\\n unchecked {\\n return toHexString(value, Math.log256(value) + 1);\\n }\\n }\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.\\n */\\n function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {\\n bytes memory buffer = new bytes(2 * length + 2);\\n buffer[0] = \\\"0\\\";\\n buffer[1] = \\\"x\\\";\\n for (uint256 i = 2 * length + 1; i > 1; --i) {\\n buffer[i] = _SYMBOLS[value & 0xf];\\n value >>= 4;\\n }\\n require(value == 0, \\\"Strings: hex length insufficient\\\");\\n return string(buffer);\\n }\\n\\n /**\\n * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.\\n */\\n function toHexString(address addr) internal pure returns (string memory) {\\n return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);\\n }\\n}\\n\",\"keccak256\":\"0xa4d1d62251f8574deb032a35fc948386a9b4de74b812d4f545a1ac120486b48a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/ECDSA.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../Strings.sol\\\";\\n\\n/**\\n * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.\\n *\\n * These functions can be used to verify that a message was signed by the holder\\n * of the private keys of a given address.\\n */\\nlibrary ECDSA {\\n enum RecoverError {\\n NoError,\\n InvalidSignature,\\n InvalidSignatureLength,\\n InvalidSignatureS,\\n InvalidSignatureV // Deprecated in v4.8\\n }\\n\\n function _throwError(RecoverError error) private pure {\\n if (error == RecoverError.NoError) {\\n return; // no error: do nothing\\n } else if (error == RecoverError.InvalidSignature) {\\n revert(\\\"ECDSA: invalid signature\\\");\\n } else if (error == RecoverError.InvalidSignatureLength) {\\n revert(\\\"ECDSA: invalid signature length\\\");\\n } else if (error == RecoverError.InvalidSignatureS) {\\n revert(\\\"ECDSA: invalid signature 's' value\\\");\\n }\\n }\\n\\n /**\\n * @dev Returns the address that signed a hashed message (`hash`) with\\n * `signature` or error string. This address can then be used for verification purposes.\\n *\\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\\n * this function rejects them by requiring the `s` value to be in the lower\\n * half order, and the `v` value to be either 27 or 28.\\n *\\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\\n * verification to be secure: it is possible to craft signatures that\\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\\n * this is by receiving a hash of the original message (which may otherwise\\n * be too long), and then calling {toEthSignedMessageHash} on it.\\n *\\n * Documentation for signature generation:\\n * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]\\n * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) {\\n if (signature.length == 65) {\\n bytes32 r;\\n bytes32 s;\\n uint8 v;\\n // ecrecover takes the signature parameters, and the only way to get them\\n // currently is to use assembly.\\n /// @solidity memory-safe-assembly\\n assembly {\\n r := mload(add(signature, 0x20))\\n s := mload(add(signature, 0x40))\\n v := byte(0, mload(add(signature, 0x60)))\\n }\\n return tryRecover(hash, v, r, s);\\n } else {\\n return (address(0), RecoverError.InvalidSignatureLength);\\n }\\n }\\n\\n /**\\n * @dev Returns the address that signed a hashed message (`hash`) with\\n * `signature`. This address can then be used for verification purposes.\\n *\\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\\n * this function rejects them by requiring the `s` value to be in the lower\\n * half order, and the `v` value to be either 27 or 28.\\n *\\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\\n * verification to be secure: it is possible to craft signatures that\\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\\n * this is by receiving a hash of the original message (which may otherwise\\n * be too long), and then calling {toEthSignedMessageHash} on it.\\n */\\n function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, signature);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.\\n *\\n * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(\\n bytes32 hash,\\n bytes32 r,\\n bytes32 vs\\n ) internal pure returns (address, RecoverError) {\\n bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff);\\n uint8 v = uint8((uint256(vs) >> 255) + 27);\\n return tryRecover(hash, v, r, s);\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.\\n *\\n * _Available since v4.2._\\n */\\n function recover(\\n bytes32 hash,\\n bytes32 r,\\n bytes32 vs\\n ) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, r, vs);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-tryRecover} that receives the `v`,\\n * `r` and `s` signature fields separately.\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(\\n bytes32 hash,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) internal pure returns (address, RecoverError) {\\n // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature\\n // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines\\n // the valid range for s in (301): 0 < s < secp256k1n \\u00f7 2 + 1, and for v in (302): v \\u2208 {27, 28}. Most\\n // signatures from current libraries generate a unique signature with an s-value in the lower half order.\\n //\\n // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value\\n // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or\\n // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept\\n // these malleable signatures as well.\\n if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {\\n return (address(0), RecoverError.InvalidSignatureS);\\n }\\n\\n // If the signature is valid (and not malleable), return the signer address\\n address signer = ecrecover(hash, v, r, s);\\n if (signer == address(0)) {\\n return (address(0), RecoverError.InvalidSignature);\\n }\\n\\n return (signer, RecoverError.NoError);\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-recover} that receives the `v`,\\n * `r` and `s` signature fields separately.\\n */\\n function recover(\\n bytes32 hash,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, v, r, s);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Message, created from a `hash`. This\\n * produces hash corresponding to the one signed with the\\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\\n * JSON-RPC method as part of EIP-191.\\n *\\n * See {recover}.\\n */\\n function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {\\n // 32 is the length in bytes of hash,\\n // enforced by the type signature above\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n32\\\", hash));\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Message, created from `s`. This\\n * produces hash corresponding to the one signed with the\\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\\n * JSON-RPC method as part of EIP-191.\\n *\\n * See {recover}.\\n */\\n function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n\\\", Strings.toString(s.length), s));\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Typed Data, created from a\\n * `domainSeparator` and a `structHash`. This produces hash corresponding\\n * to the one signed with the\\n * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]\\n * JSON-RPC method as part of EIP-712.\\n *\\n * See {recover}.\\n */\\n function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19\\\\x01\\\", domainSeparator, structHash));\\n }\\n}\\n\",\"keccak256\":\"0xda898fa084aa1ddfdb346e6a40459e00a59d87071cce7c315a46d648dd71d0ba\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/cryptography/EIP712.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/EIP712.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./ECDSA.sol\\\";\\n\\n/**\\n * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.\\n *\\n * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible,\\n * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding\\n * they need in their contracts using a combination of `abi.encode` and `keccak256`.\\n *\\n * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding\\n * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA\\n * ({_hashTypedDataV4}).\\n *\\n * The implementation of the domain separator was designed to be as efficient as possible while still properly updating\\n * the chain id to protect against replay attacks on an eventual fork of the chain.\\n *\\n * NOTE: This contract implements the version of the encoding known as \\\"v4\\\", as implemented by the JSON RPC method\\n * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].\\n *\\n * _Available since v3.4._\\n */\\nabstract contract EIP712 {\\n /* solhint-disable var-name-mixedcase */\\n // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to\\n // invalidate the cached domain separator if the chain id changes.\\n bytes32 private immutable _CACHED_DOMAIN_SEPARATOR;\\n uint256 private immutable _CACHED_CHAIN_ID;\\n address private immutable _CACHED_THIS;\\n\\n bytes32 private immutable _HASHED_NAME;\\n bytes32 private immutable _HASHED_VERSION;\\n bytes32 private immutable _TYPE_HASH;\\n\\n /* solhint-enable var-name-mixedcase */\\n\\n /**\\n * @dev Initializes the domain separator and parameter caches.\\n *\\n * The meaning of `name` and `version` is specified in\\n * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]:\\n *\\n * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol.\\n * - `version`: the current major version of the signing domain.\\n *\\n * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart\\n * contract upgrade].\\n */\\n constructor(string memory name, string memory version) {\\n bytes32 hashedName = keccak256(bytes(name));\\n bytes32 hashedVersion = keccak256(bytes(version));\\n bytes32 typeHash = keccak256(\\n \\\"EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)\\\"\\n );\\n _HASHED_NAME = hashedName;\\n _HASHED_VERSION = hashedVersion;\\n _CACHED_CHAIN_ID = block.chainid;\\n _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion);\\n _CACHED_THIS = address(this);\\n _TYPE_HASH = typeHash;\\n }\\n\\n /**\\n * @dev Returns the domain separator for the current chain.\\n */\\n function _domainSeparatorV4() internal view returns (bytes32) {\\n if (address(this) == _CACHED_THIS && block.chainid == _CACHED_CHAIN_ID) {\\n return _CACHED_DOMAIN_SEPARATOR;\\n } else {\\n return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION);\\n }\\n }\\n\\n function _buildDomainSeparator(\\n bytes32 typeHash,\\n bytes32 nameHash,\\n bytes32 versionHash\\n ) private view returns (bytes32) {\\n return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this)));\\n }\\n\\n /**\\n * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this\\n * function returns the hash of the fully encoded EIP712 message for this domain.\\n *\\n * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example:\\n *\\n * ```solidity\\n * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode(\\n * keccak256(\\\"Mail(address to,string contents)\\\"),\\n * mailTo,\\n * keccak256(bytes(mailContents))\\n * )));\\n * address signer = ECDSA.recover(digest, signature);\\n * ```\\n */\\n function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) {\\n return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash);\\n }\\n}\\n\",\"keccak256\":\"0x948d8b2d18f38141ec78c5229d770d950ebc781ed3f44cc9e3ccbb9fded5846a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/math/Math.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Standard math utilities missing in the Solidity language.\\n */\\nlibrary Math {\\n enum Rounding {\\n Down, // Toward negative infinity\\n Up, // Toward infinity\\n Zero // Toward zero\\n }\\n\\n /**\\n * @dev Returns the largest of two numbers.\\n */\\n function max(uint256 a, uint256 b) internal pure returns (uint256) {\\n return a > b ? a : b;\\n }\\n\\n /**\\n * @dev Returns the smallest of two numbers.\\n */\\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\\n return a < b ? a : b;\\n }\\n\\n /**\\n * @dev Returns the average of two numbers. The result is rounded towards\\n * zero.\\n */\\n function average(uint256 a, uint256 b) internal pure returns (uint256) {\\n // (a + b) / 2 can overflow.\\n return (a & b) + (a ^ b) / 2;\\n }\\n\\n /**\\n * @dev Returns the ceiling of the division of two numbers.\\n *\\n * This differs from standard division with `/` in that it rounds up instead\\n * of rounding down.\\n */\\n function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {\\n // (a + b - 1) / b can overflow on addition, so we distribute.\\n return a == 0 ? 0 : (a - 1) / b + 1;\\n }\\n\\n /**\\n * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0\\n * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)\\n * with further edits by Uniswap Labs also under MIT license.\\n */\\n function mulDiv(\\n uint256 x,\\n uint256 y,\\n uint256 denominator\\n ) internal pure returns (uint256 result) {\\n unchecked {\\n // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use\\n // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256\\n // variables such that product = prod1 * 2^256 + prod0.\\n uint256 prod0; // Least significant 256 bits of the product\\n uint256 prod1; // Most significant 256 bits of the product\\n assembly {\\n let mm := mulmod(x, y, not(0))\\n prod0 := mul(x, y)\\n prod1 := sub(sub(mm, prod0), lt(mm, prod0))\\n }\\n\\n // Handle non-overflow cases, 256 by 256 division.\\n if (prod1 == 0) {\\n return prod0 / denominator;\\n }\\n\\n // Make sure the result is less than 2^256. Also prevents denominator == 0.\\n require(denominator > prod1);\\n\\n ///////////////////////////////////////////////\\n // 512 by 256 division.\\n ///////////////////////////////////////////////\\n\\n // Make division exact by subtracting the remainder from [prod1 prod0].\\n uint256 remainder;\\n assembly {\\n // Compute remainder using mulmod.\\n remainder := mulmod(x, y, denominator)\\n\\n // Subtract 256 bit number from 512 bit number.\\n prod1 := sub(prod1, gt(remainder, prod0))\\n prod0 := sub(prod0, remainder)\\n }\\n\\n // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.\\n // See https://cs.stackexchange.com/q/138556/92363.\\n\\n // Does not overflow because the denominator cannot be zero at this stage in the function.\\n uint256 twos = denominator & (~denominator + 1);\\n assembly {\\n // Divide denominator by twos.\\n denominator := div(denominator, twos)\\n\\n // Divide [prod1 prod0] by twos.\\n prod0 := div(prod0, twos)\\n\\n // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.\\n twos := add(div(sub(0, twos), twos), 1)\\n }\\n\\n // Shift in bits from prod1 into prod0.\\n prod0 |= prod1 * twos;\\n\\n // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such\\n // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for\\n // four bits. That is, denominator * inv = 1 mod 2^4.\\n uint256 inverse = (3 * denominator) ^ 2;\\n\\n // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works\\n // in modular arithmetic, doubling the correct bits in each step.\\n inverse *= 2 - denominator * inverse; // inverse mod 2^8\\n inverse *= 2 - denominator * inverse; // inverse mod 2^16\\n inverse *= 2 - denominator * inverse; // inverse mod 2^32\\n inverse *= 2 - denominator * inverse; // inverse mod 2^64\\n inverse *= 2 - denominator * inverse; // inverse mod 2^128\\n inverse *= 2 - denominator * inverse; // inverse mod 2^256\\n\\n // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.\\n // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is\\n // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1\\n // is no longer required.\\n result = prod0 * inverse;\\n return result;\\n }\\n }\\n\\n /**\\n * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.\\n */\\n function mulDiv(\\n uint256 x,\\n uint256 y,\\n uint256 denominator,\\n Rounding rounding\\n ) internal pure returns (uint256) {\\n uint256 result = mulDiv(x, y, denominator);\\n if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {\\n result += 1;\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.\\n *\\n * Inspired by Henry S. Warren, Jr.'s \\\"Hacker's Delight\\\" (Chapter 11).\\n */\\n function sqrt(uint256 a) internal pure returns (uint256) {\\n if (a == 0) {\\n return 0;\\n }\\n\\n // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.\\n //\\n // We know that the \\\"msb\\\" (most significant bit) of our target number `a` is a power of 2 such that we have\\n // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.\\n //\\n // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`\\n // \\u2192 `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`\\n // \\u2192 `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`\\n //\\n // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.\\n uint256 result = 1 << (log2(a) >> 1);\\n\\n // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,\\n // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at\\n // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision\\n // into the expected uint128 result.\\n unchecked {\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n return min(result, a / result);\\n }\\n }\\n\\n /**\\n * @notice Calculates sqrt(a), following the selected rounding direction.\\n */\\n function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = sqrt(a);\\n return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 2, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log2(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >> 128 > 0) {\\n value >>= 128;\\n result += 128;\\n }\\n if (value >> 64 > 0) {\\n value >>= 64;\\n result += 64;\\n }\\n if (value >> 32 > 0) {\\n value >>= 32;\\n result += 32;\\n }\\n if (value >> 16 > 0) {\\n value >>= 16;\\n result += 16;\\n }\\n if (value >> 8 > 0) {\\n value >>= 8;\\n result += 8;\\n }\\n if (value >> 4 > 0) {\\n value >>= 4;\\n result += 4;\\n }\\n if (value >> 2 > 0) {\\n value >>= 2;\\n result += 2;\\n }\\n if (value >> 1 > 0) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 2, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log2(value);\\n return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 10, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log10(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >= 10**64) {\\n value /= 10**64;\\n result += 64;\\n }\\n if (value >= 10**32) {\\n value /= 10**32;\\n result += 32;\\n }\\n if (value >= 10**16) {\\n value /= 10**16;\\n result += 16;\\n }\\n if (value >= 10**8) {\\n value /= 10**8;\\n result += 8;\\n }\\n if (value >= 10**4) {\\n value /= 10**4;\\n result += 4;\\n }\\n if (value >= 10**2) {\\n value /= 10**2;\\n result += 2;\\n }\\n if (value >= 10**1) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log10(value);\\n return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 256, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n *\\n * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.\\n */\\n function log256(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >> 128 > 0) {\\n value >>= 128;\\n result += 16;\\n }\\n if (value >> 64 > 0) {\\n value >>= 64;\\n result += 8;\\n }\\n if (value >> 32 > 0) {\\n value >>= 32;\\n result += 4;\\n }\\n if (value >> 16 > 0) {\\n value >>= 16;\\n result += 2;\\n }\\n if (value >> 8 > 0) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log256(value);\\n return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);\\n }\\n }\\n}\\n\",\"keccak256\":\"0xa1e8e83cd0087785df04ac79fb395d9f3684caeaf973d9e2c71caef723a3a5d6\",\"license\":\"MIT\"},\"contracts/integration/MoC/IMoC.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\n/// Interface to the Money OnChain main contract MoC to mint DoC and redeem RBTC\\ninterface IMocMintRedeemDoc {\\n /**\\n @dev Returns the total amount of Docs in the redeem queue for redeemer\\n @param redeemer address for which ^ is computed\\n @return total amount of Docs in the redeem queue for redeemer\\n */\\n function docAmountToRedeem(address redeemer) external view returns (uint256);\\n\\n /**\\n * @dev Creates or updates the amount of a Doc redeem Request from the msg.sender\\n * @param docAmount Amount of Docs to redeem on settlement [using mocPrecision]\\n */\\n function redeemDocRequest(uint256 docAmount) external;\\n\\n /**\\n @dev Alters the redeem amount position for the redeemer\\n @param isAddition true if adding amount to redeem, false to substract.\\n @param delta the amount to add/substract to current position\\n */\\n function alterRedeemRequestAmount(bool isAddition, uint256 delta) external;\\n\\n /**\\n @dev Mint Doc tokens and pays the commisions of the operation (retrocompatible function).\\n @dev Retrocompatible function.\\n @param btcToMint Amount in RBTC to mint\\n */\\n function mintDoc(uint256 btcToMint) external payable;\\n\\n /**\\n * @dev Mint Doc tokens and pays the commisions of the operation\\n * @param btcToMint Amount in RBTC to mint\\n * @param vendorAccount Vendor address\\n */\\n function mintDocVendors(uint256 btcToMint, address payable vendorAccount) external payable;\\n\\n /**\\n @dev Redeems the requested amount for the msg.sender, or the max amount of free docs possible (retrocompatible function).\\n @dev Retrocompatible function.\\n @param docAmount Amount of Docs to redeem.\\n */\\n function redeemFreeDoc(uint256 docAmount) external;\\n\\n /**\\n @dev Redeems the requested amount for the msg.sender, or the max amount of free docs possible.\\n @param docAmount Amount of Docs to redeem.\\n @param vendorAccount Vendor address\\n */\\n function redeemFreeDocVendors(uint256 docAmount, address payable vendorAccount) external;\\n\\n /**\\n @dev Allow redeem on liquidation state, user DoCs get burned and he receives\\n the equivalent BTCs if can be covered, or the maximum available\\n */\\n function redeemAllDoc() external;\\n}\\n\\n/// An aggregating interface\\ninterface IMoC is IMocMintRedeemDoc {\\n\\n}\\n\",\"keccak256\":\"0xc571f8c743be8c85e8d570ec0378abef85ffc676e58a6fd3861501689721f944\",\"license\":\"MIT\"},\"contracts/integration/MoC/MocIntegration.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol\\\";\\nimport \\\"@openzeppelin/contracts-upgradeable/proxy/ERC1967/ERC1967UpgradeUpgradeable.sol\\\";\\nimport { IMocMintRedeemDoc } from \\\"./IMoC.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC20/IERC20.sol\\\";\\nimport \\\"../../meta-asset-token/DLLR.sol\\\";\\nimport \\\"../../interfaces/IMassetManager.sol\\\";\\nimport { IDLLR, PermitParams } from \\\"../../interfaces/IDLLR.sol\\\";\\n\\n/// @notice This contract provides compound functions with Money On Chain wrapping them in one transaction for convenience and to save on gas\\ncontract MocIntegration is OwnableUpgradeable, ERC1967UpgradeUpgradeable {\\n // Money On Chain DoC redeem interface at MoC main contract address\\n IMocMintRedeemDoc public immutable moc;\\n // IERC20@[DoC token]\\n IERC20 public immutable doc;\\n IDLLR public immutable dllr;\\n IMassetManager public immutable massetManager;\\n\\n address public mocVendorAccount;\\n\\n event GetDocFromDllrAndRedeemRBTC(uint256 fromDLLR, uint256 toRBTC);\\n event MocVendorAccountSet(address newMocVendorAccount);\\n\\n /**\\n * @param _moc MoC main contract address\\n * @param _doc DoC contract address\\n * @param _dllr DLLR contract address\\n * @param _massetManager MassetManager contract address\\n */\\n constructor(address _moc, address _doc, address _dllr, address _massetManager) {\\n require(\\n _moc != address(0) &&\\n _doc != address(0) &&\\n _dllr != address(0) &&\\n _massetManager != address(0),\\n \\\"MocIntegration:: no null addresses allowed\\\"\\n );\\n moc = IMocMintRedeemDoc(_moc);\\n doc = IERC20(_doc);\\n dllr = IDLLR(_dllr);\\n massetManager = IMassetManager(_massetManager);\\n }\\n\\n function initialize(address payable _mocVendorAccount) external initializer {\\n __Ownable_init();\\n _setMocVendorAccount(_mocVendorAccount);\\n }\\n\\n ///@dev the contract requires receiving funds temporarily before transferring them to users\\n receive() external payable {}\\n\\n /**\\n * @notice how getDocFromDllrAndRedeemRBTC function works:\\n * -------------------------------------------------------------------------------------------\\n * | Mynt | Money On Chain |\\n * -------------------------------------------------------------------------------------------\\n * | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user |\\n * -------------------------------------------------------------------------------------------\\n *\\n * @param _dllrAmount The amount of the DLLR (mAsset) that will be burned in exchange for _toToken\\n * @param _permitParams EIP-2612 permit params:\\n * _deadline Expiration time of the signature.\\n * _v Last 1 byte of ECDSA signature.\\n * _r First 32 bytes of ECDSA signature.\\n * _s 32 bytes after _r in ECDSA signature.\\n */\\n function getDocFromDllrAndRedeemRBTC(\\n uint256 _dllrAmount,\\n PermitParams calldata _permitParams\\n ) external {\\n // transfer _dllrAmount to this contract by permit (EIP-2612)\\n address thisAddress = address(this);\\n dllr.transferWithPermit(\\n msg.sender,\\n thisAddress,\\n _dllrAmount,\\n _permitParams.deadline,\\n _permitParams.v,\\n _permitParams.r,\\n _permitParams.s\\n );\\n\\n // redeem DoC from DLLR\\n require(\\n massetManager.redeemTo(address(doc), _dllrAmount, thisAddress) == _dllrAmount,\\n \\\"MocIntegration:: redeemed incorrect DoC amount\\\"\\n );\\n\\n // redeem RBTC from DoC using Money On Chain and send to the user\\n uint256 rbtcBalanceBefore = thisAddress.balance;\\n moc.redeemFreeDocVendors(_dllrAmount, payable(mocVendorAccount));\\n uint256 rbtcAmount = thisAddress.balance - rbtcBalanceBefore;\\n (bool success, ) = msg.sender.call{ value: rbtcAmount }(\\\"\\\");\\n require(success, \\\"MocIntegration:: error transferring redeemed RBTC\\\");\\n\\n emit GetDocFromDllrAndRedeemRBTC(_dllrAmount, rbtcAmount);\\n }\\n\\n /// Set MoC registered Vendor account to receive markup fees https://docs.moneyonchain.com/main-rbtc-contract/integration-with-moc-platform/vendors\\n function setMocVendorAccount(address payable newMocVedorAccount) external onlyOwner {\\n _setMocVendorAccount(newMocVedorAccount);\\n }\\n\\n function _setMocVendorAccount(address newMocVedorAccount) internal {\\n mocVendorAccount = newMocVedorAccount;\\n emit MocVendorAccountSet(mocVendorAccount);\\n }\\n\\n /**\\n * @dev get the implementation logic address referring to ERC1967 standard.\\n *\\n * @return logic implementation address.\\n */\\n function getProxyImplementation() external view returns (address) {\\n return ERC1967UpgradeUpgradeable._getImplementation();\\n }\\n}\\n\",\"keccak256\":\"0xa89a4b16d18c4916d5493abe0b683bb4d07f14f3fe858f0a3e829ea7db129fba\",\"license\":\"MIT\"},\"contracts/interfaces/IApproveAndCall.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\n/**\\n * @title Interface for contract governance/ApprovalReceiver.sol\\n * @dev Interfaces are used to cast a contract address into a callable instance.\\n */\\ninterface IApproveAndCall {\\n /**\\n * @notice Receives approval from SOV token.\\n * @param _sender The sender of SOV.approveAndCall function.\\n * @param _amount The amount was approved.\\n * @param _token The address of token.\\n * @param _data The data will be used for low level call.\\n * */\\n function receiveApproval(address _sender, uint256 _amount, address _token, bytes calldata _data) external;\\n}\\n\",\"keccak256\":\"0x1b4b414bcae5c700e5f08422afaeb86f111de0f28aaa6b8230f1f13190ca0e23\",\"license\":\"MIT\"},\"contracts/interfaces/IDLLR.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"@openzeppelin/contracts/token/ERC20/IERC20.sol\\\";\\n\\n/**\\n * @dev Permit params (EIP-2612) wrapper struct\\n */\\nstruct PermitParams {\\n uint256 deadline;\\n uint8 v;\\n bytes32 r;\\n bytes32 s;\\n}\\n\\n/**\\n * @title DLLR mAsset interface.\\n * @dev mAsset - Meta Asset Token implementation.\\n * Inherits from ERC20.\\n * mint and burn functions.\\n */\\ninterface IDLLR is IERC20 {\\n // events\\n\\n /**\\n * @dev Emitted when MassetManager config is changed.\\n * @param _newMassetManagerProxy Address of new MassetManager proxy.\\n */\\n event MassetManagerProxyChanged(address indexed _newMassetManagerProxy);\\n\\n /**\\n * @dev Emitted when Basket Manager config is changed.\\n * @param _newBasketManagerProxy Address of new Basket Manager proxy.\\n */\\n event BasketManagerProxyChanged(address indexed _newBasketManagerProxy);\\n\\n /**\\n * @dev getter function of MassetManager implementation address\\n *\\n * @return MassetManager implementation address\\n */\\n function massetManagerImplementation() external view returns (address);\\n\\n /**\\n * @dev getter function of basket manager implementation address\\n *\\n * @return basket manager implementation address\\n */\\n function basketManagerImplementation() external view returns (address);\\n\\n /**\\n * @notice setMassetManagerProxy sets the MassetManager proxy address\\n * @param _massetManagerProxy The address of the MassetManager proxy contract\\n */\\n function setMassetManagerProxy(address _massetManagerProxy) external;\\n\\n /**\\n * @notice setBasketManagerConfig sets the Basket Manager proxy address\\n * @param _basketManagerProxy The address of the Basket Manager proxy contract\\n */\\n function setBasketManagerProxy(address _basketManagerProxy) external;\\n\\n /**\\n * @notice Creates new tokens and sends them to the recipient.\\n * @notice Can be minted only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function mint(address _account, uint256 _amount) external;\\n\\n /**\\n * @notice Burns tokens for the given account.\\n * @notice Can be burned only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function burn(address _account, uint256 _amount) external;\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _recipient Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transfer(address _recipient, uint256 _amount) external returns (bool);\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _from Sender of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transferFrom(address _from, address _to, uint256 _amount) external returns (bool);\\n\\n /**\\n * @notice transfer utilizing EIP-2612, to reduce the additional sending transaction for doing the approval to the spender.\\n *\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @dev By calling this function, the allowance will be overwritten by the total amount.\\n *\\n * @param _from Owner of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of the token that will be transferred.\\n * @param _deadline Expiration time of the signature.\\n * @param _v Last 1 byte of ECDSA signature.\\n * @param _r First 32 bytes of ECDSA signature.\\n * @param _s 32 bytes after _r in ECDSA signature.\\n */\\n function transferWithPermit(\\n address _from,\\n address _to,\\n uint256 _amount,\\n uint256 _deadline,\\n uint8 _v,\\n bytes32 _r,\\n bytes32 _s\\n ) external;\\n\\n /**\\n * @notice Approves and then calls the receiving contract.\\n * Useful to encapsulate sending tokens to a contract in one call.\\n * Solidity has no native way to send tokens to contracts.\\n * ERC-20 tokens require approval to be spent by third parties, such as a contract in this case.\\n * @param _spender The contract address to spend the tokens.\\n * @param _amount The amount of tokens to be sent.\\n * @param _data Parameters for the contract call, such as endpoint signature.\\n */\\n function approveAndCall(address _spender, uint256 _amount, bytes calldata _data) external;\\n\\n /**\\n * @dev to support EIP712, will need the token contract to return the chain id.\\n *\\n * @return chain id.\\n *\\n */\\n function getChainId() external view returns (uint256);\\n}\\n\",\"keccak256\":\"0x34068131b6d47697cdf66239fe8f28b191afe6e13b5d145a39e7c93c8a092a01\",\"license\":\"MIT\"},\"contracts/interfaces/IMassetManager.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\n/**\\n * @title MassetManager\\n * @dev Contract is responsible for managing mAsset and bAsset.\\n * Used for minting and burning tokens and calculating fees\\n * if transaction based on token from another blockchain.\\n */\\n\\ninterface IMassetManager {\\n // events\\n\\n /**\\n * @dev Emitted when deposit is completed.\\n * @param minter Address of the minter.\\n * @param recipient Address of the recipient.\\n * @param massetQuantity Masset quantity.\\n * @param bAsset Address of the bAsset.\\n * @param bassetQuantity Basset quantity.\\n */\\n event Minted(\\n address indexed minter,\\n address indexed recipient,\\n uint256 massetQuantity,\\n address bAsset,\\n uint256 bassetQuantity\\n );\\n\\n /**\\n * @dev Emitted when withdrawal is completed.\\n * @param redeemer Address of the redeemer.\\n * @param recipient Address of the recipient.\\n * @param massetQuantity Masset quantity.\\n * @param bAsset Address of the bAsset.\\n * @param bassetQuantity Basset quantity.\\n */\\n event Redeemed(\\n address indexed redeemer,\\n address indexed recipient,\\n uint256 massetQuantity,\\n address bAsset,\\n uint256 bassetQuantity\\n );\\n\\n /***************************************\\n MINTING (PUBLIC)\\n ****************************************/\\n\\n /**\\n * @dev Mint a single mAsset, at a 1:1 ratio with the bAsset. This contract\\n * must have approval to spend the senders bAsset.\\n * @param _bAsset Address of the bAsset.\\n * @param _bAssetQuantity Quantity in bAsset units.\\n * @return massetMinted Quantity of newly minted mAsset.\\n */\\n function mint(\\n address _bAsset,\\n uint256 _bAssetQuantity\\n ) external returns (uint256 massetMinted);\\n\\n /**\\n * @dev Mint a single mAsset to recipient address, at a 1:1 ratio with the bAsset.\\n * This contract must have approval to spend the senders bAsset.\\n * @param _bAsset Address of the bAsset.\\n * @param _bAssetQuantity Quantity in bAsset units.\\n * @param _recipient Receipient of the newly minted mAsset tokens.\\n * @return massetMinted Number of newly minted mAssets.\\n */\\n function mintTo(\\n address _bAsset,\\n uint256 _bAssetQuantity,\\n address _recipient\\n ) external returns (uint256 massetMinted);\\n\\n /***************************************\\n REDEMPTION (PUBLIC)\\n ****************************************/\\n\\n /**\\n * @dev Credits the sender with a certain quantity of selected bAsset, in exchange for burning the\\n * relative mAsset quantity from the sender. Sender also incurs a small mAsset fee, if any.\\n * @param _bAsset Address of the bAsset to redeem.\\n * @param _massetQuantity Units of the masset to redeem.\\n * @return massetRedeemed Relative number of mAsset units burned to pay for the bAssets.\\n */\\n function redeem(\\n address _bAsset,\\n uint256 _massetQuantity\\n ) external returns (uint256 massetRedeemed);\\n\\n /**\\n * @dev Credits a recipient with a certain quantity of selected bAsset, in exchange for burning the\\n * relative mAsset quantity from the sender. Sender also incurs a small fee, if any.\\n * @param _bAsset Address of the bAsset to redeem.\\n * @param _massetQuantity Units of the masset to redeem.\\n * @param _recipient Address to credit with withdrawn bAssets.\\n * @return massetRedeemed Relative number of mAsset units burned to pay for the bAssets.\\n */\\n function redeemTo(\\n address _bAsset,\\n uint256 _massetQuantity,\\n address _recipient\\n ) external returns (uint256 massetRedeemed);\\n\\n // Getters\\n\\n function getFeesVault() external view returns (address);\\n\\n function getFeesManager() external view returns (address);\\n\\n function getVersion() external view returns (string memory);\\n\\n function getToken() external view returns (address);\\n\\n function getBasketManager() external view returns (address);\\n\\n /**\\n * @dev get the implementation logic address referring to ERC1967 standard.\\n *\\n * @return logic implementation address.\\n */\\n function getProxyImplementation() external view returns (address);\\n}\\n\",\"keccak256\":\"0xa1f03fbed78848636e091cf9558ad018306a099d58dec55738aee06f3dec432a\",\"license\":\"MIT\"},\"contracts/interfaces/IProxy.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.8.17;\\n\\ninterface IProxy {\\n function getProxyImplementation() external view returns (address);\\n}\\n\",\"keccak256\":\"0x5bf844214dbafb99a41cd0dff86537312cd3f20636dbb8d27cc91496fd808bc5\",\"license\":\"MIT\"},\"contracts/meta-asset-token/DLLR.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"./MetaAssetToken.sol\\\";\\n\\ncontract DLLR is MetaAssetToken {\\n constructor() MetaAssetToken(\\\"Sovryn Dollar\\\", \\\"DLLR\\\") {}\\n}\\n\",\"keccak256\":\"0x38a864f85b864d9b413c67d789493690aca728ca555ac6d0a345a40ee5b1794f\",\"license\":\"MIT\"},\"contracts/meta-asset-token/MetaAssetToken.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"@openzeppelin/contracts/access/Ownable.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC20/extensions/draft-ERC20Permit.sol\\\";\\nimport \\\"../interfaces/IApproveAndCall.sol\\\";\\nimport \\\"../interfaces/IProxy.sol\\\";\\n\\n/**\\n * @title MetaAssetToken\\n * @dev mAsset - Meta Asset Token implementation.\\n * Inherits from ERC20.\\n * mint and burn functions.\\n */\\n\\ncontract MetaAssetToken is ERC20Permit, Ownable {\\n // events\\n\\n /**\\n * @dev Emitted when MassetManager config is changed.\\n * @param _newMassetManagerProxy Address of new MassetManager proxy.\\n */\\n event MassetManagerProxyChanged(address indexed _newMassetManagerProxy);\\n\\n /**\\n * @dev Emitted when Basket Manager config is changed.\\n * @param _newBasketManagerProxy Address of new Basket Manager proxy.\\n */\\n event BasketManagerProxyChanged(address indexed _newBasketManagerProxy);\\n\\n /**\\n * @dev Emitted when transfer Manager config is changed.\\n */\\n event TransferWithPermit(address _from, address _to, uint256 _amount);\\n\\n // state\\n\\n address public massetManagerProxy;\\n address public basketManagerProxy;\\n\\n // modifiers\\n modifier onlyMassetManagerProxy() {\\n require(msg.sender == massetManagerProxy, \\\"DLLR:unauthorized MassetManager proxy\\\");\\n _;\\n }\\n\\n modifier requireValidRecipient(address _recipient) {\\n require(\\n _recipient != address(0) && _recipient != address(this),\\n \\\"DLLR: Invalid address. Cannot transfer DLLR to the null address.\\\"\\n );\\n _;\\n }\\n\\n /**\\n * @notice Constructor called on deployment, initiates the contract.\\n */\\n constructor(\\n string memory _tokenName,\\n string memory _symbol\\n ) ERC20(_tokenName, _symbol) ERC20Permit(_tokenName) {}\\n\\n /**\\n * @dev getter function of MassetManager implementation address\\n *\\n * @return MassetManager implementation address\\n */\\n function massetManagerImplementation() public view virtual returns (address) {\\n return IProxy(massetManagerProxy).getProxyImplementation();\\n }\\n\\n /**\\n * @dev getter function of basket manager implementation address\\n *\\n * @return basket manager implementation address\\n */\\n function basketManagerImplementation() public view virtual returns (address) {\\n return IProxy(basketManagerProxy).getProxyImplementation();\\n }\\n\\n /**\\n * @notice setMassetManagerProxy sets the MassetManager proxy address\\n * @param _massetManagerProxy The address of the MassetManager proxy contract\\n */\\n function setMassetManagerProxy(address _massetManagerProxy) external onlyOwner {\\n require(_massetManagerProxy != address(0), \\\"invalid MassetManager proxy address\\\");\\n massetManagerProxy = _massetManagerProxy;\\n\\n emit MassetManagerProxyChanged(massetManagerProxy);\\n }\\n\\n /**\\n * @notice setBasketManagerConfig sets the Basket Manager proxy address\\n * @param _basketManagerProxy The address of the Basket Manager proxy contract\\n */\\n function setBasketManagerProxy(address _basketManagerProxy) external onlyOwner {\\n require(_basketManagerProxy != address(0), \\\"invalid address\\\");\\n basketManagerProxy = _basketManagerProxy;\\n emit BasketManagerProxyChanged(basketManagerProxy);\\n }\\n\\n /**\\n * @notice Creates new tokens and sends them to the recipient.\\n * @notice Can be minted only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function mint(address _account, uint256 _amount) external onlyMassetManagerProxy {\\n _mint(_account, _amount);\\n }\\n\\n /**\\n * @notice Burns tokens for the given account.\\n * @notice Can be burned only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function burn(address _account, uint256 _amount) external onlyMassetManagerProxy {\\n _burn(_account, _amount);\\n }\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _recipient Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transfer(\\n address _recipient,\\n uint256 _amount\\n ) public override requireValidRecipient(_recipient) returns (bool) {\\n _transfer(_msgSender(), _recipient, _amount);\\n return true;\\n }\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _from Sender of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transferFrom(\\n address _from,\\n address _to,\\n uint256 _amount\\n ) public override requireValidRecipient(_to) returns (bool) {\\n _approve(_from, msg.sender, allowance(_from, msg.sender) - _amount);\\n _transfer(_from, _to, _amount);\\n return true;\\n }\\n\\n /**\\n * @notice transfer utilizing EIP-2612, to reduce the additional sending transaction for doing the approval to the spender.\\n *\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @dev By calling this function, the allowance will be overwritten by the total amount.\\n *\\n * @param _from Owner of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of the token that will be transferred.\\n * @param _deadline Expiration time of the signature.\\n * @param _v Last 1 byte of ECDSA signature.\\n * @param _r First 32 bytes of ECDSA signature.\\n * @param _s 32 bytes after _r in ECDSA signature.\\n */\\n function transferWithPermit(\\n address _from,\\n address _to,\\n uint256 _amount,\\n uint256 _deadline,\\n uint8 _v,\\n bytes32 _r,\\n bytes32 _s\\n ) external requireValidRecipient(_to) {\\n permit(_from, msg.sender, _amount, _deadline, _v, _r, _s);\\n require(\\n transferFrom(_from, _to, _amount),\\n \\\"MetaAssetToken::transferWithPermit: transfer failed\\\"\\n );\\n\\n emit TransferWithPermit(_from, _to, _amount);\\n }\\n\\n /**\\n * @notice Approves and then calls the receiving contract.\\n * Useful to encapsulate sending tokens to a contract in one call.\\n * Solidity has no native way to send tokens to contracts.\\n * ERC-20 tokens require approval to be spent by third parties, such as a contract in this case.\\n * @param _spender The contract address to spend the tokens.\\n * @param _amount The amount of tokens to be sent.\\n * @param _data Parameters for the contract call, such as endpoint signature.\\n */\\n function approveAndCall(address _spender, uint256 _amount, bytes calldata _data) external {\\n approve(_spender, _amount);\\n IApproveAndCall(_spender).receiveApproval(msg.sender, _amount, address(this), _data);\\n }\\n\\n /**\\n * @dev to support EIP712, will need the token contract to return the chain id.\\n *\\n * @return chain id.\\n *\\n */\\n function getChainId() external view returns (uint256) {\\n return block.chainid;\\n }\\n}\\n\",\"keccak256\":\"0x887c09ca5cf835d67db8389c8f4ab4fc2689444bb5806370431e1a18900b66d7\",\"license\":\"MIT\"}},\"version\":1}", - "bytecode": "0x61010060405234801561001157600080fd5b50604051610c80380380610c8083398101604081905261003091610119565b6001600160a01b0384161580159061005057506001600160a01b03831615155b801561006457506001600160a01b03821615155b801561007857506001600160a01b03811615155b6100db5760405162461bcd60e51b815260206004820152602a60248201527f4d6f63496e746567726174696f6e3a3a206e6f206e756c6c2061646472657373604482015269195cc8185b1b1bddd95960b21b606482015260840160405180910390fd5b6001600160a01b0393841660805291831660a052821660c0521660e05261016d565b80516001600160a01b038116811461011457600080fd5b919050565b6000806000806080858703121561012f57600080fd5b610138856100fd565b9350610146602086016100fd565b9250610154604086016100fd565b9150610162606086016100fd565b905092959194509250565b60805160a05160c05160e051610abf6101c1600039600081816101eb01526103ab01526000818160c90152610298015260008181610184015261037101526000818161013b01526104b00152610abf6000f3fe6080604052600436106100ab5760003560e01c806390e4b7201161006457806390e4b720146101c4578063b5c89bab146101d9578063c4d66de81461020d578063e50855171461022d578063f2fde38b1461024d578063fc1768191461026d57600080fd5b806333c507ae146100b7578063460f2de1146101075780635342825314610129578063715018a61461015d5780637a0a3ac5146101725780638da5cb5b146101a657600080fd5b366100b257005b600080fd5b3480156100c357600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b03909116815260200160405180910390f35b34801561011357600080fd5b5061012761012236600461096a565b61028d565b005b34801561013557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561016957600080fd5b5061012761061a565b34801561017e57600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101b257600080fd5b506033546001600160a01b03166100eb565b3480156101d057600080fd5b506100eb61062e565b3480156101e557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561021957600080fd5b506101276102283660046109b7565b610666565b34801561023957600080fd5b506101276102483660046109b7565b610781565b34801561025957600080fd5b506101276102683660046109b7565b610795565b34801561027957600080fd5b506097546100eb906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356102d26040890160208a016109db565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561034457600080fd5b505af1158015610358573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156103f5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061041991906109fe565b146104825760405162461bcd60e51b815260206004820152602e60248201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260448201526d1958dd08111bd0c8185b5bdd5b9d60921b60648201526084015b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156104f457600080fd5b505af1158015610508573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105249190610a17565b604051909150600090339083908381818185875af1925050503d8060008114610569576040519150601f19603f3d011682016040523d82523d6000602084013e61056e565b606091505b50509050806105d95760405162461bcd60e51b815260206004820152603160248201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604482015270696e672072656465656d6564205242544360781b6064820152608401610479565b60408051878152602081018490527f9d8e423b23af97e1b68e81e339269059cbacc1c8754155bf6f0fd3e5adf8abe8910160405180910390a1505050505050565b61062261080b565b61062c6000610865565b565b60006106617f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b600054610100900460ff16158080156106865750600054600160ff909116105b806106a05750303b1580156106a0575060005460ff166001145b6107035760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610479565b6000805460ff191660011790558015610726576000805461ff0019166101001790555b61072e6108b7565b610737826108e6565b801561077d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b61078961080b565b610792816108e6565b50565b61079d61080b565b6001600160a01b0381166108025760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610479565b61079281610865565b6033546001600160a01b0316331461062c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610479565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166108de5760405162461bcd60e51b815260040161047990610a3e565b61062c61093a565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff166109615760405162461bcd60e51b815260040161047990610a3e565b61062c33610865565b60008082840360a081121561097e57600080fd5b833592506080601f198201121561099457600080fd5b506020830190509250929050565b6001600160a01b038116811461079257600080fd5b6000602082840312156109c957600080fd5b81356109d4816109a2565b9392505050565b6000602082840312156109ed57600080fd5b813560ff811681146109d457600080fd5b600060208284031215610a1057600080fd5b5051919050565b81810381811115610a3857634e487b7160e01b600052601160045260246000fd5b92915050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea26469706673582212202a5366146f46faa5442344d8b38cb389baf682ed6006aecb0bc51ebfd3050eaa64736f6c63430008110033", - "deployedBytecode": "0x6080604052600436106100ab5760003560e01c806390e4b7201161006457806390e4b720146101c4578063b5c89bab146101d9578063c4d66de81461020d578063e50855171461022d578063f2fde38b1461024d578063fc1768191461026d57600080fd5b806333c507ae146100b7578063460f2de1146101075780635342825314610129578063715018a61461015d5780637a0a3ac5146101725780638da5cb5b146101a657600080fd5b366100b257005b600080fd5b3480156100c357600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b03909116815260200160405180910390f35b34801561011357600080fd5b5061012761012236600461096a565b61028d565b005b34801561013557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561016957600080fd5b5061012761061a565b34801561017e57600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101b257600080fd5b506033546001600160a01b03166100eb565b3480156101d057600080fd5b506100eb61062e565b3480156101e557600080fd5b506100eb7f000000000000000000000000000000000000000000000000000000000000000081565b34801561021957600080fd5b506101276102283660046109b7565b610666565b34801561023957600080fd5b506101276102483660046109b7565b610781565b34801561025957600080fd5b506101276102683660046109b7565b610795565b34801561027957600080fd5b506097546100eb906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356102d26040890160208a016109db565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561034457600080fd5b505af1158015610358573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156103f5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061041991906109fe565b146104825760405162461bcd60e51b815260206004820152602e60248201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260448201526d1958dd08111bd0c8185b5bdd5b9d60921b60648201526084015b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156104f457600080fd5b505af1158015610508573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105249190610a17565b604051909150600090339083908381818185875af1925050503d8060008114610569576040519150601f19603f3d011682016040523d82523d6000602084013e61056e565b606091505b50509050806105d95760405162461bcd60e51b815260206004820152603160248201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604482015270696e672072656465656d6564205242544360781b6064820152608401610479565b60408051878152602081018490527f9d8e423b23af97e1b68e81e339269059cbacc1c8754155bf6f0fd3e5adf8abe8910160405180910390a1505050505050565b61062261080b565b61062c6000610865565b565b60006106617f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b600054610100900460ff16158080156106865750600054600160ff909116105b806106a05750303b1580156106a0575060005460ff166001145b6107035760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401610479565b6000805460ff191660011790558015610726576000805461ff0019166101001790555b61072e6108b7565b610737826108e6565b801561077d576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b61078961080b565b610792816108e6565b50565b61079d61080b565b6001600160a01b0381166108025760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610479565b61079281610865565b6033546001600160a01b0316331461062c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610479565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166108de5760405162461bcd60e51b815260040161047990610a3e565b61062c61093a565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff166109615760405162461bcd60e51b815260040161047990610a3e565b61062c33610865565b60008082840360a081121561097e57600080fd5b833592506080601f198201121561099457600080fd5b506020830190509250929050565b6001600160a01b038116811461079257600080fd5b6000602082840312156109c957600080fd5b81356109d4816109a2565b9392505050565b6000602082840312156109ed57600080fd5b813560ff811681146109d457600080fd5b600060208284031215610a1057600080fd5b5051919050565b81810381811115610a3857634e487b7160e01b600052601160045260246000fd5b92915050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea26469706673582212202a5366146f46faa5442344d8b38cb389baf682ed6006aecb0bc51ebfd3050eaa64736f6c63430008110033", + "numDeployments": 5, + "solcInputHash": "5e9cad20f8ac20fd24c0890da61ad30f", + "metadata": "{\"compiler\":{\"version\":\"0.8.17+commit.8df45f5f\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_moc\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_doc\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_dllr\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_massetManager\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_permit2\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"previousAdmin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newAdmin\",\"type\":\"address\"}],\"name\":\"AdminChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"beacon\",\"type\":\"address\"}],\"name\":\"BeaconUpgraded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fromDLLR\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"toRBTC\",\"type\":\"uint256\"}],\"name\":\"GetDocFromDllrAndRedeemRBTC\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newMocVendorAccount\",\"type\":\"address\"}],\"name\":\"MocVendorAccountSet\",\"type\":\"event\"},{\"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\":true,\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\"}],\"name\":\"Upgraded\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"dllr\",\"outputs\":[{\"internalType\":\"contract IDLLR\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"doc\",\"outputs\":[{\"internalType\":\"contract IERC20\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_dllrAmount\",\"type\":\"uint256\"},{\"components\":[{\"internalType\":\"uint256\",\"name\":\"deadline\",\"type\":\"uint256\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"internalType\":\"struct PermitParams\",\"name\":\"_permitParams\",\"type\":\"tuple\"}],\"name\":\"getDocFromDllrAndRedeemRBTC\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"struct ISignatureTransfer.TokenPermissions\",\"name\":\"permitted\",\"type\":\"tuple\"},{\"internalType\":\"uint256\",\"name\":\"nonce\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"deadline\",\"type\":\"uint256\"}],\"internalType\":\"struct ISignatureTransfer.PermitTransferFrom\",\"name\":\"permit\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"name\":\"getDocFromDllrAndRedeemRbtcWithPermit2\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_address\",\"type\":\"address\"}],\"name\":\"getPermit2Nonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProxyImplementation\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"_mocVendorAccount\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"massetManager\",\"outputs\":[{\"internalType\":\"contract IMassetManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"moc\",\"outputs\":[{\"internalType\":\"contract IMocMintRedeemDoc\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"mocVendorAccount\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"permit2\",\"outputs\":[{\"internalType\":\"contract IPermit2\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"newMocVedorAccount\",\"type\":\"address\"}],\"name\":\"setMocVendorAccount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"constructor\":{\"params\":{\"_dllr\":\"DLLR contract address\",\"_doc\":\"DoC contract address\",\"_massetManager\":\"MassetManager contract address\",\"_moc\":\"MoC main contract address\"}},\"getDocFromDllrAndRedeemRBTC(uint256,(uint256,uint8,bytes32,bytes32))\":{\"params\":{\"_dllrAmount\":\"The amount of the DLLR (mAsset) that will be burned in exchange for _toToken\",\"_permitParams\":\"EIP-2612 permit params: _deadline Expiration time of the signature. _v Last 1 byte of ECDSA signature. _r First 32 bytes of ECDSA signature. _s 32 bytes after _r in ECDSA signature.\"}},\"getDocFromDllrAndRedeemRbtcWithPermit2(((address,uint256),uint256,uint256),bytes)\":{\"params\":{\"permit\":\"permit data, in form of PermitTransferFrom struct.\",\"signature\":\"of the permit data.\"}},\"getPermit2Nonce(address)\":{\"details\":\"getter for currernt nonce\",\"params\":{\"_address\":\"address of owner\"},\"returns\":{\"_0\":\"current nonce of the owner's address\"}},\"getProxyImplementation()\":{\"details\":\"get the implementation logic address referring to ERC1967 standard.\",\"returns\":{\"_0\":\"logic implementation address.\"}},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"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.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"getDocFromDllrAndRedeemRBTC(uint256,(uint256,uint8,bytes32,bytes32))\":{\"notice\":\"how getDocFromDllrAndRedeemRBTC function works: ------------------------------------------------------------------------------------------- | Mynt | Money On Chain | ------------------------------------------------------------------------------------------- | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user | -------------------------------------------------------------------------------------------\"},\"getDocFromDllrAndRedeemRbtcWithPermit2(((address,uint256),uint256,uint256),bytes)\":{\"notice\":\"how getDocFromDllrAndRedeemRBTC function works: ------------------------------------------------------------------------------------------- | Mynt | Money On Chain | ------------------------------------------------------------------------------------------- | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user | -------------------------------------------------------------------------------------------\"},\"setMocVendorAccount(address)\":{\"notice\":\"Set MoC registered Vendor account to receive markup fees https://docs.moneyonchain.com/main-rbtc-contract/integration-with-moc-platform/vendors\"}},\"notice\":\"This contract provides compound functions with Money On Chain wrapping them in one transaction for convenience and to save on gas\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/integration/MoC/MocIntegration.sol\":\"MocIntegration\"},\"evmVersion\":\"london\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\",\"useLiteralContent\":true},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../utils/ContextUpgradeable.sol\\\";\\nimport \\\"../proxy/utils/Initializable.sol\\\";\\n\\n/**\\n * @dev Contract module which provides a basic access control mechanism, where\\n * there is an account (an owner) that can be granted exclusive access to\\n * specific functions.\\n *\\n * By default, the owner account will be the one that deploys the contract. This\\n * can later be changed with {transferOwnership}.\\n *\\n * This module is used through inheritance. It will make available the modifier\\n * `onlyOwner`, which can be applied to your functions to restrict their use to\\n * the owner.\\n */\\nabstract contract OwnableUpgradeable is Initializable, ContextUpgradeable {\\n address private _owner;\\n\\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\\n\\n /**\\n * @dev Initializes the contract setting the deployer as the initial owner.\\n */\\n function __Ownable_init() internal onlyInitializing {\\n __Ownable_init_unchained();\\n }\\n\\n function __Ownable_init_unchained() internal onlyInitializing {\\n _transferOwnership(_msgSender());\\n }\\n\\n /**\\n * @dev Throws if called by any account other than the owner.\\n */\\n modifier onlyOwner() {\\n _checkOwner();\\n _;\\n }\\n\\n /**\\n * @dev Returns the address of the current owner.\\n */\\n function owner() public view virtual returns (address) {\\n return _owner;\\n }\\n\\n /**\\n * @dev Throws if the sender is not the owner.\\n */\\n function _checkOwner() internal view virtual {\\n require(owner() == _msgSender(), \\\"Ownable: caller is not the owner\\\");\\n }\\n\\n /**\\n * @dev Leaves the contract without owner. It will not be possible to call\\n * `onlyOwner` functions anymore. Can only be called by the current owner.\\n *\\n * NOTE: Renouncing ownership will leave the contract without an owner,\\n * thereby removing any functionality that is only available to the owner.\\n */\\n function renounceOwnership() public virtual onlyOwner {\\n _transferOwnership(address(0));\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Can only be called by the current owner.\\n */\\n function transferOwnership(address newOwner) public virtual onlyOwner {\\n require(newOwner != address(0), \\\"Ownable: new owner is the zero address\\\");\\n _transferOwnership(newOwner);\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Internal function without access restriction.\\n */\\n function _transferOwnership(address newOwner) internal virtual {\\n address oldOwner = _owner;\\n _owner = newOwner;\\n emit OwnershipTransferred(oldOwner, newOwner);\\n }\\n\\n /**\\n * @dev This empty reserved space is put in place to allow future versions to add new\\n * variables without shifting down storage in the inheritance chain.\\n * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps\\n */\\n uint256[49] private __gap;\\n}\\n\",\"keccak256\":\"0x247c62047745915c0af6b955470a72d1696ebad4352d7d3011aef1a2463cd888\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/interfaces/IERC1967Upgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.3) (interfaces/IERC1967.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev ERC-1967: Proxy Storage Slots. This interface contains the events defined in the ERC.\\n *\\n * _Available since v4.9._\\n */\\ninterface IERC1967Upgradeable {\\n /**\\n * @dev Emitted when the implementation is upgraded.\\n */\\n event Upgraded(address indexed implementation);\\n\\n /**\\n * @dev Emitted when the admin account has changed.\\n */\\n event AdminChanged(address previousAdmin, address newAdmin);\\n\\n /**\\n * @dev Emitted when the beacon is changed.\\n */\\n event BeaconUpgraded(address indexed beacon);\\n}\\n\",\"keccak256\":\"0xb8d68221343ed784c7b76edb6a686cb65e49c476d9e22bb89a5c0c3947ff14db\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/interfaces/draft-IERC1822Upgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.5.0) (interfaces/draft-IERC1822.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev ERC1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified\\n * proxy whose upgrades are fully controlled by the current implementation.\\n */\\ninterface IERC1822ProxiableUpgradeable {\\n /**\\n * @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation\\n * address.\\n *\\n * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\\n * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\\n * function revert if invoked through a proxy.\\n */\\n function proxiableUUID() external view returns (bytes32);\\n}\\n\",\"keccak256\":\"0x77c89f893e403efc6929ba842b7ccf6534d4ffe03afe31670b4a528c0ad78c0f\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/proxy/ERC1967/ERC1967UpgradeUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.3) (proxy/ERC1967/ERC1967Upgrade.sol)\\n\\npragma solidity ^0.8.2;\\n\\nimport \\\"../beacon/IBeaconUpgradeable.sol\\\";\\nimport \\\"../../interfaces/IERC1967Upgradeable.sol\\\";\\nimport \\\"../../interfaces/draft-IERC1822Upgradeable.sol\\\";\\nimport \\\"../../utils/AddressUpgradeable.sol\\\";\\nimport \\\"../../utils/StorageSlotUpgradeable.sol\\\";\\nimport \\\"../utils/Initializable.sol\\\";\\n\\n/**\\n * @dev This abstract contract provides getters and event emitting update functions for\\n * https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots.\\n *\\n * _Available since v4.1._\\n *\\n * @custom:oz-upgrades-unsafe-allow delegatecall\\n */\\nabstract contract ERC1967UpgradeUpgradeable is Initializable, IERC1967Upgradeable {\\n function __ERC1967Upgrade_init() internal onlyInitializing {\\n }\\n\\n function __ERC1967Upgrade_init_unchained() internal onlyInitializing {\\n }\\n // This is the keccak-256 hash of \\\"eip1967.proxy.rollback\\\" subtracted by 1\\n bytes32 private constant _ROLLBACK_SLOT = 0x4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143;\\n\\n /**\\n * @dev Storage slot with the address of the current implementation.\\n * This is the keccak-256 hash of \\\"eip1967.proxy.implementation\\\" subtracted by 1, and is\\n * validated in the constructor.\\n */\\n bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\\n\\n /**\\n * @dev Returns the current implementation address.\\n */\\n function _getImplementation() internal view returns (address) {\\n return StorageSlotUpgradeable.getAddressSlot(_IMPLEMENTATION_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new address in the EIP1967 implementation slot.\\n */\\n function _setImplementation(address newImplementation) private {\\n require(AddressUpgradeable.isContract(newImplementation), \\\"ERC1967: new implementation is not a contract\\\");\\n StorageSlotUpgradeable.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\\n }\\n\\n /**\\n * @dev Perform implementation upgrade\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeTo(address newImplementation) internal {\\n _setImplementation(newImplementation);\\n emit Upgraded(newImplementation);\\n }\\n\\n /**\\n * @dev Perform implementation upgrade with additional setup call.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeToAndCall(\\n address newImplementation,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n _upgradeTo(newImplementation);\\n if (data.length > 0 || forceCall) {\\n _functionDelegateCall(newImplementation, data);\\n }\\n }\\n\\n /**\\n * @dev Perform implementation upgrade with security checks for UUPS proxies, and additional setup call.\\n *\\n * Emits an {Upgraded} event.\\n */\\n function _upgradeToAndCallUUPS(\\n address newImplementation,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n // Upgrades from old implementations will perform a rollback test. This test requires the new\\n // implementation to upgrade back to the old, non-ERC1822 compliant, implementation. Removing\\n // this special case will break upgrade paths from old UUPS implementation to new ones.\\n if (StorageSlotUpgradeable.getBooleanSlot(_ROLLBACK_SLOT).value) {\\n _setImplementation(newImplementation);\\n } else {\\n try IERC1822ProxiableUpgradeable(newImplementation).proxiableUUID() returns (bytes32 slot) {\\n require(slot == _IMPLEMENTATION_SLOT, \\\"ERC1967Upgrade: unsupported proxiableUUID\\\");\\n } catch {\\n revert(\\\"ERC1967Upgrade: new implementation is not UUPS\\\");\\n }\\n _upgradeToAndCall(newImplementation, data, forceCall);\\n }\\n }\\n\\n /**\\n * @dev Storage slot with the admin of the contract.\\n * This is the keccak-256 hash of \\\"eip1967.proxy.admin\\\" subtracted by 1, and is\\n * validated in the constructor.\\n */\\n bytes32 internal constant _ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;\\n\\n /**\\n * @dev Returns the current admin.\\n */\\n function _getAdmin() internal view returns (address) {\\n return StorageSlotUpgradeable.getAddressSlot(_ADMIN_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new address in the EIP1967 admin slot.\\n */\\n function _setAdmin(address newAdmin) private {\\n require(newAdmin != address(0), \\\"ERC1967: new admin is the zero address\\\");\\n StorageSlotUpgradeable.getAddressSlot(_ADMIN_SLOT).value = newAdmin;\\n }\\n\\n /**\\n * @dev Changes the admin of the proxy.\\n *\\n * Emits an {AdminChanged} event.\\n */\\n function _changeAdmin(address newAdmin) internal {\\n emit AdminChanged(_getAdmin(), newAdmin);\\n _setAdmin(newAdmin);\\n }\\n\\n /**\\n * @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy.\\n * This is bytes32(uint256(keccak256('eip1967.proxy.beacon')) - 1)) and is validated in the constructor.\\n */\\n bytes32 internal constant _BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50;\\n\\n /**\\n * @dev Returns the current beacon.\\n */\\n function _getBeacon() internal view returns (address) {\\n return StorageSlotUpgradeable.getAddressSlot(_BEACON_SLOT).value;\\n }\\n\\n /**\\n * @dev Stores a new beacon in the EIP1967 beacon slot.\\n */\\n function _setBeacon(address newBeacon) private {\\n require(AddressUpgradeable.isContract(newBeacon), \\\"ERC1967: new beacon is not a contract\\\");\\n require(\\n AddressUpgradeable.isContract(IBeaconUpgradeable(newBeacon).implementation()),\\n \\\"ERC1967: beacon implementation is not a contract\\\"\\n );\\n StorageSlotUpgradeable.getAddressSlot(_BEACON_SLOT).value = newBeacon;\\n }\\n\\n /**\\n * @dev Perform beacon upgrade with additional setup call. Note: This upgrades the address of the beacon, it does\\n * not upgrade the implementation contained in the beacon (see {UpgradeableBeacon-_setImplementation} for that).\\n *\\n * Emits a {BeaconUpgraded} event.\\n */\\n function _upgradeBeaconToAndCall(\\n address newBeacon,\\n bytes memory data,\\n bool forceCall\\n ) internal {\\n _setBeacon(newBeacon);\\n emit BeaconUpgraded(newBeacon);\\n if (data.length > 0 || forceCall) {\\n _functionDelegateCall(IBeaconUpgradeable(newBeacon).implementation(), data);\\n }\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\\n * but performing a delegate call.\\n *\\n * _Available since v3.4._\\n */\\n function _functionDelegateCall(address target, bytes memory data) private returns (bytes memory) {\\n require(AddressUpgradeable.isContract(target), \\\"Address: delegate call to non-contract\\\");\\n\\n // solhint-disable-next-line avoid-low-level-calls\\n (bool success, bytes memory returndata) = target.delegatecall(data);\\n return AddressUpgradeable.verifyCallResult(success, returndata, \\\"Address: low-level delegate call failed\\\");\\n }\\n\\n /**\\n * @dev This empty reserved space is put in place to allow future versions to add new\\n * variables without shifting down storage in the inheritance chain.\\n * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps\\n */\\n uint256[50] private __gap;\\n}\\n\",\"keccak256\":\"0x1599637b52d20dc3954cea44914b2a4a9a8a5caade58d9da947e0b6c9acc07ba\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/proxy/beacon/IBeaconUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (proxy/beacon/IBeacon.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev This is the interface that {BeaconProxy} expects of its beacon.\\n */\\ninterface IBeaconUpgradeable {\\n /**\\n * @dev Must return an address that can be used as a delegate call target.\\n *\\n * {BeaconProxy} will check that this address is a contract.\\n */\\n function implementation() external view returns (address);\\n}\\n\",\"keccak256\":\"0x24b86ac8c005b8c654fbf6ac34a5a4f61580d7273541e83e013e89d66fbf0908\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.1) (proxy/utils/Initializable.sol)\\n\\npragma solidity ^0.8.2;\\n\\nimport \\\"../../utils/AddressUpgradeable.sol\\\";\\n\\n/**\\n * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed\\n * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an\\n * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer\\n * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.\\n *\\n * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be\\n * reused. This mechanism prevents re-execution of each \\\"step\\\" but allows the creation of new initialization steps in\\n * case an upgrade adds a module that needs to be initialized.\\n *\\n * For example:\\n *\\n * [.hljs-theme-light.nopadding]\\n * ```\\n * contract MyToken is ERC20Upgradeable {\\n * function initialize() initializer public {\\n * __ERC20_init(\\\"MyToken\\\", \\\"MTK\\\");\\n * }\\n * }\\n * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {\\n * function initializeV2() reinitializer(2) public {\\n * __ERC20Permit_init(\\\"MyToken\\\");\\n * }\\n * }\\n * ```\\n *\\n * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as\\n * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.\\n *\\n * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure\\n * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.\\n *\\n * [CAUTION]\\n * ====\\n * Avoid leaving a contract uninitialized.\\n *\\n * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation\\n * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke\\n * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:\\n *\\n * [.hljs-theme-light.nopadding]\\n * ```\\n * /// @custom:oz-upgrades-unsafe-allow constructor\\n * constructor() {\\n * _disableInitializers();\\n * }\\n * ```\\n * ====\\n */\\nabstract contract Initializable {\\n /**\\n * @dev Indicates that the contract has been initialized.\\n * @custom:oz-retyped-from bool\\n */\\n uint8 private _initialized;\\n\\n /**\\n * @dev Indicates that the contract is in the process of being initialized.\\n */\\n bool private _initializing;\\n\\n /**\\n * @dev Triggered when the contract has been initialized or reinitialized.\\n */\\n event Initialized(uint8 version);\\n\\n /**\\n * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,\\n * `onlyInitializing` functions can be used to initialize parent contracts.\\n *\\n * Similar to `reinitializer(1)`, except that functions marked with `initializer` can be nested in the context of a\\n * constructor.\\n *\\n * Emits an {Initialized} event.\\n */\\n modifier initializer() {\\n bool isTopLevelCall = !_initializing;\\n require(\\n (isTopLevelCall && _initialized < 1) || (!AddressUpgradeable.isContract(address(this)) && _initialized == 1),\\n \\\"Initializable: contract is already initialized\\\"\\n );\\n _initialized = 1;\\n if (isTopLevelCall) {\\n _initializing = true;\\n }\\n _;\\n if (isTopLevelCall) {\\n _initializing = false;\\n emit Initialized(1);\\n }\\n }\\n\\n /**\\n * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the\\n * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be\\n * used to initialize parent contracts.\\n *\\n * A reinitializer may be used after the original initialization step. This is essential to configure modules that\\n * are added through upgrades and that require initialization.\\n *\\n * When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`\\n * cannot be nested. If one is invoked in the context of another, execution will revert.\\n *\\n * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in\\n * a contract, executing them in the right order is up to the developer or operator.\\n *\\n * WARNING: setting the version to 255 will prevent any future reinitialization.\\n *\\n * Emits an {Initialized} event.\\n */\\n modifier reinitializer(uint8 version) {\\n require(!_initializing && _initialized < version, \\\"Initializable: contract is already initialized\\\");\\n _initialized = version;\\n _initializing = true;\\n _;\\n _initializing = false;\\n emit Initialized(version);\\n }\\n\\n /**\\n * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the\\n * {initializer} and {reinitializer} modifiers, directly or indirectly.\\n */\\n modifier onlyInitializing() {\\n require(_initializing, \\\"Initializable: contract is not initializing\\\");\\n _;\\n }\\n\\n /**\\n * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.\\n * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized\\n * to any version. It is recommended to use this to lock implementation contracts that are designed to be called\\n * through proxies.\\n *\\n * Emits an {Initialized} event the first time it is successfully executed.\\n */\\n function _disableInitializers() internal virtual {\\n require(!_initializing, \\\"Initializable: contract is initializing\\\");\\n if (_initialized < type(uint8).max) {\\n _initialized = type(uint8).max;\\n emit Initialized(type(uint8).max);\\n }\\n }\\n\\n /**\\n * @dev Returns the highest version that has been initialized. See {reinitializer}.\\n */\\n function _getInitializedVersion() internal view returns (uint8) {\\n return _initialized;\\n }\\n\\n /**\\n * @dev Returns `true` if the contract is currently initializing. See {onlyInitializing}.\\n */\\n function _isInitializing() internal view returns (bool) {\\n return _initializing;\\n }\\n}\\n\",\"keccak256\":\"0x037c334add4b033ad3493038c25be1682d78c00992e1acb0e2795caff3925271\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/utils/AddressUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)\\n\\npragma solidity ^0.8.1;\\n\\n/**\\n * @dev Collection of functions related to the address type\\n */\\nlibrary AddressUpgradeable {\\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 * [IMPORTANT]\\n * ====\\n * You shouldn't rely on `isContract` to protect against flash loan attacks!\\n *\\n * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets\\n * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract\\n * constructor.\\n * ====\\n */\\n function isContract(address account) internal view returns (bool) {\\n // This method relies on extcodesize/address.code.length, which returns 0\\n // for contracts in construction, since the code is only stored at the end\\n // of the constructor execution.\\n\\n return account.code.length > 0;\\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 (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 functionCallWithValue(target, data, 0, \\\"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(\\n address target,\\n bytes memory data,\\n string memory errorMessage\\n ) 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(\\n address target,\\n bytes memory data,\\n uint256 value\\n ) 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(\\n address target,\\n bytes memory data,\\n uint256 value,\\n string memory errorMessage\\n ) internal returns (bytes memory) {\\n require(address(this).balance >= value, \\\"Address: insufficient balance for call\\\");\\n (bool success, bytes memory returndata) = target.call{value: value}(data);\\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\\n * but performing a static call.\\n *\\n * _Available since v3.3._\\n */\\n function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {\\n return functionStaticCall(target, data, \\\"Address: low-level static call failed\\\");\\n }\\n\\n /**\\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\\n * but performing a static call.\\n *\\n * _Available since v3.3._\\n */\\n function functionStaticCall(\\n address target,\\n bytes memory data,\\n string memory errorMessage\\n ) internal view returns (bytes memory) {\\n (bool success, bytes memory returndata) = target.staticcall(data);\\n return verifyCallResultFromTarget(target, success, returndata, errorMessage);\\n }\\n\\n /**\\n * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling\\n * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.\\n *\\n * _Available since v4.8._\\n */\\n function verifyCallResultFromTarget(\\n address target,\\n bool success,\\n bytes memory returndata,\\n string memory errorMessage\\n ) internal view returns (bytes memory) {\\n if (success) {\\n if (returndata.length == 0) {\\n // only check isContract if the call was successful and the return data is empty\\n // otherwise we already know that it was a contract\\n require(isContract(target), \\\"Address: call to non-contract\\\");\\n }\\n return returndata;\\n } else {\\n _revert(returndata, errorMessage);\\n }\\n }\\n\\n /**\\n * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the\\n * revert reason or using the provided one.\\n *\\n * _Available since v4.3._\\n */\\n function verifyCallResult(\\n bool success,\\n bytes memory returndata,\\n string memory errorMessage\\n ) internal pure returns (bytes memory) {\\n if (success) {\\n return returndata;\\n } else {\\n _revert(returndata, errorMessage);\\n }\\n }\\n\\n function _revert(bytes memory returndata, string memory errorMessage) private pure {\\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 /// @solidity memory-safe-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\",\"keccak256\":\"0x2edcb41c121abc510932e8d83ff8b82cf9cdde35e7c297622f5c29ef0af25183\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)\\n\\npragma solidity ^0.8.0;\\nimport \\\"../proxy/utils/Initializable.sol\\\";\\n\\n/**\\n * @dev Provides information about the current execution context, including the\\n * sender of the transaction and its data. While these are generally available\\n * via msg.sender and msg.data, they should not be accessed in such a direct\\n * manner, since when dealing with meta-transactions the account sending and\\n * paying for execution may not be the actual sender (as far as an application\\n * is concerned).\\n *\\n * This contract is only required for intermediate, library-like contracts.\\n */\\nabstract contract ContextUpgradeable is Initializable {\\n function __Context_init() internal onlyInitializing {\\n }\\n\\n function __Context_init_unchained() internal onlyInitializing {\\n }\\n function _msgSender() internal view virtual returns (address) {\\n return msg.sender;\\n }\\n\\n function _msgData() internal view virtual returns (bytes calldata) {\\n return msg.data;\\n }\\n\\n /**\\n * @dev This empty reserved space is put in place to allow future versions to add new\\n * variables without shifting down storage in the inheritance chain.\\n * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps\\n */\\n uint256[50] private __gap;\\n}\\n\",\"keccak256\":\"0x963ea7f0b48b032eef72fe3a7582edf78408d6f834115b9feadd673a4d5bd149\",\"license\":\"MIT\"},\"@openzeppelin/contracts-upgradeable/utils/StorageSlotUpgradeable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (utils/StorageSlot.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Library for reading and writing primitive types to specific storage slots.\\n *\\n * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.\\n * This library helps with reading and writing to such slots without the need for inline assembly.\\n *\\n * The functions in this library return Slot structs that contain a `value` member that can be used to read or write.\\n *\\n * Example usage to set ERC1967 implementation slot:\\n * ```\\n * contract ERC1967 {\\n * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\\n *\\n * function _getImplementation() internal view returns (address) {\\n * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\\n * }\\n *\\n * function _setImplementation(address newImplementation) internal {\\n * require(Address.isContract(newImplementation), \\\"ERC1967: new implementation is not a contract\\\");\\n * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\\n * }\\n * }\\n * ```\\n *\\n * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._\\n */\\nlibrary StorageSlotUpgradeable {\\n struct AddressSlot {\\n address value;\\n }\\n\\n struct BooleanSlot {\\n bool value;\\n }\\n\\n struct Bytes32Slot {\\n bytes32 value;\\n }\\n\\n struct Uint256Slot {\\n uint256 value;\\n }\\n\\n /**\\n * @dev Returns an `AddressSlot` with member `value` located at `slot`.\\n */\\n function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `BooleanSlot` with member `value` located at `slot`.\\n */\\n function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `Bytes32Slot` with member `value` located at `slot`.\\n */\\n function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n\\n /**\\n * @dev Returns an `Uint256Slot` with member `value` located at `slot`.\\n */\\n function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {\\n /// @solidity memory-safe-assembly\\n assembly {\\n r.slot := slot\\n }\\n }\\n}\\n\",\"keccak256\":\"0x09864aea84f01e39313375b5610c73a3c1c68abbdc51e5ccdd25ff977fdadf9a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/access/Ownable.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../utils/Context.sol\\\";\\n\\n/**\\n * @dev Contract module which provides a basic access control mechanism, where\\n * there is an account (an owner) that can be granted exclusive access to\\n * specific functions.\\n *\\n * By default, the owner account will be the one that deploys the contract. This\\n * can later be changed with {transferOwnership}.\\n *\\n * This module is used through inheritance. It will make available the modifier\\n * `onlyOwner`, which can be applied to your functions to restrict their use to\\n * the owner.\\n */\\nabstract contract Ownable is Context {\\n address private _owner;\\n\\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\\n\\n /**\\n * @dev Initializes the contract setting the deployer as the initial owner.\\n */\\n constructor() {\\n _transferOwnership(_msgSender());\\n }\\n\\n /**\\n * @dev Throws if called by any account other than the owner.\\n */\\n modifier onlyOwner() {\\n _checkOwner();\\n _;\\n }\\n\\n /**\\n * @dev Returns the address of the current owner.\\n */\\n function owner() public view virtual returns (address) {\\n return _owner;\\n }\\n\\n /**\\n * @dev Throws if the sender is not the owner.\\n */\\n function _checkOwner() internal view virtual {\\n require(owner() == _msgSender(), \\\"Ownable: caller is not the owner\\\");\\n }\\n\\n /**\\n * @dev Leaves the contract without owner. It will not be possible to call\\n * `onlyOwner` functions anymore. Can only be called by the current owner.\\n *\\n * NOTE: Renouncing ownership will leave the contract without an owner,\\n * thereby removing any functionality that is only available to the owner.\\n */\\n function renounceOwnership() public virtual onlyOwner {\\n _transferOwnership(address(0));\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Can only be called by the current owner.\\n */\\n function transferOwnership(address newOwner) public virtual onlyOwner {\\n require(newOwner != address(0), \\\"Ownable: new owner is the zero address\\\");\\n _transferOwnership(newOwner);\\n }\\n\\n /**\\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\\n * Internal function without access restriction.\\n */\\n function _transferOwnership(address newOwner) internal virtual {\\n address oldOwner = _owner;\\n _owner = newOwner;\\n emit OwnershipTransferred(oldOwner, newOwner);\\n }\\n}\\n\",\"keccak256\":\"0xa94b34880e3c1b0b931662cb1c09e5dfa6662f31cba80e07c5ee71cd135c9673\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/ERC20.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/ERC20.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./IERC20.sol\\\";\\nimport \\\"./extensions/IERC20Metadata.sol\\\";\\nimport \\\"../../utils/Context.sol\\\";\\n\\n/**\\n * @dev Implementation of the {IERC20} interface.\\n *\\n * This implementation is agnostic to the way tokens are created. This means\\n * that a supply mechanism has to be added in a derived contract using {_mint}.\\n * For a generic mechanism see {ERC20PresetMinterPauser}.\\n *\\n * TIP: For a detailed writeup see our guide\\n * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How\\n * to implement supply mechanisms].\\n *\\n * We have followed general OpenZeppelin Contracts guidelines: functions revert\\n * instead returning `false` on failure. This behavior is nonetheless\\n * conventional and does not conflict with the expectations of ERC20\\n * applications.\\n *\\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\\n * This allows applications to reconstruct the allowance for all accounts just\\n * by listening to said events. Other implementations of the EIP may not emit\\n * these events, as it isn't required by the specification.\\n *\\n * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}\\n * functions have been added to mitigate the well-known issues around setting\\n * allowances. See {IERC20-approve}.\\n */\\ncontract ERC20 is Context, IERC20, IERC20Metadata {\\n mapping(address => uint256) private _balances;\\n\\n mapping(address => mapping(address => uint256)) private _allowances;\\n\\n uint256 private _totalSupply;\\n\\n string private _name;\\n string private _symbol;\\n\\n /**\\n * @dev Sets the values for {name} and {symbol}.\\n *\\n * The default value of {decimals} is 18. To select a different value for\\n * {decimals} you should overload it.\\n *\\n * All two of these values are immutable: they can only be set once during\\n * construction.\\n */\\n constructor(string memory name_, string memory symbol_) {\\n _name = name_;\\n _symbol = symbol_;\\n }\\n\\n /**\\n * @dev Returns the name of the token.\\n */\\n function name() public view virtual override returns (string memory) {\\n return _name;\\n }\\n\\n /**\\n * @dev Returns the symbol of the token, usually a shorter version of the\\n * name.\\n */\\n function symbol() public view virtual override returns (string memory) {\\n return _symbol;\\n }\\n\\n /**\\n * @dev Returns the number of decimals used to get its user representation.\\n * For example, if `decimals` equals `2`, a balance of `505` tokens should\\n * be displayed to a user as `5.05` (`505 / 10 ** 2`).\\n *\\n * Tokens usually opt for a value of 18, imitating the relationship between\\n * Ether and Wei. This is the value {ERC20} uses, unless this function is\\n * overridden;\\n *\\n * NOTE: This information is only used for _display_ purposes: it in\\n * no way affects any of the arithmetic of the contract, including\\n * {IERC20-balanceOf} and {IERC20-transfer}.\\n */\\n function decimals() public view virtual override returns (uint8) {\\n return 18;\\n }\\n\\n /**\\n * @dev See {IERC20-totalSupply}.\\n */\\n function totalSupply() public view virtual override returns (uint256) {\\n return _totalSupply;\\n }\\n\\n /**\\n * @dev See {IERC20-balanceOf}.\\n */\\n function balanceOf(address account) public view virtual override returns (uint256) {\\n return _balances[account];\\n }\\n\\n /**\\n * @dev See {IERC20-transfer}.\\n *\\n * Requirements:\\n *\\n * - `to` cannot be the zero address.\\n * - the caller must have a balance of at least `amount`.\\n */\\n function transfer(address to, uint256 amount) public virtual override returns (bool) {\\n address owner = _msgSender();\\n _transfer(owner, to, amount);\\n return true;\\n }\\n\\n /**\\n * @dev See {IERC20-allowance}.\\n */\\n function allowance(address owner, address spender) public view virtual override returns (uint256) {\\n return _allowances[owner][spender];\\n }\\n\\n /**\\n * @dev See {IERC20-approve}.\\n *\\n * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on\\n * `transferFrom`. This is semantically equivalent to an infinite approval.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n */\\n function approve(address spender, uint256 amount) public virtual override returns (bool) {\\n address owner = _msgSender();\\n _approve(owner, spender, amount);\\n return true;\\n }\\n\\n /**\\n * @dev See {IERC20-transferFrom}.\\n *\\n * Emits an {Approval} event indicating the updated allowance. This is not\\n * required by the EIP. See the note at the beginning of {ERC20}.\\n *\\n * NOTE: Does not update the allowance if the current allowance\\n * is the maximum `uint256`.\\n *\\n * Requirements:\\n *\\n * - `from` and `to` cannot be the zero address.\\n * - `from` must have a balance of at least `amount`.\\n * - the caller must have allowance for ``from``'s tokens of at least\\n * `amount`.\\n */\\n function transferFrom(\\n address from,\\n address to,\\n uint256 amount\\n ) public virtual override returns (bool) {\\n address spender = _msgSender();\\n _spendAllowance(from, spender, amount);\\n _transfer(from, to, amount);\\n return true;\\n }\\n\\n /**\\n * @dev Atomically increases the allowance granted to `spender` by the caller.\\n *\\n * This is an alternative to {approve} that can be used as a mitigation for\\n * problems described in {IERC20-approve}.\\n *\\n * Emits an {Approval} event indicating the updated allowance.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n */\\n function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {\\n address owner = _msgSender();\\n _approve(owner, spender, allowance(owner, spender) + addedValue);\\n return true;\\n }\\n\\n /**\\n * @dev Atomically decreases the allowance granted to `spender` by the caller.\\n *\\n * This is an alternative to {approve} that can be used as a mitigation for\\n * problems described in {IERC20-approve}.\\n *\\n * Emits an {Approval} event indicating the updated allowance.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n * - `spender` must have allowance for the caller of at least\\n * `subtractedValue`.\\n */\\n function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {\\n address owner = _msgSender();\\n uint256 currentAllowance = allowance(owner, spender);\\n require(currentAllowance >= subtractedValue, \\\"ERC20: decreased allowance below zero\\\");\\n unchecked {\\n _approve(owner, spender, currentAllowance - subtractedValue);\\n }\\n\\n return true;\\n }\\n\\n /**\\n * @dev Moves `amount` of tokens from `from` to `to`.\\n *\\n * This internal function is equivalent to {transfer}, and can be used to\\n * e.g. implement automatic token fees, slashing mechanisms, etc.\\n *\\n * Emits a {Transfer} event.\\n *\\n * Requirements:\\n *\\n * - `from` cannot be the zero address.\\n * - `to` cannot be the zero address.\\n * - `from` must have a balance of at least `amount`.\\n */\\n function _transfer(\\n address from,\\n address to,\\n uint256 amount\\n ) internal virtual {\\n require(from != address(0), \\\"ERC20: transfer from the zero address\\\");\\n require(to != address(0), \\\"ERC20: transfer to the zero address\\\");\\n\\n _beforeTokenTransfer(from, to, amount);\\n\\n uint256 fromBalance = _balances[from];\\n require(fromBalance >= amount, \\\"ERC20: transfer amount exceeds balance\\\");\\n unchecked {\\n _balances[from] = fromBalance - amount;\\n // Overflow not possible: the sum of all balances is capped by totalSupply, and the sum is preserved by\\n // decrementing then incrementing.\\n _balances[to] += amount;\\n }\\n\\n emit Transfer(from, to, amount);\\n\\n _afterTokenTransfer(from, to, amount);\\n }\\n\\n /** @dev Creates `amount` tokens and assigns them to `account`, increasing\\n * the total supply.\\n *\\n * Emits a {Transfer} event with `from` set to the zero address.\\n *\\n * Requirements:\\n *\\n * - `account` cannot be the zero address.\\n */\\n function _mint(address account, uint256 amount) internal virtual {\\n require(account != address(0), \\\"ERC20: mint to the zero address\\\");\\n\\n _beforeTokenTransfer(address(0), account, amount);\\n\\n _totalSupply += amount;\\n unchecked {\\n // Overflow not possible: balance + amount is at most totalSupply + amount, which is checked above.\\n _balances[account] += amount;\\n }\\n emit Transfer(address(0), account, amount);\\n\\n _afterTokenTransfer(address(0), account, amount);\\n }\\n\\n /**\\n * @dev Destroys `amount` tokens from `account`, reducing the\\n * total supply.\\n *\\n * Emits a {Transfer} event with `to` set to the zero address.\\n *\\n * Requirements:\\n *\\n * - `account` cannot be the zero address.\\n * - `account` must have at least `amount` tokens.\\n */\\n function _burn(address account, uint256 amount) internal virtual {\\n require(account != address(0), \\\"ERC20: burn from the zero address\\\");\\n\\n _beforeTokenTransfer(account, address(0), amount);\\n\\n uint256 accountBalance = _balances[account];\\n require(accountBalance >= amount, \\\"ERC20: burn amount exceeds balance\\\");\\n unchecked {\\n _balances[account] = accountBalance - amount;\\n // Overflow not possible: amount <= accountBalance <= totalSupply.\\n _totalSupply -= amount;\\n }\\n\\n emit Transfer(account, address(0), amount);\\n\\n _afterTokenTransfer(account, address(0), amount);\\n }\\n\\n /**\\n * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.\\n *\\n * This internal function is equivalent to `approve`, and can be used to\\n * e.g. set automatic allowances for certain subsystems, etc.\\n *\\n * Emits an {Approval} event.\\n *\\n * Requirements:\\n *\\n * - `owner` cannot be the zero address.\\n * - `spender` cannot be the zero address.\\n */\\n function _approve(\\n address owner,\\n address spender,\\n uint256 amount\\n ) internal virtual {\\n require(owner != address(0), \\\"ERC20: approve from the zero address\\\");\\n require(spender != address(0), \\\"ERC20: approve to the zero address\\\");\\n\\n _allowances[owner][spender] = amount;\\n emit Approval(owner, spender, amount);\\n }\\n\\n /**\\n * @dev Updates `owner` s allowance for `spender` based on spent `amount`.\\n *\\n * Does not update the allowance amount in case of infinite allowance.\\n * Revert if not enough allowance is available.\\n *\\n * Might emit an {Approval} event.\\n */\\n function _spendAllowance(\\n address owner,\\n address spender,\\n uint256 amount\\n ) internal virtual {\\n uint256 currentAllowance = allowance(owner, spender);\\n if (currentAllowance != type(uint256).max) {\\n require(currentAllowance >= amount, \\\"ERC20: insufficient allowance\\\");\\n unchecked {\\n _approve(owner, spender, currentAllowance - amount);\\n }\\n }\\n }\\n\\n /**\\n * @dev Hook that is called before any transfer of tokens. This includes\\n * minting and burning.\\n *\\n * Calling conditions:\\n *\\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\\n * will be transferred to `to`.\\n * - when `from` is zero, `amount` tokens will be minted for `to`.\\n * - when `to` is zero, `amount` of ``from``'s tokens will be burned.\\n * - `from` and `to` are never both zero.\\n *\\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\\n */\\n function _beforeTokenTransfer(\\n address from,\\n address to,\\n uint256 amount\\n ) internal virtual {}\\n\\n /**\\n * @dev Hook that is called after any transfer of tokens. This includes\\n * minting and burning.\\n *\\n * Calling conditions:\\n *\\n * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens\\n * has been transferred to `to`.\\n * - when `from` is zero, `amount` tokens have been minted for `to`.\\n * - when `to` is zero, `amount` of ``from``'s tokens have been burned.\\n * - `from` and `to` are never both zero.\\n *\\n * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].\\n */\\n function _afterTokenTransfer(\\n address from,\\n address to,\\n uint256 amount\\n ) internal virtual {}\\n}\\n\",\"keccak256\":\"0x4ffc0547c02ad22925310c585c0f166f8759e2648a09e9b489100c42f15dd98d\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Interface of the ERC20 standard as defined in the EIP.\\n */\\ninterface IERC20 {\\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 /**\\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 `to`.\\n *\\n * Returns a boolean value indicating whether the operation succeeded.\\n *\\n * Emits a {Transfer} event.\\n */\\n function transfer(address to, 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 `from` to `to` 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(\\n address from,\\n address to,\\n uint256 amount\\n ) external returns (bool);\\n}\\n\",\"keccak256\":\"0x9750c6b834f7b43000631af5cc30001c5f547b3ceb3635488f140f60e897ea6b\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../IERC20.sol\\\";\\n\\n/**\\n * @dev Interface for the optional metadata functions from the ERC20 standard.\\n *\\n * _Available since v4.1._\\n */\\ninterface IERC20Metadata is IERC20 {\\n /**\\n * @dev Returns the name of the token.\\n */\\n function name() external view returns (string memory);\\n\\n /**\\n * @dev Returns the symbol of the token.\\n */\\n function symbol() external view returns (string memory);\\n\\n /**\\n * @dev Returns the decimals places of the token.\\n */\\n function decimals() external view returns (uint8);\\n}\\n\",\"keccak256\":\"0x8de418a5503946cabe331f35fe242d3201a73f67f77aaeb7110acb1f30423aca\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/extensions/draft-ERC20Permit.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/extensions/draft-ERC20Permit.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./draft-IERC20Permit.sol\\\";\\nimport \\\"../ERC20.sol\\\";\\nimport \\\"../../../utils/cryptography/ECDSA.sol\\\";\\nimport \\\"../../../utils/cryptography/EIP712.sol\\\";\\nimport \\\"../../../utils/Counters.sol\\\";\\n\\n/**\\n * @dev Implementation of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in\\n * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].\\n *\\n * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by\\n * presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't\\n * need to send a transaction, and thus is not required to hold Ether at all.\\n *\\n * _Available since v3.4._\\n */\\nabstract contract ERC20Permit is ERC20, IERC20Permit, EIP712 {\\n using Counters for Counters.Counter;\\n\\n mapping(address => Counters.Counter) private _nonces;\\n\\n // solhint-disable-next-line var-name-mixedcase\\n bytes32 private constant _PERMIT_TYPEHASH =\\n keccak256(\\\"Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)\\\");\\n /**\\n * @dev In previous versions `_PERMIT_TYPEHASH` was declared as `immutable`.\\n * However, to ensure consistency with the upgradeable transpiler, we will continue\\n * to reserve a slot.\\n * @custom:oz-renamed-from _PERMIT_TYPEHASH\\n */\\n // solhint-disable-next-line var-name-mixedcase\\n bytes32 private _PERMIT_TYPEHASH_DEPRECATED_SLOT;\\n\\n /**\\n * @dev Initializes the {EIP712} domain separator using the `name` parameter, and setting `version` to `\\\"1\\\"`.\\n *\\n * It's a good idea to use the same `name` that is defined as the ERC20 token name.\\n */\\n constructor(string memory name) EIP712(name, \\\"1\\\") {}\\n\\n /**\\n * @dev See {IERC20Permit-permit}.\\n */\\n function permit(\\n address owner,\\n address spender,\\n uint256 value,\\n uint256 deadline,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) public virtual override {\\n require(block.timestamp <= deadline, \\\"ERC20Permit: expired deadline\\\");\\n\\n bytes32 structHash = keccak256(abi.encode(_PERMIT_TYPEHASH, owner, spender, value, _useNonce(owner), deadline));\\n\\n bytes32 hash = _hashTypedDataV4(structHash);\\n\\n address signer = ECDSA.recover(hash, v, r, s);\\n require(signer == owner, \\\"ERC20Permit: invalid signature\\\");\\n\\n _approve(owner, spender, value);\\n }\\n\\n /**\\n * @dev See {IERC20Permit-nonces}.\\n */\\n function nonces(address owner) public view virtual override returns (uint256) {\\n return _nonces[owner].current();\\n }\\n\\n /**\\n * @dev See {IERC20Permit-DOMAIN_SEPARATOR}.\\n */\\n // solhint-disable-next-line func-name-mixedcase\\n function DOMAIN_SEPARATOR() external view override returns (bytes32) {\\n return _domainSeparatorV4();\\n }\\n\\n /**\\n * @dev \\\"Consume a nonce\\\": return the current value and increment.\\n *\\n * _Available since v4.1._\\n */\\n function _useNonce(address owner) internal virtual returns (uint256 current) {\\n Counters.Counter storage nonce = _nonces[owner];\\n current = nonce.current();\\n nonce.increment();\\n }\\n}\\n\",\"keccak256\":\"0xd2dd6003a2dc02ab905fd405938322e510429d19ae6c07c2c683d70f13ab2f36\",\"license\":\"MIT\"},\"@openzeppelin/contracts/token/ERC20/extensions/draft-IERC20Permit.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in\\n * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].\\n *\\n * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by\\n * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't\\n * need to send a transaction, and thus is not required to hold Ether at all.\\n */\\ninterface IERC20Permit {\\n /**\\n * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,\\n * given ``owner``'s signed approval.\\n *\\n * IMPORTANT: The same issues {IERC20-approve} has related to transaction\\n * ordering also apply here.\\n *\\n * Emits an {Approval} event.\\n *\\n * Requirements:\\n *\\n * - `spender` cannot be the zero address.\\n * - `deadline` must be a timestamp in the future.\\n * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`\\n * over the EIP712-formatted function arguments.\\n * - the signature must use ``owner``'s current nonce (see {nonces}).\\n *\\n * For more information on the signature format, see the\\n * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP\\n * section].\\n */\\n function permit(\\n address owner,\\n address spender,\\n uint256 value,\\n uint256 deadline,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) external;\\n\\n /**\\n * @dev Returns the current nonce for `owner`. This value must be\\n * included whenever a signature is generated for {permit}.\\n *\\n * Every successful call to {permit} increases ``owner``'s nonce by one. This\\n * prevents a signature from being used multiple times.\\n */\\n function nonces(address owner) external view returns (uint256);\\n\\n /**\\n * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.\\n */\\n // solhint-disable-next-line func-name-mixedcase\\n function DOMAIN_SEPARATOR() external view returns (bytes32);\\n}\\n\",\"keccak256\":\"0xf41ca991f30855bf80ffd11e9347856a517b977f0a6c2d52e6421a99b7840329\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Context.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Provides information about the current execution context, including the\\n * sender of the transaction and its data. While these are generally available\\n * via msg.sender and msg.data, they should not be accessed in such a direct\\n * manner, since when dealing with meta-transactions the account sending and\\n * paying for execution may not be the actual sender (as far as an application\\n * is concerned).\\n *\\n * This contract is only required for intermediate, library-like contracts.\\n */\\nabstract contract Context {\\n function _msgSender() internal view virtual returns (address) {\\n return msg.sender;\\n }\\n\\n function _msgData() internal view virtual returns (bytes calldata) {\\n return msg.data;\\n }\\n}\\n\",\"keccak256\":\"0xe2e337e6dde9ef6b680e07338c493ebea1b5fd09b43424112868e9cc1706bca7\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Counters.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts v4.4.1 (utils/Counters.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @title Counters\\n * @author Matt Condon (@shrugs)\\n * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number\\n * of elements in a mapping, issuing ERC721 ids, or counting request ids.\\n *\\n * Include with `using Counters for Counters.Counter;`\\n */\\nlibrary Counters {\\n struct Counter {\\n // This variable should never be directly accessed by users of the library: interactions must be restricted to\\n // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add\\n // this feature: see https://github.com/ethereum/solidity/issues/4637\\n uint256 _value; // default: 0\\n }\\n\\n function current(Counter storage counter) internal view returns (uint256) {\\n return counter._value;\\n }\\n\\n function increment(Counter storage counter) internal {\\n unchecked {\\n counter._value += 1;\\n }\\n }\\n\\n function decrement(Counter storage counter) internal {\\n uint256 value = counter._value;\\n require(value > 0, \\\"Counter: decrement overflow\\\");\\n unchecked {\\n counter._value = value - 1;\\n }\\n }\\n\\n function reset(Counter storage counter) internal {\\n counter._value = 0;\\n }\\n}\\n\",\"keccak256\":\"0xf0018c2440fbe238dd3a8732fa8e17a0f9dce84d31451dc8a32f6d62b349c9f1\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/Strings.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./math/Math.sol\\\";\\n\\n/**\\n * @dev String operations.\\n */\\nlibrary Strings {\\n bytes16 private constant _SYMBOLS = \\\"0123456789abcdef\\\";\\n uint8 private constant _ADDRESS_LENGTH = 20;\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` decimal representation.\\n */\\n function toString(uint256 value) internal pure returns (string memory) {\\n unchecked {\\n uint256 length = Math.log10(value) + 1;\\n string memory buffer = new string(length);\\n uint256 ptr;\\n /// @solidity memory-safe-assembly\\n assembly {\\n ptr := add(buffer, add(32, length))\\n }\\n while (true) {\\n ptr--;\\n /// @solidity memory-safe-assembly\\n assembly {\\n mstore8(ptr, byte(mod(value, 10), _SYMBOLS))\\n }\\n value /= 10;\\n if (value == 0) break;\\n }\\n return buffer;\\n }\\n }\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.\\n */\\n function toHexString(uint256 value) internal pure returns (string memory) {\\n unchecked {\\n return toHexString(value, Math.log256(value) + 1);\\n }\\n }\\n\\n /**\\n * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.\\n */\\n function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {\\n bytes memory buffer = new bytes(2 * length + 2);\\n buffer[0] = \\\"0\\\";\\n buffer[1] = \\\"x\\\";\\n for (uint256 i = 2 * length + 1; i > 1; --i) {\\n buffer[i] = _SYMBOLS[value & 0xf];\\n value >>= 4;\\n }\\n require(value == 0, \\\"Strings: hex length insufficient\\\");\\n return string(buffer);\\n }\\n\\n /**\\n * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.\\n */\\n function toHexString(address addr) internal pure returns (string memory) {\\n return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);\\n }\\n}\\n\",\"keccak256\":\"0xa4d1d62251f8574deb032a35fc948386a9b4de74b812d4f545a1ac120486b48a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/cryptography/ECDSA.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/ECDSA.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"../Strings.sol\\\";\\n\\n/**\\n * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.\\n *\\n * These functions can be used to verify that a message was signed by the holder\\n * of the private keys of a given address.\\n */\\nlibrary ECDSA {\\n enum RecoverError {\\n NoError,\\n InvalidSignature,\\n InvalidSignatureLength,\\n InvalidSignatureS,\\n InvalidSignatureV // Deprecated in v4.8\\n }\\n\\n function _throwError(RecoverError error) private pure {\\n if (error == RecoverError.NoError) {\\n return; // no error: do nothing\\n } else if (error == RecoverError.InvalidSignature) {\\n revert(\\\"ECDSA: invalid signature\\\");\\n } else if (error == RecoverError.InvalidSignatureLength) {\\n revert(\\\"ECDSA: invalid signature length\\\");\\n } else if (error == RecoverError.InvalidSignatureS) {\\n revert(\\\"ECDSA: invalid signature 's' value\\\");\\n }\\n }\\n\\n /**\\n * @dev Returns the address that signed a hashed message (`hash`) with\\n * `signature` or error string. This address can then be used for verification purposes.\\n *\\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\\n * this function rejects them by requiring the `s` value to be in the lower\\n * half order, and the `v` value to be either 27 or 28.\\n *\\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\\n * verification to be secure: it is possible to craft signatures that\\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\\n * this is by receiving a hash of the original message (which may otherwise\\n * be too long), and then calling {toEthSignedMessageHash} on it.\\n *\\n * Documentation for signature generation:\\n * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]\\n * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) {\\n if (signature.length == 65) {\\n bytes32 r;\\n bytes32 s;\\n uint8 v;\\n // ecrecover takes the signature parameters, and the only way to get them\\n // currently is to use assembly.\\n /// @solidity memory-safe-assembly\\n assembly {\\n r := mload(add(signature, 0x20))\\n s := mload(add(signature, 0x40))\\n v := byte(0, mload(add(signature, 0x60)))\\n }\\n return tryRecover(hash, v, r, s);\\n } else {\\n return (address(0), RecoverError.InvalidSignatureLength);\\n }\\n }\\n\\n /**\\n * @dev Returns the address that signed a hashed message (`hash`) with\\n * `signature`. This address can then be used for verification purposes.\\n *\\n * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:\\n * this function rejects them by requiring the `s` value to be in the lower\\n * half order, and the `v` value to be either 27 or 28.\\n *\\n * IMPORTANT: `hash` _must_ be the result of a hash operation for the\\n * verification to be secure: it is possible to craft signatures that\\n * recover to arbitrary addresses for non-hashed data. A safe way to ensure\\n * this is by receiving a hash of the original message (which may otherwise\\n * be too long), and then calling {toEthSignedMessageHash} on it.\\n */\\n function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, signature);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.\\n *\\n * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(\\n bytes32 hash,\\n bytes32 r,\\n bytes32 vs\\n ) internal pure returns (address, RecoverError) {\\n bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff);\\n uint8 v = uint8((uint256(vs) >> 255) + 27);\\n return tryRecover(hash, v, r, s);\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.\\n *\\n * _Available since v4.2._\\n */\\n function recover(\\n bytes32 hash,\\n bytes32 r,\\n bytes32 vs\\n ) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, r, vs);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-tryRecover} that receives the `v`,\\n * `r` and `s` signature fields separately.\\n *\\n * _Available since v4.3._\\n */\\n function tryRecover(\\n bytes32 hash,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) internal pure returns (address, RecoverError) {\\n // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature\\n // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines\\n // the valid range for s in (301): 0 < s < secp256k1n \\u00f7 2 + 1, and for v in (302): v \\u2208 {27, 28}. Most\\n // signatures from current libraries generate a unique signature with an s-value in the lower half order.\\n //\\n // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value\\n // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or\\n // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept\\n // these malleable signatures as well.\\n if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {\\n return (address(0), RecoverError.InvalidSignatureS);\\n }\\n\\n // If the signature is valid (and not malleable), return the signer address\\n address signer = ecrecover(hash, v, r, s);\\n if (signer == address(0)) {\\n return (address(0), RecoverError.InvalidSignature);\\n }\\n\\n return (signer, RecoverError.NoError);\\n }\\n\\n /**\\n * @dev Overload of {ECDSA-recover} that receives the `v`,\\n * `r` and `s` signature fields separately.\\n */\\n function recover(\\n bytes32 hash,\\n uint8 v,\\n bytes32 r,\\n bytes32 s\\n ) internal pure returns (address) {\\n (address recovered, RecoverError error) = tryRecover(hash, v, r, s);\\n _throwError(error);\\n return recovered;\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Message, created from a `hash`. This\\n * produces hash corresponding to the one signed with the\\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\\n * JSON-RPC method as part of EIP-191.\\n *\\n * See {recover}.\\n */\\n function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {\\n // 32 is the length in bytes of hash,\\n // enforced by the type signature above\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n32\\\", hash));\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Message, created from `s`. This\\n * produces hash corresponding to the one signed with the\\n * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]\\n * JSON-RPC method as part of EIP-191.\\n *\\n * See {recover}.\\n */\\n function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19Ethereum Signed Message:\\\\n\\\", Strings.toString(s.length), s));\\n }\\n\\n /**\\n * @dev Returns an Ethereum Signed Typed Data, created from a\\n * `domainSeparator` and a `structHash`. This produces hash corresponding\\n * to the one signed with the\\n * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]\\n * JSON-RPC method as part of EIP-712.\\n *\\n * See {recover}.\\n */\\n function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) {\\n return keccak256(abi.encodePacked(\\\"\\\\x19\\\\x01\\\", domainSeparator, structHash));\\n }\\n}\\n\",\"keccak256\":\"0xda898fa084aa1ddfdb346e6a40459e00a59d87071cce7c315a46d648dd71d0ba\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/cryptography/EIP712.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/EIP712.sol)\\n\\npragma solidity ^0.8.0;\\n\\nimport \\\"./ECDSA.sol\\\";\\n\\n/**\\n * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.\\n *\\n * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible,\\n * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding\\n * they need in their contracts using a combination of `abi.encode` and `keccak256`.\\n *\\n * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding\\n * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA\\n * ({_hashTypedDataV4}).\\n *\\n * The implementation of the domain separator was designed to be as efficient as possible while still properly updating\\n * the chain id to protect against replay attacks on an eventual fork of the chain.\\n *\\n * NOTE: This contract implements the version of the encoding known as \\\"v4\\\", as implemented by the JSON RPC method\\n * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].\\n *\\n * _Available since v3.4._\\n */\\nabstract contract EIP712 {\\n /* solhint-disable var-name-mixedcase */\\n // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to\\n // invalidate the cached domain separator if the chain id changes.\\n bytes32 private immutable _CACHED_DOMAIN_SEPARATOR;\\n uint256 private immutable _CACHED_CHAIN_ID;\\n address private immutable _CACHED_THIS;\\n\\n bytes32 private immutable _HASHED_NAME;\\n bytes32 private immutable _HASHED_VERSION;\\n bytes32 private immutable _TYPE_HASH;\\n\\n /* solhint-enable var-name-mixedcase */\\n\\n /**\\n * @dev Initializes the domain separator and parameter caches.\\n *\\n * The meaning of `name` and `version` is specified in\\n * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]:\\n *\\n * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol.\\n * - `version`: the current major version of the signing domain.\\n *\\n * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart\\n * contract upgrade].\\n */\\n constructor(string memory name, string memory version) {\\n bytes32 hashedName = keccak256(bytes(name));\\n bytes32 hashedVersion = keccak256(bytes(version));\\n bytes32 typeHash = keccak256(\\n \\\"EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)\\\"\\n );\\n _HASHED_NAME = hashedName;\\n _HASHED_VERSION = hashedVersion;\\n _CACHED_CHAIN_ID = block.chainid;\\n _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion);\\n _CACHED_THIS = address(this);\\n _TYPE_HASH = typeHash;\\n }\\n\\n /**\\n * @dev Returns the domain separator for the current chain.\\n */\\n function _domainSeparatorV4() internal view returns (bytes32) {\\n if (address(this) == _CACHED_THIS && block.chainid == _CACHED_CHAIN_ID) {\\n return _CACHED_DOMAIN_SEPARATOR;\\n } else {\\n return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION);\\n }\\n }\\n\\n function _buildDomainSeparator(\\n bytes32 typeHash,\\n bytes32 nameHash,\\n bytes32 versionHash\\n ) private view returns (bytes32) {\\n return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this)));\\n }\\n\\n /**\\n * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this\\n * function returns the hash of the fully encoded EIP712 message for this domain.\\n *\\n * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example:\\n *\\n * ```solidity\\n * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode(\\n * keccak256(\\\"Mail(address to,string contents)\\\"),\\n * mailTo,\\n * keccak256(bytes(mailContents))\\n * )));\\n * address signer = ECDSA.recover(digest, signature);\\n * ```\\n */\\n function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) {\\n return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash);\\n }\\n}\\n\",\"keccak256\":\"0x948d8b2d18f38141ec78c5229d770d950ebc781ed3f44cc9e3ccbb9fded5846a\",\"license\":\"MIT\"},\"@openzeppelin/contracts/utils/math/Math.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)\\n\\npragma solidity ^0.8.0;\\n\\n/**\\n * @dev Standard math utilities missing in the Solidity language.\\n */\\nlibrary Math {\\n enum Rounding {\\n Down, // Toward negative infinity\\n Up, // Toward infinity\\n Zero // Toward zero\\n }\\n\\n /**\\n * @dev Returns the largest of two numbers.\\n */\\n function max(uint256 a, uint256 b) internal pure returns (uint256) {\\n return a > b ? a : b;\\n }\\n\\n /**\\n * @dev Returns the smallest of two numbers.\\n */\\n function min(uint256 a, uint256 b) internal pure returns (uint256) {\\n return a < b ? a : b;\\n }\\n\\n /**\\n * @dev Returns the average of two numbers. The result is rounded towards\\n * zero.\\n */\\n function average(uint256 a, uint256 b) internal pure returns (uint256) {\\n // (a + b) / 2 can overflow.\\n return (a & b) + (a ^ b) / 2;\\n }\\n\\n /**\\n * @dev Returns the ceiling of the division of two numbers.\\n *\\n * This differs from standard division with `/` in that it rounds up instead\\n * of rounding down.\\n */\\n function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {\\n // (a + b - 1) / b can overflow on addition, so we distribute.\\n return a == 0 ? 0 : (a - 1) / b + 1;\\n }\\n\\n /**\\n * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0\\n * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)\\n * with further edits by Uniswap Labs also under MIT license.\\n */\\n function mulDiv(\\n uint256 x,\\n uint256 y,\\n uint256 denominator\\n ) internal pure returns (uint256 result) {\\n unchecked {\\n // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use\\n // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256\\n // variables such that product = prod1 * 2^256 + prod0.\\n uint256 prod0; // Least significant 256 bits of the product\\n uint256 prod1; // Most significant 256 bits of the product\\n assembly {\\n let mm := mulmod(x, y, not(0))\\n prod0 := mul(x, y)\\n prod1 := sub(sub(mm, prod0), lt(mm, prod0))\\n }\\n\\n // Handle non-overflow cases, 256 by 256 division.\\n if (prod1 == 0) {\\n return prod0 / denominator;\\n }\\n\\n // Make sure the result is less than 2^256. Also prevents denominator == 0.\\n require(denominator > prod1);\\n\\n ///////////////////////////////////////////////\\n // 512 by 256 division.\\n ///////////////////////////////////////////////\\n\\n // Make division exact by subtracting the remainder from [prod1 prod0].\\n uint256 remainder;\\n assembly {\\n // Compute remainder using mulmod.\\n remainder := mulmod(x, y, denominator)\\n\\n // Subtract 256 bit number from 512 bit number.\\n prod1 := sub(prod1, gt(remainder, prod0))\\n prod0 := sub(prod0, remainder)\\n }\\n\\n // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.\\n // See https://cs.stackexchange.com/q/138556/92363.\\n\\n // Does not overflow because the denominator cannot be zero at this stage in the function.\\n uint256 twos = denominator & (~denominator + 1);\\n assembly {\\n // Divide denominator by twos.\\n denominator := div(denominator, twos)\\n\\n // Divide [prod1 prod0] by twos.\\n prod0 := div(prod0, twos)\\n\\n // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.\\n twos := add(div(sub(0, twos), twos), 1)\\n }\\n\\n // Shift in bits from prod1 into prod0.\\n prod0 |= prod1 * twos;\\n\\n // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such\\n // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for\\n // four bits. That is, denominator * inv = 1 mod 2^4.\\n uint256 inverse = (3 * denominator) ^ 2;\\n\\n // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works\\n // in modular arithmetic, doubling the correct bits in each step.\\n inverse *= 2 - denominator * inverse; // inverse mod 2^8\\n inverse *= 2 - denominator * inverse; // inverse mod 2^16\\n inverse *= 2 - denominator * inverse; // inverse mod 2^32\\n inverse *= 2 - denominator * inverse; // inverse mod 2^64\\n inverse *= 2 - denominator * inverse; // inverse mod 2^128\\n inverse *= 2 - denominator * inverse; // inverse mod 2^256\\n\\n // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.\\n // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is\\n // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1\\n // is no longer required.\\n result = prod0 * inverse;\\n return result;\\n }\\n }\\n\\n /**\\n * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.\\n */\\n function mulDiv(\\n uint256 x,\\n uint256 y,\\n uint256 denominator,\\n Rounding rounding\\n ) internal pure returns (uint256) {\\n uint256 result = mulDiv(x, y, denominator);\\n if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {\\n result += 1;\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.\\n *\\n * Inspired by Henry S. Warren, Jr.'s \\\"Hacker's Delight\\\" (Chapter 11).\\n */\\n function sqrt(uint256 a) internal pure returns (uint256) {\\n if (a == 0) {\\n return 0;\\n }\\n\\n // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.\\n //\\n // We know that the \\\"msb\\\" (most significant bit) of our target number `a` is a power of 2 such that we have\\n // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.\\n //\\n // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`\\n // \\u2192 `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`\\n // \\u2192 `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`\\n //\\n // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.\\n uint256 result = 1 << (log2(a) >> 1);\\n\\n // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,\\n // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at\\n // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision\\n // into the expected uint128 result.\\n unchecked {\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n result = (result + a / result) >> 1;\\n return min(result, a / result);\\n }\\n }\\n\\n /**\\n * @notice Calculates sqrt(a), following the selected rounding direction.\\n */\\n function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = sqrt(a);\\n return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 2, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log2(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >> 128 > 0) {\\n value >>= 128;\\n result += 128;\\n }\\n if (value >> 64 > 0) {\\n value >>= 64;\\n result += 64;\\n }\\n if (value >> 32 > 0) {\\n value >>= 32;\\n result += 32;\\n }\\n if (value >> 16 > 0) {\\n value >>= 16;\\n result += 16;\\n }\\n if (value >> 8 > 0) {\\n value >>= 8;\\n result += 8;\\n }\\n if (value >> 4 > 0) {\\n value >>= 4;\\n result += 4;\\n }\\n if (value >> 2 > 0) {\\n value >>= 2;\\n result += 2;\\n }\\n if (value >> 1 > 0) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 2, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log2(value);\\n return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 10, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log10(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >= 10**64) {\\n value /= 10**64;\\n result += 64;\\n }\\n if (value >= 10**32) {\\n value /= 10**32;\\n result += 32;\\n }\\n if (value >= 10**16) {\\n value /= 10**16;\\n result += 16;\\n }\\n if (value >= 10**8) {\\n value /= 10**8;\\n result += 8;\\n }\\n if (value >= 10**4) {\\n value /= 10**4;\\n result += 4;\\n }\\n if (value >= 10**2) {\\n value /= 10**2;\\n result += 2;\\n }\\n if (value >= 10**1) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log10(value);\\n return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);\\n }\\n }\\n\\n /**\\n * @dev Return the log in base 256, rounded down, of a positive value.\\n * Returns 0 if given 0.\\n *\\n * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.\\n */\\n function log256(uint256 value) internal pure returns (uint256) {\\n uint256 result = 0;\\n unchecked {\\n if (value >> 128 > 0) {\\n value >>= 128;\\n result += 16;\\n }\\n if (value >> 64 > 0) {\\n value >>= 64;\\n result += 8;\\n }\\n if (value >> 32 > 0) {\\n value >>= 32;\\n result += 4;\\n }\\n if (value >> 16 > 0) {\\n value >>= 16;\\n result += 2;\\n }\\n if (value >> 8 > 0) {\\n result += 1;\\n }\\n }\\n return result;\\n }\\n\\n /**\\n * @dev Return the log in base 10, following the selected rounding direction, of a positive value.\\n * Returns 0 if given 0.\\n */\\n function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {\\n unchecked {\\n uint256 result = log256(value);\\n return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);\\n }\\n }\\n}\\n\",\"keccak256\":\"0xa1e8e83cd0087785df04ac79fb395d9f3684caeaf973d9e2c71caef723a3a5d6\",\"license\":\"MIT\"},\"contracts/integration/MoC/IMoC.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\n/// Interface to the Money OnChain main contract MoC to mint DoC and redeem RBTC\\ninterface IMocMintRedeemDoc {\\n /**\\n @dev Returns the total amount of Docs in the redeem queue for redeemer\\n @param redeemer address for which ^ is computed\\n @return total amount of Docs in the redeem queue for redeemer\\n */\\n function docAmountToRedeem(address redeemer) external view returns (uint256);\\n\\n /**\\n * @dev Creates or updates the amount of a Doc redeem Request from the msg.sender\\n * @param docAmount Amount of Docs to redeem on settlement [using mocPrecision]\\n */\\n function redeemDocRequest(uint256 docAmount) external;\\n\\n /**\\n @dev Alters the redeem amount position for the redeemer\\n @param isAddition true if adding amount to redeem, false to substract.\\n @param delta the amount to add/substract to current position\\n */\\n function alterRedeemRequestAmount(bool isAddition, uint256 delta) external;\\n\\n /**\\n @dev Mint Doc tokens and pays the commisions of the operation (retrocompatible function).\\n @dev Retrocompatible function.\\n @param btcToMint Amount in RBTC to mint\\n */\\n function mintDoc(uint256 btcToMint) external payable;\\n\\n /**\\n * @dev Mint Doc tokens and pays the commisions of the operation\\n * @param btcToMint Amount in RBTC to mint\\n * @param vendorAccount Vendor address\\n */\\n function mintDocVendors(uint256 btcToMint, address payable vendorAccount) external payable;\\n\\n /**\\n @dev Redeems the requested amount for the msg.sender, or the max amount of free docs possible (retrocompatible function).\\n @dev Retrocompatible function.\\n @param docAmount Amount of Docs to redeem.\\n */\\n function redeemFreeDoc(uint256 docAmount) external;\\n\\n /**\\n @dev Redeems the requested amount for the msg.sender, or the max amount of free docs possible.\\n @param docAmount Amount of Docs to redeem.\\n @param vendorAccount Vendor address\\n */\\n function redeemFreeDocVendors(uint256 docAmount, address payable vendorAccount) external;\\n\\n /**\\n @dev Allow redeem on liquidation state, user DoCs get burned and he receives\\n the equivalent BTCs if can be covered, or the maximum available\\n */\\n function redeemAllDoc() external;\\n}\\n\\n/// An aggregating interface\\ninterface IMoC is IMocMintRedeemDoc {\\n\\n}\\n\",\"keccak256\":\"0xc571f8c743be8c85e8d570ec0378abef85ffc676e58a6fd3861501689721f944\",\"license\":\"MIT\"},\"contracts/integration/MoC/MocIntegration.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol\\\";\\nimport \\\"@openzeppelin/contracts-upgradeable/proxy/ERC1967/ERC1967UpgradeUpgradeable.sol\\\";\\nimport { IMocMintRedeemDoc } from \\\"./IMoC.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC20/IERC20.sol\\\";\\nimport \\\"@openzeppelin/contracts/utils/Counters.sol\\\";\\nimport \\\"../../meta-asset-token/DLLR.sol\\\";\\nimport \\\"../../interfaces/IMassetManager.sol\\\";\\nimport { IDLLR, PermitParams } from \\\"../../interfaces/IDLLR.sol\\\";\\nimport { IPermit2, ISignatureTransfer } from \\\"../../permit2/interfaces/IPermit2.sol\\\";\\n\\n/// @notice This contract provides compound functions with Money On Chain wrapping them in one transaction for convenience and to save on gas\\ncontract MocIntegration is OwnableUpgradeable, ERC1967UpgradeUpgradeable {\\n using Counters for Counters.Counter;\\n // Money On Chain DoC redeem interface at MoC main contract address\\n IMocMintRedeemDoc public immutable moc;\\n // IERC20@[DoC token]\\n IERC20 public immutable doc;\\n IDLLR public immutable dllr;\\n IMassetManager public immutable massetManager;\\n\\n address public mocVendorAccount;\\n\\n IPermit2 public immutable permit2;\\n\\n mapping(address => Counters.Counter) private _permit2Nonces;\\n\\n event GetDocFromDllrAndRedeemRBTC(address indexed from, uint256 fromDLLR, uint256 toRBTC);\\n event MocVendorAccountSet(address newMocVendorAccount);\\n\\n /**\\n * @param _moc MoC main contract address\\n * @param _doc DoC contract address\\n * @param _dllr DLLR contract address\\n * @param _massetManager MassetManager contract address\\n */\\n constructor(\\n address _moc,\\n address _doc,\\n address _dllr,\\n address _massetManager,\\n address _permit2\\n ) {\\n require(\\n _moc != address(0) &&\\n _doc != address(0) &&\\n _dllr != address(0) &&\\n _massetManager != address(0) &&\\n _permit2 != address(0),\\n \\\"MocIntegration:: no null addresses allowed\\\"\\n );\\n moc = IMocMintRedeemDoc(_moc);\\n doc = IERC20(_doc);\\n dllr = IDLLR(_dllr);\\n massetManager = IMassetManager(_massetManager);\\n permit2 = IPermit2(_permit2);\\n }\\n\\n function initialize(address payable _mocVendorAccount) external initializer {\\n __Ownable_init();\\n _setMocVendorAccount(_mocVendorAccount);\\n }\\n\\n ///@dev the contract requires receiving funds temporarily before transferring them to users\\n receive() external payable {}\\n\\n /**\\n * @notice how getDocFromDllrAndRedeemRBTC function works:\\n * -------------------------------------------------------------------------------------------\\n * | Mynt | Money On Chain |\\n * -------------------------------------------------------------------------------------------\\n * | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user |\\n * -------------------------------------------------------------------------------------------\\n *\\n * @param _dllrAmount The amount of the DLLR (mAsset) that will be burned in exchange for _toToken\\n * @param _permitParams EIP-2612 permit params:\\n * _deadline Expiration time of the signature.\\n * _v Last 1 byte of ECDSA signature.\\n * _r First 32 bytes of ECDSA signature.\\n * _s 32 bytes after _r in ECDSA signature.\\n */\\n function getDocFromDllrAndRedeemRBTC(\\n uint256 _dllrAmount,\\n PermitParams calldata _permitParams\\n ) external {\\n // transfer _dllrAmount to this contract by permit (EIP-2612)\\n address thisAddress = address(this);\\n dllr.transferWithPermit(\\n msg.sender,\\n thisAddress,\\n _dllrAmount,\\n _permitParams.deadline,\\n _permitParams.v,\\n _permitParams.r,\\n _permitParams.s\\n );\\n\\n // redeem DoC from DLLR\\n require(\\n massetManager.redeemTo(address(doc), _dllrAmount, thisAddress) == _dllrAmount,\\n \\\"MocIntegration:: redeemed incorrect DoC amount\\\"\\n );\\n\\n // redeem RBTC from DoC using Money On Chain and send to the user\\n uint256 rbtcBalanceBefore = thisAddress.balance;\\n moc.redeemFreeDocVendors(_dllrAmount, payable(mocVendorAccount));\\n uint256 rbtcAmount = thisAddress.balance - rbtcBalanceBefore;\\n (bool success, ) = msg.sender.call{ value: rbtcAmount }(\\\"\\\");\\n require(success, \\\"MocIntegration:: error transferring redeemed RBTC\\\");\\n\\n emit GetDocFromDllrAndRedeemRBTC(msg.sender, _dllrAmount, rbtcAmount);\\n }\\n\\n /**\\n * @notice how getDocFromDllrAndRedeemRBTC function works:\\n * -------------------------------------------------------------------------------------------\\n * | Mynt | Money On Chain |\\n * -------------------------------------------------------------------------------------------\\n * | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user |\\n * -------------------------------------------------------------------------------------------\\n *\\n * @param permit permit data, in form of PermitTransferFrom struct.\\n * @param signature of the permit data.\\n */\\n function getDocFromDllrAndRedeemRbtcWithPermit2(\\n ISignatureTransfer.PermitTransferFrom memory permit,\\n bytes memory signature\\n ) external {\\n address thisAddress = address(this);\\n uint256 _dllrAmount = permit.permitted.amount;\\n\\n ISignatureTransfer.SignatureTransferDetails\\n memory transferDetails = _generateTransferDetails(thisAddress, _dllrAmount);\\n\\n permit2.permitTransferFrom(permit, transferDetails, msg.sender, signature);\\n\\n _useNonce(msg.sender);\\n\\n // redeem DoC from DLLR\\n require(\\n massetManager.redeemTo(address(doc), _dllrAmount, thisAddress) == _dllrAmount,\\n \\\"MocIntegration:: redeemed incorrect DoC amount\\\"\\n );\\n\\n // redeem RBTC from DoC using Money On Chain and send to the user\\n uint256 rbtcBalanceBefore = thisAddress.balance;\\n moc.redeemFreeDocVendors(_dllrAmount, payable(mocVendorAccount));\\n uint256 rbtcAmount = thisAddress.balance - rbtcBalanceBefore;\\n (bool success, ) = msg.sender.call{ value: rbtcAmount }(\\\"\\\");\\n require(success, \\\"MocIntegration:: error transferring redeemed RBTC\\\");\\n\\n emit GetDocFromDllrAndRedeemRBTC(msg.sender, _dllrAmount, rbtcAmount);\\n }\\n\\n /// Set MoC registered Vendor account to receive markup fees https://docs.moneyonchain.com/main-rbtc-contract/integration-with-moc-platform/vendors\\n function setMocVendorAccount(address payable newMocVedorAccount) external onlyOwner {\\n _setMocVendorAccount(newMocVedorAccount);\\n }\\n\\n function _setMocVendorAccount(address newMocVedorAccount) internal {\\n mocVendorAccount = newMocVedorAccount;\\n emit MocVendorAccountSet(mocVendorAccount);\\n }\\n\\n /**\\n * @dev get the implementation logic address referring to ERC1967 standard.\\n *\\n * @return logic implementation address.\\n */\\n function getProxyImplementation() external view returns (address) {\\n return ERC1967UpgradeUpgradeable._getImplementation();\\n }\\n\\n /**\\n * @dev view function to construct SignatureTransferDetails struct to be used by Permit2\\n *\\n * @param _to ultimate recipient\\n * @param _amount amount of transfer\\n *\\n * @return SignatureTransferDetails struct object\\n */\\n function _generateTransferDetails(\\n address _to,\\n uint256 _amount\\n ) private pure returns (ISignatureTransfer.SignatureTransferDetails memory) {\\n ISignatureTransfer.SignatureTransferDetails memory transferDetails = ISignatureTransfer\\n .SignatureTransferDetails({ to: _to, requestedAmount: _amount });\\n\\n return transferDetails;\\n }\\n\\n /**\\n * @dev \\\"Consume a nonce\\\": return the current value and increment.\\n *\\n * @param _address address of owner\\n *\\n * @return current nonce of the owner's address\\n */\\n function _useNonce(address _address) internal virtual returns (uint256 current) {\\n Counters.Counter storage nonce = _permit2Nonces[_address];\\n current = nonce.current();\\n nonce.increment();\\n }\\n\\n /**\\n * @dev getter for currernt nonce\\n *\\n * @param _address address of owner\\n * @return current nonce of the owner's address\\n */\\n function getPermit2Nonce(address _address) public view returns (uint256) {\\n return _permit2Nonces[_address].current();\\n }\\n}\\n\",\"keccak256\":\"0x278b8cde5ae41db03f2286320f13e9bb046058c6ca094ded0b567ff19f6c5aa2\",\"license\":\"MIT\"},\"contracts/interfaces/IApproveAndCall.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\n/**\\n * @title Interface for contract governance/ApprovalReceiver.sol\\n * @dev Interfaces are used to cast a contract address into a callable instance.\\n */\\ninterface IApproveAndCall {\\n /**\\n * @notice Receives approval from SOV token.\\n * @param _sender The sender of SOV.approveAndCall function.\\n * @param _amount The amount was approved.\\n * @param _token The address of token.\\n * @param _data The data will be used for low level call.\\n * */\\n function receiveApproval(\\n address _sender,\\n uint256 _amount,\\n address _token,\\n bytes calldata _data\\n ) external;\\n}\\n\",\"keccak256\":\"0x0dd8105c56c42841b136acb14c8058f7802800727d76daf708ec67f614f8f7f3\",\"license\":\"MIT\"},\"contracts/interfaces/IDLLR.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"@openzeppelin/contracts/token/ERC20/IERC20.sol\\\";\\n\\n/**\\n * @dev Permit params (EIP-2612) wrapper struct\\n */\\nstruct PermitParams {\\n uint256 deadline;\\n uint8 v;\\n bytes32 r;\\n bytes32 s;\\n}\\n\\n/**\\n * @title DLLR mAsset interface.\\n * @dev mAsset - Meta Asset Token implementation.\\n * Inherits from ERC20.\\n * mint and burn functions.\\n */\\ninterface IDLLR is IERC20 {\\n // events\\n\\n /**\\n * @dev Emitted when MassetManager config is changed.\\n * @param _newMassetManagerProxy Address of new MassetManager proxy.\\n */\\n event MassetManagerProxyChanged(address indexed _newMassetManagerProxy);\\n\\n /**\\n * @dev Emitted when Basket Manager config is changed.\\n * @param _newBasketManagerProxy Address of new Basket Manager proxy.\\n */\\n event BasketManagerProxyChanged(address indexed _newBasketManagerProxy);\\n\\n /**\\n * @dev getter function of MassetManager implementation address\\n *\\n * @return MassetManager implementation address\\n */\\n function massetManagerImplementation() external view returns (address);\\n\\n /**\\n * @dev getter function of basket manager implementation address\\n *\\n * @return basket manager implementation address\\n */\\n function basketManagerImplementation() external view returns (address);\\n\\n /**\\n * @notice setMassetManagerProxy sets the MassetManager proxy address\\n * @param _massetManagerProxy The address of the MassetManager proxy contract\\n */\\n function setMassetManagerProxy(address _massetManagerProxy) external;\\n\\n /**\\n * @notice setBasketManagerConfig sets the Basket Manager proxy address\\n * @param _basketManagerProxy The address of the Basket Manager proxy contract\\n */\\n function setBasketManagerProxy(address _basketManagerProxy) external;\\n\\n /**\\n * @notice Creates new tokens and sends them to the recipient.\\n * @notice Can be minted only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function mint(address _account, uint256 _amount) external;\\n\\n /**\\n * @notice Burns tokens for the given account.\\n * @notice Can be burned only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function burn(address _account, uint256 _amount) external;\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _recipient Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transfer(address _recipient, uint256 _amount) external returns (bool);\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _from Sender of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transferFrom(address _from, address _to, uint256 _amount) external returns (bool);\\n\\n /**\\n * @notice transfer utilizing EIP-2612, to reduce the additional sending transaction for doing the approval to the spender.\\n *\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @dev By calling this function, the allowance will be overwritten by the total amount.\\n *\\n * @param _from Owner of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of the token that will be transferred.\\n * @param _deadline Expiration time of the signature.\\n * @param _v Last 1 byte of ECDSA signature.\\n * @param _r First 32 bytes of ECDSA signature.\\n * @param _s 32 bytes after _r in ECDSA signature.\\n */\\n function transferWithPermit(\\n address _from,\\n address _to,\\n uint256 _amount,\\n uint256 _deadline,\\n uint8 _v,\\n bytes32 _r,\\n bytes32 _s\\n ) external;\\n\\n /**\\n * @notice Approves and then calls the receiving contract.\\n * Useful to encapsulate sending tokens to a contract in one call.\\n * Solidity has no native way to send tokens to contracts.\\n * ERC-20 tokens require approval to be spent by third parties, such as a contract in this case.\\n * @param _spender The contract address to spend the tokens.\\n * @param _amount The amount of tokens to be sent.\\n * @param _data Parameters for the contract call, such as endpoint signature.\\n */\\n function approveAndCall(address _spender, uint256 _amount, bytes calldata _data) external;\\n\\n /**\\n * @dev to support EIP712, will need the token contract to return the chain id.\\n *\\n * @return chain id.\\n *\\n */\\n function getChainId() external view returns (uint256);\\n}\\n\",\"keccak256\":\"0x34068131b6d47697cdf66239fe8f28b191afe6e13b5d145a39e7c93c8a092a01\",\"license\":\"MIT\"},\"contracts/interfaces/IMassetManager.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\n/**\\n * @title MassetManager\\n * @dev Contract is responsible for managing mAsset and bAsset.\\n * Used for minting and burning tokens and calculating fees\\n * if transaction based on token from another blockchain.\\n */\\n\\ninterface IMassetManager {\\n // events\\n\\n /**\\n * @dev Emitted when deposit is completed.\\n * @param minter Address of the minter.\\n * @param recipient Address of the recipient.\\n * @param massetQuantity Masset quantity.\\n * @param bAsset Address of the bAsset.\\n * @param bassetQuantity Basset quantity.\\n */\\n event Minted(\\n address indexed minter,\\n address indexed recipient,\\n uint256 massetQuantity,\\n address bAsset,\\n uint256 bassetQuantity\\n );\\n\\n /**\\n * @dev Emitted when withdrawal is completed.\\n * @param redeemer Address of the redeemer.\\n * @param recipient Address of the recipient.\\n * @param massetQuantity Masset quantity.\\n * @param bAsset Address of the bAsset.\\n * @param bassetQuantity Basset quantity.\\n */\\n event Redeemed(\\n address indexed redeemer,\\n address indexed recipient,\\n uint256 massetQuantity,\\n address bAsset,\\n uint256 bassetQuantity\\n );\\n\\n /***************************************\\n MINTING (PUBLIC)\\n ****************************************/\\n\\n /**\\n * @dev Mint a single mAsset, at a 1:1 ratio with the bAsset. This contract\\n * must have approval to spend the senders bAsset.\\n * @param _bAsset Address of the bAsset.\\n * @param _bAssetQuantity Quantity in bAsset units.\\n * @return massetMinted Quantity of newly minted mAsset.\\n */\\n function mint(\\n address _bAsset,\\n uint256 _bAssetQuantity\\n ) external returns (uint256 massetMinted);\\n\\n /**\\n * @dev Mint a single mAsset to recipient address, at a 1:1 ratio with the bAsset.\\n * This contract must have approval to spend the senders bAsset.\\n * @param _bAsset Address of the bAsset.\\n * @param _bAssetQuantity Quantity in bAsset units.\\n * @param _recipient Receipient of the newly minted mAsset tokens.\\n * @return massetMinted Number of newly minted mAssets.\\n */\\n function mintTo(\\n address _bAsset,\\n uint256 _bAssetQuantity,\\n address _recipient\\n ) external returns (uint256 massetMinted);\\n\\n /***************************************\\n REDEMPTION (PUBLIC)\\n ****************************************/\\n\\n /**\\n * @dev Credits the sender with a certain quantity of selected bAsset, in exchange for burning the\\n * relative mAsset quantity from the sender. Sender also incurs a small mAsset fee, if any.\\n * @param _bAsset Address of the bAsset to redeem.\\n * @param _massetQuantity Units of the masset to redeem.\\n * @return massetRedeemed Relative number of mAsset units burned to pay for the bAssets.\\n */\\n function redeem(\\n address _bAsset,\\n uint256 _massetQuantity\\n ) external returns (uint256 massetRedeemed);\\n\\n /**\\n * @dev Credits a recipient with a certain quantity of selected bAsset, in exchange for burning the\\n * relative mAsset quantity from the sender. Sender also incurs a small fee, if any.\\n * @param _bAsset Address of the bAsset to redeem.\\n * @param _massetQuantity Units of the masset to redeem.\\n * @param _recipient Address to credit with withdrawn bAssets.\\n * @return massetRedeemed Relative number of mAsset units burned to pay for the bAssets.\\n */\\n function redeemTo(\\n address _bAsset,\\n uint256 _massetQuantity,\\n address _recipient\\n ) external returns (uint256 massetRedeemed);\\n\\n // Getters\\n\\n function getFeesVault() external view returns (address);\\n\\n function getFeesManager() external view returns (address);\\n\\n function getVersion() external view returns (string memory);\\n\\n function getToken() external view returns (address);\\n\\n function getBasketManager() external view returns (address);\\n\\n /**\\n * @dev get the implementation logic address referring to ERC1967 standard.\\n *\\n * @return logic implementation address.\\n */\\n function getProxyImplementation() external view returns (address);\\n}\\n\",\"keccak256\":\"0xa1f03fbed78848636e091cf9558ad018306a099d58dec55738aee06f3dec432a\",\"license\":\"MIT\"},\"contracts/interfaces/IProxy.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\n\\npragma solidity ^0.8.17;\\n\\ninterface IProxy {\\n function getProxyImplementation() external view returns (address);\\n}\\n\",\"keccak256\":\"0x5bf844214dbafb99a41cd0dff86537312cd3f20636dbb8d27cc91496fd808bc5\",\"license\":\"MIT\"},\"contracts/meta-asset-token/DLLR.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"./MetaAssetToken.sol\\\";\\n\\ncontract DLLR is MetaAssetToken {\\n constructor() MetaAssetToken(\\\"Sovryn Dollar\\\", \\\"DLLR\\\") {}\\n}\\n\",\"keccak256\":\"0x38a864f85b864d9b413c67d789493690aca728ca555ac6d0a345a40ee5b1794f\",\"license\":\"MIT\"},\"contracts/meta-asset-token/MetaAssetToken.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.17;\\n\\nimport \\\"@openzeppelin/contracts/access/Ownable.sol\\\";\\nimport \\\"@openzeppelin/contracts/token/ERC20/extensions/draft-ERC20Permit.sol\\\";\\nimport \\\"../interfaces/IApproveAndCall.sol\\\";\\nimport \\\"../interfaces/IProxy.sol\\\";\\n\\n/**\\n * @title MetaAssetToken\\n * @dev mAsset - Meta Asset Token implementation.\\n * Inherits from ERC20.\\n * mint and burn functions.\\n */\\n\\ncontract MetaAssetToken is ERC20Permit, Ownable {\\n // events\\n\\n /**\\n * @dev Emitted when MassetManager config is changed.\\n * @param _newMassetManagerProxy Address of new MassetManager proxy.\\n */\\n event MassetManagerProxyChanged(address indexed _newMassetManagerProxy);\\n\\n /**\\n * @dev Emitted when Basket Manager config is changed.\\n * @param _newBasketManagerProxy Address of new Basket Manager proxy.\\n */\\n event BasketManagerProxyChanged(address indexed _newBasketManagerProxy);\\n\\n /**\\n * @dev Emitted when transfer Manager config is changed.\\n */\\n event TransferWithPermit(address _from, address _to, uint256 _amount);\\n\\n // state\\n\\n address public massetManagerProxy;\\n address public basketManagerProxy;\\n\\n // modifiers\\n modifier onlyMassetManagerProxy() {\\n require(msg.sender == massetManagerProxy, \\\"DLLR:unauthorized MassetManager proxy\\\");\\n _;\\n }\\n\\n modifier requireValidRecipient(address _recipient) {\\n require(\\n _recipient != address(0) && _recipient != address(this),\\n \\\"DLLR: Invalid address. Cannot transfer DLLR to the null address.\\\"\\n );\\n _;\\n }\\n\\n /**\\n * @notice Constructor called on deployment, initiates the contract.\\n */\\n constructor(\\n string memory _tokenName,\\n string memory _symbol\\n ) ERC20(_tokenName, _symbol) ERC20Permit(_tokenName) {}\\n\\n /**\\n * @dev getter function of MassetManager implementation address\\n *\\n * @return MassetManager implementation address\\n */\\n function massetManagerImplementation() public view virtual returns (address) {\\n return IProxy(massetManagerProxy).getProxyImplementation();\\n }\\n\\n /**\\n * @dev getter function of basket manager implementation address\\n *\\n * @return basket manager implementation address\\n */\\n function basketManagerImplementation() public view virtual returns (address) {\\n return IProxy(basketManagerProxy).getProxyImplementation();\\n }\\n\\n /**\\n * @notice setMassetManagerProxy sets the MassetManager proxy address\\n * @param _massetManagerProxy The address of the MassetManager proxy contract\\n */\\n function setMassetManagerProxy(address _massetManagerProxy) external onlyOwner {\\n require(_massetManagerProxy != address(0), \\\"invalid MassetManager proxy address\\\");\\n massetManagerProxy = _massetManagerProxy;\\n\\n emit MassetManagerProxyChanged(massetManagerProxy);\\n }\\n\\n /**\\n * @notice setBasketManagerConfig sets the Basket Manager proxy address\\n * @param _basketManagerProxy The address of the Basket Manager proxy contract\\n */\\n function setBasketManagerProxy(address _basketManagerProxy) external onlyOwner {\\n require(_basketManagerProxy != address(0), \\\"invalid address\\\");\\n basketManagerProxy = _basketManagerProxy;\\n emit BasketManagerProxyChanged(basketManagerProxy);\\n }\\n\\n /**\\n * @notice Creates new tokens and sends them to the recipient.\\n * @notice Can be minted only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function mint(address _account, uint256 _amount) external onlyMassetManagerProxy {\\n _mint(_account, _amount);\\n }\\n\\n /**\\n * @notice Burns tokens for the given account.\\n * @notice Can be burned only by the MassetManager proxy contract.\\n *\\n * @param _account The recipient address to get the minted tokens.\\n * @param _amount The amount of tokens to be minted.\\n */\\n function burn(address _account, uint256 _amount) external onlyMassetManagerProxy {\\n _burn(_account, _amount);\\n }\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _recipient Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transfer(\\n address _recipient,\\n uint256 _amount\\n ) public override requireValidRecipient(_recipient) returns (bool) {\\n _transfer(_msgSender(), _recipient, _amount);\\n return true;\\n }\\n\\n /**\\n * @notice Only owner who can transfer the token.\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @param _from Sender of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of token that will be transferred.\\n *\\n * @return true / false.\\n */\\n function transferFrom(\\n address _from,\\n address _to,\\n uint256 _amount\\n ) public override requireValidRecipient(_to) returns (bool) {\\n _approve(_from, msg.sender, allowance(_from, msg.sender) - _amount);\\n _transfer(_from, _to, _amount);\\n return true;\\n }\\n\\n /**\\n * @notice transfer utilizing EIP-2612, to reduce the additional sending transaction for doing the approval to the spender.\\n *\\n * @notice destination cannot be:\\n * - zero (0x0) address.\\n *\\n * @dev By calling this function, the allowance will be overwritten by the total amount.\\n *\\n * @param _from Owner of the token.\\n * @param _to Recipient of the token.\\n * @param _amount The amount of the token that will be transferred.\\n * @param _deadline Expiration time of the signature.\\n * @param _v Last 1 byte of ECDSA signature.\\n * @param _r First 32 bytes of ECDSA signature.\\n * @param _s 32 bytes after _r in ECDSA signature.\\n */\\n function transferWithPermit(\\n address _from,\\n address _to,\\n uint256 _amount,\\n uint256 _deadline,\\n uint8 _v,\\n bytes32 _r,\\n bytes32 _s\\n ) external requireValidRecipient(_to) {\\n permit(_from, msg.sender, _amount, _deadline, _v, _r, _s);\\n require(\\n transferFrom(_from, _to, _amount),\\n \\\"MetaAssetToken::transferWithPermit: transfer failed\\\"\\n );\\n\\n emit TransferWithPermit(_from, _to, _amount);\\n }\\n\\n /**\\n * @notice Approves and then calls the receiving contract.\\n * Useful to encapsulate sending tokens to a contract in one call.\\n * Solidity has no native way to send tokens to contracts.\\n * ERC-20 tokens require approval to be spent by third parties, such as a contract in this case.\\n * @param _spender The contract address to spend the tokens.\\n * @param _amount The amount of tokens to be sent.\\n * @param _data Parameters for the contract call, such as endpoint signature.\\n */\\n function approveAndCall(address _spender, uint256 _amount, bytes calldata _data) external {\\n approve(_spender, _amount);\\n IApproveAndCall(_spender).receiveApproval(msg.sender, _amount, address(this), _data);\\n }\\n\\n /**\\n * @dev to support EIP712, will need the token contract to return the chain id.\\n *\\n * @return chain id.\\n *\\n */\\n function getChainId() external view returns (uint256) {\\n return block.chainid;\\n }\\n}\\n\",\"keccak256\":\"0x887c09ca5cf835d67db8389c8f4ab4fc2689444bb5806370431e1a18900b66d7\",\"license\":\"MIT\"},\"contracts/permit2/interfaces/IAllowanceTransfer.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.0;\\n\\nimport {IEIP712} from \\\"./IEIP712.sol\\\";\\n\\n/// @title AllowanceTransfer\\n/// @notice Handles ERC20 token permissions through signature based allowance setting and ERC20 token transfers by checking allowed amounts\\n/// @dev Requires user's token approval on the Permit2 contract\\ninterface IAllowanceTransfer is IEIP712 {\\n /// @notice Thrown when an allowance on a token has expired.\\n /// @param deadline The timestamp at which the allowed amount is no longer valid\\n error AllowanceExpired(uint256 deadline);\\n\\n /// @notice Thrown when an allowance on a token has been depleted.\\n /// @param amount The maximum amount allowed\\n error InsufficientAllowance(uint256 amount);\\n\\n /// @notice Thrown when too many nonces are invalidated.\\n error ExcessiveInvalidation();\\n\\n /// @notice Emits an event when the owner successfully invalidates an ordered nonce.\\n event NonceInvalidation(\\n address indexed owner, address indexed token, address indexed spender, uint48 newNonce, uint48 oldNonce\\n );\\n\\n /// @notice Emits an event when the owner successfully sets permissions on a token for the spender.\\n event Approval(\\n address indexed owner, address indexed token, address indexed spender, uint160 amount, uint48 expiration\\n );\\n\\n /// @notice Emits an event when the owner successfully sets permissions using a permit signature on a token for the spender.\\n event Permit(\\n address indexed owner,\\n address indexed token,\\n address indexed spender,\\n uint160 amount,\\n uint48 expiration,\\n uint48 nonce\\n );\\n\\n /// @notice Emits an event when the owner sets the allowance back to 0 with the lockdown function.\\n event Lockdown(address indexed owner, address token, address spender);\\n\\n /// @notice The permit data for a token\\n struct PermitDetails {\\n // ERC20 token address\\n address token;\\n // the maximum amount allowed to spend\\n uint160 amount;\\n // timestamp at which a spender's token allowances become invalid\\n uint48 expiration;\\n // an incrementing value indexed per owner,token,and spender for each signature\\n uint48 nonce;\\n }\\n\\n /// @notice The permit message signed for a single token allowance\\n struct PermitSingle {\\n // the permit data for a single token alownce\\n PermitDetails details;\\n // address permissioned on the allowed tokens\\n address spender;\\n // deadline on the permit signature\\n uint256 sigDeadline;\\n }\\n\\n /// @notice The permit message signed for multiple token allowances\\n struct PermitBatch {\\n // the permit data for multiple token allowances\\n PermitDetails[] details;\\n // address permissioned on the allowed tokens\\n address spender;\\n // deadline on the permit signature\\n uint256 sigDeadline;\\n }\\n\\n /// @notice The saved permissions\\n /// @dev This info is saved per owner, per token, per spender and all signed over in the permit message\\n /// @dev Setting amount to type(uint160).max sets an unlimited approval\\n struct PackedAllowance {\\n // amount allowed\\n uint160 amount;\\n // permission expiry\\n uint48 expiration;\\n // an incrementing value indexed per owner,token,and spender for each signature\\n uint48 nonce;\\n }\\n\\n /// @notice A token spender pair.\\n struct TokenSpenderPair {\\n // the token the spender is approved\\n address token;\\n // the spender address\\n address spender;\\n }\\n\\n /// @notice Details for a token transfer.\\n struct AllowanceTransferDetails {\\n // the owner of the token\\n address from;\\n // the recipient of the token\\n address to;\\n // the amount of the token\\n uint160 amount;\\n // the token to be transferred\\n address token;\\n }\\n\\n /// @notice A mapping from owner address to token address to spender address to PackedAllowance struct, which contains details and conditions of the approval.\\n /// @notice The mapping is indexed in the above order see: allowance[ownerAddress][tokenAddress][spenderAddress]\\n /// @dev The packed slot holds the allowed amount, expiration at which the allowed amount is no longer valid, and current nonce thats updated on any signature based approvals.\\n function allowance(address user, address token, address spender)\\n external\\n view\\n returns (uint160 amount, uint48 expiration, uint48 nonce);\\n\\n /// @notice Approves the spender to use up to amount of the specified token up until the expiration\\n /// @param token The token to approve\\n /// @param spender The spender address to approve\\n /// @param amount The approved amount of the token\\n /// @param expiration The timestamp at which the approval is no longer valid\\n /// @dev The packed allowance also holds a nonce, which will stay unchanged in approve\\n /// @dev Setting amount to type(uint160).max sets an unlimited approval\\n function approve(address token, address spender, uint160 amount, uint48 expiration) external;\\n\\n /// @notice Permit a spender to a given amount of the owners token via the owner's EIP-712 signature\\n /// @dev May fail if the owner's nonce was invalidated in-flight by invalidateNonce\\n /// @param owner The owner of the tokens being approved\\n /// @param permitSingle Data signed over by the owner specifying the terms of approval\\n /// @param signature The owner's signature over the permit data\\n function permit(address owner, PermitSingle memory permitSingle, bytes calldata signature) external;\\n\\n /// @notice Permit a spender to the signed amounts of the owners tokens via the owner's EIP-712 signature\\n /// @dev May fail if the owner's nonce was invalidated in-flight by invalidateNonce\\n /// @param owner The owner of the tokens being approved\\n /// @param permitBatch Data signed over by the owner specifying the terms of approval\\n /// @param signature The owner's signature over the permit data\\n function permit(address owner, PermitBatch memory permitBatch, bytes calldata signature) external;\\n\\n /// @notice Transfer approved tokens from one address to another\\n /// @param from The address to transfer from\\n /// @param to The address of the recipient\\n /// @param amount The amount of the token to transfer\\n /// @param token The token address to transfer\\n /// @dev Requires the from address to have approved at least the desired amount\\n /// of tokens to msg.sender.\\n function transferFrom(address from, address to, uint160 amount, address token) external;\\n\\n /// @notice Transfer approved tokens in a batch\\n /// @param transferDetails Array of owners, recipients, amounts, and tokens for the transfers\\n /// @dev Requires the from addresses to have approved at least the desired amount\\n /// of tokens to msg.sender.\\n function transferFrom(AllowanceTransferDetails[] calldata transferDetails) external;\\n\\n /// @notice Enables performing a \\\"lockdown\\\" of the sender's Permit2 identity\\n /// by batch revoking approvals\\n /// @param approvals Array of approvals to revoke.\\n function lockdown(TokenSpenderPair[] calldata approvals) external;\\n\\n /// @notice Invalidate nonces for a given (token, spender) pair\\n /// @param token The token to invalidate nonces for\\n /// @param spender The spender to invalidate nonces for\\n /// @param newNonce The new nonce to set. Invalidates all nonces less than it.\\n /// @dev Can't invalidate more than 2**16 nonces per transaction.\\n function invalidateNonces(address token, address spender, uint48 newNonce) external;\\n}\\n\",\"keccak256\":\"0x37f0ac203b6ef605c9533e1a739477e8e9dcea90710b40e645a367f8a21ace29\",\"license\":\"MIT\"},\"contracts/permit2/interfaces/IEIP712.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.0;\\n\\ninterface IEIP712 {\\n function DOMAIN_SEPARATOR() external view returns (bytes32);\\n}\\n\",\"keccak256\":\"0xfdccf2b9639070803cd0e4198427fb0df3cc452ca59bd3b8a0d957a9a4254138\",\"license\":\"MIT\"},\"contracts/permit2/interfaces/IPermit2.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.0;\\n\\nimport {ISignatureTransfer} from \\\"./ISignatureTransfer.sol\\\";\\nimport {IAllowanceTransfer} from \\\"./IAllowanceTransfer.sol\\\";\\n\\n/// @notice Permit2 handles signature-based transfers in SignatureTransfer and allowance-based transfers in AllowanceTransfer.\\n/// @dev Users must approve Permit2 before calling any of the transfer functions.\\ninterface IPermit2 is ISignatureTransfer, IAllowanceTransfer {\\n// IPermit2 unifies the two interfaces so users have maximal flexibility with their approval.\\n}\\n\",\"keccak256\":\"0xaa631cc9f53e699301d94233007110a345e6779011def484e8dd97b8fe0af771\",\"license\":\"MIT\"},\"contracts/permit2/interfaces/ISignatureTransfer.sol\":{\"content\":\"// SPDX-License-Identifier: MIT\\npragma solidity ^0.8.0;\\n\\nimport {IEIP712} from \\\"./IEIP712.sol\\\";\\n\\n/// @title SignatureTransfer\\n/// @notice Handles ERC20 token transfers through signature based actions\\n/// @dev Requires user's token approval on the Permit2 contract\\ninterface ISignatureTransfer is IEIP712 {\\n /// @notice Thrown when the requested amount for a transfer is larger than the permissioned amount\\n /// @param maxAmount The maximum amount a spender can request to transfer\\n error InvalidAmount(uint256 maxAmount);\\n\\n /// @notice Thrown when the number of tokens permissioned to a spender does not match the number of tokens being transferred\\n /// @dev If the spender does not need to transfer the number of tokens permitted, the spender can request amount 0 to be transferred\\n error LengthMismatch();\\n\\n /// @notice Emits an event when the owner successfully invalidates an unordered nonce.\\n event UnorderedNonceInvalidation(address indexed owner, uint256 word, uint256 mask);\\n\\n /// @notice The token and amount details for a transfer signed in the permit transfer signature\\n struct TokenPermissions {\\n // ERC20 token address\\n address token;\\n // the maximum amount that can be spent\\n uint256 amount;\\n }\\n\\n /// @notice The signed permit message for a single token transfer\\n struct PermitTransferFrom {\\n TokenPermissions permitted;\\n // a unique value for every token owner's signature to prevent signature replays\\n uint256 nonce;\\n // deadline on the permit signature\\n uint256 deadline;\\n }\\n\\n /// @notice Specifies the recipient address and amount for batched transfers.\\n /// @dev Recipients and amounts correspond to the index of the signed token permissions array.\\n /// @dev Reverts if the requested amount is greater than the permitted signed amount.\\n struct SignatureTransferDetails {\\n // recipient address\\n address to;\\n // spender requested amount\\n uint256 requestedAmount;\\n }\\n\\n /// @notice Used to reconstruct the signed permit message for multiple token transfers\\n /// @dev Do not need to pass in spender address as it is required that it is msg.sender\\n /// @dev Note that a user still signs over a spender address\\n struct PermitBatchTransferFrom {\\n // the tokens and corresponding amounts permitted for a transfer\\n TokenPermissions[] permitted;\\n // a unique value for every token owner's signature to prevent signature replays\\n uint256 nonce;\\n // deadline on the permit signature\\n uint256 deadline;\\n }\\n\\n /// @notice A map from token owner address and a caller specified word index to a bitmap. Used to set bits in the bitmap to prevent against signature replay protection\\n /// @dev Uses unordered nonces so that permit messages do not need to be spent in a certain order\\n /// @dev The mapping is indexed first by the token owner, then by an index specified in the nonce\\n /// @dev It returns a uint256 bitmap\\n /// @dev The index, or wordPosition is capped at type(uint248).max\\n function nonceBitmap(address, uint256) external view returns (uint256);\\n\\n /// @notice Transfers a token using a signed permit message\\n /// @dev Reverts if the requested amount is greater than the permitted signed amount\\n /// @param permit The permit data signed over by the owner\\n /// @param owner The owner of the tokens to transfer\\n /// @param transferDetails The spender's requested transfer details for the permitted token\\n /// @param signature The signature to verify\\n function permitTransferFrom(\\n PermitTransferFrom memory permit,\\n SignatureTransferDetails calldata transferDetails,\\n address owner,\\n bytes calldata signature\\n ) external;\\n\\n /// @notice Transfers multiple tokens using a signed permit message\\n /// @param permit The permit data signed over by the owner\\n /// @param owner The owner of the tokens to transfer\\n /// @param transferDetails Specifies the recipient and requested amount for the token transfer\\n /// @param signature The signature to verify\\n function permitTransferFrom(\\n PermitBatchTransferFrom memory permit,\\n SignatureTransferDetails[] calldata transferDetails,\\n address owner,\\n bytes calldata signature\\n ) external;\\n\\n /// @notice Invalidates the bits specified in mask for the bitmap at the word position\\n /// @dev The wordPos is maxed at type(uint248).max\\n /// @param wordPos A number to index the nonceBitmap at\\n /// @param mask A bitmap masked against msg.sender's current bitmap at the word position\\n function invalidateUnorderedNonces(uint256 wordPos, uint256 mask) external;\\n}\\n\",\"keccak256\":\"0xaffef816ae65c11123e5ac0ae0e7bf73506635bf6004d1ae3b4deed8c1bc69bd\",\"license\":\"MIT\"}},\"version\":1}", + "bytecode": "0x6101206040523480156200001257600080fd5b506040516200132938038062001329833981016040819052620000359162000140565b6001600160a01b038516158015906200005657506001600160a01b03841615155b80156200006b57506001600160a01b03831615155b80156200008057506001600160a01b03821615155b80156200009557506001600160a01b03811615155b620000f95760405162461bcd60e51b815260206004820152602a60248201527f4d6f63496e746567726174696f6e3a3a206e6f206e756c6c2061646472657373604482015269195cc8185b1b1bddd95960b21b606482015260840160405180910390fd5b6001600160a01b0394851660805292841660a05290831660c052821660e0521661010052620001b0565b80516001600160a01b03811681146200013b57600080fd5b919050565b600080600080600060a086880312156200015957600080fd5b620001648662000123565b9450620001746020870162000123565b9350620001846040870162000123565b9250620001946060870162000123565b9150620001a46080870162000123565b90509295509295909350565b60805160a05160c05160e051610100516110fc6200022d6000396000818161010a01526106f80152600081816102af0152818161046f01526107dd01526000818161015b015261035c0152600081816102280152818161043501526107a40152600081816101b101528181610531015261089701526110fc6000f3fe6080604052600436106100ec5760003560e01c80638da5cb5b1161008a578063c4d66de811610059578063c4d66de8146102d1578063e5085517146102f1578063f2fde38b14610311578063fc1768191461033157600080fd5b80638da5cb5b1461024a57806390e4b720146102685780639b2633ae1461027d578063b5c89bab1461029d57600080fd5b806353428253116100c6578063534282531461019f57806366960ead146101d3578063715018a6146102015780637a0a3ac51461021657600080fd5b806312261ee7146100f857806333c507ae14610149578063460f2de11461017d57600080fd5b366100f357005b600080fd5b34801561010457600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b34801561015557600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561018957600080fd5b5061019d610198366004610cbf565b610351565b005b3480156101ab57600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101df57600080fd5b506101f36101ee366004610d0c565b610653565b604051908152602001610140565b34801561020d57600080fd5b5061019d610673565b34801561022257600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561025657600080fd5b506033546001600160a01b031661012c565b34801561027457600080fd5b5061012c610687565b34801561028957600080fd5b5061019d610298366004610dfc565b6106bf565b3480156102a957600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102dd57600080fd5b5061019d6102ec366004610d0c565b6109bb565b3480156102fd57600080fd5b5061019d61030c366004610d0c565b610ad6565b34801561031d57600080fd5b5061019d61032c366004610d0c565b610aea565b34801561033d57600080fd5b5060975461012c906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356103966040890160208a01610ebf565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561040857600080fd5b505af115801561041c573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156104b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104dd9190610ee2565b146105035760405162461bcd60e51b81526004016104fa90610efb565b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b15801561057557600080fd5b505af1158015610589573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105a59190610f49565b604051909150600090339083908381818185875af1925050503d80600081146105ea576040519150601f19603f3d011682016040523d82523d6000602084013e6105ef565b606091505b50509050806106105760405162461bcd60e51b81526004016104fa90610f6a565b604080518781526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a2505050505050565b6001600160a01b0381166000908152609860205260408120545b92915050565b61067b610b60565b6106856000610bba565b565b60006106ba7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b81516020908101516040805180820182526000808252908401528051808201825230808252938101839052905163187945bd60e11b81527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906330f28b7a9061073b908890859033908a90600401610fbb565b600060405180830381600087803b15801561075557600080fd5b505af1158015610769573d6000803e3d6000fd5b5050336000908152609860205260409020805460018101909155915061078c9050565b5060405163fb2c922360e01b81526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116600483015260248201849052848116604483015283917f00000000000000000000000000000000000000000000000000000000000000009091169063fb2c9223906064016020604051808303816000875af1158015610828573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061084c9190610ee2565b146108695760405162461bcd60e51b81526004016104fa90610efb565b60975460405163b7aa53e760e01b8152600481018490526001600160a01b03918216602482015284821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156108db57600080fd5b505af11580156108ef573d6000803e3d6000fd5b50505050600081856001600160a01b03163161090b9190610f49565b604051909150600090339083908381818185875af1925050503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b50509050806109765760405162461bcd60e51b81526004016104fa90610f6a565b604080518681526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a25050505050505050565b600054610100900460ff16158080156109db5750600054600160ff909116105b806109f55750303b1580156109f5575060005460ff166001145b610a585760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104fa565b6000805460ff191660011790558015610a7b576000805461ff0019166101001790555b610a83610c0c565b610a8c82610c3b565b8015610ad2576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b610ade610b60565b610ae781610c3b565b50565b610af2610b60565b6001600160a01b038116610b575760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016104fa565b610ae781610bba565b6033546001600160a01b031633146106855760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104fa565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16610c335760405162461bcd60e51b81526004016104fa9061107b565b610685610c8f565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff16610cb65760405162461bcd60e51b81526004016104fa9061107b565b61068533610bba565b60008082840360a0811215610cd357600080fd5b833592506080601f1982011215610ce957600080fd5b506020830190509250929050565b6001600160a01b0381168114610ae757600080fd5b600060208284031215610d1e57600080fd5b8135610d2981610cf7565b9392505050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610d6957610d69610d30565b60405290565b600082601f830112610d8057600080fd5b813567ffffffffffffffff80821115610d9b57610d9b610d30565b604051601f8301601f19908116603f01168101908282118183101715610dc357610dc3610d30565b81604052838152866020858801011115610ddc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b60008082840360a0811215610e1057600080fd5b6080811215610e1e57600080fd5b6040516060810167ffffffffffffffff8282108183111715610e4257610e42610d30565b816040526040841215610e5457600080fd5b610e5c610d46565b935086359150610e6b82610cf7565b8184526020870135602085015283835260408701356020840152606087013560408401528295506080870135935080841115610ea657600080fd5b505050610eb585828601610d6f565b9150509250929050565b600060208284031215610ed157600080fd5b813560ff81168114610d2957600080fd5b600060208284031215610ef457600080fd5b5051919050565b6020808252602e908201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260408201526d1958dd08111bd0c8185b5bdd5b9d60921b606082015260800190565b8181038181111561066d57634e487b7160e01b600052601160045260246000fd5b60208082526031908201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604082015270696e672072656465656d6564205242544360781b606082015260800190565b6000610100610fde83885180516001600160a01b03168252602090810151910152565b602080880151604085015260408801516060850152611013608085018880516001600160a01b03168252602090810151910152565b6001600160a01b03861660c085015260e0840182905284519184018290526000915b8083101561105457858301820151858401610120015291810191611035565b6101209250600083828701015282601f19601f830116860101935050505095945050505050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea2646970667358221220d3520caf24be1597c52a894253bc89ae96dd1ecde727f772f65c3be231572d2864736f6c63430008110033", + "deployedBytecode": "0x6080604052600436106100ec5760003560e01c80638da5cb5b1161008a578063c4d66de811610059578063c4d66de8146102d1578063e5085517146102f1578063f2fde38b14610311578063fc1768191461033157600080fd5b80638da5cb5b1461024a57806390e4b720146102685780639b2633ae1461027d578063b5c89bab1461029d57600080fd5b806353428253116100c6578063534282531461019f57806366960ead146101d3578063715018a6146102015780637a0a3ac51461021657600080fd5b806312261ee7146100f857806333c507ae14610149578063460f2de11461017d57600080fd5b366100f357005b600080fd5b34801561010457600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b34801561015557600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561018957600080fd5b5061019d610198366004610cbf565b610351565b005b3480156101ab57600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101df57600080fd5b506101f36101ee366004610d0c565b610653565b604051908152602001610140565b34801561020d57600080fd5b5061019d610673565b34801561022257600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561025657600080fd5b506033546001600160a01b031661012c565b34801561027457600080fd5b5061012c610687565b34801561028957600080fd5b5061019d610298366004610dfc565b6106bf565b3480156102a957600080fd5b5061012c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102dd57600080fd5b5061019d6102ec366004610d0c565b6109bb565b3480156102fd57600080fd5b5061019d61030c366004610d0c565b610ad6565b34801561031d57600080fd5b5061019d61032c366004610d0c565b610aea565b34801561033d57600080fd5b5060975461012c906001600160a01b031681565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663605629d633838686356103966040890160208a01610ebf565b604080516001600160e01b031960e089901b1681526001600160a01b0396871660048201529590941660248601526044850192909252606484015260ff16608483015285013560a4820152606085013560c482015260e401600060405180830381600087803b15801561040857600080fd5b505af115801561041c573d6000803e3d6000fd5b505060405163fb2c922360e01b81526001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000811660048301526024820187905284811660448301528693507f000000000000000000000000000000000000000000000000000000000000000016915063fb2c9223906064016020604051808303816000875af11580156104b9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104dd9190610ee2565b146105035760405162461bcd60e51b81526004016104fa90610efb565b60405180910390fd5b60975460405163b7aa53e760e01b8152600481018590526001600160a01b03918216602482015282821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b15801561057557600080fd5b505af1158015610589573d6000803e3d6000fd5b50505050600081836001600160a01b0316316105a59190610f49565b604051909150600090339083908381818185875af1925050503d80600081146105ea576040519150601f19603f3d011682016040523d82523d6000602084013e6105ef565b606091505b50509050806106105760405162461bcd60e51b81526004016104fa90610f6a565b604080518781526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a2505050505050565b6001600160a01b0381166000908152609860205260408120545b92915050565b61067b610b60565b6106856000610bba565b565b60006106ba7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b905090565b81516020908101516040805180820182526000808252908401528051808201825230808252938101839052905163187945bd60e11b81527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906330f28b7a9061073b908890859033908a90600401610fbb565b600060405180830381600087803b15801561075557600080fd5b505af1158015610769573d6000803e3d6000fd5b5050336000908152609860205260409020805460018101909155915061078c9050565b5060405163fb2c922360e01b81526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116600483015260248201849052848116604483015283917f00000000000000000000000000000000000000000000000000000000000000009091169063fb2c9223906064016020604051808303816000875af1158015610828573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061084c9190610ee2565b146108695760405162461bcd60e51b81526004016104fa90610efb565b60975460405163b7aa53e760e01b8152600481018490526001600160a01b03918216602482015284821631917f0000000000000000000000000000000000000000000000000000000000000000169063b7aa53e790604401600060405180830381600087803b1580156108db57600080fd5b505af11580156108ef573d6000803e3d6000fd5b50505050600081856001600160a01b03163161090b9190610f49565b604051909150600090339083908381818185875af1925050503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b50509050806109765760405162461bcd60e51b81526004016104fa90610f6a565b604080518681526020810184905233917f5933f612d4a5aafda234d2ad17b54eba4187e2bb520cf7373e223c5894851ca5910160405180910390a25050505050505050565b600054610100900460ff16158080156109db5750600054600160ff909116105b806109f55750303b1580156109f5575060005460ff166001145b610a585760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016104fa565b6000805460ff191660011790558015610a7b576000805461ff0019166101001790555b610a83610c0c565b610a8c82610c3b565b8015610ad2576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050565b610ade610b60565b610ae781610c3b565b50565b610af2610b60565b6001600160a01b038116610b575760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016104fa565b610ae781610bba565b6033546001600160a01b031633146106855760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104fa565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16610c335760405162461bcd60e51b81526004016104fa9061107b565b610685610c8f565b609780546001600160a01b0319166001600160a01b0383169081179091556040519081527fc2a1feb9d65ecb31b0e93a520a66d19319929a2bf58046d92d762c04e7dd06c99060200160405180910390a150565b600054610100900460ff16610cb65760405162461bcd60e51b81526004016104fa9061107b565b61068533610bba565b60008082840360a0811215610cd357600080fd5b833592506080601f1982011215610ce957600080fd5b506020830190509250929050565b6001600160a01b0381168114610ae757600080fd5b600060208284031215610d1e57600080fd5b8135610d2981610cf7565b9392505050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610d6957610d69610d30565b60405290565b600082601f830112610d8057600080fd5b813567ffffffffffffffff80821115610d9b57610d9b610d30565b604051601f8301601f19908116603f01168101908282118183101715610dc357610dc3610d30565b81604052838152866020858801011115610ddc57600080fd5b836020870160208301376000602085830101528094505050505092915050565b60008082840360a0811215610e1057600080fd5b6080811215610e1e57600080fd5b6040516060810167ffffffffffffffff8282108183111715610e4257610e42610d30565b816040526040841215610e5457600080fd5b610e5c610d46565b935086359150610e6b82610cf7565b8184526020870135602085015283835260408701356020840152606087013560408401528295506080870135935080841115610ea657600080fd5b505050610eb585828601610d6f565b9150509250929050565b600060208284031215610ed157600080fd5b813560ff81168114610d2957600080fd5b600060208284031215610ef457600080fd5b5051919050565b6020808252602e908201527f4d6f63496e746567726174696f6e3a3a2072656465656d656420696e636f727260408201526d1958dd08111bd0c8185b5bdd5b9d60921b606082015260800190565b8181038181111561066d57634e487b7160e01b600052601160045260246000fd5b60208082526031908201527f4d6f63496e746567726174696f6e3a3a206572726f72207472616e7366657272604082015270696e672072656465656d6564205242544360781b606082015260800190565b6000610100610fde83885180516001600160a01b03168252602090810151910152565b602080880151604085015260408801516060850152611013608085018880516001600160a01b03168252602090810151910152565b6001600160a01b03861660c085015260e0840182905284519184018290526000915b8083101561105457858301820151858401610120015291810191611035565b6101209250600083828701015282601f19601f830116860101935050505095945050505050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b60608201526080019056fea2646970667358221220d3520caf24be1597c52a894253bc89ae96dd1ecde727f772f65c3be231572d2864736f6c63430008110033", "devdoc": { "kind": "dev", "methods": { @@ -362,6 +453,21 @@ "_permitParams": "EIP-2612 permit params: _deadline Expiration time of the signature. _v Last 1 byte of ECDSA signature. _r First 32 bytes of ECDSA signature. _s 32 bytes after _r in ECDSA signature." } }, + "getDocFromDllrAndRedeemRbtcWithPermit2(((address,uint256),uint256,uint256),bytes)": { + "params": { + "permit": "permit data, in form of PermitTransferFrom struct.", + "signature": "of the permit data." + } + }, + "getPermit2Nonce(address)": { + "details": "getter for currernt nonce", + "params": { + "_address": "address of owner" + }, + "returns": { + "_0": "current nonce of the owner's address" + } + }, "getProxyImplementation()": { "details": "get the implementation logic address referring to ERC1967 standard.", "returns": { @@ -386,6 +492,9 @@ "getDocFromDllrAndRedeemRBTC(uint256,(uint256,uint8,bytes32,bytes32))": { "notice": "how getDocFromDllrAndRedeemRBTC function works: ------------------------------------------------------------------------------------------- | Mynt | Money On Chain | ------------------------------------------------------------------------------------------- | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user | -------------------------------------------------------------------------------------------" }, + "getDocFromDllrAndRedeemRbtcWithPermit2(((address,uint256),uint256,uint256),bytes)": { + "notice": "how getDocFromDllrAndRedeemRBTC function works: ------------------------------------------------------------------------------------------- | Mynt | Money On Chain | ------------------------------------------------------------------------------------------- | get DLLR (EIP-2612) -> convert DLLR to DoC | -> get RBTC from DoC -> send RBTC to user | -------------------------------------------------------------------------------------------" + }, "setMocVendorAccount(address)": { "notice": "Set MoC registered Vendor account to receive markup fees https://docs.moneyonchain.com/main-rbtc-contract/integration-with-moc-platform/vendors" } @@ -412,7 +521,7 @@ "type": "t_bool" }, { - "astId": 1094, + "astId": 1021, "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", "label": "__gap", "offset": 0, @@ -444,12 +553,20 @@ "type": "t_array(t_uint256)50_storage" }, { - "astId": 5786, + "astId": 3845, "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", "label": "mocVendorAccount", "offset": 0, "slot": "151", "type": "t_address" + }, + { + "astId": 3853, + "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", + "label": "_permit2Nonces", + "offset": 0, + "slot": "152", + "type": "t_mapping(t_address,t_struct(Counter)2121_storage)" } ], "types": { @@ -475,6 +592,28 @@ "label": "bool", "numberOfBytes": "1" }, + "t_mapping(t_address,t_struct(Counter)2121_storage)": { + "encoding": "mapping", + "key": "t_address", + "label": "mapping(address => struct Counters.Counter)", + "numberOfBytes": "32", + "value": "t_struct(Counter)2121_storage" + }, + "t_struct(Counter)2121_storage": { + "encoding": "inplace", + "label": "struct Counters.Counter", + "members": [ + { + "astId": 2120, + "contract": "contracts/integration/MoC/MocIntegration.sol:MocIntegration", + "label": "_value", + "offset": 0, + "slot": "0", + "type": "t_uint256" + } + ], + "numberOfBytes": "32" + }, "t_uint256": { "encoding": "inplace", "label": "uint256",