Esempio n. 1
0
 def build_rule(self):
     pprcj = ProcessorPipeline.required_config.jit
     return JitCrashCategorizeRule(
         dump_field=pprcj.dump_field.default,
         command_pathname=pprcj.command_pathname.default,
         command_line=pprcj.command_line.default,
         kill_timeout=5)
    def get_ruleset(self, config):
        """Generate rule set for Mozilla crash processing.

        :arg config: configman DotDict config instance

        :returns: pipeline of rules

        """
        return [
            # fix the raw crash removing null characters
            DeNullRule(),
            # rules to change the internals of the raw crash
            ProductRewrite(),
            ESRVersionRewrite(),
            PluginContentURL(),
            PluginUserComment(),
            # rules to transform a raw crash into a processed crash
            IdentifierRule(),
            MinidumpSha256Rule(),
            BreakpadStackwalkerRule2015(
                dump_field=config.breakpad.dump_field,
                symbols_urls=config.breakpad.symbols_urls,
                command_line=config.breakpad.command_line,
                command_pathname=config.breakpad.command_pathname,
                kill_timeout=config.breakpad.kill_timeout,
                symbol_tmp_path=config.breakpad.symbol_tmp_path,
                symbol_cache_path=config.breakpad.symbol_cache_path,
                tmp_storage_path=config.breakpad.tmp_storage_path),
            ProductRule(),
            UserDataRule(),
            EnvironmentRule(),
            PluginRule(),
            AddonsRule(),
            DatesAndTimesRule(),
            OutOfMemoryBinaryRule(),
            JavaProcessRule(),
            MozCrashReasonRule(),
            # post processing of the processed crash
            CrashingThreadRule(),
            CPUInfoRule(),
            OSInfoRule(),
            BetaVersionRule(
                version_string_api=config.betaversion.version_string_api),
            ExploitablityRule(),
            FlashVersionRule(),
            OSPrettyVersionRule(),
            TopMostFilesRule(),
            ThemePrettyNameRule(),
            MemoryReportExtraction(),
            # generate signature now that we've done all the processing it depends on
            SignatureGeneratorRule(),
            # a set of classifiers to help with jit crashes--must be last since it
            # depends on signature generation
            JitCrashCategorizeRule(
                dump_field=config.jit.dump_field,
                command_line=config.jit.command_line,
                command_pathname=config.jit.command_pathname,
                kill_timeout=config.jit.kill_timeout),
        ]