当前位置: 首页>>代码示例>>Python>>正文


Python ida_kernwin.Form方法代码示例

本文整理汇总了Python中ida_kernwin.Form方法的典型用法代码示例。如果您正苦于以下问题:Python ida_kernwin.Form方法的具体用法?Python ida_kernwin.Form怎么用?Python ida_kernwin.Form使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ida_kernwin的用法示例。


在下文中一共展示了ida_kernwin.Form方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

# 需要导入模块: import ida_kernwin [as 别名]
# 或者: from ida_kernwin import Form [as 别名]
def __init__(self):
    self.invert = False
    ida_kernwin.Form.__init__(self, r"""STARTITEM 0
BUTTON YES Ok
BUTTON NO*  No
BUTTON Cancel Cancel
VirusTotal Plugin for IDA Pro 7

Welcome to the Beta Version of the VirusTotal IDA Pro Plugin !

Auto uploads of samples is enabled by default. By submitting 
your file to VirusTotal you are asking VirusTotal to share 
your submission with the security community and agree to our 
Terms of Service and Privacy Policy. 

For further information click on the following links:
- {cHtml1}
- {cHtml2}

Press "Ok" to agree, "No" to disable uploads or "Cancel"
to stop using this plugin.
 
""", {
    'cHtml1': ida_kernwin.Form.StringLabel(
        '<a href=\"https://support.virustotal.com/hc/en-us/articles/115002145529-Terms-of-Service\">Terms of Service</a>',
        tp=ida_kernwin.Form.FT_HTML_LABEL
    ),
    'cHtml2': ida_kernwin.Form.StringLabel(
        '<a href=\"https://support.virustotal.com/hc/en-us/articles/115002168385-Privacy-Policy\">Privacy Policy</a>',
        tp=ida_kernwin.Form.FT_HTML_LABEL
    )
}) 
开发者ID:VirusTotal,项目名称:vt-ida-plugin,代码行数:34,代码来源:plugin_loader.py

示例2: __init__

# 需要导入模块: import ida_kernwin [as 别名]
# 或者: from ida_kernwin import Form [as 别名]
def __init__(self):

        addr = idc.ScreenEA()
        func = idaapi.get_func(addr)

        tests_choice = "\n".join(map(lambda x: "<%s:{r%s}>" % (x, x), AVAILABLE_TESTS))
        ida_kernwin.Form.__init__(self,
r"""BUTTON YES* Launch
BUTTON CANCEL NONE
Sibyl Settings

{FormChangeCb}
Apply on:
<One function:{rOneFunc}>
<All functions:{rAllFunc}>{cMode}>

<Targeted function:{cbFunc}>

Testsets to use:
%s{cTest}>

""" % tests_choice, {
    'FormChangeCb': ida_kernwin.Form.FormChangeCb(self.OnFormChange),
    'cMode': ida_kernwin.Form.RadGroupControl(("rOneFunc", "rAllFunc")),
    'cTest': ida_kernwin.Form.ChkGroupControl(map(lambda x: "r%s" % x,
                                      AVAILABLE_TESTS),
                                  value=(1 << len(AVAILABLE_TESTS)) - 1),
    'cbFunc': ida_kernwin.Form.DropdownListControl(
        items=self.available_funcs,
        readonly=False,
        selval="0x%x" % func.startEA),
}
        )

        self.Compile() 
开发者ID:cea-sec,项目名称:Sibyl,代码行数:37,代码来源:find.py

示例3: __init__

# 需要导入模块: import ida_kernwin [as 别名]
# 或者: from ida_kernwin import Form [as 别名]
def __init__(self, address, current_name):
        """
        Display a Pop-Up and get a new name for the symbol
        """
        self.invert = False
        rename_form_dict = {
            'cAddr': ida_kernwin.Form.NumericLabel(address,
                                                   ida_kernwin.Form.FT_ADDR),
            'cLbl': ida_kernwin.Form.StringLabel(current_name),
            'iStr': ida_kernwin.Form.StringInput(),
        }
        ida_kernwin.Form.__init__(self, RENAME_FORM_TEXT, rename_form_dict) 
