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


Python idaapi.attach_action_to_popup方法代码示例

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


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

示例1: _inject_ctx_actions

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def _inject_ctx_actions(self, view, popup, view_type):
        """
        Inject context menu entries into IDA's right click menus.

        NOTE: This is only being used for coverage xref at this time, but
        may host additional actions in the future.

        """

        if view_type == idaapi.BWN_DISASMS:

            idaapi.attach_action_to_popup(
                view,
                popup,
                self.ACTION_COVERAGE_XREF,  # The action ID (see above)
                "Xrefs graph from...",      # Relative path of where to add the action
                idaapi.SETMENU_APP          # We want to append the action after ^
            ) 
开发者ID:gaasedelen,项目名称:lighthouse,代码行数:20,代码来源:ida_integration.py

示例2: callback

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def callback(self, event, *args):
        if event == idaapi.hxe_populating_popup:
            form, phandle, vu = args
            if vu.item.citype == idaapi.VDI_FUNC or (vu.item.citype == idaapi.VDI_EXPR and vu.item.e.is_expr() and vu.item.e.type.is_funcptr()):
                idaapi.attach_action_to_popup(form, phandle, ACTION_HX_REMOVERETTYPE, None)
        elif event == idaapi.hxe_double_click:
            vu, shift_state = args
            # auto jump to target if clicked item is xxx->func();
            if vu.item.citype == idaapi.VDI_EXPR and vu.item.e.is_expr():
                expr = idaapi.tag_remove(vu.item.e.print1(None))
                if "->" in expr:
                    # find target function
                    name = expr.split("->")[-1]
                    addr = idc.get_name_ea_simple(name)
                    if addr == idaapi.BADADDR:
                        # try class::function
                        e = vu.item.e
                        while e.x:
                            e = e.x
                        addr = idc.get_name_ea_simple("%s::%s" % (str(e.type).split()[0], name))

                    if addr != idaapi.BADADDR:
                        idc.jumpto(addr)
                        return 1
        return 0 
开发者ID:L4ys,项目名称:LazyIDA,代码行数:27,代码来源:LazyIDA.py

示例3: register_menu_actions

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def register_menu_actions(form):
    widget = form.GetWidget()
    for action in form.menu_actions:
        act_name = action.name
        if act_name != '-':
            act_name = "%s:%s" % (PLUGIN_NAME, action.name)
            idaapi.register_action(
                idaapi.action_desc_t(
                    act_name, 
                    action.title,
                    ActionHandler(form, action), 
                    action.shortcut, 
                    action.tooltip, 
                    action.icon
                )
            )
        if action.checkable is not None:
            idaapi.update_action_checkable(act_name, True)
            idaapi.update_action_checked(act_name, action.checkable)

        idaapi.attach_action_to_popup(widget, None, act_name)

# ----------------------------------------------------------------------- 
开发者ID:danigargu,项目名称:deREferencing,代码行数:25,代码来源:actions.py

示例4: finish_populating_widget_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_widget_popup(form, popup):
    if idaapi.get_widget_type(form) == idaapi.BWN_DISASM:
      idaapi.attach_action_to_popup(
          form,
          popup,
          VTGrepBytes.get_name(),
          'VirusTotal/'
          )
      idaapi.attach_action_to_popup(
          form,
          popup,
          VTGrepWildcards.get_name(),
          'VirusTotal/',
          )
      idaapi.attach_action_to_popup(
          form,
          popup,
          VTGrepWildCardsStrict.get_name(),
          'VirusTotal/',
          )
      idaapi.attach_action_to_popup(
          form,
          popup,
          VTGrepWildCardsFunction.get_name(),
          'VirusTotal/',
          )
    elif idaapi.get_widget_type(form) == idaapi.BWN_STRINGS:
      idaapi.attach_action_to_popup(
          form,
          popup,
          VTGrepStrings.get_name(),
          'VirusTotal/') 
开发者ID:VirusTotal,项目名称:vt-ida-plugin,代码行数:34,代码来源:plugin_loader.py

示例5: finish_populating_tform_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_tform_popup(form, popup):
        idaapi.attach_action_to_popup(form, popup, "Find", "IDAngr/")
        idaapi.attach_action_to_popup(form, popup, "Avoid", "IDAngr/")
        idaapi.attach_action_to_popup(form, popup, "Symbolic", "IDAngr/") 
开发者ID:andreafioraldi,项目名称:IDAngr,代码行数:6,代码来源:main_gui.py

示例6: finish_populating_tform_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_tform_popup(self, form, popup):
        # TODO - Attach to the functions view.
        # if idaapi.get_tform_type(form) == idaapi.BWN_FUNCS:
        #     idaapi.attach_action_to_popup(
        #         form, popup, "my:disasmsaction", None)

        # Attach to the disassembler view only
        if idaapi.get_tform_type(form) == idaapi.BWN_DISASMS:
            idaapi.attach_action_to_popup(
                form, popup, "my:disasmsaction", None)
            idaapi.attach_action_to_popup(
                form, popup, "my:disasmtracker", None)
            idaapi.attach_action_to_popup(
                form, popup, "my:invalidatecache", None) 
开发者ID:Cisco-Talos,项目名称:GhIDA,代码行数:16,代码来源:ghida.py

