diff --git a/packages-ts/starknet-gauntlet-ocr2/src/commands/proxy/disableAccessCheck.ts b/packages-ts/starknet-gauntlet-ocr2/src/commands/proxy/disableAccessCheck.ts new file mode 100644 index 00000000..36eaeaf3 --- /dev/null +++ b/packages-ts/starknet-gauntlet-ocr2/src/commands/proxy/disableAccessCheck.ts @@ -0,0 +1,32 @@ +import { ExecuteCommandConfig, makeExecuteCommand } from '@chainlink/starknet-gauntlet' +import { CATEGORIES } from '../../lib/categories' +import { ocr2ProxyLoader, CONTRACT_LIST } from '../../lib/contracts' + +type UserInput = {} + +type ContractInput = [] + +const makeUserInput = async (flags, args, env): Promise => { + if (flags.input) return flags.input as UserInput + return {} +} + +const makeContractInput = async (input: UserInput): Promise => { + return [] +} + +const commandConfig: ExecuteCommandConfig = { + contractId: CONTRACT_LIST.PROXY, + category: CATEGORIES.PROXY, + action: 'disable_access_check', + ux: { + description: 'Disable access check at aggregator proxy', + examples: [`${CATEGORIES.PROXY}:disable_access_check --network= `], + }, + makeUserInput, + makeContractInput, + validations: [], + loadContract: ocr2ProxyLoader, +} + +export default makeExecuteCommand(commandConfig) diff --git a/packages-ts/starknet-gauntlet-ocr2/src/commands/proxy/index.ts b/packages-ts/starknet-gauntlet-ocr2/src/commands/proxy/index.ts index 89fe2959..60b5fe19 100644 --- a/packages-ts/starknet-gauntlet-ocr2/src/commands/proxy/index.ts +++ b/packages-ts/starknet-gauntlet-ocr2/src/commands/proxy/index.ts @@ -6,6 +6,7 @@ import ProposeAggregator from './proposeAggregator' import ConfirmAggregator from './confirmAggregator' import TransferOwnership from './transferOwnership' import AcceptOwnership from './acceptOwnership' +import DisableAccessCheck from './disableAccessCheck' export const executeCommands = [ Deploy, @@ -15,5 +16,6 @@ export const executeCommands = [ ConfirmAggregator, TransferOwnership, AcceptOwnership, + DisableAccessCheck, ] export const inspectionCommands = [Inspect]