开发者ID:Cisco-Talos,项目名称:GhIDA,代码行数:14,代码来源:ui.py

示例4: __init__

# 需要导入模块: import ida_kernwin [as 别名]
# 或者: from ida_kernwin import Form [as 别名]
def __init__(self):
        ida_kernwin.Form.__init__(self,
r"""BUTTON YES* Run
BUTTON CANCEL Cancel
stackstring_static

{FormChangeCb}
<current function only:{cCurrentOnly}>
<enable debug messages:{cDebug}>
<enable xor decoding:{cDecode}>{cGroup}>
""",
        {
            'FormChangeCb': ida_kernwin.Form.FormChangeCb(self.OnFormChange),
            'cGroup': ida_kernwin.Form.ChkGroupControl(("cCurrentOnly", "cDebug", "cDecode")),
        }) 
开发者ID:TakahiroHaruyama,项目名称:ida_haru,代码行数:17,代码来源:stackstring_static.py

示例5: __init__

# 需要导入模块: import ida_kernwin [as 别名]
# 或者: from ida_kernwin import Form [as 别名]
def __init__(self):
        ida_kernwin.Form.__init__(
            self,
            r"""BUTTON YES* Launch
BUTTON CANCEL NONE
Graph IR Settings

{FormChangeCb}
Analysis:
<Graph IR :{rGraphIR}>
<Graph IR + SSA :{rGraphIRSSA}>
<Graph IR + SSA + UnSSA :{rGraphIRSSAUNSSA}>{cScope}>

Options:
<Simplify code:{rCodeSimplify}>
<Subcalls dont change stack:{rDontModStack}>
<Load static memory:{rLoadMemInt}>{cOptions}>
""",
            {
                'FormChangeCb': ida_kernwin.Form.FormChangeCb(self.OnFormChange),
                'cScope': ida_kernwin.Form.RadGroupControl(
                    (
                        "rGraphIR",
                        "rGraphIRSSA",
                        "rGraphIRSSAUNSSA"
                    )
                ),
                'cOptions': ida_kernwin.Form.ChkGroupControl(
                    (
                        "rCodeSimplify",
                        "rDontModStack",
                        "rLoadMemInt"
                    )
                ),
            }
        )
        form, _ = self.Compile()
        form.rCodeSimplify.checked = True
        form.rDontModStack.checked = False
        form.rLoadMemInt.checked = False 
开发者ID:cea-sec,项目名称:miasm,代码行数:42,代码来源:graph_ir.py

示例6: get_options

# 需要导入模块: import ida_kernwin [as 别名]
# 或者: from ida_kernwin import Form [as 别名]
def get_options(self, display):
        """
        Displays the options menu and retrieves the option settings. 
        """
        fmt = "HELP\n"
        fmt += "XML PROGRAM loader/importer plugin (Python)\n"
        fmt += "IDA SDK: " + str(IDA_SDK_VERSION) + "\n\n"
        fmt += "The XML PROGRAM loader loads elements from a "
        fmt += "XML <PROGRAM> document to create an idb database.\n\n"
        fmt += "ENDHELP\n"
        fmt += "Import from XML PROGRAM document...."
        fmt += "\n <##Options##Code Blocks:{CodeBlocks}>"
        fmt += "\n <Entry Points:{EntryPoints}>"
        fmt += "\n <Segment Register Value Ranges:{RegisterValues}>"
        fmt += "\n <Data Types:{DataTypes}>"
        fmt += "\n <Data Definitions:{DataDefinitions}>"
        fmt += "\n <Symbols:{Symbols}>"
        fmt += "\n <Comments:{Comments}>"
        fmt += "\n <Bookmarks:{Bookmarks}>"
        fmt += "\n <Functions:{Functions}>"
        fmt += "\n <Memory References:{MemoryReferences}>"
        fmt += "\n <Equate/Enum References:{EquateReferences}>"
        fmt += "\n <Manual Instructions/Operands:{Manual}>{cGroup1}>"
        fmt += "\n\n"

        Opts = {'cGroup1': ida_kernwin.Form.ChkGroupControl((
            "CodeBlocks",
            "EntryPoints",
            "RegisterValues",
            "DataTypes",
            "DataDefinitions",
            "Symbols",
            "Comments",
            "Bookmarks",
            "Functions",
            "MemoryReferences",
            "EquateReferences",
            "Manual"
        ))}

        self.options = ida_kernwin.Form(fmt, Opts)
        self.options.Compile()

        self.options.CodeBlocks.checked = True
        self.options.EntryPoints.checked = True
        self.options.RegisterValues.checked = True
        self.options.DataTypes.checked = True
        self.options.DataDefinitions.checked = True
        self.options.Symbols.checked = True
        self.options.Functions.checked = True
        self.options.Comments.checked = True
        self.options.Bookmarks.checked = True
        self.options.MemoryReferences.checked = True
        self.options.EquateReferences.checked = True
        self.options.Manual.checked = True

        if display == True:
            ok = self.options.Execute()
            if (ok == 0):
                raise Cancelled 