示例7: _attach_to_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def _attach_to_popup(self, action_name):
        idaapi.attach_action_to_popup(self.GetTCustomControl(), None, action_name) 
开发者ID:tmr232,项目名称:Sark,代码行数:4,代码来源:lca.py

示例8: idaview_hooks

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def idaview_hooks(idaview_handler):
    class Hooks(idaapi.UI_Hooks):
        def finish_populating_widget_popup(self, form, popup):
            if idaapi.get_widget_type(form) == idaapi.BWN_DISASM:
                idaapi.attach_action_to_popup(form, popup, idaview_handler.get_name(), "")

    return Hooks 
开发者ID:tmr232,项目名称:Sark,代码行数:9,代码来源:lca.py

示例9: finish_populating_widget_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_widget_popup(self, form, popup):
        # Or here, after the popup is done being populated by its owner.

        if idaapi.get_widget_type(form) == idaapi.BWN_DISASM:
            idaapi.attach_action_to_popup(form, popup, ShowXrefsGraphFrom.get_name(), '')
            idaapi.attach_action_to_popup(form, popup, ShowXrefsGraphTo.get_name(), '') 
开发者ID:tmr232,项目名称:Sark,代码行数:8,代码来源:xrefsgraph.py

示例10: finish_populating_widget_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_widget_popup(self, form, popup):
        # Or here, after the popup is done being populated by its owner.

        if idaapi.get_widget_type(form) == idaapi.BWN_DISASM:
            idaapi.attach_action_to_popup(form, popup, MarkReachableNodesHandler.get_name(), "Mark/")
            idaapi.attach_action_to_popup(form, popup, MarkUnReachableNodesHandler.get_name(), "Mark/")
            idaapi.attach_action_to_popup(form, popup, MarkReachingNodesHandler.get_name(), "Mark/")
            idaapi.attach_action_to_popup(form, popup, MarkNotReachingNodesHandler.get_name(), "Mark/")
            idaapi.attach_action_to_popup(form, popup, MarkExits.get_name(), "Mark/")
            idaapi.attach_action_to_popup(form, popup, MarkClearHandler.get_name(), "Mark/") 
开发者ID:tmr232,项目名称:Sark,代码行数:12,代码来源:function_flow.py

示例11: finish_populating_widget_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_widget_popup(self, form, popup):
        idaapi.attach_action_to_popup(form, popup, 'my:expand', None)
        idaapi.attach_action_to_popup(form, popup, 'my:translate', None) 
开发者ID:cea-sec,项目名称:miasm,代码行数:5,代码来源:symbol_exec.py

示例12: finish_populating_widget_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_widget_popup(self, form, popup):
        idaapi.attach_action_to_popup(form, popup, "mkYARA:generate_loose_yara", "mkYARA/")
        idaapi.attach_action_to_popup(form, popup, "mkYARA:generate_normal_yara", "mkYARA/")
        idaapi.attach_action_to_popup(form, popup, "mkYARA:generate_strict_yara", "mkYARA/")
        idaapi.attach_action_to_popup(form, popup, "mkYARA:generate_data_yara", "mkYARA/") 
开发者ID:fox-it,项目名称:mkYARA,代码行数:7,代码来源:mkyara_plugin.py

示例13: finish_populating_widget_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_widget_popup(self, form, popup):
        form_type = idaapi.get_widget_type(form)

        if form_type == idaapi.BWN_DISASM or form_type == idaapi.BWN_DUMP:
            t0, t1, view = idaapi.twinpos_t(), idaapi.twinpos_t(), idaapi.get_current_viewer()
            if idaapi.read_selection(view, t0, t1) or idc.get_item_size(idc.get_screen_ea()) > 1:
                idaapi.attach_action_to_popup(form, popup, ACTION_XORDATA, None)
                idaapi.attach_action_to_popup(form, popup, ACTION_FILLNOP, None)
                for action in ACTION_CONVERT:
                    idaapi.attach_action_to_popup(form, popup, action, "Convert/")

        if form_type == idaapi.BWN_DISASM and (ARCH, BITS) in [(idaapi.PLFM_386, 32),
                                                               (idaapi.PLFM_386, 64),
                                                               (idaapi.PLFM_ARM, 32),]:
            idaapi.attach_action_to_popup(form, popup, ACTION_SCANVUL, None) 
开发者ID:L4ys,项目名称:LazyIDA,代码行数:17,代码来源:LazyIDA.py

示例14: finish_populating_tform_popup

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def finish_populating_tform_popup(self, form, popup):
        #formtype = idaapi.get_tform_type(form)

        #if formtype == idaapi.BWN_DISASM or idaapi.BWN_DUMP:

        for action, position, condition in self.popups:
            if condition(form):
                idaapi.attach_action_to_popup(form, popup, action, position) 
开发者ID:Tekiter,项目名称:WatchDBG-IDA,代码行数:10,代码来源:util.py

示例15: cb

# 需要导入模块: import idaapi [as 别名]
# 或者: from idaapi import attach_action_to_popup [as 别名]
def cb(event, *args):
    if event == ida_hexrays.hxe_populating_popup:
        widget, phandle, vu = args
        res = idaapi.attach_action_to_popup(vu.ct, None, ACTION_NAME)

    return 0 
开发者ID:fireeye,项目名称:flare-ida,代码行数:8,代码来源:stack_strings_helper.py


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