├── SenderCreator__factory.ts ├── IStakeManager__factory.ts ├── MaliciousAccount__factory.ts ├── StakeManager__factory.ts ├── VerifyingPaymaster__factory.ts ├── SimpleAccount__factory.ts ├── SimpleAccountFactory__factory.ts └── TokenPaymaster__factory.ts /SenderCreator__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; 5 | import type { Provider, TransactionRequest } from "@ethersproject/providers"; 6 | import type { PromiseOrValue } from "../common"; 7 | import type { SenderCreator, SenderCreatorInterface } from "../SenderCreator"; 8 | 9 | const _abi = [ 10 | { 11 | inputs: [ 12 | { 13 | internalType: "bytes", 14 | name: "initCode", 15 | type: "bytes", 16 | }, 17 | ], 18 | name: "createSender", 19 | outputs: [ 20 | { 21 | internalType: "address", 22 | name: "sender", 23 | type: "address", 24 | }, 25 | ], 26 | stateMutability: "nonpayable", 27 | type: "function", 28 | }, 29 | ] as const; 30 | 31 | const _bytecode = 32 | "0x608060405234801561001057600080fd5b50610213806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c8063570e1a3614610030575b600080fd5b61004361003e3660046100f9565b61006c565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b60008061007c601482858761016b565b61008591610195565b60601c90506000610099846014818861016b565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092018290525084519495509360209350849250905082850182875af190506000519350806100f057600093505b50505092915050565b6000806020838503121561010c57600080fd5b823567ffffffffffffffff8082111561012457600080fd5b818501915085601f83011261013857600080fd5b81358181111561014757600080fd5b86602082850101111561015957600080fd5b60209290920196919550909350505050565b6000808585111561017b57600080fd5b8386111561018857600080fd5b5050820193919092039150565b7fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081358181169160148510156101d55780818660140360031b1b83161692505b50509291505056fea2646970667358221220d5d7cb55b3123d86b2710028be2074a469cca162ad2a26c50fb1cfdce4424b9464736f6c634300080f0033"; 33 | 34 | type SenderCreatorConstructorParams = 35 | | [signer?: Signer] 36 | | ConstructorParameters; 37 | 38 | const isSuperArgs = ( 39 | xs: SenderCreatorConstructorParams 40 | ): xs is ConstructorParameters => xs.length > 1; 41 | 42 | export class SenderCreator__factory extends ContractFactory { 43 | constructor(...args: SenderCreatorConstructorParams) { 44 | if (isSuperArgs(args)) { 45 | super(...args); 46 | } else { 47 | super(_abi, _bytecode, args[0]); 48 | } 49 | } 50 | 51 | override deploy( 52 | overrides?: Overrides & { from?: PromiseOrValue } 53 | ): Promise { 54 | return super.deploy(overrides || {}) as Promise; 55 | } 56 | override getDeployTransaction( 57 | overrides?: Overrides & { from?: PromiseOrValue } 58 | ): TransactionRequest { 59 | return super.getDeployTransaction(overrides || {}); 60 | } 61 | override attach(address: string): SenderCreator { 62 | return super.attach(address) as SenderCreator; 63 | } 64 | override connect(signer: Signer): SenderCreator__factory { 65 | return super.connect(signer) as SenderCreator__factory; 66 | } 67 | 68 | static readonly bytecode = _bytecode; 69 | static readonly abi = _abi; 70 | static createInterface(): SenderCreatorInterface { 71 | return new utils.Interface(_abi) as SenderCreatorInterface; 72 | } 73 | static connect( 74 | address: string, 75 | signerOrProvider: Signer | Provider 76 | ): SenderCreator { 77 | return new Contract(address, _abi, signerOrProvider) as SenderCreator; 78 | } 79 | } 80 | -------------------------------------------------------------------------------- /IStakeManager__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | 5 | import { Contract, Signer, utils } from "ethers"; 6 | import type { Provider } from "@ethersproject/providers"; 7 | import type { IStakeManager, IStakeManagerInterface } from "../IStakeManager"; 8 | 9 | const _abi = [ 10 | { 11 | anonymous: false, 12 | inputs: [ 13 | { 14 | indexed: true, 15 | internalType: "address", 16 | name: "account", 17 | type: "address", 18 | }, 19 | { 20 | indexed: false, 21 | internalType: "uint256", 22 | name: "totalDeposit", 23 | type: "uint256", 24 | }, 25 | ], 26 | name: "Deposited", 27 | type: "event", 28 | }, 29 | { 30 | anonymous: false, 31 | inputs: [ 32 | { 33 | indexed: true, 34 | internalType: "address", 35 | name: "account", 36 | type: "address", 37 | }, 38 | { 39 | indexed: false, 40 | internalType: "uint256", 41 | name: "totalStaked", 42 | type: "uint256", 43 | }, 44 | { 45 | indexed: false, 46 | internalType: "uint256", 47 | name: "unstakeDelaySec", 48 | type: "uint256", 49 | }, 50 | ], 51 | name: "StakeLocked", 52 | type: "event", 53 | }, 54 | { 55 | anonymous: false, 56 | inputs: [ 57 | { 58 | indexed: true, 59 | internalType: "address", 60 | name: "account", 61 | type: "address", 62 | }, 63 | { 64 | indexed: false, 65 | internalType: "uint256", 66 | name: "withdrawTime", 67 | type: "uint256", 68 | }, 69 | ], 70 | name: "StakeUnlocked", 71 | type: "event", 72 | }, 73 | { 74 | anonymous: false, 75 | inputs: [ 76 | { 77 | indexed: true, 78 | internalType: "address", 79 | name: "account", 80 | type: "address", 81 | }, 82 | { 83 | indexed: false, 84 | internalType: "address", 85 | name: "withdrawAddress", 86 | type: "address", 87 | }, 88 | { 89 | indexed: false, 90 | internalType: "uint256", 91 | name: "amount", 92 | type: "uint256", 93 | }, 94 | ], 95 | name: "StakeWithdrawn", 96 | type: "event", 97 | }, 98 | { 99 | anonymous: false, 100 | inputs: [ 101 | { 102 | indexed: true, 103 | internalType: "address", 104 | name: "account", 105 | type: "address", 106 | }, 107 | { 108 | indexed: false, 109 | internalType: "address", 110 | name: "withdrawAddress", 111 | type: "address", 112 | }, 113 | { 114 | indexed: false, 115 | internalType: "uint256", 116 | name: "amount", 117 | type: "uint256", 118 | }, 119 | ], 120 | name: "Withdrawn", 121 | type: "event", 122 | }, 123 | { 124 | inputs: [ 125 | { 126 | internalType: "uint32", 127 | name: "_unstakeDelaySec", 128 | type: "uint32", 129 | }, 130 | ], 131 | name: "addStake", 132 | outputs: [], 133 | stateMutability: "payable", 134 | type: "function", 135 | }, 136 | { 137 | inputs: [ 138 | { 139 | internalType: "address", 140 | name: "account", 141 | type: "address", 142 | }, 143 | ], 144 | name: "balanceOf", 145 | outputs: [ 146 | { 147 | internalType: "uint256", 148 | name: "", 149 | type: "uint256", 150 | }, 151 | ], 152 | stateMutability: "view", 153 | type: "function", 154 | }, 155 | { 156 | inputs: [ 157 | { 158 | internalType: "address", 159 | name: "account", 160 | type: "address", 161 | }, 162 | ], 163 | name: "depositTo", 164 | outputs: [], 165 | stateMutability: "payable", 166 | type: "function", 167 | }, 168 | { 169 | inputs: [ 170 | { 171 | internalType: "address", 172 | name: "account", 173 | type: "address", 174 | }, 175 | ], 176 | name: "getDepositInfo", 177 | outputs: [ 178 | { 179 | components: [ 180 | { 181 | internalType: "uint112", 182 | name: "deposit", 183 | type: "uint112", 184 | }, 185 | { 186 | internalType: "bool", 187 | name: "staked", 188 | type: "bool", 189 | }, 190 | { 191 | internalType: "uint112", 192 | name: "stake", 193 | type: "uint112", 194 | }, 195 | { 196 | internalType: "uint32", 197 | name: "unstakeDelaySec", 198 | type: "uint32", 199 | }, 200 | { 201 | internalType: "uint48", 202 | name: "withdrawTime", 203 | type: "uint48", 204 | }, 205 | ], 206 | internalType: "struct IStakeManager.DepositInfo", 207 | name: "info", 208 | type: "tuple", 209 | }, 210 | ], 211 | stateMutability: "view", 212 | type: "function", 213 | }, 214 | { 215 | inputs: [], 216 | name: "unlockStake", 217 | outputs: [], 218 | stateMutability: "nonpayable", 219 | type: "function", 220 | }, 221 | { 222 | inputs: [ 223 | { 224 | internalType: "address payable", 225 | name: "withdrawAddress", 226 | type: "address", 227 | }, 228 | ], 229 | name: "withdrawStake", 230 | outputs: [], 231 | stateMutability: "nonpayable", 232 | type: "function", 233 | }, 234 | { 235 | inputs: [ 236 | { 237 | internalType: "address payable", 238 | name: "withdrawAddress", 239 | type: "address", 240 | }, 241 | { 242 | internalType: "uint256", 243 | name: "withdrawAmount", 244 | type: "uint256", 245 | }, 246 | ], 247 | name: "withdrawTo", 248 | outputs: [], 249 | stateMutability: "nonpayable", 250 | type: "function", 251 | }, 252 | ] as const; 253 | 254 | export class IStakeManager__factory { 255 | static readonly abi = _abi; 256 | static createInterface(): IStakeManagerInterface { 257 | return new utils.Interface(_abi) as IStakeManagerInterface; 258 | } 259 | static connect( 260 | address: string, 261 | signerOrProvider: Signer | Provider 262 | ): IStakeManager { 263 | return new Contract(address, _abi, signerOrProvider) as IStakeManager; 264 | } 265 | } 266 | -------------------------------------------------------------------------------- /MaliciousAccount__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | import { 5 | Signer, 6 | utils, 7 | Contract, 8 | ContractFactory, 9 | PayableOverrides, 10 | } from "ethers"; 11 | import type { Provider, TransactionRequest } from "@ethersproject/providers"; 12 | import type { PromiseOrValue } from "../common"; 13 | import type { 14 | MaliciousAccount, 15 | MaliciousAccountInterface, 16 | } from "../MaliciousAccount"; 17 | 18 | const _abi = [ 19 | { 20 | inputs: [ 21 | { 22 | internalType: "contract IEntryPoint", 23 | name: "_ep", 24 | type: "address", 25 | }, 26 | ], 27 | stateMutability: "payable", 28 | type: "constructor", 29 | }, 30 | { 31 | inputs: [ 32 | { 33 | components: [ 34 | { 35 | internalType: "address", 36 | name: "sender", 37 | type: "address", 38 | }, 39 | { 40 | internalType: "uint256", 41 | name: "nonce", 42 | type: "uint256", 43 | }, 44 | { 45 | internalType: "bytes", 46 | name: "initCode", 47 | type: "bytes", 48 | }, 49 | { 50 | internalType: "bytes", 51 | name: "callData", 52 | type: "bytes", 53 | }, 54 | { 55 | internalType: "uint256", 56 | name: "callGasLimit", 57 | type: "uint256", 58 | }, 59 | { 60 | internalType: "uint256", 61 | name: "verificationGasLimit", 62 | type: "uint256", 63 | }, 64 | { 65 | internalType: "uint256", 66 | name: "preVerificationGas", 67 | type: "uint256", 68 | }, 69 | { 70 | internalType: "uint256", 71 | name: "maxFeePerGas", 72 | type: "uint256", 73 | }, 74 | { 75 | internalType: "uint256", 76 | name: "maxPriorityFeePerGas", 77 | type: "uint256", 78 | }, 79 | { 80 | internalType: "bytes", 81 | name: "paymasterAndData", 82 | type: "bytes", 83 | }, 84 | { 85 | internalType: "bytes", 86 | name: "signature", 87 | type: "bytes", 88 | }, 89 | ], 90 | internalType: "struct UserOperation", 91 | name: "userOp", 92 | type: "tuple", 93 | }, 94 | { 95 | internalType: "bytes32", 96 | name: "", 97 | type: "bytes32", 98 | }, 99 | { 100 | internalType: "uint256", 101 | name: "missingAccountFunds", 102 | type: "uint256", 103 | }, 104 | ], 105 | name: "validateUserOp", 106 | outputs: [ 107 | { 108 | internalType: "uint256", 109 | name: "validationData", 110 | type: "uint256", 111 | }, 112 | ], 113 | stateMutability: "nonpayable", 114 | type: "function", 115 | }, 116 | ] as const; 117 | 118 | const _bytecode = 119 | "0x608060405260405161034a38038061034a83398101604081905261002291610047565b600080546001600160a01b0319166001600160a01b0392909216919091179055610077565b60006020828403121561005957600080fd5b81516001600160a01b038116811461007057600080fd5b9392505050565b6102c4806100866000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c80633a871cdd14610030575b600080fd5b61004361003e3660046101a1565b610055565b60405190815260200160405180910390f35b600080546040517fb760faf900000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff9091169063b760faf99084906024016000604051808303818588803b1580156100c257600080fd5b505af11580156100d6573d6000803e3d6000fd5b505050505060008460c001358560a0013586608001356100f69190610224565b6101009190610224565b9050600061010e828561023c565b9050600061012161010088013583610277565b905086602001358114610194576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f5265766572742061667465722066697273742076616c69646174696f6e000000604482015260640160405180910390fd5b5060009695505050505050565b6000806000606084860312156101b657600080fd5b833567ffffffffffffffff8111156101cd57600080fd5b840161016081870312156101e057600080fd5b95602085013595506040909401359392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115610237576102376101f5565b500190565b600082610272577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b600082821015610289576102896101f5565b50039056fea2646970667358221220233c1b53bed3630405955a2809bf977fcd3053b67e56cf39bd460d18cc03844c64736f6c634300080f0033"; 120 | 121 | type MaliciousAccountConstructorParams = 122 | | [signer?: Signer] 123 | | ConstructorParameters; 124 | 125 | const isSuperArgs = ( 126 | xs: MaliciousAccountConstructorParams 127 | ): xs is ConstructorParameters => xs.length > 1; 128 | 129 | export class MaliciousAccount__factory extends ContractFactory { 130 | constructor(...args: MaliciousAccountConstructorParams) { 131 | if (isSuperArgs(args)) { 132 | super(...args); 133 | } else { 134 | super(_abi, _bytecode, args[0]); 135 | } 136 | } 137 | 138 | override deploy( 139 | _ep: PromiseOrValue, 140 | overrides?: PayableOverrides & { from?: PromiseOrValue } 141 | ): Promise { 142 | return super.deploy(_ep, overrides || {}) as Promise; 143 | } 144 | override getDeployTransaction( 145 | _ep: PromiseOrValue, 146 | overrides?: PayableOverrides & { from?: PromiseOrValue } 147 | ): TransactionRequest { 148 | return super.getDeployTransaction(_ep, overrides || {}); 149 | } 150 | override attach(address: string): MaliciousAccount { 151 | return super.attach(address) as MaliciousAccount; 152 | } 153 | override connect(signer: Signer): MaliciousAccount__factory { 154 | return super.connect(signer) as MaliciousAccount__factory; 155 | } 156 | 157 | static readonly bytecode = _bytecode; 158 | static readonly abi = _abi; 159 | static createInterface(): MaliciousAccountInterface { 160 | return new utils.Interface(_abi) as MaliciousAccountInterface; 161 | } 162 | static connect( 163 | address: string, 164 | signerOrProvider: Signer | Provider 165 | ): MaliciousAccount { 166 | return new Contract(address, _abi, signerOrProvider) as MaliciousAccount; 167 | } 168 | } 169 | -------------------------------------------------------------------------------- /StakeManager__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | 5 | import { Contract, Signer, utils } from "ethers"; 6 | import type { Provider } from "@ethersproject/providers"; 7 | import type { StakeManager, StakeManagerInterface } from "../StakeManager"; 8 | 9 | const _abi = [ 10 | { 11 | anonymous: false, 12 | inputs: [ 13 | { 14 | indexed: true, 15 | internalType: "address", 16 | name: "account", 17 | type: "address", 18 | }, 19 | { 20 | indexed: false, 21 | internalType: "uint256", 22 | name: "totalDeposit", 23 | type: "uint256", 24 | }, 25 | ], 26 | name: "Deposited", 27 | type: "event", 28 | }, 29 | { 30 | anonymous: false, 31 | inputs: [ 32 | { 33 | indexed: true, 34 | internalType: "address", 35 | name: "account", 36 | type: "address", 37 | }, 38 | { 39 | indexed: false, 40 | internalType: "uint256", 41 | name: "totalStaked", 42 | type: "uint256", 43 | }, 44 | { 45 | indexed: false, 46 | internalType: "uint256", 47 | name: "unstakeDelaySec", 48 | type: "uint256", 49 | }, 50 | ], 51 | name: "StakeLocked", 52 | type: "event", 53 | }, 54 | { 55 | anonymous: false, 56 | inputs: [ 57 | { 58 | indexed: true, 59 | internalType: "address", 60 | name: "account", 61 | type: "address", 62 | }, 63 | { 64 | indexed: false, 65 | internalType: "uint256", 66 | name: "withdrawTime", 67 | type: "uint256", 68 | }, 69 | ], 70 | name: "StakeUnlocked", 71 | type: "event", 72 | }, 73 | { 74 | anonymous: false, 75 | inputs: [ 76 | { 77 | indexed: true, 78 | internalType: "address", 79 | name: "account", 80 | type: "address", 81 | }, 82 | { 83 | indexed: false, 84 | internalType: "address", 85 | name: "withdrawAddress", 86 | type: "address", 87 | }, 88 | { 89 | indexed: false, 90 | internalType: "uint256", 91 | name: "amount", 92 | type: "uint256", 93 | }, 94 | ], 95 | name: "StakeWithdrawn", 96 | type: "event", 97 | }, 98 | { 99 | anonymous: false, 100 | inputs: [ 101 | { 102 | indexed: true, 103 | internalType: "address", 104 | name: "account", 105 | type: "address", 106 | }, 107 | { 108 | indexed: false, 109 | internalType: "address", 110 | name: "withdrawAddress", 111 | type: "address", 112 | }, 113 | { 114 | indexed: false, 115 | internalType: "uint256", 116 | name: "amount", 117 | type: "uint256", 118 | }, 119 | ], 120 | name: "Withdrawn", 121 | type: "event", 122 | }, 123 | { 124 | inputs: [ 125 | { 126 | internalType: "uint32", 127 | name: "unstakeDelaySec", 128 | type: "uint32", 129 | }, 130 | ], 131 | name: "addStake", 132 | outputs: [], 133 | stateMutability: "payable", 134 | type: "function", 135 | }, 136 | { 137 | inputs: [ 138 | { 139 | internalType: "address", 140 | name: "account", 141 | type: "address", 142 | }, 143 | ], 144 | name: "balanceOf", 145 | outputs: [ 146 | { 147 | internalType: "uint256", 148 | name: "", 149 | type: "uint256", 150 | }, 151 | ], 152 | stateMutability: "view", 153 | type: "function", 154 | }, 155 | { 156 | inputs: [ 157 | { 158 | internalType: "address", 159 | name: "account", 160 | type: "address", 161 | }, 162 | ], 163 | name: "depositTo", 164 | outputs: [], 165 | stateMutability: "payable", 166 | type: "function", 167 | }, 168 | { 169 | inputs: [ 170 | { 171 | internalType: "address", 172 | name: "", 173 | type: "address", 174 | }, 175 | ], 176 | name: "deposits", 177 | outputs: [ 178 | { 179 | internalType: "uint112", 180 | name: "deposit", 181 | type: "uint112", 182 | }, 183 | { 184 | internalType: "bool", 185 | name: "staked", 186 | type: "bool", 187 | }, 188 | { 189 | internalType: "uint112", 190 | name: "stake", 191 | type: "uint112", 192 | }, 193 | { 194 | internalType: "uint32", 195 | name: "unstakeDelaySec", 196 | type: "uint32", 197 | }, 198 | { 199 | internalType: "uint48", 200 | name: "withdrawTime", 201 | type: "uint48", 202 | }, 203 | ], 204 | stateMutability: "view", 205 | type: "function", 206 | }, 207 | { 208 | inputs: [ 209 | { 210 | internalType: "address", 211 | name: "account", 212 | type: "address", 213 | }, 214 | ], 215 | name: "getDepositInfo", 216 | outputs: [ 217 | { 218 | components: [ 219 | { 220 | internalType: "uint112", 221 | name: "deposit", 222 | type: "uint112", 223 | }, 224 | { 225 | internalType: "bool", 226 | name: "staked", 227 | type: "bool", 228 | }, 229 | { 230 | internalType: "uint112", 231 | name: "stake", 232 | type: "uint112", 233 | }, 234 | { 235 | internalType: "uint32", 236 | name: "unstakeDelaySec", 237 | type: "uint32", 238 | }, 239 | { 240 | internalType: "uint48", 241 | name: "withdrawTime", 242 | type: "uint48", 243 | }, 244 | ], 245 | internalType: "struct IStakeManager.DepositInfo", 246 | name: "info", 247 | type: "tuple", 248 | }, 249 | ], 250 | stateMutability: "view", 251 | type: "function", 252 | }, 253 | { 254 | inputs: [], 255 | name: "unlockStake", 256 | outputs: [], 257 | stateMutability: "nonpayable", 258 | type: "function", 259 | }, 260 | { 261 | inputs: [ 262 | { 263 | internalType: "address payable", 264 | name: "withdrawAddress", 265 | type: "address", 266 | }, 267 | ], 268 | name: "withdrawStake", 269 | outputs: [], 270 | stateMutability: "nonpayable", 271 | type: "function", 272 | }, 273 | { 274 | inputs: [ 275 | { 276 | internalType: "address payable", 277 | name: "withdrawAddress", 278 | type: "address", 279 | }, 280 | { 281 | internalType: "uint256", 282 | name: "withdrawAmount", 283 | type: "uint256", 284 | }, 285 | ], 286 | name: "withdrawTo", 287 | outputs: [], 288 | stateMutability: "nonpayable", 289 | type: "function", 290 | }, 291 | { 292 | stateMutability: "payable", 293 | type: "receive", 294 | }, 295 | ] as const; 296 | 297 | export class StakeManager__factory { 298 | static readonly abi = _abi; 299 | static createInterface(): StakeManagerInterface { 300 | return new utils.Interface(_abi) as StakeManagerInterface; 301 | } 302 | static connect( 303 | address: string, 304 | signerOrProvider: Signer | Provider 305 | ): StakeManager { 306 | return new Contract(address, _abi, signerOrProvider) as StakeManager; 307 | } 308 | } 309 | -------------------------------------------------------------------------------- /VerifyingPaymaster__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; 5 | import type { Provider, TransactionRequest } from "@ethersproject/providers"; 6 | import type { PromiseOrValue } from "../common"; 7 | import type { 8 | VerifyingPaymaster, 9 | VerifyingPaymasterInterface, 10 | } from "../VerifyingPaymaster"; 11 | 12 | const _abi = [ 13 | { 14 | inputs: [ 15 | { 16 | internalType: "contract IEntryPoint", 17 | name: "_entryPoint", 18 | type: "address", 19 | }, 20 | { 21 | internalType: "address", 22 | name: "_verifyingSigner", 23 | type: "address", 24 | }, 25 | ], 26 | stateMutability: "nonpayable", 27 | type: "constructor", 28 | }, 29 | { 30 | anonymous: false, 31 | inputs: [ 32 | { 33 | indexed: true, 34 | internalType: "address", 35 | name: "previousOwner", 36 | type: "address", 37 | }, 38 | { 39 | indexed: true, 40 | internalType: "address", 41 | name: "newOwner", 42 | type: "address", 43 | }, 44 | ], 45 | name: "OwnershipTransferred", 46 | type: "event", 47 | }, 48 | { 49 | inputs: [ 50 | { 51 | internalType: "uint32", 52 | name: "unstakeDelaySec", 53 | type: "uint32", 54 | }, 55 | ], 56 | name: "addStake", 57 | outputs: [], 58 | stateMutability: "payable", 59 | type: "function", 60 | }, 61 | { 62 | inputs: [], 63 | name: "deposit", 64 | outputs: [], 65 | stateMutability: "payable", 66 | type: "function", 67 | }, 68 | { 69 | inputs: [], 70 | name: "entryPoint", 71 | outputs: [ 72 | { 73 | internalType: "contract IEntryPoint", 74 | name: "", 75 | type: "address", 76 | }, 77 | ], 78 | stateMutability: "view", 79 | type: "function", 80 | }, 81 | { 82 | inputs: [], 83 | name: "getDeposit", 84 | outputs: [ 85 | { 86 | internalType: "uint256", 87 | name: "", 88 | type: "uint256", 89 | }, 90 | ], 91 | stateMutability: "view", 92 | type: "function", 93 | }, 94 | { 95 | inputs: [ 96 | { 97 | components: [ 98 | { 99 | internalType: "address", 100 | name: "sender", 101 | type: "address", 102 | }, 103 | { 104 | internalType: "uint256", 105 | name: "nonce", 106 | type: "uint256", 107 | }, 108 | { 109 | internalType: "bytes", 110 | name: "initCode", 111 | type: "bytes", 112 | }, 113 | { 114 | internalType: "bytes", 115 | name: "callData", 116 | type: "bytes", 117 | }, 118 | { 119 | internalType: "uint256", 120 | name: "callGasLimit", 121 | type: "uint256", 122 | }, 123 | { 124 | internalType: "uint256", 125 | name: "verificationGasLimit", 126 | type: "uint256", 127 | }, 128 | { 129 | internalType: "uint256", 130 | name: "preVerificationGas", 131 | type: "uint256", 132 | }, 133 | { 134 | internalType: "uint256", 135 | name: "maxFeePerGas", 136 | type: "uint256", 137 | }, 138 | { 139 | internalType: "uint256", 140 | name: "maxPriorityFeePerGas", 141 | type: "uint256", 142 | }, 143 | { 144 | internalType: "bytes", 145 | name: "paymasterAndData", 146 | type: "bytes", 147 | }, 148 | { 149 | internalType: "bytes", 150 | name: "signature", 151 | type: "bytes", 152 | }, 153 | ], 154 | internalType: "struct UserOperation", 155 | name: "userOp", 156 | type: "tuple", 157 | }, 158 | { 159 | internalType: "uint48", 160 | name: "validUntil", 161 | type: "uint48", 162 | }, 163 | { 164 | internalType: "uint48", 165 | name: "validAfter", 166 | type: "uint48", 167 | }, 168 | ], 169 | name: "getHash", 170 | outputs: [ 171 | { 172 | internalType: "bytes32", 173 | name: "", 174 | type: "bytes32", 175 | }, 176 | ], 177 | stateMutability: "view", 178 | type: "function", 179 | }, 180 | { 181 | inputs: [], 182 | name: "owner", 183 | outputs: [ 184 | { 185 | internalType: "address", 186 | name: "", 187 | type: "address", 188 | }, 189 | ], 190 | stateMutability: "view", 191 | type: "function", 192 | }, 193 | { 194 | inputs: [ 195 | { 196 | internalType: "bytes", 197 | name: "paymasterAndData", 198 | type: "bytes", 199 | }, 200 | ], 201 | name: "parsePaymasterAndData", 202 | outputs: [ 203 | { 204 | internalType: "uint48", 205 | name: "validUntil", 206 | type: "uint48", 207 | }, 208 | { 209 | internalType: "uint48", 210 | name: "validAfter", 211 | type: "uint48", 212 | }, 213 | { 214 | internalType: "bytes", 215 | name: "signature", 216 | type: "bytes", 217 | }, 218 | ], 219 | stateMutability: "pure", 220 | type: "function", 221 | }, 222 | { 223 | inputs: [ 224 | { 225 | internalType: "enum IPaymaster.PostOpMode", 226 | name: "mode", 227 | type: "uint8", 228 | }, 229 | { 230 | internalType: "bytes", 231 | name: "context", 232 | type: "bytes", 233 | }, 234 | { 235 | internalType: "uint256", 236 | name: "actualGasCost", 237 | type: "uint256", 238 | }, 239 | ], 240 | name: "postOp", 241 | outputs: [], 242 | stateMutability: "nonpayable", 243 | type: "function", 244 | }, 245 | { 246 | inputs: [], 247 | name: "renounceOwnership", 248 | outputs: [], 249 | stateMutability: "nonpayable", 250 | type: "function", 251 | }, 252 | { 253 | inputs: [ 254 | { 255 | internalType: "address", 256 | name: "", 257 | type: "address", 258 | }, 259 | ], 260 | name: "senderNonce", 261 | outputs: [ 262 | { 263 | internalType: "uint256", 264 | name: "", 265 | type: "uint256", 266 | }, 267 | ], 268 | stateMutability: "view", 269 | type: "function", 270 | }, 271 | { 272 | inputs: [ 273 | { 274 | internalType: "address", 275 | name: "newOwner", 276 | type: "address", 277 | }, 278 | ], 279 | name: "transferOwnership", 280 | outputs: [], 281 | stateMutability: "nonpayable", 282 | type: "function", 283 | }, 284 | { 285 | inputs: [], 286 | name: "unlockStake", 287 | outputs: [], 288 | stateMutability: "nonpayable", 289 | type: "function", 290 | }, 291 | { 292 | inputs: [ 293 | { 294 | components: [ 295 | { 296 | internalType: "address", 297 | name: "sender", 298 | type: "address", 299 | }, 300 | { 301 | internalType: "uint256", 302 | name: "nonce", 303 | type: "uint256", 304 | }, 305 | { 306 | internalType: "bytes", 307 | name: "initCode", 308 | type: "bytes", 309 | }, 310 | { 311 | internalType: "bytes", 312 | name: "callData", 313 | type: "bytes", 314 | }, 315 | { 316 | internalType: "uint256", 317 | name: "callGasLimit", 318 | type: "uint256", 319 | }, 320 | { 321 | internalType: "uint256", 322 | name: "verificationGasLimit", 323 | type: "uint256", 324 | }, 325 | { 326 | internalType: "uint256", 327 | name: "preVerificationGas", 328 | type: "uint256", 329 | }, 330 | { 331 | internalType: "uint256", 332 | name: "maxFeePerGas", 333 | type: "uint256", 334 | }, 335 | { 336 | internalType: "uint256", 337 | name: "maxPriorityFeePerGas", 338 | type: "uint256", 339 | }, 340 | { 341 | internalType: "bytes", 342 | name: "paymasterAndData", 343 | type: "bytes", 344 | }, 345 | { 346 | internalType: "bytes", 347 | name: "signature", 348 | type: "bytes", 349 | }, 350 | ], 351 | internalType: "struct UserOperation", 352 | name: "userOp", 353 | type: "tuple", 354 | }, 355 | { 356 | internalType: "bytes32", 357 | name: "userOpHash", 358 | type: "bytes32", 359 | }, 360 | { 361 | internalType: "uint256", 362 | name: "maxCost", 363 | type: "uint256", 364 | }, 365 | ], 366 | name: "validatePaymasterUserOp", 367 | outputs: [ 368 | { 369 | internalType: "bytes", 370 | name: "context", 371 | type: "bytes", 372 | }, 373 | { 374 | internalType: "uint256", 375 | name: "validationData", 376 | type: "uint256", 377 | }, 378 | ], 379 | stateMutability: "nonpayable", 380 | type: "function", 381 | }, 382 | { 383 | inputs: [], 384 | name: "verifyingSigner", 385 | outputs: [ 386 | { 387 | internalType: "address", 388 | name: "", 389 | type: "address", 390 | }, 391 | ], 392 | stateMutability: "view", 393 | type: "function", 394 | }, 395 | { 396 | inputs: [ 397 | { 398 | internalType: "address payable", 399 | name: "withdrawAddress", 400 | type: "address", 401 | }, 402 | ], 403 | name: "withdrawStake", 404 | outputs: [], 405 | stateMutability: "nonpayable", 406 | type: "function", 407 | }, 408 | { 409 | inputs: [ 410 | { 411 | internalType: "address payable", 412 | name: "withdrawAddress", 413 | type: "address", 414 | }, 415 | { 416 | internalType: "uint256", 417 | name: "amount", 418 | type: "uint256", 419 | }, 420 | ], 421 | name: "withdrawTo", 422 | outputs: [], 423 | stateMutability: "nonpayable", 424 | type: "function", 425 | }, 426 | ] as const; 427 | 428 | const _bytecode = 429 | "0x60c06040523480156200001157600080fd5b5060405162001723380380620017238339810160408190526200003491620000c2565b81620000403362000059565b6001600160a01b039081166080521660a0525062000101565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160a01b0381168114620000bf57600080fd5b50565b60008060408385031215620000d657600080fd5b8251620000e381620000a9565b6020840151909250620000f681620000a9565b809150509250929050565b60805160a0516115c46200015f6000396000818161013f0152610ca20152600081816102880152818161038601528181610450015281816105730152818161063a015281816106ca0152818161077d0152610a0401526115c46000f3fe6080604052600436106100f35760003560e01c8063a9a234091161008a578063c399ec8811610059578063c399ec88146102df578063d0e30db0146102f4578063f2fde38b146102fc578063f465c77e1461031c57600080fd5b8063a9a2340914610256578063b0d691fe14610276578063bb9fe6bf146102aa578063c23a5cea146102bf57600080fd5b80638da5cb5b116100c65780638da5cb5b146101a057806394d4ad60146101cb57806394e1fc19146101fb5780639c90b4431461022957600080fd5b80630396cb60146100f8578063205c28781461010d57806323d9ac9b1461012d578063715018a61461018b575b600080fd5b61010b610106366004611075565b61034a565b005b34801561011957600080fd5b5061010b6101283660046110c4565b6103fc565b34801561013957600080fd5b506101617f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b34801561019757600080fd5b5061010b610494565b3480156101ac57600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610161565b3480156101d757600080fd5b506101eb6101e6366004611132565b6104a8565b6040516101829493929190611174565b34801561020757600080fd5b5061021b610216366004611212565b6104e5565b604051908152602001610182565b34801561023557600080fd5b5061021b610244366004611270565b60016020526000908152604090205481565b34801561026257600080fd5b5061010b61027136600461128d565b61054f565b34801561028257600080fd5b506101617f000000000000000000000000000000000000000000000000000000000000000081565b3480156102b657600080fd5b5061010b610569565b3480156102cb57600080fd5b5061010b6102da366004611270565b6105ed565b3480156102eb57600080fd5b5061021b610699565b61010b61074f565b34801561030857600080fd5b5061010b610317366004611270565b6107d7565b34801561032857600080fd5b5061033c6103373660046112ed565b610893565b6040516101829291906113a6565b6103526108b7565b6040517f0396cb6000000000000000000000000000000000000000000000000000000000815263ffffffff821660048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1690630396cb609034906024016000604051808303818588803b1580156103e057600080fd5b505af11580156103f4573d6000803e3d6000fd5b505050505050565b6104046108b7565b6040517f205c287800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8381166004830152602482018390527f0000000000000000000000000000000000000000000000000000000000000000169063205c287890604401600060405180830381600087803b1580156103e057600080fd5b61049c6108b7565b6104a66000610938565b565b60008036816104bb6054601487896113c8565b8101906104c891906113f2565b90945092506104da85605481896113c8565b949793965094505050565b60006104f0846109ad565b73ffffffffffffffffffffffffffffffffffffffff8535166000908152600160209081526040918290205491516105309392469230928991899101611425565b6040516020818303038152906040528051906020012090509392505050565b6105576109ec565b61056384848484610a8b565b50505050565b6105716108b7565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663bb9fe6bf6040518163ffffffff1660e01b8152600401600060405180830381600087803b1580156105d957600080fd5b505af1158015610563573d6000803e3d6000fd5b6105f56108b7565b6040517fc23a5cea00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82811660048301527f0000000000000000000000000000000000000000000000000000000000000000169063c23a5cea90602401600060405180830381600087803b15801561067e57600080fd5b505af1158015610692573d6000803e3d6000fd5b5050505050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610726573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061074a9190611482565b905090565b6040517fb760faf90000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063b760faf99034906024016000604051808303818588803b15801561067e57600080fd5b6107df6108b7565b73ffffffffffffffffffffffffffffffffffffffff8116610887576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b61089081610938565b50565b6060600061089f6109ec565b6108aa858585610aed565b915091505b935093915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146104a6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161087e565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60603660006109c061012085018561149b565b915091508360208184030360405194506020810185016040528085528082602087013750505050919050565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146104a6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f53656e646572206e6f7420456e747279506f696e740000000000000000000000604482015260640161087e565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f6d757374206f7665727269646500000000000000000000000000000000000000604482015260640161087e565b6060600080803681610b066101e66101208b018b61149b565b929650909450925090506040811480610b1f5750604181145b610bad57604080517f08c379a00000000000000000000000000000000000000000000000000000000081526020600482015260248101919091527f566572696679696e675061796d61737465723a20696e76616c6964207369676e60448201527f6174757265206c656e67746820696e207061796d6173746572416e6444617461606482015260840161087e565b6000610c10610bbd8b87876104e5565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b73ffffffffffffffffffffffffffffffffffffffff8b35166000908152600160205260408120805492935090610c4583611500565b9190505550610c8a8184848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610d3292505050565b73ffffffffffffffffffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1614610d0757610ce860018686610d56565b60405180602001604052806000815250909650965050505050506108af565b610d1360008686610d56565b6040805160208101909152600081529b909a5098505050505050505050565b6000806000610d418585610d8e565b91509150610d4e81610dd3565b509392505050565b600060d08265ffffffffffff16901b60a08465ffffffffffff16901b85610d7e576000610d81565b60015b60ff161717949350505050565b6000808251604103610dc45760208301516040840151606085015160001a610db887828585610f86565b94509450505050610dcc565b506000905060025b9250929050565b6000816004811115610de757610de761155f565b03610def5750565b6001816004811115610e0357610e0361155f565b03610e6a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f45434453413a20696e76616c6964207369676e61747572650000000000000000604482015260640161087e565b6002816004811115610e7e57610e7e61155f565b03610ee5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e67746800604482015260640161087e565b6003816004811115610ef957610ef961155f565b03610890576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f7565000000000000000000000000000000000000000000000000000000000000606482015260840161087e565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115610fbd575060009050600361106c565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015611011573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166110655760006001925092505061106c565b9150600090505b94509492505050565b60006020828403121561108757600080fd5b813563ffffffff8116811461109b57600080fd5b9392505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461089057600080fd5b600080604083850312156110d757600080fd5b82356110e2816110a2565b946020939093013593505050565b60008083601f84011261110257600080fd5b50813567ffffffffffffffff81111561111a57600080fd5b602083019150836020828501011115610dcc57600080fd5b6000806020838503121561114557600080fd5b823567ffffffffffffffff81111561115c57600080fd5b611168858286016110f0565b90969095509350505050565b600065ffffffffffff8087168352808616602084015250606060408301528260608301528284608084013760006080848401015260807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f850116830101905095945050505050565b600061016082840312156111f157600080fd5b50919050565b803565ffffffffffff8116811461120d57600080fd5b919050565b60008060006060848603121561122757600080fd5b833567ffffffffffffffff81111561123e57600080fd5b61124a868287016111de565b935050611259602085016111f7565b9150611267604085016111f7565b90509250925092565b60006020828403121561128257600080fd5b813561109b816110a2565b600080600080606085870312156112a357600080fd5b8435600381106112b257600080fd5b9350602085013567ffffffffffffffff8111156112ce57600080fd5b6112da878288016110f0565b9598909750949560400135949350505050565b60008060006060848603121561130257600080fd5b833567ffffffffffffffff81111561131957600080fd5b611325868287016111de565b9660208601359650604090950135949350505050565b6000815180845260005b8181101561136157602081850181015186830182015201611345565b81811115611373576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6040815260006113b9604083018561133b565b90508260208301529392505050565b600080858511156113d857600080fd5b838611156113e557600080fd5b5050820193919092039150565b6000806040838503121561140557600080fd5b61140e836111f7565b915061141c602084016111f7565b90509250929050565b60c08152600061143860c083018961133b565b60208301979097525073ffffffffffffffffffffffffffffffffffffffff949094166040850152606084019290925265ffffffffffff90811660808401521660a090910152919050565b60006020828403121561149457600080fd5b5051919050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126114d057600080fd5b83018035915067ffffffffffffffff8211156114eb57600080fd5b602001915036819003821315610dcc57600080fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611558577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fdfea26469706673582212201f0be91b92179d101ae4aa96dcbd313210e5b62f1b15c18338e0acb937cb466a64736f6c634300080f0033"; 430 | 431 | type VerifyingPaymasterConstructorParams = 432 | | [signer?: Signer] 433 | | ConstructorParameters; 434 | 435 | const isSuperArgs = ( 436 | xs: VerifyingPaymasterConstructorParams 437 | ): xs is ConstructorParameters => xs.length > 1; 438 | 439 | export class VerifyingPaymaster__factory extends ContractFactory { 440 | constructor(...args: VerifyingPaymasterConstructorParams) { 441 | if (isSuperArgs(args)) { 442 | super(...args); 443 | } else { 444 | super(_abi, _bytecode, args[0]); 445 | } 446 | } 447 | 448 | override deploy( 449 | _entryPoint: PromiseOrValue, 450 | _verifyingSigner: PromiseOrValue, 451 | overrides?: Overrides & { from?: PromiseOrValue } 452 | ): Promise { 453 | return super.deploy( 454 | _entryPoint, 455 | _verifyingSigner, 456 | overrides || {} 457 | ) as Promise; 458 | } 459 | override getDeployTransaction( 460 | _entryPoint: PromiseOrValue, 461 | _verifyingSigner: PromiseOrValue, 462 | overrides?: Overrides & { from?: PromiseOrValue } 463 | ): TransactionRequest { 464 | return super.getDeployTransaction( 465 | _entryPoint, 466 | _verifyingSigner, 467 | overrides || {} 468 | ); 469 | } 470 | override attach(address: string): VerifyingPaymaster { 471 | return super.attach(address) as VerifyingPaymaster; 472 | } 473 | override connect(signer: Signer): VerifyingPaymaster__factory { 474 | return super.connect(signer) as VerifyingPaymaster__factory; 475 | } 476 | 477 | static readonly bytecode = _bytecode; 478 | static readonly abi = _abi; 479 | static createInterface(): VerifyingPaymasterInterface { 480 | return new utils.Interface(_abi) as VerifyingPaymasterInterface; 481 | } 482 | static connect( 483 | address: string, 484 | signerOrProvider: Signer | Provider 485 | ): VerifyingPaymaster { 486 | return new Contract(address, _abi, signerOrProvider) as VerifyingPaymaster; 487 | } 488 | } 489 | -------------------------------------------------------------------------------- /SimpleAccount__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; 5 | import type { Provider, TransactionRequest } from "@ethersproject/providers"; 6 | import type { PromiseOrValue } from "../common"; 7 | import type { SimpleAccount, SimpleAccountInterface } from "../SimpleAccount"; 8 | 9 | const _abi = [ 10 | { 11 | inputs: [ 12 | { 13 | internalType: "contract IEntryPoint", 14 | name: "anEntryPoint", 15 | type: "address", 16 | }, 17 | ], 18 | stateMutability: "nonpayable", 19 | type: "constructor", 20 | }, 21 | { 22 | anonymous: false, 23 | inputs: [ 24 | { 25 | indexed: false, 26 | internalType: "address", 27 | name: "previousAdmin", 28 | type: "address", 29 | }, 30 | { 31 | indexed: false, 32 | internalType: "address", 33 | name: "newAdmin", 34 | type: "address", 35 | }, 36 | ], 37 | name: "AdminChanged", 38 | type: "event", 39 | }, 40 | { 41 | anonymous: false, 42 | inputs: [ 43 | { 44 | indexed: true, 45 | internalType: "address", 46 | name: "beacon", 47 | type: "address", 48 | }, 49 | ], 50 | name: "BeaconUpgraded", 51 | type: "event", 52 | }, 53 | { 54 | anonymous: false, 55 | inputs: [ 56 | { 57 | indexed: false, 58 | internalType: "uint8", 59 | name: "version", 60 | type: "uint8", 61 | }, 62 | ], 63 | name: "Initialized", 64 | type: "event", 65 | }, 66 | { 67 | anonymous: false, 68 | inputs: [ 69 | { 70 | indexed: true, 71 | internalType: "contract IEntryPoint", 72 | name: "entryPoint", 73 | type: "address", 74 | }, 75 | { 76 | indexed: true, 77 | internalType: "address", 78 | name: "owner", 79 | type: "address", 80 | }, 81 | ], 82 | name: "SimpleAccountInitialized", 83 | type: "event", 84 | }, 85 | { 86 | anonymous: false, 87 | inputs: [ 88 | { 89 | indexed: true, 90 | internalType: "address", 91 | name: "implementation", 92 | type: "address", 93 | }, 94 | ], 95 | name: "Upgraded", 96 | type: "event", 97 | }, 98 | { 99 | inputs: [], 100 | name: "addDeposit", 101 | outputs: [], 102 | stateMutability: "payable", 103 | type: "function", 104 | }, 105 | { 106 | inputs: [], 107 | name: "entryPoint", 108 | outputs: [ 109 | { 110 | internalType: "contract IEntryPoint", 111 | name: "", 112 | type: "address", 113 | }, 114 | ], 115 | stateMutability: "view", 116 | type: "function", 117 | }, 118 | { 119 | inputs: [ 120 | { 121 | internalType: "address", 122 | name: "dest", 123 | type: "address", 124 | }, 125 | { 126 | internalType: "uint256", 127 | name: "value", 128 | type: "uint256", 129 | }, 130 | { 131 | internalType: "bytes", 132 | name: "func", 133 | type: "bytes", 134 | }, 135 | ], 136 | name: "execute", 137 | outputs: [], 138 | stateMutability: "nonpayable", 139 | type: "function", 140 | }, 141 | { 142 | inputs: [ 143 | { 144 | internalType: "address[]", 145 | name: "dest", 146 | type: "address[]", 147 | }, 148 | { 149 | internalType: "bytes[]", 150 | name: "func", 151 | type: "bytes[]", 152 | }, 153 | ], 154 | name: "executeBatch", 155 | outputs: [], 156 | stateMutability: "nonpayable", 157 | type: "function", 158 | }, 159 | { 160 | inputs: [], 161 | name: "getDeposit", 162 | outputs: [ 163 | { 164 | internalType: "uint256", 165 | name: "", 166 | type: "uint256", 167 | }, 168 | ], 169 | stateMutability: "view", 170 | type: "function", 171 | }, 172 | { 173 | inputs: [ 174 | { 175 | internalType: "address", 176 | name: "anOwner", 177 | type: "address", 178 | }, 179 | ], 180 | name: "initialize", 181 | outputs: [], 182 | stateMutability: "nonpayable", 183 | type: "function", 184 | }, 185 | { 186 | inputs: [], 187 | name: "nonce", 188 | outputs: [ 189 | { 190 | internalType: "uint256", 191 | name: "", 192 | type: "uint256", 193 | }, 194 | ], 195 | stateMutability: "view", 196 | type: "function", 197 | }, 198 | { 199 | inputs: [], 200 | name: "owner", 201 | outputs: [ 202 | { 203 | internalType: "address", 204 | name: "", 205 | type: "address", 206 | }, 207 | ], 208 | stateMutability: "view", 209 | type: "function", 210 | }, 211 | { 212 | inputs: [], 213 | name: "proxiableUUID", 214 | outputs: [ 215 | { 216 | internalType: "bytes32", 217 | name: "", 218 | type: "bytes32", 219 | }, 220 | ], 221 | stateMutability: "view", 222 | type: "function", 223 | }, 224 | { 225 | inputs: [ 226 | { 227 | internalType: "address", 228 | name: "newImplementation", 229 | type: "address", 230 | }, 231 | ], 232 | name: "upgradeTo", 233 | outputs: [], 234 | stateMutability: "nonpayable", 235 | type: "function", 236 | }, 237 | { 238 | inputs: [ 239 | { 240 | internalType: "address", 241 | name: "newImplementation", 242 | type: "address", 243 | }, 244 | { 245 | internalType: "bytes", 246 | name: "data", 247 | type: "bytes", 248 | }, 249 | ], 250 | name: "upgradeToAndCall", 251 | outputs: [], 252 | stateMutability: "payable", 253 | type: "function", 254 | }, 255 | { 256 | inputs: [ 257 | { 258 | components: [ 259 | { 260 | internalType: "address", 261 | name: "sender", 262 | type: "address", 263 | }, 264 | { 265 | internalType: "uint256", 266 | name: "nonce", 267 | type: "uint256", 268 | }, 269 | { 270 | internalType: "bytes", 271 | name: "initCode", 272 | type: "bytes", 273 | }, 274 | { 275 | internalType: "bytes", 276 | name: "callData", 277 | type: "bytes", 278 | }, 279 | { 280 | internalType: "uint256", 281 | name: "callGasLimit", 282 | type: "uint256", 283 | }, 284 | { 285 | internalType: "uint256", 286 | name: "verificationGasLimit", 287 | type: "uint256", 288 | }, 289 | { 290 | internalType: "uint256", 291 | name: "preVerificationGas", 292 | type: "uint256", 293 | }, 294 | { 295 | internalType: "uint256", 296 | name: "maxFeePerGas", 297 | type: "uint256", 298 | }, 299 | { 300 | internalType: "uint256", 301 | name: "maxPriorityFeePerGas", 302 | type: "uint256", 303 | }, 304 | { 305 | internalType: "bytes", 306 | name: "paymasterAndData", 307 | type: "bytes", 308 | }, 309 | { 310 | internalType: "bytes", 311 | name: "signature", 312 | type: "bytes", 313 | }, 314 | ], 315 | internalType: "struct UserOperation", 316 | name: "userOp", 317 | type: "tuple", 318 | }, 319 | { 320 | internalType: "bytes32", 321 | name: "userOpHash", 322 | type: "bytes32", 323 | }, 324 | { 325 | internalType: "uint256", 326 | name: "missingAccountFunds", 327 | type: "uint256", 328 | }, 329 | ], 330 | name: "validateUserOp", 331 | outputs: [ 332 | { 333 | internalType: "uint256", 334 | name: "validationData", 335 | type: "uint256", 336 | }, 337 | ], 338 | stateMutability: "nonpayable", 339 | type: "function", 340 | }, 341 | { 342 | inputs: [ 343 | { 344 | internalType: "address payable", 345 | name: "withdrawAddress", 346 | type: "address", 347 | }, 348 | { 349 | internalType: "uint256", 350 | name: "amount", 351 | type: "uint256", 352 | }, 353 | ], 354 | name: "withdrawDepositTo", 355 | outputs: [], 356 | stateMutability: "nonpayable", 357 | type: "function", 358 | }, 359 | { 360 | stateMutability: "payable", 361 | type: "receive", 362 | }, 363 | ] as const; 364 | 365 | const _bytecode = 366 | "0x60c03461015a57601f62001ed338819003918201601f19168301916001600160401b0383118484101761015f5780849260209460405283398101031261015a57516001600160a01b038116810361015a573060805260a05260005460ff8160081c166101055760ff808216106100ca575b604051611d5d908162000176823960805181818161032601528181610a460152610c23015260a051818181610548015281816107180152818161080101528181610dcf01528181610ef20152818161187301526118d10152f35b60ff90811916176000557f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498602060405160ff8152a138610070565b60405162461bcd60e51b815260206004820152602760248201527f496e697469616c697a61626c653a20636f6e747261637420697320696e697469604482015266616c697a696e6760c81b6064820152608490fd5b600080fd5b634e487b7160e01b600052604160045260246000fdfe6080604052600436101561001b575b361561001957600080fd5b005b60003560e01c806318dfb3c71461011f5780633659cfe6146101165780633a871cdd1461010d5780634a58db19146101045780634d44560d146100fb5780634f1ef286146100f257806352d1902d146100e95780638da5cb5b146100e0578063affed0e0146100d7578063b0d691fe146100ce578063b61d27f6146100c5578063c399ec88146100bc5763c4d66de80361000e576100b7610f75565b61000e565b506100b7610e78565b506100b7610df3565b506100b7610d83565b506100b7610d38565b506100b7610cf8565b506100b7610bdc565b506100b76109c4565b506100b76107a2565b506100b76106d5565b506100b76104dd565b506100b76102d1565b506100b761015e565b9181601f840112156101595782359167ffffffffffffffff8311610159576020808501948460051b01011161015957565b600080fd5b50346101595760407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126101595767ffffffffffffffff600435818111610159576101af903690600401610128565b9091602435908111610159576101c9903690600401610128565b91906101d36118ba565b8282036102555760005b8281106101e657005b8061021a6101ff6101fa600194878a61173f565b61175d565b61021461020d848988611767565b369161098d565b90611c93565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610248575b016101dd565b6102506116df565b610242565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f77726f6e67206172726179206c656e67746873000000000000000000000000006044820152fd5b73ffffffffffffffffffffffffffffffffffffffff81160361015957565b50346101595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126101595760043561030d816102b3565b73ffffffffffffffffffffffffffffffffffffffff90817f00000000000000000000000000000000000000000000000000000000000000001691610353833014156110d9565b6103827f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc938285541614611164565b61038a611caa565b60405190610397826108cb565b600082527f4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd91435460ff16156103d15750506100199150611296565b6020600491604094939451928380927f52d1902d00000000000000000000000000000000000000000000000000000000825286165afa600091816104ad575b5061049a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f45524331393637557067726164653a206e657720696d706c656d656e7461746960448201527f6f6e206973206e6f7420555550530000000000000000000000000000000000006064820152608490fd5b610019936104a8911461120b565b611382565b6104cf91925060203d81116104d6575b6104c78183610903565b8101906111ef565b9038610410565b503d6104bd565b5034610159577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc6060813601126101595760043567ffffffffffffffff811161015957610160816004019282360301126101595773ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001633036106775761058861057d6024358461196d565b926044830190611620565b9050156105b3575b6105af8261059f604435611671565b6040519081529081906020820190565b0390f35b6024600154916bffffffffffffffffffffffff927fffffffffffffffffffffffffffffffffffffffff0000000000000000000000008482169480861461066a575b600186011691161760015501350361060c5738610590565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f6163636f756e743a20696e76616c6964206e6f6e6365000000000000000000006044820152fd5b6106726116df565b6105f4565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f6163636f756e743a206e6f742066726f6d20456e747279506f696e74000000006044820152fd5b506000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261079f5773ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001681813b1561079f57602491604051928380927fb760faf900000000000000000000000000000000000000000000000000000000825230600483015234905af18015610792575b610786575080f35b61078f906108aa565b80f35b61079a6111fe565b61077e565b80fd5b503461015957600060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261079f576004356107e0816102b3565b6107e8611caa565b8173ffffffffffffffffffffffffffffffffffffffff807f00000000000000000000000000000000000000000000000000000000000000001692833b15610876576044908360405195869485937f205c287800000000000000000000000000000000000000000000000000000000855216600484015260243560248401525af1801561079257610786575080f35b8280fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b67ffffffffffffffff81116108be57604052565b6108c661087a565b604052565b6020810190811067ffffffffffffffff8211176108be57604052565b6060810190811067ffffffffffffffff8211176108be57604052565b90601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0910116810190811067ffffffffffffffff8211176108be57604052565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f60209267ffffffffffffffff8111610980575b01160190565b61098861087a565b61097a565b92919261099982610944565b916109a76040519384610903565b829481845281830111610159578281602093846000960137010152565b5060407ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc360112610159576004356109fb816102b3565b60243567ffffffffffffffff8111610159573660238201121561015957610a2c90369060248160040135910161098d565b9073ffffffffffffffffffffffffffffffffffffffff91827f00000000000000000000000000000000000000000000000000000000000000001692610a73843014156110d9565b610aa27f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc948286541614611164565b610aaa611caa565b7f4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd91435460ff1615610ae05750506100199150611296565b6020600491604094939451928380927f52d1902d00000000000000000000000000000000000000000000000000000000825286165afa60009181610bbc575b50610ba9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f45524331393637557067726164653a206e657720696d706c656d656e7461746960448201527f6f6e206973206e6f7420555550530000000000000000000000000000000000006064820152608490fd5b61001993610bb7911461120b565b611461565b610bd591925060203d81116104d6576104c78183610903565b9038610b1f565b50346101595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126101595773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000163003610c74576040517f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc8152602090f35b60846040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603860248201527f555550535570677261646561626c653a206d757374206e6f742062652063616c60448201527f6c6564207468726f7567682064656c656761746563616c6c00000000000000006064820152fd5b50346101595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261015957602060015460601c604051908152f35b50346101595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc3601126101595760206bffffffffffffffffffffffff60015416604051908152f35b50346101595760007ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261015957602060405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b50346101595760607ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261015957600435610e2f816102b3565b6044359067ffffffffffffffff908183116101595736602384011215610159578260040135918211610159573660248385010111610159576024610019930190602435906116ab565b5034610159576000807ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261079f576040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260208160248173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000165afa908115610f68575b8291610f2e575b604051828152602090f35b90506020813d8211610f60575b81610f4860209383610903565b81010312610f5c576105af91505138610f23565b5080fd5b3d9150610f3b565b610f706111fe565b610f1c565b50346101595760207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc36011261015957600435610fb1816102b3565b61101360005491610fd960ff8460081c1615809481956110cb575b81156110ab575b50611791565b8261100a60017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff006000541617600055565b6110755761181c565b61101957005b6110467fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff60005416600055565b604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb384740249890602090a1005b6110a66101007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff6000541617600055565b61181c565b303b159150816110bd575b5038610fd3565b6001915060ff1614386110b6565b600160ff8216109150610fcc565b156110e057565b60846040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f64656c656761746563616c6c00000000000000000000000000000000000000006064820152fd5b1561116b57565b60846040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f6163746976652070726f787900000000000000000000000000000000000000006064820152fd5b90816020910312610159575190565b506040513d6000823e3d90fd5b1561121257565b60846040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602960248201527f45524331393637557067726164653a20756e737570706f727465642070726f7860448201527f6961626c655555494400000000000000000000000000000000000000000000006064820152fd5b803b156112fe5773ffffffffffffffffffffffffffffffffffffffff7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc91167fffffffffffffffffffffffff0000000000000000000000000000000000000000825416179055565b60846040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201527f6f74206120636f6e7472616374000000000000000000000000000000000000006064820152fd5b9061138c82611296565b73ffffffffffffffffffffffffffffffffffffffff82167fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b600080a2805115801590611459575b6113db575050565b61145691600080604051936113ef856108e7565b602785527f416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c60208601527f206661696c6564000000000000000000000000000000000000000000000000006040860152602081519101845af46114506114c1565b91611556565b50565b5060006113d3565b9061146b82611296565b73ffffffffffffffffffffffffffffffffffffffff82167fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b600080a28051158015906114b9576113db575050565b5060016113d3565b3d156114ec573d906114d282610944565b916114e06040519384610903565b82523d6000602084013e565b606090565b156114f857565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152fd5b91929015611579575081511561156a575090565b611576903b15156114f1565b90565b82519091501561158c5750805190602001fd5b604051907f08c379a000000000000000000000000000000000000000000000000000000000825281602080600483015282519283602484015260005b848110611609575050507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f836000604480968601015201168101030190fd5b8181018301518682016044015285935082016115c8565b9035907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe181360301821215610159570180359067ffffffffffffffff82116101595760200191813603831361015957565b806116795750565b600080808093337ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1506114566114c1565b6116bc60009493859461020d6118ba565b91602083519301915af16116ce6114c1565b90156116d75750565b602081519101fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b507f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b9190811015611750575b60051b0190565b61175861170f565b611749565b35611576816102b3565b909161178092811015611784575b60051b810190611620565b9091565b61178c61170f565b611775565b1561179857565b60846040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152fd5b6bffffffffffffffffffffffff7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000006001549260601b169116178060015560601c73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000167f47e55c76e7a6f1fd8996a1da8008c1ea29699cca35e7bcd057f2dec313b6e5de600080a3565b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000163314801561195f575b1561190157565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602060248201527f6163636f756e743a206e6f74204f776e6572206f7220456e747279506f696e746044820152fd5b5060015460601c33146118fa565b906119f06119e873ffffffffffffffffffffffffffffffffffffffff9260405160208101917f19457468657265756d205369676e6564204d6573736167653a0a3332000000008352603c820152603c81526119c7816108e7565b5190206119e261020d60015460601c96610140810190611620565b90611bc2565b919091611a39565b16036119fb57600090565b600190565b60051115611a0a57565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b611a4281611a00565b80611a4a5750565b611a5381611a00565b60018103611aba576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606490fd5b611ac381611a00565b60028103611b2a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606490fd5b80611b36600392611a00565b14611b3d57565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f75650000000000000000000000000000000000000000000000000000000000006064820152608490fd5b906041815114600014611bec57611780916020820151906060604084015193015160001a90611bf6565b5050600090600290565b9291907f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311611c875791608094939160ff602094604051948552168484015260408301526060820152600093849182805260015afa15611c7a575b815173ffffffffffffffffffffffffffffffffffffffff811615611c74579190565b50600190565b611c826111fe565b611c52565b50505050600090600390565b600091829182602083519301915af16116ce6114c1565b60015460601c33148015611d1e575b15611cc057565b60646040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6f6e6c79206f776e6572000000000000000000000000000000000000000000006044820152fd5b50303314611cb956fea2646970667358221220593fa2403beef0636f4ff38625c8e0f27859145384a308b0a9f2e56754fd82f664736f6c63430008110033"; 367 | 368 | type SimpleAccountConstructorParams = 369 | | [signer?: Signer] 370 | | ConstructorParameters; 371 | 372 | const isSuperArgs = ( 373 | xs: SimpleAccountConstructorParams 374 | ): xs is ConstructorParameters => xs.length > 1; 375 | 376 | export class SimpleAccount__factory extends ContractFactory { 377 | constructor(...args: SimpleAccountConstructorParams) { 378 | if (isSuperArgs(args)) { 379 | super(...args); 380 | } else { 381 | super(_abi, _bytecode, args[0]); 382 | } 383 | } 384 | 385 | override deploy( 386 | anEntryPoint: PromiseOrValue, 387 | overrides?: Overrides & { from?: PromiseOrValue } 388 | ): Promise { 389 | return super.deploy( 390 | anEntryPoint, 391 | overrides || {} 392 | ) as Promise; 393 | } 394 | override getDeployTransaction( 395 | anEntryPoint: PromiseOrValue, 396 | overrides?: Overrides & { from?: PromiseOrValue } 397 | ): TransactionRequest { 398 | return super.getDeployTransaction(anEntryPoint, overrides || {}); 399 | } 400 | override attach(address: string): SimpleAccount { 401 | return super.attach(address) as SimpleAccount; 402 | } 403 | override connect(signer: Signer): SimpleAccount__factory { 404 | return super.connect(signer) as SimpleAccount__factory; 405 | } 406 | 407 | static readonly bytecode = _bytecode; 408 | static readonly abi = _abi; 409 | static createInterface(): SimpleAccountInterface { 410 | return new utils.Interface(_abi) as SimpleAccountInterface; 411 | } 412 | static connect( 413 | address: string, 414 | signerOrProvider: Signer | Provider 415 | ): SimpleAccount { 416 | return new Contract(address, _abi, signerOrProvider) as SimpleAccount; 417 | } 418 | } 419 | -------------------------------------------------------------------------------- /SimpleAccountFactory__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; 5 | import type { Provider, TransactionRequest } from "@ethersproject/providers"; 6 | import type { PromiseOrValue } from "../common"; 7 | import type { 8 | SimpleAccountFactory, 9 | SimpleAccountFactoryInterface, 10 | } from "../SimpleAccountFactory"; 11 | 12 | const _abi = [ 13 | { 14 | inputs: [ 15 | { 16 | internalType: "contract IEntryPoint", 17 | name: "_entryPoint", 18 | type: "address", 19 | }, 20 | ], 21 | stateMutability: "nonpayable", 22 | type: "constructor", 23 | }, 24 | { 25 | inputs: [], 26 | name: "accountImplementation", 27 | outputs: [ 28 | { 29 | internalType: "contract SimpleAccount", 30 | name: "", 31 | type: "address", 32 | }, 33 | ], 34 | stateMutability: "view", 35 | type: "function", 36 | }, 37 | { 38 | inputs: [ 39 | { 40 | internalType: "address", 41 | name: "owner", 42 | type: "address", 43 | }, 44 | { 45 | internalType: "uint256", 46 | name: "salt", 47 | type: "uint256", 48 | }, 49 | ], 50 | name: "createAccount", 51 | outputs: [ 52 | { 53 | internalType: "contract SimpleAccount", 54 | name: "ret", 55 | type: "address", 56 | }, 57 | ], 58 | stateMutability: "nonpayable", 59 | type: "function", 60 | }, 61 | { 62 | inputs: [ 63 | { 64 | internalType: "address", 65 | name: "owner", 66 | type: "address", 67 | }, 68 | { 69 | internalType: "uint256", 70 | name: "salt", 71 | type: "uint256", 72 | }, 73 | ], 74 | name: "getAddress", 75 | outputs: [ 76 | { 77 | internalType: "address", 78 | name: "", 79 | type: "address", 80 | }, 81 | ], 82 | stateMutability: "view", 83 | type: "function", 84 | }, 85 | ] as const; 86 | 87 | const _bytecode = 88 | "0x60a060405234801561001057600080fd5b50604051612f0f380380612f0f83398101604081905261002f91610088565b8060405161003c9061007b565b6001600160a01b039091168152602001604051809103906000f080158015610068573d6000803e3d6000fd5b506001600160a01b0316608052506100b8565b61218980610d8683390190565b60006020828403121561009a57600080fd5b81516001600160a01b03811681146100b157600080fd5b9392505050565b608051610ca66100e060003960008181604b0152818161011401526102580152610ca66000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806311464fbe146100465780635fbfb9cf146100965780638cb84e18146100a9575b600080fd5b61006d7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b61006d6100a436600461039d565b6100bc565b61006d6100b736600461039d565b6101ee565b6000806100c984846101ee565b905073ffffffffffffffffffffffffffffffffffffffff81163b80156100f1575090506101e8565b60405173ffffffffffffffffffffffffffffffffffffffff8616602482015284907f000000000000000000000000000000000000000000000000000000000000000090604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fc4d66de800000000000000000000000000000000000000000000000000000000179052516101b790610390565b6101c2929190610412565b8190604051809103906000f59050801580156101e2573d6000803e3d6000fd5b50925050505b92915050565b60006103578260001b6040518060200161020790610390565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082820381018352601f90910116604081905273ffffffffffffffffffffffffffffffffffffffff871660248201527f000000000000000000000000000000000000000000000000000000000000000090604401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fc4d66de800000000000000000000000000000000000000000000000000000000179052905161030093929101610412565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261033c9291602001610480565b6040516020818303038152906040528051906020012061035e565b9392505050565b60006103578383306000604051836040820152846020820152828152600b8101905060ff815360559020949350505050565b6107c1806104b083390190565b600080604083850312156103b057600080fd5b823573ffffffffffffffffffffffffffffffffffffffff811681146103d457600080fd5b946020939093013593505050565b60005b838110156103fd5781810151838201526020016103e5565b8381111561040c576000848401525b50505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000825180604084015261044d8160608501602087016103e2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016060019392505050565b600083516104928184602088016103e2565b8351908301906104a68183602088016103e2565b0194935050505056fe60806040526040516107c13803806107c183398101604081905261002291610321565b61002e82826000610035565b505061043e565b61003e8361006b565b60008251118061004b5750805b156100665761006483836100ab60201b6100291760201c565b505b505050565b610074816100d7565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b60606100d0838360405180606001604052806027815260200161079a602791396101a9565b9392505050565b6100ea8161022260201b6100551760201c565b6101515760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b60648201526084015b60405180910390fd5b806101887f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc60001b61023160201b6100711760201c565b80546001600160a01b0319166001600160a01b039290921691909117905550565b6060600080856001600160a01b0316856040516101c691906103ef565b600060405180830381855af49150503d8060008114610201576040519150601f19603f3d011682016040523d82523d6000602084013e610206565b606091505b50909250905061021886838387610234565b9695505050505050565b6001600160a01b03163b151590565b90565b606083156102a357825160000361029c576001600160a01b0385163b61029c5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610148565b50816102ad565b6102ad83836102b5565b949350505050565b8151156102c55781518083602001fd5b8060405162461bcd60e51b8152600401610148919061040b565b634e487b7160e01b600052604160045260246000fd5b60005b838110156103105781810151838201526020016102f8565b838111156100645750506000910152565b6000806040838503121561033457600080fd5b82516001600160a01b038116811461034b57600080fd5b60208401519092506001600160401b038082111561036857600080fd5b818501915085601f83011261037c57600080fd5b81518181111561038e5761038e6102df565b604051601f8201601f19908116603f011681019083821181831017156103b6576103b66102df565b816040528281528860208487010111156103cf57600080fd5b6103e08360208301602088016102f5565b80955050505050509250929050565b600082516104018184602087016102f5565b9190910192915050565b602081526000825180602084015261042a8160408501602087016102f5565b601f01601f19169190910160400192915050565b61034d8061044d6000396000f3fe60806040523661001357610011610017565b005b6100115b610027610022610074565b6100b9565b565b606061004e83836040518060600160405280602781526020016102f1602791396100dd565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff163b151590565b90565b60006100b47f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5473ffffffffffffffffffffffffffffffffffffffff1690565b905090565b3660008037600080366000845af43d6000803e8080156100d8573d6000f35b3d6000fd5b60606000808573ffffffffffffffffffffffffffffffffffffffff16856040516101079190610283565b600060405180830381855af49150503d8060008114610142576040519150601f19603f3d011682016040523d82523d6000602084013e610147565b606091505b509150915061015886838387610162565b9695505050505050565b606083156101fd5782516000036101f65773ffffffffffffffffffffffffffffffffffffffff85163b6101f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064015b60405180910390fd5b5081610207565b610207838361020f565b949350505050565b81511561021f5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101ed919061029f565b60005b8381101561026e578181015183820152602001610256565b8381111561027d576000848401525b50505050565b60008251610295818460208701610253565b9190910192915050565b60208152600082518060208401526102be816040850160208701610253565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a26469706673582212201cd78ab6a31213989661cff2d7d05fc9b9c38b1a848e8249e2e398659a9eb7e364736f6c634300080f0033416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a264697066735822122030a4cd3aed4a6d9ec37ebc1d87061b12ed9906b5ba9c82d2d00395cabba20fbd64736f6c634300080f003360c0604052306080523480156200001557600080fd5b506040516200218938038062002189833981016040819052620000389162000118565b6001600160a01b03811660a0526200004f62000056565b506200014a565b600054610100900460ff1615620000c35760405162461bcd60e51b815260206004820152602760248201527f496e697469616c697a61626c653a20636f6e747261637420697320696e697469604482015266616c697a696e6760c81b606482015260840160405180910390fd5b60005460ff908116101562000116576000805460ff191660ff9081179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b565b6000602082840312156200012b57600080fd5b81516001600160a01b03811681146200014357600080fd5b9392505050565b60805160a051611fd3620001b66000396000818161023b01528181610624015281816106cb01528181610aad01528181610d0c0152818161106801526113fc0152600081816103ef0152818161049f0152818161078f0152818161083f01526109880152611fd36000f3fe6080604052600436106100d65760003560e01c806352d1902d1161007f578063b0d691fe11610059578063b0d691fe1461022c578063b61d27f61461025f578063c399ec881461027f578063c4d66de81461029457600080fd5b806352d1902d146101925780638da5cb5b146101a7578063affed0e01461020957600080fd5b80634a58db19116100b05780634a58db19146101575780634d44560d1461015f5780634f1ef2861461017f57600080fd5b806318dfb3c7146100e25780633659cfe6146101045780633a871cdd1461012457600080fd5b366100dd57005b600080fd5b3480156100ee57600080fd5b506101026100fd366004611aaa565b6102b4565b005b34801561011057600080fd5b5061010261011f366004611b38565b6103d8565b34801561013057600080fd5b5061014461013f366004611b55565b6105dd565b6040519081526020015b60405180910390f35b610102610622565b34801561016b57600080fd5b5061010261017a366004611ba9565b6106c1565b61010261018d366004611c04565b610778565b34801561019e57600080fd5b5061014461096e565b3480156101b357600080fd5b506001546101e4906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161014e565b34801561021557600080fd5b506001546bffffffffffffffffffffffff16610144565b34801561023857600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006101e4565b34801561026b57600080fd5b5061010261027a366004611ce6565b610a5a565b34801561028b57600080fd5b50610144610aa9565b3480156102a057600080fd5b506101026102af366004611b38565b610b61565b6102bc610cf4565b82811461032a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f77726f6e67206172726179206c656e677468730000000000000000000000000060448201526064015b60405180910390fd5b60005b838110156103d1576103bf85858381811061034a5761034a611d6f565b905060200201602081019061035f9190611b38565b600085858581811061037357610373611d6f565b90506020028101906103859190611d9e565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610dc792505050565b806103c981611e32565b91505061032d565b5050505050565b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016300361049d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f64656c656761746563616c6c00000000000000000000000000000000000000006064820152608401610321565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166105127f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff16146105b5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f6163746976652070726f787900000000000000000000000000000000000000006064820152608401610321565b6105be81610e44565b604080516000808252602082019092526105da91839190610e4c565b50565b60006105e7611050565b6105f184846110ef565b90506106006040850185611d9e565b905060000361061257610612846111e1565b61061b826112aa565b9392505050565b7f00000000000000000000000000000000000000000000000000000000000000006040517fb760faf900000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff919091169063b760faf99034906024016000604051808303818588803b1580156106ad57600080fd5b505af11580156103d1573d6000803e3d6000fd5b6106c9611315565b7f00000000000000000000000000000000000000000000000000000000000000006040517f205c287800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff848116600483015260248201849052919091169063205c287890604401600060405180830381600087803b15801561075c57600080fd5b505af1158015610770573d6000803e3d6000fd5b505050505050565b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016300361083d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f64656c656761746563616c6c00000000000000000000000000000000000000006064820152608401610321565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166108b27f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff1614610955576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f46756e6374696f6e206d7573742062652063616c6c6564207468726f7567682060448201527f6163746976652070726f787900000000000000000000000000000000000000006064820152608401610321565b61095e82610e44565b61096a82826001610e4c565b5050565b60003073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610a35576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603860248201527f555550535570677261646561626c653a206d757374206e6f742062652063616c60448201527f6c6564207468726f7567682064656c656761746563616c6c00000000000000006064820152608401610321565b507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc90565b610a62610cf4565b610aa3848484848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610dc792505050565b50505050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff91909116906370a0823190602401602060405180830381865afa158015610b38573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b5c9190611e6a565b905090565b600054610100900460ff1615808015610b815750600054600160ff909116105b80610b9b5750303b158015610b9b575060005460ff166001145b610c27576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610321565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790558015610c8557600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b610c8e826113b0565b801561096a57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161480610d5f57506001546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633145b610dc5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f6163636f756e743a206e6f74204f776e6572206f7220456e747279506f696e746044820152606401610321565b565b6000808473ffffffffffffffffffffffffffffffffffffffff168484604051610df09190611eaf565b60006040518083038185875af1925050503d8060008114610e2d576040519150601f19603f3d011682016040523d82523d6000602084013e610e32565b606091505b5091509150816103d157805160208201fd5b6105da611315565b7f4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd91435460ff1615610e8457610e7f83611448565b505050565b8273ffffffffffffffffffffffffffffffffffffffff166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa925050508015610f09575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201909252610f0691810190611e6a565b60015b610f95576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f45524331393637557067726164653a206e657720696d706c656d656e7461746960448201527f6f6e206973206e6f7420555550530000000000000000000000000000000000006064820152608401610321565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc8114611044576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602960248201527f45524331393637557067726164653a20756e737570706f727465642070726f7860448201527f6961626c655555494400000000000000000000000000000000000000000000006064820152608401610321565b50610e7f838383611552565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610dc5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f6163636f756e743a206e6f742066726f6d20456e747279506f696e74000000006044820152606401610321565b600080611149836040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b905061119961115c610140860186611d9e565b8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506115779050565b6001546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff9081169116146111d55760019150506111db565b60009150505b92915050565b600180546020830135916bffffffffffffffffffffffff90911690600061120783611ecb565b91906101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506bffffffffffffffffffffffff16146105da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f6163636f756e743a20696e76616c6964206e6f6e6365000000000000000000006044820152606401610321565b80156105da5760405160009033907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90849084818181858888f193505050503d80600081146103d1576040519150601f19603f3d011682016040523d82523d6000602084013e6103d1565b6001546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633148061134a57503330145b610dc5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6f6e6c79206f776e6572000000000000000000000000000000000000000000006044820152606401610321565b600180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8481168202929092179283905560405192048116917f0000000000000000000000000000000000000000000000000000000000000000909116907f47e55c76e7a6f1fd8996a1da8008c1ea29699cca35e7bcd057f2dec313b6e5de90600090a350565b73ffffffffffffffffffffffffffffffffffffffff81163b6114ec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201527f6f74206120636f6e7472616374000000000000000000000000000000000000006064820152608401610321565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b61155b8361159b565b6000825111806115685750805b15610e7f57610aa383836115e8565b6000806000611586858561160d565b9150915061159381611652565b509392505050565b6115a481611448565b60405173ffffffffffffffffffffffffffffffffffffffff8216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b606061061b8383604051806060016040528060278152602001611f7760279139611805565b60008082516041036116435760208301516040840151606085015160001a6116378782858561188a565b9450945050505061164b565b506000905060025b9250929050565b600081600481111561166657611666611ef6565b0361166e5750565b600181600481111561168257611682611ef6565b036116e9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610321565b60028160048111156116fd576116fd611ef6565b03611764576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610321565b600381600481111561177857611778611ef6565b036105da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f75650000000000000000000000000000000000000000000000000000000000006064820152608401610321565b60606000808573ffffffffffffffffffffffffffffffffffffffff168560405161182f9190611eaf565b600060405180830381855af49150503d806000811461186a576040519150601f19603f3d011682016040523d82523d6000602084013e61186f565b606091505b509150915061188086838387611979565b9695505050505050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311156118c15750600090506003611970565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015611915573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff811661196957600060019250925050611970565b9150600090505b94509492505050565b60608315611a0f578251600003611a085773ffffffffffffffffffffffffffffffffffffffff85163b611a08576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610321565b5081611a19565b611a198383611a21565b949350505050565b815115611a315781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103219190611f25565b60008083601f840112611a7757600080fd5b50813567ffffffffffffffff811115611a8f57600080fd5b6020830191508360208260051b850101111561164b57600080fd5b60008060008060408587031215611ac057600080fd5b843567ffffffffffffffff80821115611ad857600080fd5b611ae488838901611a65565b90965094506020870135915080821115611afd57600080fd5b50611b0a87828801611a65565b95989497509550505050565b73ffffffffffffffffffffffffffffffffffffffff811681146105da57600080fd5b600060208284031215611b4a57600080fd5b813561061b81611b16565b600080600060608486031215611b6a57600080fd5b833567ffffffffffffffff811115611b8157600080fd5b84016101608187031215611b9457600080fd5b95602085013595506040909401359392505050565b60008060408385031215611bbc57600080fd5b8235611bc781611b16565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008060408385031215611c1757600080fd5b8235611c2281611b16565b9150602083013567ffffffffffffffff80821115611c3f57600080fd5b818501915085601f830112611c5357600080fd5b813581811115611c6557611c65611bd5565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715611cab57611cab611bd5565b81604052828152886020848701011115611cc457600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b60008060008060608587031215611cfc57600080fd5b8435611d0781611b16565b935060208501359250604085013567ffffffffffffffff80821115611d2b57600080fd5b818701915087601f830112611d3f57600080fd5b813581811115611d4e57600080fd5b886020828501011115611d6057600080fd5b95989497505060200194505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112611dd357600080fd5b83018035915067ffffffffffffffff821115611dee57600080fd5b60200191503681900382131561164b57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611e6357611e63611e03565b5060010190565b600060208284031215611e7c57600080fd5b5051919050565b60005b83811015611e9e578181015183820152602001611e86565b83811115610aa35750506000910152565b60008251611ec1818460208701611e83565b9190910192915050565b60006bffffffffffffffffffffffff808316818103611eec57611eec611e03565b6001019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020815260008251806020840152611f44816040850160208701611e83565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016919091016040019291505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220fd4b8799a91c8d4b8c5386672729ac9615b60b5f5b7dbac6da122be87a2a90b164736f6c634300080f0033"; 89 | 90 | type SimpleAccountFactoryConstructorParams = 91 | | [signer?: Signer] 92 | | ConstructorParameters; 93 | 94 | const isSuperArgs = ( 95 | xs: SimpleAccountFactoryConstructorParams 96 | ): xs is ConstructorParameters => xs.length > 1; 97 | 98 | export class SimpleAccountFactory__factory extends ContractFactory { 99 | constructor(...args: SimpleAccountFactoryConstructorParams) { 100 | if (isSuperArgs(args)) { 101 | super(...args); 102 | } else { 103 | super(_abi, _bytecode, args[0]); 104 | } 105 | } 106 | 107 | override deploy( 108 | _entryPoint: PromiseOrValue, 109 | overrides?: Overrides & { from?: PromiseOrValue } 110 | ): Promise { 111 | return super.deploy( 112 | _entryPoint, 113 | overrides || {} 114 | ) as Promise; 115 | } 116 | override getDeployTransaction( 117 | _entryPoint: PromiseOrValue, 118 | overrides?: Overrides & { from?: PromiseOrValue } 119 | ): TransactionRequest { 120 | return super.getDeployTransaction(_entryPoint, overrides || {}); 121 | } 122 | override attach(address: string): SimpleAccountFactory { 123 | return super.attach(address) as SimpleAccountFactory; 124 | } 125 | override connect(signer: Signer): SimpleAccountFactory__factory { 126 | return super.connect(signer) as SimpleAccountFactory__factory; 127 | } 128 | 129 | static readonly bytecode = _bytecode; 130 | static readonly abi = _abi; 131 | static createInterface(): SimpleAccountFactoryInterface { 132 | return new utils.Interface(_abi) as SimpleAccountFactoryInterface; 133 | } 134 | static connect( 135 | address: string, 136 | signerOrProvider: Signer | Provider 137 | ): SimpleAccountFactory { 138 | return new Contract( 139 | address, 140 | _abi, 141 | signerOrProvider 142 | ) as SimpleAccountFactory; 143 | } 144 | } 145 | -------------------------------------------------------------------------------- /TokenPaymaster__factory.ts: -------------------------------------------------------------------------------- 1 | /* Autogenerated file. Do not edit manually. */ 2 | /* tslint:disable */ 3 | /* eslint-disable */ 4 | import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; 5 | import type { Provider, TransactionRequest } from "@ethersproject/providers"; 6 | import type { PromiseOrValue } from "../common"; 7 | import type { 8 | TokenPaymaster, 9 | TokenPaymasterInterface, 10 | } from "../TokenPaymaster"; 11 | 12 | const _abi = [ 13 | { 14 | inputs: [ 15 | { 16 | internalType: "address", 17 | name: "accountFactory", 18 | type: "address", 19 | }, 20 | { 21 | internalType: "string", 22 | name: "_symbol", 23 | type: "string", 24 | }, 25 | { 26 | internalType: "contract IEntryPoint", 27 | name: "_entryPoint", 28 | type: "address", 29 | }, 30 | ], 31 | stateMutability: "nonpayable", 32 | type: "constructor", 33 | }, 34 | { 35 | anonymous: false, 36 | inputs: [ 37 | { 38 | indexed: true, 39 | internalType: "address", 40 | name: "owner", 41 | type: "address", 42 | }, 43 | { 44 | indexed: true, 45 | internalType: "address", 46 | name: "spender", 47 | type: "address", 48 | }, 49 | { 50 | indexed: false, 51 | internalType: "uint256", 52 | name: "value", 53 | type: "uint256", 54 | }, 55 | ], 56 | name: "Approval", 57 | type: "event", 58 | }, 59 | { 60 | anonymous: false, 61 | inputs: [ 62 | { 63 | indexed: true, 64 | internalType: "address", 65 | name: "previousOwner", 66 | type: "address", 67 | }, 68 | { 69 | indexed: true, 70 | internalType: "address", 71 | name: "newOwner", 72 | type: "address", 73 | }, 74 | ], 75 | name: "OwnershipTransferred", 76 | type: "event", 77 | }, 78 | { 79 | anonymous: false, 80 | inputs: [ 81 | { 82 | indexed: true, 83 | internalType: "address", 84 | name: "from", 85 | type: "address", 86 | }, 87 | { 88 | indexed: true, 89 | internalType: "address", 90 | name: "to", 91 | type: "address", 92 | }, 93 | { 94 | indexed: false, 95 | internalType: "uint256", 96 | name: "value", 97 | type: "uint256", 98 | }, 99 | ], 100 | name: "Transfer", 101 | type: "event", 102 | }, 103 | { 104 | inputs: [], 105 | name: "COST_OF_POST", 106 | outputs: [ 107 | { 108 | internalType: "uint256", 109 | name: "", 110 | type: "uint256", 111 | }, 112 | ], 113 | stateMutability: "view", 114 | type: "function", 115 | }, 116 | { 117 | inputs: [ 118 | { 119 | internalType: "uint32", 120 | name: "unstakeDelaySec", 121 | type: "uint32", 122 | }, 123 | ], 124 | name: "addStake", 125 | outputs: [], 126 | stateMutability: "payable", 127 | type: "function", 128 | }, 129 | { 130 | inputs: [ 131 | { 132 | internalType: "address", 133 | name: "owner", 134 | type: "address", 135 | }, 136 | { 137 | internalType: "address", 138 | name: "spender", 139 | type: "address", 140 | }, 141 | ], 142 | name: "allowance", 143 | outputs: [ 144 | { 145 | internalType: "uint256", 146 | name: "", 147 | type: "uint256", 148 | }, 149 | ], 150 | stateMutability: "view", 151 | type: "function", 152 | }, 153 | { 154 | inputs: [ 155 | { 156 | internalType: "address", 157 | name: "spender", 158 | type: "address", 159 | }, 160 | { 161 | internalType: "uint256", 162 | name: "amount", 163 | type: "uint256", 164 | }, 165 | ], 166 | name: "approve", 167 | outputs: [ 168 | { 169 | internalType: "bool", 170 | name: "", 171 | type: "bool", 172 | }, 173 | ], 174 | stateMutability: "nonpayable", 175 | type: "function", 176 | }, 177 | { 178 | inputs: [ 179 | { 180 | internalType: "address", 181 | name: "account", 182 | type: "address", 183 | }, 184 | ], 185 | name: "balanceOf", 186 | outputs: [ 187 | { 188 | internalType: "uint256", 189 | name: "", 190 | type: "uint256", 191 | }, 192 | ], 193 | stateMutability: "view", 194 | type: "function", 195 | }, 196 | { 197 | inputs: [], 198 | name: "decimals", 199 | outputs: [ 200 | { 201 | internalType: "uint8", 202 | name: "", 203 | type: "uint8", 204 | }, 205 | ], 206 | stateMutability: "view", 207 | type: "function", 208 | }, 209 | { 210 | inputs: [ 211 | { 212 | internalType: "address", 213 | name: "spender", 214 | type: "address", 215 | }, 216 | { 217 | internalType: "uint256", 218 | name: "subtractedValue", 219 | type: "uint256", 220 | }, 221 | ], 222 | name: "decreaseAllowance", 223 | outputs: [ 224 | { 225 | internalType: "bool", 226 | name: "", 227 | type: "bool", 228 | }, 229 | ], 230 | stateMutability: "nonpayable", 231 | type: "function", 232 | }, 233 | { 234 | inputs: [], 235 | name: "deposit", 236 | outputs: [], 237 | stateMutability: "payable", 238 | type: "function", 239 | }, 240 | { 241 | inputs: [], 242 | name: "entryPoint", 243 | outputs: [ 244 | { 245 | internalType: "contract IEntryPoint", 246 | name: "", 247 | type: "address", 248 | }, 249 | ], 250 | stateMutability: "view", 251 | type: "function", 252 | }, 253 | { 254 | inputs: [], 255 | name: "getDeposit", 256 | outputs: [ 257 | { 258 | internalType: "uint256", 259 | name: "", 260 | type: "uint256", 261 | }, 262 | ], 263 | stateMutability: "view", 264 | type: "function", 265 | }, 266 | { 267 | inputs: [ 268 | { 269 | internalType: "address", 270 | name: "spender", 271 | type: "address", 272 | }, 273 | { 274 | internalType: "uint256", 275 | name: "addedValue", 276 | type: "uint256", 277 | }, 278 | ], 279 | name: "increaseAllowance", 280 | outputs: [ 281 | { 282 | internalType: "bool", 283 | name: "", 284 | type: "bool", 285 | }, 286 | ], 287 | stateMutability: "nonpayable", 288 | type: "function", 289 | }, 290 | { 291 | inputs: [ 292 | { 293 | internalType: "address", 294 | name: "recipient", 295 | type: "address", 296 | }, 297 | { 298 | internalType: "uint256", 299 | name: "amount", 300 | type: "uint256", 301 | }, 302 | ], 303 | name: "mintTokens", 304 | outputs: [], 305 | stateMutability: "nonpayable", 306 | type: "function", 307 | }, 308 | { 309 | inputs: [], 310 | name: "name", 311 | outputs: [ 312 | { 313 | internalType: "string", 314 | name: "", 315 | type: "string", 316 | }, 317 | ], 318 | stateMutability: "view", 319 | type: "function", 320 | }, 321 | { 322 | inputs: [], 323 | name: "owner", 324 | outputs: [ 325 | { 326 | internalType: "address", 327 | name: "", 328 | type: "address", 329 | }, 330 | ], 331 | stateMutability: "view", 332 | type: "function", 333 | }, 334 | { 335 | inputs: [ 336 | { 337 | internalType: "enum IPaymaster.PostOpMode", 338 | name: "mode", 339 | type: "uint8", 340 | }, 341 | { 342 | internalType: "bytes", 343 | name: "context", 344 | type: "bytes", 345 | }, 346 | { 347 | internalType: "uint256", 348 | name: "actualGasCost", 349 | type: "uint256", 350 | }, 351 | ], 352 | name: "postOp", 353 | outputs: [], 354 | stateMutability: "nonpayable", 355 | type: "function", 356 | }, 357 | { 358 | inputs: [], 359 | name: "renounceOwnership", 360 | outputs: [], 361 | stateMutability: "nonpayable", 362 | type: "function", 363 | }, 364 | { 365 | inputs: [], 366 | name: "symbol", 367 | outputs: [ 368 | { 369 | internalType: "string", 370 | name: "", 371 | type: "string", 372 | }, 373 | ], 374 | stateMutability: "view", 375 | type: "function", 376 | }, 377 | { 378 | inputs: [], 379 | name: "theFactory", 380 | outputs: [ 381 | { 382 | internalType: "address", 383 | name: "", 384 | type: "address", 385 | }, 386 | ], 387 | stateMutability: "view", 388 | type: "function", 389 | }, 390 | { 391 | inputs: [], 392 | name: "totalSupply", 393 | outputs: [ 394 | { 395 | internalType: "uint256", 396 | name: "", 397 | type: "uint256", 398 | }, 399 | ], 400 | stateMutability: "view", 401 | type: "function", 402 | }, 403 | { 404 | inputs: [ 405 | { 406 | internalType: "address", 407 | name: "to", 408 | type: "address", 409 | }, 410 | { 411 | internalType: "uint256", 412 | name: "amount", 413 | type: "uint256", 414 | }, 415 | ], 416 | name: "transfer", 417 | outputs: [ 418 | { 419 | internalType: "bool", 420 | name: "", 421 | type: "bool", 422 | }, 423 | ], 424 | stateMutability: "nonpayable", 425 | type: "function", 426 | }, 427 | { 428 | inputs: [ 429 | { 430 | internalType: "address", 431 | name: "from", 432 | type: "address", 433 | }, 434 | { 435 | internalType: "address", 436 | name: "to", 437 | type: "address", 438 | }, 439 | { 440 | internalType: "uint256", 441 | name: "amount", 442 | type: "uint256", 443 | }, 444 | ], 445 | name: "transferFrom", 446 | outputs: [ 447 | { 448 | internalType: "bool", 449 | name: "", 450 | type: "bool", 451 | }, 452 | ], 453 | stateMutability: "nonpayable", 454 | type: "function", 455 | }, 456 | { 457 | inputs: [ 458 | { 459 | internalType: "address", 460 | name: "newOwner", 461 | type: "address", 462 | }, 463 | ], 464 | name: "transferOwnership", 465 | outputs: [], 466 | stateMutability: "nonpayable", 467 | type: "function", 468 | }, 469 | { 470 | inputs: [], 471 | name: "unlockStake", 472 | outputs: [], 473 | stateMutability: "nonpayable", 474 | type: "function", 475 | }, 476 | { 477 | inputs: [ 478 | { 479 | components: [ 480 | { 481 | internalType: "address", 482 | name: "sender", 483 | type: "address", 484 | }, 485 | { 486 | internalType: "uint256", 487 | name: "nonce", 488 | type: "uint256", 489 | }, 490 | { 491 | internalType: "bytes", 492 | name: "initCode", 493 | type: "bytes", 494 | }, 495 | { 496 | internalType: "bytes", 497 | name: "callData", 498 | type: "bytes", 499 | }, 500 | { 501 | internalType: "uint256", 502 | name: "callGasLimit", 503 | type: "uint256", 504 | }, 505 | { 506 | internalType: "uint256", 507 | name: "verificationGasLimit", 508 | type: "uint256", 509 | }, 510 | { 511 | internalType: "uint256", 512 | name: "preVerificationGas", 513 | type: "uint256", 514 | }, 515 | { 516 | internalType: "uint256", 517 | name: "maxFeePerGas", 518 | type: "uint256", 519 | }, 520 | { 521 | internalType: "uint256", 522 | name: "maxPriorityFeePerGas", 523 | type: "uint256", 524 | }, 525 | { 526 | internalType: "bytes", 527 | name: "paymasterAndData", 528 | type: "bytes", 529 | }, 530 | { 531 | internalType: "bytes", 532 | name: "signature", 533 | type: "bytes", 534 | }, 535 | ], 536 | internalType: "struct UserOperation", 537 | name: "userOp", 538 | type: "tuple", 539 | }, 540 | { 541 | internalType: "bytes32", 542 | name: "userOpHash", 543 | type: "bytes32", 544 | }, 545 | { 546 | internalType: "uint256", 547 | name: "maxCost", 548 | type: "uint256", 549 | }, 550 | ], 551 | name: "validatePaymasterUserOp", 552 | outputs: [ 553 | { 554 | internalType: "bytes", 555 | name: "context", 556 | type: "bytes", 557 | }, 558 | { 559 | internalType: "uint256", 560 | name: "validationData", 561 | type: "uint256", 562 | }, 563 | ], 564 | stateMutability: "nonpayable", 565 | type: "function", 566 | }, 567 | { 568 | inputs: [ 569 | { 570 | internalType: "address payable", 571 | name: "withdrawAddress", 572 | type: "address", 573 | }, 574 | ], 575 | name: "withdrawStake", 576 | outputs: [], 577 | stateMutability: "nonpayable", 578 | type: "function", 579 | }, 580 | { 581 | inputs: [ 582 | { 583 | internalType: "address payable", 584 | name: "withdrawAddress", 585 | type: "address", 586 | }, 587 | { 588 | internalType: "uint256", 589 | name: "amount", 590 | type: "uint256", 591 | }, 592 | ], 593 | name: "withdrawTo", 594 | outputs: [], 595 | stateMutability: "nonpayable", 596 | type: "function", 597 | }, 598 | ] as const; 599 | 600 | const _bytecode = 601 | "0x60c06040523480156200001157600080fd5b506040516200224438038062002244833981016040819052620000349162000327565b8180826200004233620000a0565b6001600160a01b031660805260046200005c8382620004bc565b5060056200006b8282620004bc565b5050506001600160a01b03831660a05262000088306001620000f0565b620000973033600019620001b9565b505050620005af565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160a01b0382166200014c5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064015b60405180910390fd5b806003600082825462000160919062000588565b90915550506001600160a01b0382166000818152600160209081526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a35050565b6001600160a01b0383166200021d5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b606482015260840162000143565b6001600160a01b038216620002805760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b606482015260840162000143565b6001600160a01b0383811660008181526002602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b505050565b6001600160a01b0381168114620002fc57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b80516200032281620002e6565b919050565b6000806000606084860312156200033d57600080fd5b83516200034a81620002e6565b602085810151919450906001600160401b03808211156200036a57600080fd5b818701915087601f8301126200037f57600080fd5b815181811115620003945762000394620002ff565b604051601f8201601f19908116603f01168101908382118183101715620003bf57620003bf620002ff565b816040528281528a86848701011115620003d857600080fd5b600093505b82841015620003fc5784840186015181850187015292850192620003dd565b828411156200040e5760008684830101525b809750505050505050620004256040850162000315565b90509250925092565b600181811c908216806200044357607f821691505b6020821081036200046457634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002e157600081815260208120601f850160051c81016020861015620004935750805b601f850160051c820191505b81811015620004b4578281556001016200049f565b505050505050565b81516001600160401b03811115620004d857620004d8620002ff565b620004f081620004e984546200042e565b846200046a565b602080601f8311600181146200052857600084156200050f5750858301515b600019600386901b1c1916600185901b178555620004b4565b600085815260208120601f198616915b82811015620005595788860151825594840194600190910190840162000538565b5085821015620005785787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008219821115620005aa57634e487b7160e01b600052601160045260246000fd5b500190565b60805160a051611c376200060d6000396000818161039201526116fa015260008181610426015281816105970152818161070b015281816108ea015281816109b101528181610a4101528181610af401526111f80152611c376000f3fe6080604052600436106101a15760003560e01c80639f5ca221116100e1578063c23a5cea1161008a578063dd62ed3e11610064578063dd62ed3e1461049a578063f0dda65c146104ed578063f2fde38b1461050d578063f465c77e1461052d57600080fd5b8063c23a5cea1461045d578063c399ec881461047d578063d0e30db01461049257600080fd5b8063a9a23409116100bb578063a9a23409146103f4578063b0d691fe14610414578063bb9fe6bf1461044857600080fd5b80639f5ca22114610380578063a457c2d7146103b4578063a9059cbb146103d457600080fd5b8063313ce5671161014e578063715018a611610128578063715018a6146102f4578063796d4371146103095780638da5cb5b1461031f57806395d89b411461036b57600080fd5b8063313ce56714610275578063395093511461029157806370a08231146102b157600080fd5b806318160ddd1161017f57806318160ddd14610216578063205c28781461023557806323b872dd1461025557600080fd5b80630396cb60146101a657806306fdde03146101bb578063095ea7b3146101e6575b600080fd5b6101b96101b43660046117a8565b61055b565b005b3480156101c757600080fd5b506101d061060d565b6040516101dd9190611840565b60405180910390f35b3480156101f257600080fd5b50610206610201366004611875565b61069f565b60405190151581526020016101dd565b34801561022257600080fd5b506003545b6040519081526020016101dd565b34801561024157600080fd5b506101b9610250366004611875565b6106b7565b34801561026157600080fd5b506102066102703660046118a1565b61074f565b34801561028157600080fd5b50604051601281526020016101dd565b34801561029d57600080fd5b506102066102ac366004611875565b610773565b3480156102bd57600080fd5b506102276102cc3660046118e2565b73ffffffffffffffffffffffffffffffffffffffff1660009081526001602052604090205490565b34801561030057600080fd5b506101b96107bf565b34801561031557600080fd5b50610227613a9881565b34801561032b57600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101dd565b34801561037757600080fd5b506101d06107d3565b34801561038c57600080fd5b506103467f000000000000000000000000000000000000000000000000000000000000000081565b3480156103c057600080fd5b506102066103cf366004611875565b6107e2565b3480156103e057600080fd5b506102066103ef366004611875565b6108b8565b34801561040057600080fd5b506101b961040f3660046118ff565b6108c6565b34801561042057600080fd5b506103467f000000000000000000000000000000000000000000000000000000000000000081565b34801561045457600080fd5b506101b96108e0565b34801561046957600080fd5b506101b96104783660046118e2565b610964565b34801561048957600080fd5b50610227610a10565b6101b9610ac6565b3480156104a657600080fd5b506102276104b536600461198e565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260026020908152604080832093909416825291909152205490565b3480156104f957600080fd5b506101b9610508366004611875565b610b4e565b34801561051957600080fd5b506101b96105283660046118e2565b610b64565b34801561053957600080fd5b5061054d6105483660046119c7565b610bcd565b6040516101dd929190611a1b565b610563610bf0565b6040517f0396cb6000000000000000000000000000000000000000000000000000000000815263ffffffff821660048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1690630396cb609034906024016000604051808303818588803b1580156105f157600080fd5b505af1158015610605573d6000803e3d6000fd5b505050505050565b60606004805461061c90611a3d565b80601f016020809104026020016040519081016040528092919081815260200182805461064890611a3d565b80156106955780601f1061066a57610100808354040283529160200191610695565b820191906000526020600020905b81548152906001019060200180831161067857829003601f168201915b5050505050905090565b6000336106ad818585610c71565b5060019392505050565b6106bf610bf0565b6040517f205c287800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8381166004830152602482018390527f0000000000000000000000000000000000000000000000000000000000000000169063205c287890604401600060405180830381600087803b1580156105f157600080fd5b60003361075d858285610e24565b610768858585610ef5565b506001949350505050565b33600081815260026020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906106ad90829086906107ba908790611a90565b610c71565b6107c7610bf0565b6107d1600061116b565b565b60606005805461061c90611a3d565b33600081815260026020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452909152812054909190838110156108ab576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f00000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b6107688286868403610c71565b6000336106ad818585610ef5565b6108ce6111e0565b6108da8484848461127f565b50505050565b6108e8610bf0565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663bb9fe6bf6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561095057600080fd5b505af11580156108da573d6000803e3d6000fd5b61096c610bf0565b6040517fc23a5cea00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82811660048301527f0000000000000000000000000000000000000000000000000000000000000000169063c23a5cea90602401600060405180830381600087803b1580156109f557600080fd5b505af1158015610a09573d6000803e3d6000fd5b5050505050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610a9d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ac19190611acf565b905090565b6040517fb760faf90000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063b760faf99034906024016000604051808303818588803b1580156109f557600080fd5b610b56610bf0565b610b6082826112b2565b5050565b610b6c610bf0565b610b9630610b8f60005473ffffffffffffffffffffffffffffffffffffffff1690565b6000610c71565b610b9f816113a7565b610bca30827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff610c71565b50565b60606000610bd96111e0565b610be485858561145b565b91509150935093915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146107d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016108a2565b73ffffffffffffffffffffffffffffffffffffffff8316610d13576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016108a2565b73ffffffffffffffffffffffffffffffffffffffff8216610db6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f737300000000000000000000000000000000000000000000000000000000000060648201526084016108a2565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526002602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600260209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146108da5781811015610ee8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016108a2565b6108da8484848403610c71565b73ffffffffffffffffffffffffffffffffffffffff8316610f98576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016108a2565b73ffffffffffffffffffffffffffffffffffffffff821661103b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f657373000000000000000000000000000000000000000000000000000000000060648201526084016108a2565b73ffffffffffffffffffffffffffffffffffffffff8316600090815260016020526040902054818110156110f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e6365000000000000000000000000000000000000000000000000000060648201526084016108a2565b73ffffffffffffffffffffffffffffffffffffffff80851660008181526001602052604080822086860390559286168082529083902080548601905591517fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9061115e9086815260200190565b60405180910390a36108da565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146107d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f53656e646572206e6f7420456e747279506f696e74000000000000000000000060448201526064016108a2565b600061128d838501856118e2565b905060006112a56112a0613a9885611a90565b6116a4565b9050610605823083610ef5565b73ffffffffffffffffffffffffffffffffffffffff821661132f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016108a2565b80600360008282546113419190611a90565b909155505073ffffffffffffffffffffffffffffffffffffffff82166000818152600160209081526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a35050565b6113af610bf0565b73ffffffffffffffffffffffffffffffffffffffff8116611452576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016108a2565b610bca8161116b565b6060600080611469846116a4565b9050613a988660a0013511611500576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f546f6b656e5061796d61737465723a2067617320746f6f206c6f7720666f722060448201527f706f73744f70000000000000000000000000000000000000000000000000000060648201526084016108a2565b61150d6040870187611ae8565b1590506115c15761151d866116b7565b8061152e6102cc60208901896118e2565b10156115bc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602760248201527f546f6b656e5061796d61737465723a206e6f2062616c616e636520287072652d60448201527f637265617465290000000000000000000000000000000000000000000000000060648201526084016108a2565b61163a565b806115d26102cc60208901896118e2565b101561163a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f546f6b656e5061796d61737465723a206e6f2062616c616e636500000000000060448201526064016108a2565b61164760208701876118e2565b6040805173ffffffffffffffffffffffffffffffffffffffff909216602083015201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190529660009650945050505050565b60006116b1606483611b54565b92915050565b60006116c66040830183611ae8565b6116d591601491600091611b8f565b6116de91611bb9565b60601c905073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168114610b60576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f546f6b656e5061796d61737465723a2077726f6e67206163636f756e7420666160448201527f63746f727900000000000000000000000000000000000000000000000000000060648201526084016108a2565b6000602082840312156117ba57600080fd5b813563ffffffff811681146117ce57600080fd5b9392505050565b6000815180845260005b818110156117fb576020818501810151868301820152016117df565b8181111561180d576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117ce60208301846117d5565b73ffffffffffffffffffffffffffffffffffffffff81168114610bca57600080fd5b6000806040838503121561188857600080fd5b823561189381611853565b946020939093013593505050565b6000806000606084860312156118b657600080fd5b83356118c181611853565b925060208401356118d181611853565b929592945050506040919091013590565b6000602082840312156118f457600080fd5b81356117ce81611853565b6000806000806060858703121561191557600080fd5b84356003811061192457600080fd5b9350602085013567ffffffffffffffff8082111561194157600080fd5b818701915087601f83011261195557600080fd5b81358181111561196457600080fd5b88602082850101111561197657600080fd5b95986020929092019750949560400135945092505050565b600080604083850312156119a157600080fd5b82356119ac81611853565b915060208301356119bc81611853565b809150509250929050565b6000806000606084860312156119dc57600080fd5b833567ffffffffffffffff8111156119f357600080fd5b84016101608187031215611a0657600080fd5b95602085013595506040909401359392505050565b604081526000611a2e60408301856117d5565b90508260208301529392505050565b600181811c90821680611a5157607f821691505b602082108103611a8a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008219821115611aca577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b600060208284031215611ae157600080fd5b5051919050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112611b1d57600080fd5b83018035915067ffffffffffffffff821115611b3857600080fd5b602001915036819003821315611b4d57600080fd5b9250929050565b600082611b8a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b60008085851115611b9f57600080fd5b83861115611bac57600080fd5b5050820193919092039150565b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000008135818116916014851015611bf95780818660140360031b1b83161692505b50509291505056fea2646970667358221220a332863119321216e5189708c2880dbc64e46a1707c0f292f429daa2c9a7ea3764736f6c634300080f0033"; 602 | 603 | type TokenPaymasterConstructorParams = 604 | | [signer?: Signer] 605 | | ConstructorParameters; 606 | 607 | const isSuperArgs = ( 608 | xs: TokenPaymasterConstructorParams 609 | ): xs is ConstructorParameters => xs.length > 1; 610 | 611 | export class TokenPaymaster__factory extends ContractFactory { 612 | constructor(...args: TokenPaymasterConstructorParams) { 613 | if (isSuperArgs(args)) { 614 | super(...args); 615 | } else { 616 | super(_abi, _bytecode, args[0]); 617 | } 618 | } 619 | 620 | override deploy( 621 | accountFactory: PromiseOrValue, 622 | _symbol: PromiseOrValue, 623 | _entryPoint: PromiseOrValue, 624 | overrides?: Overrides & { from?: PromiseOrValue } 625 | ): Promise { 626 | return super.deploy( 627 | accountFactory, 628 | _symbol, 629 | _entryPoint, 630 | overrides || {} 631 | ) as Promise; 632 | } 633 | override getDeployTransaction( 634 | accountFactory: PromiseOrValue, 635 | _symbol: PromiseOrValue, 636 | _entryPoint: PromiseOrValue, 637 | overrides?: Overrides & { from?: PromiseOrValue } 638 | ): TransactionRequest { 639 | return super.getDeployTransaction( 640 | accountFactory, 641 | _symbol, 642 | _entryPoint, 643 | overrides || {} 644 | ); 645 | } 646 | override attach(address: string): TokenPaymaster { 647 | return super.attach(address) as TokenPaymaster; 648 | } 649 | override connect(signer: Signer): TokenPaymaster__factory { 650 | return super.connect(signer) as TokenPaymaster__factory; 651 | } 652 | 653 | static readonly bytecode = _bytecode; 654 | static readonly abi = _abi; 655 | static createInterface(): TokenPaymasterInterface { 656 | return new utils.Interface(_abi) as TokenPaymasterInterface; 657 | } 658 | static connect( 659 | address: string, 660 | signerOrProvider: Signer | Provider 661 | ): TokenPaymaster { 662 | return new Contract(address, _abi, signerOrProvider) as TokenPaymaster; 663 | } 664 | } 665 | --------------------------------------------------------------------------------