开发者ID:Cisco-Talos,项目名称:GhIDA,代码行数:62,代码来源:idaxml.py

示例7: __init__

# 需要导入模块: import ida_kernwin [as 别名]
# 或者: from ida_kernwin import Form [as 别名]
def __init__(self):
        ida_kernwin.Form.__init__(self,
r"""BUTTON YES* Run
BUTTON CANCEL Cancel
fn_fuzzy

{FormChangeCb}
General Options
<DB file path:{iDBSave}>
<minimum function code size:{iMinBytes}>
<exclude library/thunk functions:{cLibthunk}>
<enable debug messages:{cDebug}>{cGroup}>

<##Commands##Export:{rExport}>
<Compare:{rCompare}>{rGroup}>

Export Options
<update the DB records:{cUpdate}>
<store flags as analyzed functions:{cAnaExp}>{cEGroup}>
<analyzed function name prefix/suffix (regex):{iPrefix}>

Compare Options
<compare with only analyzed functions:{cAnaCmp}>
<compare with only IDBs in the specified folder:{cFolCmp}>{cCGroup}>
<the folder path:{iFolder}>
<function code size comparison criteria (0-100):{iRatio}>
<function similarity score threshold (0-100) without CFG match:{iSimilarity}>
<function similarity score threshold (0-100) with CFG match:{iSimilarityCFG}>
<function code size threshold evaluated by only CFG match:{iMaxBytesForScore}>
""",
        {
            'FormChangeCb': ida_kernwin.Form.FormChangeCb(self.OnFormChange),
            'cGroup': ida_kernwin.Form.ChkGroupControl(("cLibthunk", "cDebug")),
            'iDBSave': ida_kernwin.Form.FileInput(save=True),
            'iMinBytes': ida_kernwin.Form.NumericInput(tp=ida_kernwin.Form.FT_HEX),
            'rGroup': ida_kernwin.Form.RadGroupControl(("rCompare", "rExport")),
            'cEGroup': ida_kernwin.Form.ChkGroupControl(("cUpdate", "cAnaExp")),
            'iPrefix': ida_kernwin.Form.StringInput(),
            'cCGroup': ida_kernwin.Form.ChkGroupControl(("cAnaCmp", "cFolCmp")),
            'iFolder': ida_kernwin.Form.DirInput(),
            'iRatio': ida_kernwin.Form.NumericInput(tp=ida_kernwin.Form.FT_DEC),
            'iSimilarity': ida_kernwin.Form.NumericInput(tp=ida_kernwin.Form.FT_DEC),
            'iSimilarityCFG': ida_kernwin.Form.NumericInput(tp=ida_kernwin.Form.FT_DEC),
            'iMaxBytesForScore': ida_kernwin.Form.NumericInput(tp=ida_kernwin.Form.FT_HEX),            
        }) 
开发者ID:TakahiroHaruyama,项目名称:ida_haru,代码行数:47,代码来源:fn_fuzzy.py


注:本文中的ida_kernwin.Form方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。