def __init__(self, pomidor): self.pomidor = pomidor Form.__init__(self, r"""BUTTON YES* NONE BUTTON NO NONE BUTTON CANCEL NONE IDA Pomidor {FormChangeCb} {imgPomidor} <Pomidor:{iButtonPomidor}> <Short Break:{iButtonShortBreak}> <Long Break:{iButtonLongBreak}> {strTime} <Pomidor Log:{cEChooser}> """, { 'imgPomidor' : Form.StringLabel(""), 'FormChangeCb' : Form.FormChangeCb(self.OnFormChange), 'cEChooser' : Form.EmbeddedChooserControl(self.pomidor.pomidorView, swidth=50), 'strTime' : Form.StringLabel(""), 'iButtonPomidor' : Form.ButtonInput(self.OnButtonPomidor, swidth=16), 'iButtonShortBreak': Form.ButtonInput(self.OnButtonShortBreak, swidth=16), 'iButtonLongBreak' : Form.ButtonInput(self.OnButtonLongBreak, swidth=16), }) self.Compile()
def __init__(self,manager): self.manager = manager self.conf = manager.get_config() self.changed = False Form.__init__(self, """Neo4IDA - Manage Neo4j Connection {form_change} <#Host#~H~ost:{host}> <#Port#~P~ort:{port}> <#Username#~U~sername:{username}> <#Password#~P~assword:{password}> """ , { "form_change": Form.FormChangeCb(self.form_change), "host":Form.StringInput(swidth=20), "port":Form.StringInput(swidth=10), "username":Form.StringInput(swidth=40), "password":Form.StringInput(swidth=40) } ) self.Compile() self.host.value = self.conf["host"] self.port.value = self.conf["port"] self.username.value = self.conf["username"] self.password.value = self.conf["password"] self.Execute()
def __init__(self, start_ea, end_ea): Form.__init__(self, r"""BUTTON YES* Import Import data {FormChangeCb} <##Start EA :{intStartEA}> <##End EA :{intEndEA}> Import type: Patching options: <hex string:{rHex}><##Trim to selection:{cSize}>{cGroup}> <string literal:{rString}> <binary file:{rFile}>{rGroup}> <:{strPatch}> <##Import BIN file:{impFile}> """, { 'intStartEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=start_ea), 'intEndEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=end_ea), 'cGroup': Form.ChkGroupControl(("cSize",)), 'rGroup': Form.RadGroupControl(("rHex", "rString", "rFile")), #'strPatch': Form.MultiLineTextControl(swidth=80, flags=Form.MultiLineTextControl.TXTF_FIXEDFONT), 'strPatch': Form.StringInput(tp=None, width=1024, swidth=40, hlp=None, value=None, size=None), 'impFile': Form.FileInput(swidth=50, open=True), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) self.Compile()
def __init__(self): self.__n = 0 Form.__init__(self, r"""BUTTON YES* Yeah BUTTON NO Nope BUTTON CANCEL NONE Dropdown list test {FormChangeCb} <Dropdown list (readonly):{cbReadonly}> <Add element:{iButtonAddelement}> <Set index:{iButtonSetIndex}> <Dropdown list (editable):{cbEditable}> <Set string:{iButtonSetString}> """, { 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'cbReadonly': Form.DropdownListControl( items=["red", "green", "blue"], readonly=True, selval=1), 'cbEditable': Form.DropdownListControl( items=["1MB", "2MB", "3MB", "4MB"], readonly=False, selval="4MB"), 'iButtonAddelement': Form.ButtonInput(self.OnButtonNop), 'iButtonSetIndex': Form.ButtonInput(self.OnButtonNop), 'iButtonSetString': Form.ButtonInput(self.OnButtonNop), })
def __init__(self): # Load custom icon self.icon_id = idaapi.load_custom_icon(data=MyChooserForm.icon_data) if self.icon_id == 0: raise RuntimeError("Failed to load icon data!") self.main_current_index = -1 self.EChMain = MainChooserClass("MainChooser", self.icon_id) self.EChAux = AuxChooserClass("AuxChooser", self.icon_id) # Link the form to the EChooser self.EChMain.form = self self.EChAux.form = self Form.__init__( self, r"""STARTITEM 0 Form with choosers {FormChangeCb} Select an item in the main chooser: <Main chooser:{ctrlMainChooser}><Auxiliar chooser (multi):{ctrlAuxChooser}> <Selection:{ctrlSelectionEdit}> """, { "ctrlSelectionEdit": Form.StringInput(), "FormChangeCb": Form.FormChangeCb(self.OnFormChange), "ctrlMainChooser": Form.EmbeddedChooserControl(self.EChMain), "ctrlAuxChooser": Form.EmbeddedChooserControl(self.EChAux), }, )
def __init__(self): Form.__init__(self, ("STARTITEM 0\n" "BUTTON YES* Save Settings\n" "BUTTON CANCEL Cancel\n" "Form Setup View\n" "\n" "Debbuging:\n" "<##Maximal function calls:{iMaxFuncCall}>\n" "<##Maximal dereference depth:{iDerefDepth}>\n" "\n" "\n" "Debug Values:\n" "<Step Into System Libraries:{rStepInSysLibs}>\n" "<New Function Analysis:{rFuncAnalysis}>\n" "<Add xrefs:{rAddXref}>\n" "<Raw:{rRaw}>\n" "<Parse:{rParse}>\n" "<Array:{rArray}>\n" "<Enum:{rEnum}>\n" "<Containers:{rContainer}>\n" "<Dereference:{rDeref}>\n" "<Arguments:{rArgs}>{cDebugValues}>\n" "\n" ), { 'cDebugValues': Form.ChkGroupControl( ("rStepInSysLibs", "rAddXref", "rFuncAnalysis", "rRaw", "rParse", "rArray", "rContainer", "rDeref", "rArgs", "rEnum")), 'iMaxFuncCall': Form.NumericInput(tp=Form.FT_DEC), 'iDerefDepth': Form.NumericInput(tp=Form.FT_DEC), })
def __init__(self): Form.__init__(self, r"""STARTITEM 0 BUTTON YES* Yeah BUTTON NO Nope BUTTON CANCEL NONE Form Test {FormChangeCb} <Multilinetext:{txtMultiLineText}> """, { 'txtMultiLineText': Form.MultiLineTextControl(text="Hello"), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self): self.invert = False Form.__init__(self, r"""STARTITEM {id:host} FCatalog Client Configuration <#Host:{host}> <#Port:{port}> <#Database Name:{db_name}> """, { 'host': Form.StringInput(tp=Form.FT_TYPE), 'port': Form.StringInput(tp=Form.FT_TYPE), 'db_name': Form.StringInput(tp=Form.FT_TYPE), })
def __init__(self, addr_str, fpos_str, patch_str, org_str): Form.__init__(self, r"""Edit patch bytes Address {strAddr} File offset {strFpos} <:{strPatch}> """, { 'strAddr': Form.StringLabel(addr_str), 'strFpos': Form.StringLabel(fpos_str), 'strPatch': Form.MultiLineTextControl(text=patch_str, flags = Form.MultiLineTextControl.TXTF_FIXEDFONT), }) self.Compile()
def __init__(self, addr_str, fpos_str, patch_str, org_str): Form.__init__(self, r"""Edit patch bytes Address {strAddr} File offset {strFpos} <:{strPatch}> """, { 'strAddr': Form.StringLabel(addr_str), 'strFpos': Form.StringLabel(fpos_str), #'strPatch': Form.MultiLineTextControl(text=patch_str, flags = Form.MultiLineTextControl.TXTF_FIXEDFONT), 'strPatch': Form.StringInput(tp=None, width=1024, swidth=40, hlp=None, value=patch_str, size=None), }) self.Compile()
def __init__(self,defaultpath): Form.__init__(self, r"""BUTTON YES* 保存 BUTTON CANCEL 取消 请选择输出目录 {FormChangeCb} <##输出目录:{impFile}> """, { 'impFile': Form.DirInput(value=defaultpath), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) self.Compile()
def __init__(self, addr_str, fpos_str, patch_str, org_str): Form.__init__(self, r"""BUTTON YES* Restore BUTTON CANCEL Cancel Restore patch bytes Address {strAddr} File offset {strFpos} <:{strOrg}> """, { 'strAddr': Form.StringLabel(addr_str), 'strFpos': Form.StringLabel(fpos_str), 'strOrg': Form.MultiLineTextControl(text=org_str, flags = Form.MultiLineTextControl.TXTF_FIXEDFONT | Form.MultiLineTextControl.TXTF_READONLY), }) self.Compile()
def __init__(self): self.invert = False Form.__init__( self, r"""STARTITEM {id:host} FCatalog Client Configuration <#Host:{host}> <#Port:{port}> <#Database Name:{db_name}> <#Exclude Pattern:{exclude_pattern}> """, { 'host': Form.StringInput(tp=Form.FT_TYPE), 'port': Form.StringInput(tp=Form.FT_TYPE), 'db_name': Form.StringInput(tp=Form.FT_TYPE), 'exclude_pattern': Form.StringInput(tp=Form.FT_TYPE), })
def __init__(self, cnn, funcs): self.cnn = cnn self.actionView = ActionView(form=self, funcs=funcs, embedded=True) self.initialized = False Form.__init__(self, r"""BUTTON YES* OK BUTTON NO NONE BUTTON CANCEL NONE Indexing job {FormChangeCb} <Index progress:{cEChooser}> """, { 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'cEChooser': Form.EmbeddedChooserControl(self.actionView, swidth=0), }) self.Compile()
def __init__(self, start_ea, end_ea, fill_value): Form.__init__(self, r"""BUTTON YES* Fill Fill bytes <##Start EA :{intStartEA}> <##End EA :{intEndEA}> <##Value :{intPatch}> """, { 'intStartEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=start_ea), 'intEndEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=end_ea), 'intPatch': Form.NumericInput(swidth=40,tp=Form.FT_HEX,value=fill_value), }) self.Compile()
def __init__(self,defaultpath): Form.__init__(self, r"""BUTTON YES* 保存 BUTTON CANCEL 取消 请选择输出目录 {FormChangeCb} <##输出目录:{impFile}> """.decode('utf-8').encode(sys.getfilesystemencoding()), { 'impFile': Form.DirInput(value=defaultpath), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) self.Compile()
def __init__(self, addr_str, fpos_str, patch_str, org_str): Form.__init__(self, r"""BUTTON YES* Restore BUTTON CANCEL Cancel Restore patch bytes (Please don't edit) Address {strAddr} File offset {strFpos} <:{strOrg}> """, { 'strAddr': Form.StringLabel(addr_str), 'strFpos': Form.StringLabel(fpos_str), #'strOrg': Form.MultiLineTextControl(text=org_str, flags = Form.MultiLineTextControl.TXTF_FIXEDFONT | Form.MultiLineTextControl.TXTF_READONLY), 'strOrg': Form.StringInput(tp=None, width=1024, swidth=40, hlp=None, value=org_str, size=None), }) self.Compile()
def __init__(self): self.invert = False Form.__init__( self, r"""STARTITEM {id:cGoVers} GoLoader {FormChangeCb} <##Try to detemine go version based on moduledata:{iButton1}> <##Try to detemine go version based on version string:{iButton2}> <##Rename functions:{iButton3}> <##Rename structs:{iButton6}> <##Save package info to txt:{iButton7}> Go version: <Go1.2:{r2}> <Go1.4:{r4}> <Go1.5:{r5}> <Go1.6:{r6}> <Go1.7:{r7}> <Go1.8:{r8}> <Go1.9:{r9}> <Go1.10:{r10}> <Go1.11:{r11}> <Go1.12:{r12}> <Go1.13:{r13}>{cGoVers}> <##Add standard go types:{iButton4}> <##Parse types by moduledata:{iButton5}> """, { 'iButton1': Form.ButtonInput(self.OnButton1), 'iButton2': Form.ButtonInput(self.OnButton2), 'iButton3': Form.ButtonInput(self.OnButton3), 'iButton4': Form.ButtonInput(self.OnButton4), 'iButton5': Form.ButtonInput(self.OnButton5), 'iButton6': Form.ButtonInput(self.OnButton6), 'iButton7': Form.ButtonInput(self.OnButton7), 'cGoVers': Form.RadGroupControl(("r2", "r3", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12", "r13")), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self, manager): self.allFuncs = [GetFunction(x) for x in GetFunctions()] self.funcList = FunctionListView("asm", allFuncs=self.allFuncs, flags=Choose2.CH_MULTI) self.funcs = [] self.cnn = manager.connector self.Kconf = manager.Kconf dpItems = self.Kconf['cnns'].keys() if self.Kconf['default-cnn'] is not None: defaultIndex = self.Kconf['cnns'].keys().index( self.Kconf['default-cnn']) else: defaultIndex = 0 Form.__init__( self, r"""BUTTON YES* Index BUTTON CANCEL Cancel Kam1n0 {FormChangeCb} Select Function to be indexed <(Use ctrl/shift + click to select multiple functions):{fvChooser}> <Select all functions:{chkSearchAll}> <Select all library functions:{chkOnlyLib}> <Select all but not library functions:{chkSkipLib}>{adSearchGroup}> Index configuration <Server :{dpServer}> """, { 'adSearchGroup': Form.ChkGroupControl( ["chkSearchAll", "chkSkipLib", "chkOnlyLib"]), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'txtSim': Form.StringInput(swidth=25, tp=Form.FT_ASCII, value='0.5'), 'dpServer': Form.DropdownListControl(swidth=45, width=45, selval=defaultIndex, items=dpItems, readonly=True), 'fvChooser': Form.EmbeddedChooserControl(self.funcList) }) self.Compile() self.activated = False
def __init__(self): print("in init") Form.__init__( self, r"""STARTITEM 0 BUTTON YES* OK BUTTON NO NONE BUTTON CANCEL NONE Please wait, CGC Monitor working... {FormChangeCb} {cStr1} """, { 'cStr1': Form.StringLabel("Please wait, CGC Monitor working..."), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self, addr_str, fpos_str, patch_str, org_str): Form.__init__(self, r"""BUTTON YES* Restore BUTTON CANCEL Cancel Restore patch bytes Address {strAddr} File offset {strFpos} <:{strOrg}> """, { 'strAddr': Form.StringLabel(addr_str), 'strFpos': Form.StringLabel(fpos_str), 'strOrg': Form.MultiLineTextControl(text=org_str, flags = Form.MultiLineTextControl.TXTF_FIXEDFONT | Form.MultiLineTextControl.TXTF_READONLY), }) self.Compile()
def __init__(self): Form.__init__( self, r"""STARTITEM {id:start_addr} BUTTON YES* Enter BUTTON CANCEL Cancel Rename Function by log Log func address and new function name in located . <##StartEa\::{start_addr}> <##EndEa\::{end_addr}> <##off_func_addr\::{off_func_addr}> <##off_next_new_name\::{off_new_name}> """, { 'start_addr': Form.NumericInput(swidth=20, tp=Form.FT_HEX), 'end_addr': Form.NumericInput(swidth=20, tp=Form.FT_HEX), 'off_new_name': Form.NumericInput(swidth=20, tp=Form.FT_DEC), 'off_func_addr': Form.NumericInput(swidth=20, tp=Form.FT_DEC), })
def __init__(self,bundleFile,impFile): Form.__init__(self, r"""BUTTON YES* 替换 BUTTON CANCEL 取消 请选择文件(文件压缩后数据大小必须小于替换前压缩后数据大小) {FormChangeCb} <##选择被打包的文件:{bundleFile}> <##选择修改后的文件:{impFile}> """.decode('utf-8').encode(sys.getfilesystemencoding()), { 'bundleFile': Form.FileInput(open=True,value=bundleFile), 'impFile': Form.FileInput(open=True,value=impFile), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) self.Compile()
def __init__(self, db_list): Form.__init__(self, r"""STARTITEM {id:db_id} BUTTON YES* Exec BUTTON CANCEL Cancel Execute Query <##DB ID\::{db_id}> <##Query\::{db_query}> """, { 'db_id': Form.DropdownListControl( items=db_list, readonly=True, selval=0, swidth=20, width=20), 'db_query': Form.MultiLineTextControl(flags=self.textFlags, tabsize=self.textTab, width=200, swidth=200), })
def __init__(self): s = r"""Pigaios Please select the path to the exported source code SQLite database to diff against the current binary database. <#Select an exported source code SQLite database #Database :{iFileOpen}> <#Enter the command line for indenting sources and pseudo-codes (leave blank to ignore it) #Indent command :{iIndentCommand}> <#Minimum ratio to consider a match good enough (set to zero to automatically calculate it)#Calculations ratio :{iMinLevel}> <#Minimum ratio for a match to be displayed (set to zero to automatically calculate it) #Display ratio :{iMinDisplayLevel}> <Use the decompiler if available:{rUseDecompiler}>{cGroup1}>""" args = {'iFileOpen' : Form.FileInput(open=True, swidth=45), 'iIndentCommand' : Form.StringInput(swidth=45), 'iMinLevel' : Form.StringInput(swidth=10), 'iMinDisplayLevel': Form.StringInput(swidth=10), 'cGroup1' : Form.ChkGroupControl(("rUseDecompiler",)) } Form.__init__(self, s, args)
def __init__(self): """ Arguments: Return Value: Description: - TODO: - Doc String """ self.invert = False self.EChooser = TestEmbeddedChooserClass("E1", flags=Choose2.CH_MULTI) Form.__init__(self, r"""STARTITEM Arguments <##Enter length of argument:{iArgLen}> """, { 'iArgLen':Form.NumericInput() })
def __init__(self, heaptracer): self.heaptracer = heaptracer Form.__init__(self, r"""Heap Tracer {FormChangeCb} Pin path <##:{strPinPath}> Executable path<##:{strExecPath}> <Host:{strHost}>{spacer}<Port:{intPort}> """, { 'spacer' : Form.StringLabel(" "), 'strPinPath' : Form.StringInput(swidth=35,tp=Form.FT_ASCII), 'strExecPath' : Form.StringInput(swidth=35,tp=Form.FT_ASCII), 'FormChangeCb' : Form.FormChangeCb(self.OnFormChange), 'strHost' : Form.StringInput(swidth=25,tp=Form.FT_ASCII), 'intPort' : Form.NumericInput(swidth=10,tp=Form.FT_DEC), }) self.Compile()
def __init__(self, engine, recentFile): Form.__init__(self, r"""STARTITEM {id:script} BUTTON YES* Save BUTTON CANCEL Close Execute Custom Frida Script Recent source file:{src_file} <##Script source code\::{script}> <##Load from file:{loadfile}><##Update from file:{update}><##Execute:{execute}> """, { 'src_file': Form.StringLabel(recentFile if recentFile is not None else "", tp='f'), 'script': Form.MultiLineTextControl(flags=self.textFlags, tabsize=self.textTab, width=200, swidth=200), 'loadfile': Form.ButtonInput(self.onLoad), 'update': Form.ButtonInput(self.onUpdate), 'execute': Form.ButtonInput(self.onExecute), }) self.engine = engine self.recentScriptFile = recentFile
def __init__(self): self.invert = False Form.__init__( self, r"""STARTITEM {id:iUserName} BUTTON YES* Login BUTTON CANCEL Cancel Login form {FormChangeCb} <##Enter your username:{iUserName}> <##Enter your password:{iPassword}> {iResult} """, { 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'iUserName': Form.StringInput(tp=Form.FT_ASCII), 'iPassword': Form.StringInput(tp=Form.FT_ASCII), "iResult": Form.StringLabel( tp=Form.FT_ASCII, value="", sz=1024) })
def __init__(self, cnn, funcs): self.cnn = cnn self.actionView = ActionView(form=self, funcs=funcs, embedded=True) self.initialized = False Form.__init__( self, r"""BUTTON YES* OK BUTTON NO NONE BUTTON CANCEL NONE Indexing job {FormChangeCb} <Index progress:{cEChooser}> """, { 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'cEChooser': Form.EmbeddedChooserControl(self.actionView, swidth=0), }) self.Compile()
def __init__(self): Form.__init__( self, r"""STARTITEM {id:iAddr} BUTTON YES* OK BUTTON CANCEL Cancel Modify memory with a string {FormChangeCb} <#Hint1#Enter string :{iStr1}> <##Enter an address :{iAddr}> """, { 'iStr1': Form.StringInput(), 'iAddr': Form.NumericInput(tp=Form.FT_ADDR), 'iButton1': Form.ButtonInput(self.OnButton1), 'iButton2': Form.ButtonInput(self.OnButton2), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self): Form.__init__( self, r"""STARTITEM {id:iAddr} BUTTON YES* OK BUTTON CANCEL Cancel Get address and count for memory watch {FormChangeCb} <##Enter an address :{iAddr}> <##Enter count :{iRawHex}> """, { 'iAddr': Form.NumericInput(tp=Form.FT_ADDR), 'iRawHex': Form.NumericInput(tp=Form.FT_ADDR), 'iButton1': Form.ButtonInput(self.OnButton1), 'iButton2': Form.ButtonInput(self.OnButton2), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self): Form.__init__( self, r"""BUTTON YES* NONE BUTTON NO NONE BUTTON CANCEL NONE DIE - Dynamic IDA Enrichment {FormChangeCb} {imgDIE} DIE - Dynamic IDA Enrichment Framework Version 0.1 Written by: Yaniv Balmas. """, { 'imgDIE': Form.StringLabel(""), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) self.Compile()
def __init__(self, manager): self.manager = manager self.conf = manager.get_config() self.changed = False Form.__init__( self, """Neo4IDA - Execute Cypher Query {form_change} <#Query#~Q~uery:{query}> <#Execute Query#~E~xecute:{executeButton}> """, { "form_change": Form.FormChangeCb(self.form_change), "query": Form.StringInput(swidth=80), "executeButton": Form.ButtonInput(self.button_press) }) self.Compile() self.query.value = "START n=node(*) return n;" self.Execute()
def __init__(self, manager): self.cnn = manager.connector self.Kconf = manager.Kconf self.listView = ConnectionListView(manager) dpItems = self.Kconf['cnns'].keys() if self.Kconf['default-cnn'] is not None: defaultIndex = self.Kconf['cnns'].keys().index( self.Kconf['default-cnn'] ) else: defaultIndex = 0 Form.__init__(self, r"""BUTTON YES* OK BUTTON CANCEL NONE Kam1n0 - Manage connections {FormChangeCb} Manage Connections: <(Click to edit):{fvChooser}> <Remove :{btnRemove}> Remove selected connection. <Protocol :{txtProtocol}> <Server :{txtServer}> <Port :{txtPort}> Login Info: <User :{txtUser}> <Password :{txtPw}> <Update / Add:{btnUpdate}> <Default :{dpCnn}> < > """ , { 'fvChooser': Form.EmbeddedChooserControl(self.listView), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'txtServer': Form.StringInput(swidth=30,tp=Form.FT_ASCII), 'txtProtocol': Form.StringInput(swidth=30,tp=Form.FT_ASCII), 'txtPort': Form.StringInput(swidth=30,tp=Form.FT_ASCII), 'txtUser': Form.StringInput(swidth=30,tp=Form.FT_ASCII), 'txtPw': Form.StringInput(swidth=30,tp=Form.FT_ASCII), 'btnRemove' : Form.ButtonInput(self.OnButtonRemove), 'btnUpdate' : Form.ButtonInput(self.OnButtonUpdate), 'dpCnn' : Form.DropdownListControl(swidth=45, width=45, selval=defaultIndex, items=dpItems, readonly=True) }) self.Compile()
def __init__(self, start_ea, end_ea, fill_value): Form.__init__( self, r"""BUTTON YES* Fill Fill bytes <##Start EA :{intStartEA}> <##End EA :{intEndEA}> <##Value :{intPatch}> """, { 'intStartEA': Form.NumericInput(swidth=40, tp=Form.FT_ADDR, value=start_ea), 'intEndEA': Form.NumericInput(swidth=40, tp=Form.FT_ADDR, value=end_ea), 'intPatch': Form.NumericInput(swidth=40, tp=Form.FT_HEX, value=fill_value), }) self.Compile()
def __init__(self, addr_str, fpos_str, patch_str, org_str): Form.__init__( self, r"""Edit patch bytes Address {strAddr} File offset {strFpos} <:{strPatch}> """, { 'strAddr': Form.StringLabel(addr_str), 'strFpos': Form.StringLabel(fpos_str), 'strPatch': Form.MultiLineTextControl( text=patch_str, flags=Form.MultiLineTextControl.TXTF_FIXEDFONT), }) self.Compile()
def __init__(self, names, packageName): idx = 0 if packageName and packageName in names: idx = names.index(packageName) Form.__init__(self, ("STARTITEM 0\n" "BUTTON YES* Attach\n" "BUTTON CANCEL Cancel\n" "Attach android application\n" "\n" "<## Package Name:{names}>\n" "<## IDA Debug Port:{idaDebugPort}>\n" "Launch Options" " <Debug Mode:{debug}>{launchOptions}>\n" "\n" ), {'names': Form.DropdownListControl(items=names, readonly=True, selval=idx), 'idaDebugPort': Form.NumericInput(tp=Form.FT_DEC), "launchOptions": Form.ChkGroupControl(["debug"])}) self.pns = names self.pn = packageName
def __init__(self): Form.__init__(self, r"""STARTITEM {id:iRawHex} BUTTON YES* OK BUTTON CANCEL Cancel Modify word {FormChangeCb} <##Enter hex value :{iRawHex}> <##Enter an address :{iAddr}> <##Enter an offset :{iOffset}> """, { 'iRawHex': Form.NumericInput(tp=Form.FT_RAWHEX), 'iAddr': Form.NumericInput(tp=Form.FT_ADDR), 'iOffset': Form.NumericInput(tp=Form.FT_ADDR), 'iButton1': Form.ButtonInput(self.OnButton1), 'iButton2': Form.ButtonInput(self.OnButton2), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self, module, address, symbol, recent): Form.__init__( self, r"""STARTITEM {id:ret_type} BUTTON YES* Save BUTTON CANCEL Cancel Function Implementation Replace {segment} {address}: {symbol} <##return type\::{ret_type}> <##arguments\::{args}> {orig_call} Recent source file:{src_file} <##Script source code\::{script}> <##Load from file:{loadfile}><##Update from file:{update}> """, { 'segment': Form.StringLabel("[" + module + "]", tp='F'), 'address': Form.StringLabel(address, tp='A'), 'symbol': Form.StringLabel(symbol, tp='X'), 'ret_type': Form.StringInput(swidth=10), 'args': Form.StringInput(swidth=40), 'orig_call': Form.StringLabel( "NOTE: Original implementation can be called using `frlOriginalImpl()`" ), 'src_file': Form.StringLabel(recent if recent is not None else "", tp='f'), 'script': Form.MultiLineTextControl(flags=self.textFlags, tabsize=self.textTab, width=200, swidth=200), 'loadfile': Form.ButtonInput(self.onLoadScript), 'update': Form.ButtonInput(self.onUpdateScript), }) self.recentScriptFile = recent
def __init__(self): Form.__init__(self, ("STARTITEM 0\n" "BUTTON YES* Confirm\n" "BUTTON CANCEL Cancel\n" "VMAttack Settings\n" "\n" "VM Values:\n" "<Byte code start :{iCodeStart}>\n" "<Byte code end :{iCodeEnd}>\n" "<Jump table base address :{iBaseAddr}>\n" "<VM function address :{iVMAddr}>\n" "\n" "Clustering:\n" "<Show basic blocks:{rShowBB}>\n" "<Greedy clustering:{rGreedyCluster}>{cClusterValues}>\n" "<Cluster Heuristic :{iClusterHeu}>\n" "\n" "Grading Automation:\n" "<Input/Output Importance :{iInOut}>\n" "<Clustering Importance :{iClu}>\n" "<Pattern Importance :{iPaMa}>\n" "<Memory Usage Importance :{iMeUs}>\n" "<Static Analysis Importance:{iSta}>\n" "\n" "\n" "Dynamic Analysis:\n" "<Step Into System Libraries :{rStepInSysLibs}>\n" '<Extract function parameters:{rFuncParams}>{cDynamicValues}>\n' ), { 'cClusterValues': Form.ChkGroupControl(("rShowBB", "rGreedyCluster")), 'cDynamicValues': Form.ChkGroupControl(('rStepInSysLibs', 'rFuncParams')), 'iClusterHeu': Form.NumericInput(tp=Form.FT_DEC), 'iInOut': Form.NumericInput(tp=Form.FT_DEC), 'iClu': Form.NumericInput(tp=Form.FT_DEC), 'iPaMa': Form.NumericInput(tp=Form.FT_DEC), 'iMeUs': Form.NumericInput(tp=Form.FT_DEC), 'iSta': Form.NumericInput(tp=Form.FT_DEC), 'iVMAddr': Form.NumericInput(tp=Form.FT_DEC), 'iBaseAddr': Form.NumericInput(tp=Form.FT_DEC), 'iCodeEnd': Form.NumericInput(tp=Form.FT_DEC), 'iCodeStart': Form.NumericInput(tp=Form.FT_DEC), })
def __init__(self, start_ea, end_ea, org_file, bkp_file): Form.__init__(self, r"""Apply patches to input file {FormChangeCb} <##Start EA :{intStartEA}> <##End EA :{intEndEA}> <##Input file :{orgFile}> <##Backup file:{bkpFile}> <##Create backup:{rBackup}> <##Restore original bytes:{rRestore}>{cGroup1}> """, { 'intStartEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=start_ea), 'intEndEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=end_ea), 'orgFile': Form.FileInput(swidth=50, open=True, value=org_file), 'bkpFile': Form.FileInput(swidth=50, open=True, value=bkp_file), 'cGroup1': Form.ChkGroupControl(("rBackup", "rRestore")), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) self.Compile()
def __init__(self): self.invert = False self.EChooser = EmbeddedChooserClass("Title", flags=Choose.CH_MODAL) self.selected_id = 0 self.s = "" self.fst = FuzzySearchThread() self.fst.refresh_list.connect(self.refresh_list) self.fst.finished.connect(self.finished) # self.EChooser = EmbeddedChooserClass("Title", flags=Choose.CH_CAN_REFRESH) Form.__init__(self, r"""STARTITEM IDA Fuzzy Search {FormChangeCb} <:{iStr1}> <Results:{cEChooser}> """, { 'iStr1': Form.StringInput(), 'cEChooser': Form.EmbeddedChooserControl(self.EChooser), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self,manager): self.manager = manager self.conf = manager.get_config() self.changed = False Form.__init__(self, """Neo4IDA - Execute Cypher Query {form_change} <#Query#~Q~uery:{query}> <#Execute Query#~E~xecute:{executeButton}> """ , { "form_change": Form.FormChangeCb(self.form_change), "query":Form.StringInput(swidth=80), "executeButton":Form.ButtonInput(self.button_press) } ) self.Compile() self.query.value = "START n=node(*) return n;" self.Execute()
def __init__(self): self.invert = False Form.__init__( self, r"""STARTITEM {id:cGoVers} GoLoader {FormChangeCb} <##Try to detemine go version based on moduledata:{iButton1}> <##Try to detemine go version based on version string:{iButton2}> <##Rename functions:{iButton3}> Go version: <Go1.2:{r2}> <Go1.4:{r4}> <Go1.5:{r5}> <Go1.6:{r6}> <Go1.7:{r7}>{cGoVers}> <##Add standard go types:{iButton4}> <##Parse types by moduledata:{iButton5}> """, { 'iButton1': Form.ButtonInput(self.OnButton1), 'iButton2': Form.ButtonInput(self.OnButton2), 'iButton3': Form.ButtonInput(self.OnButton3), 'iButton4': Form.ButtonInput(self.OnButton4), 'iButton5': Form.ButtonInput(self.OnButton5), 'cGoVers': Form.RadGroupControl(( "r2", "r3", "r4", "r5", "r6", "r7", )), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self, lines, prompt): self.prompt = prompt print("in okTextForm init") if prompt: Form.__init__( self, r"""STARTITEM 0 BUTTON YES* OK BUTTON NO NONE BUTTON CANCEL NONE CGC Ida Client Help {FormChangeCb} <Don't show help at startup:{nShow}>{cGroup1}> {cStr1} {cStr2} """, { 'cStr1': Form.StringLabel(lines['overview']), 'cStr2': Form.StringLabel(lines['hotkeys']), 'cGroup1': Form.ChkGroupControl(("nShow", "")), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) else: Form.__init__( self, r"""STARTITEM 0 BUTTON YES* OK BUTTON NO NONE BUTTON CANCEL NONE CGC Ida Client Help {FormChangeCb} {cStr1} """, { 'cStr1': Form.StringLabel(lines['overview']), 'cStr2': Form.StringLabel(lines['hotkeys']), 'cGroup1': Form.ChkGroupControl(("nShow", "")), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), })
def __init__(self): """ Arguments: Return Value: Description: - TODO: - Doc String """ self.invert = False self.EChooser = TestEmbeddedChooserClass("E1", flags=Choose2.CH_MULTI) Form.__init__(self, r"""STARTITEM {id:rDiscardLazySolves} Options <Discard LAZY_SOLVES:{rDiscardLazySolves}> <Immutable:{rImmutable}> <Auto Load Libs:{rAutoLoadLibs}>{cGroup1}> <Time Limit:{iTimeLimit}> """, { 'cGroup1': Form.ChkGroupControl(("rDiscardLazySolves", "rImmutable", "rAutoLoadLibs")), 'iTimeLimit':Form.NumericInput(), })
def __init__(self): Form.__init__( self, r"""STARTITEM {id:db_id} BUTTON YES* Save BUTTON CANCEL Cancel Create New DB <##DB ID\: :{db_id}> <##DB File\::{db_path}> <##First Table Query\::{db_table}> """, { 'db_id': Form.StringInput(swidth=15), 'db_path': Form.FileInput(save=True), 'db_table': Form.MultiLineTextControl(flags=self.textFlags, tabsize=self.textTab, width=200, swidth=200), })
def __init__(self, functions): self.functions = functions Form.__init__( self, ("STARTITEM 0\n" "BUTTON YES* StartDIE\n" "BUTTON CANCEL Cancel\n" "Form Scope Chooser\n" "\n" "<Start Function :{cbStartFunction}>\n" "<End Function :{cbEndFunction}>\n"), { 'iStartAddr': Form.NumericInput(tp=Form.FT_ADDR), 'iEndAddr': Form.NumericInput(tp=Form.FT_ADDR), 'cbStartFunction': Form.DropdownListControl( items=self.functions, readonly=True, selval=1), 'cbEndFunction': Form.DropdownListControl( items=self.functions, readonly=True, selval=1), })
def __init__(self): Form.__init__( self, r"""Marx IDA Import Script <#Select a hierarchy file to open# Hierarchy File:{iHierarchyFileOpen}> <#Select a new operators file to open#New Operators File:{iNewOpFileOpen}> <#Select a vcalls file to open# Vcalls File:{iVcallFileOpen}> <#Select a Vtables file to open# Vtables File:{iVTablesFileOpen}> Class hierarchies <Allow hierarchies with only one class:{rAllowSingleClassHierarchies}>{cHierarchies}> """, { 'iHierarchyFileOpen': Form.FileInput(open=True, value="*.hierarchy"), 'iNewOpFileOpen': Form.FileInput(open=True, value="*.new_operators"), 'iVcallFileOpen': Form.FileInput(open=True, value="*.vcalls_extended"), 'iVTablesFileOpen': Form.FileInput(open=True, value="*_vtables.txt"), 'cHierarchies': Form.ChkGroupControl(("rAllowSingleClassHierarchies", )) })
def __init__(self, functions): self.functions = functions Form.__init__(self, ("STARTITEM 0\n" "BUTTON YES* StartDIE\n" "BUTTON CANCEL Cancel\n" "Form Scope Chooser\n" "\n" "<Start Function :{cbStartFunction}>\n" "<End Function :{cbEndFunction}>\n" ), { 'iStartAddr' : Form.NumericInput(tp=Form.FT_ADDR), 'iEndAddr' : Form.NumericInput(tp=Form.FT_ADDR), 'cbStartFunction': Form.DropdownListControl( items=self.functions, readonly=True, selval=1), 'cbEndFunction': Form.DropdownListControl( items=self.functions, readonly=True, selval=1), })
def __init__(self, start_ea, end_ea, org_file, bkp_file): Form.__init__(self, r"""Apply patches to input file {FormChangeCb} <##Start EA :{intStartEA}> <##End EA :{intEndEA}> <##Input file :{orgFile}> <##Backup file:{bkpFile}> <##Create backup:{rBackup}> <##Restore original bytes:{rRestore}>{cGroup1}> """, { 'intStartEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=start_ea), 'intEndEA': Form.NumericInput(swidth=40,tp=Form.FT_ADDR,value=end_ea), 'orgFile': Form.FileInput(swidth=50, open=True, value=org_file), 'bkpFile': Form.FileInput(swidth=50, open=True, value=bkp_file), 'cGroup1': Form.ChkGroupControl(("rBackup", "rRestore")), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), }) self.Compile()
def __init__(self, manager): global funcListG self.funcList = FunctionListView("asm", flags=Choose2.CH_MULTI) self.funcs = [] self.cnn = manager.connector self.Kconf = manager.Kconf dpItems = self.Kconf['cnns'].keys() if self.Kconf['default-cnn'] is not None: defaultIndex = self.Kconf['cnns'].keys().index( self.Kconf['default-cnn'] ) else: defaultIndex = 0 Form.__init__(self, r"""BUTTON YES* Search BUTTON CANCEL Cancel Kam1n0 {FormChangeCb} Select function to be searched <(Use ctrl/shift + click to select multiple functions):{fvChooser}> <Select all functions:{chkSearchAll}><Skip library functions:{chkSkipLib}>{adSearchGroup}> Search configuration <Threshold:{txtSim}> <Server :{dpServer}> """, { 'adSearchGroup': Form.ChkGroupControl(["chkSearchAll", "chkSkipLib"]), 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'txtSim': Form.StringInput(swidth=25,tp=Form.FT_ASCII, value='0.5'), 'dpServer':Form.DropdownListControl(swidth=45, width=45, selval=defaultIndex, items=dpItems, readonly=True), 'fvChooser': Form.EmbeddedChooserControl(self.funcList) }) self.Compile()
def __init__(self, manager, message = "Search Configuration:"): self.cnn = manager.connector Form.__init__(self, r"""BUTTON YES* Apply BUTTON CANCEL Cancel Kam1n0 {FormChangeCb} %s <Protocol :{txtProtocol}> <Server :{txtServer}> <Port :{txtPort}> Login Info: <User :{txtUser}> <Password :{txtPw}> < > """ % message, { 'FormChangeCb': Form.FormChangeCb(self.OnFormChange), 'txtServer': Form.StringInput(swidth=30,tp=Form.FT_ASCII, value=self.cnn.server), 'txtProtocol': Form.StringInput(swidth=30,tp=Form.FT_ASCII, value=self.cnn.protocol), 'txtPort': Form.StringInput(swidth=30,tp=Form.FT_ASCII, value=self.cnn.port), 'txtUser': Form.StringInput(swidth=30,tp=Form.FT_ASCII, value=self.cnn.un), 'txtPw': Form.StringInput(swidth=30,tp=Form.FT_ASCII, value=self.cnn.pw), }) self.Compile()
def __init__(self): self.invert = False self.EChooser = TestEmbeddedChooserClass("E1", flags=Choose2.CH_MULTI) Form.__init__( self, r"""STARTITEM {id:rNormal} BUTTON YES* Yeah BUTTON NO Nope BUTTON CANCEL Nevermind Form Test {FormChangeCb} This is a string: +{cStr1}+ This is an address: +{cAddr1}+ Escape\{control} This is a string: '{cStr2}' This is a number: {cVal1} <#Hint1#Enter name:{iStr1}> <#Hint2#Select color:{iColor1}> Browse test <#Select a file to open#Browse to open:{iFileOpen}> <#Select a file to save#Browse to save:{iFileSave}> <#Select dir#Browse for dir:{iDir}> Type <#Select type#Write a type:{iType}> Numbers <##Enter a selector value:{iSegment}> <##Enter a raw hex:{iRawHex}> <##Enter a character:{iChar}> <##Enter an address:{iAddr}> Button test <##Button1:{iButton1}> <##Button2:{iButton2}> Check boxes: <Error output:{rError}> <Normal output:{rNormal}> <Warnings:{rWarnings}>{cGroup1}> Radio boxes: <Green:{rGreen}> <Red:{rRed}> <Blue:{rBlue}>{cGroup2}> <Embedded chooser:{cEChooser}> The end! """, { "cStr1": Form.StringLabel("Hello"), "cStr2": Form.StringLabel("StringTest"), "cAddr1": Form.NumericLabel(0x401000, Form.FT_ADDR), "cVal1": Form.NumericLabel(99, Form.FT_HEX), "iStr1": Form.StringInput(), "iColor1": Form.ColorInput(), "iFileOpen": Form.FileInput(open=True), "iFileSave": Form.FileInput(save=True), "iDir": Form.DirInput(), "iType": Form.StringInput(tp=Form.FT_TYPE), "iSegment": Form.NumericInput(tp=Form.FT_SEG), "iRawHex": Form.NumericInput(tp=Form.FT_RAWHEX), "iAddr": Form.NumericInput(tp=Form.FT_ADDR), "iChar": Form.NumericInput(tp=Form.FT_CHAR), "iButton1": Form.ButtonInput(self.OnButton1), "iButton2": Form.ButtonInput(self.OnButton2), "cGroup1": Form.ChkGroupControl(("rNormal", "rError", "rWarnings")), "cGroup2": Form.RadGroupControl(("rRed", "rGreen", "rBlue")), "FormChangeCb": Form.FormChangeCb(self.OnFormChange), "cEChooser": Form.EmbeddedChooserControl(self.EChooser), }, )
def __init__(self, manager, disable_param=False): self.disable_param = disable_param self.all_funcs = IDAUtils.get_all_ida_funcs() self.funcList = FunctionListView("asm", flags=Choose.CH_MULTI, all_funcs=self.all_funcs) self.selected_funcs = [] self.configuration = manager.configuration apps = self.configuration['apps'].keys() default_app = self.configuration['default-app'] if self.configuration['default-app'] is not None: default_index = apps.index(default_app) else: default_index = 0 self.selected_app_key = default_app self.threshold = self.configuration['default-threshold'] self.topk = self.configuration['default-topk'] self.avoidSameBinary = self.configuration['default-avoidSameBinary'] Form.__init__(self, r"""BUTTON YES* Continue BUTTON CANCEL Cancel Kam1n0 {FormChangeCb} Select Function: <(Use ctrl/shift + click to select multiple functions):{fvChooser}> <Select all functions:{chkSearchAll}><Skip library functions:{chkSkipLib}>{adSearchGroup}> Configuration <Threshold:{txtSim}> <TopK :{txtTopK}> <Avoid Same Binary :{chkSameBin}>{chkGroup}> <App :{dpServer}> """, { 'adSearchGroup': Form.ChkGroupControl( ["chkSearchAll", "chkSkipLib"]), 'FormChangeCb': Form.FormChangeCb( self.OnFormChange), 'txtSim': Form.StringInput( swidth=25, tp=Form.FT_ASCII, value=str( self.threshold)), 'txtTopK': Form.StringInput( swidth=25, tp=Form.FT_ASCII, value=str(self.topk)), 'chkGroup': Form.ChkGroupControl( ("chkSameBin", "")), 'dpServer': Form.DropdownListControl( swidth=45, width=45, selval=default_index, items=apps, readonly=True), 'fvChooser': Form.EmbeddedChooserControl( self.funcList) }) self.Compile()