Exemplo n.º 1
0
    def invoke(self, arg, from_tty):
        arg = arg.split()
        try:
            alist, args = getopt.getopt(arg, 'a:')

            for (field, val) in alist:

                if field in '-c':
                    current_runs = True

                if field in '-s':
                    size = int(val)
        except:
            print('[shadow] usage: jeruns [-cs]')
            print('[shadow] options:')
            print('[shadow]    -c           display current runs only')
            print('[shadow]    -s <size>    runs of the given size class only')
            print('[shadow] for example: jeruns -s 256 ')
            return

        shadow.dump_chunks()
Exemplo n.º 2
0
    elif sys.argv[1] == 'jeversion':
        shadow.version()
        shadow.firefox_version()

    elif sys.argv[1] == 'jedump':
        arg = sys.argv[2:]

        if len(arg) == 0:
            path = None
        else:
            path = arg[0]

        shadow.dump_all(path=path)

    elif sys.argv[1] == 'jechunks':
        shadow.dump_chunks()

    elif sys.argv[1] == 'jechunk':
        arg = sys.argv[2:]
        if len(arg) >= 1:
            addr = arg[0]
        else:
            print('[shadow] usage: jechunk <address>')
            print('[shadow] for example: jechunk 0x900000')
            sys.exit(1)

        if addr.startswith('0x'):
            addr = dbg.to_int(addr)
        else:
            addr = dbg.to_int('0x%s' % (addr))
        shadow.dump_chunk(addr)
Exemplo n.º 3
0
        shadow.version()
        shadow.firefox_version()

    elif sys.argv[1] == 'jedump':
        arg = ''

        try:
            arg = sys.argv[2]
            screen = false
        except:
            screen = true

        shadow.dump_all(filename=arg, dump_to_screen=screen)

    elif sys.argv[1] == 'jechunks':
        shadow.dump_chunks()

    elif sys.argv[1] == 'jearenas':
        shadow.dump_arenas()

    elif sys.argv[1] == 'jeruns':
        current_runs = false
        size = 0

        try:

            alist, args = getopt.getopt(sys.argv[2:], 'cs:')

            for (field, val) in alist:

                if field in '-c':
Exemplo n.º 4
0
 def invoke(self, arg, from_tty):
     shadow.dump_chunks(proc=self.proc)
Exemplo n.º 5
0
 def invoke(self, arg, from_tty):
     shadow.dump_chunks(proc = self.proc)