def main(): parser = optparse.OptionParser() if ( len ( sys.argv ) <= 1 ): print("usage: vbadump: file") sys.exit(1) # prepare for supporting more options options, args = parser.parse_args() params = globals.Params() container = ole.OleContainer( args[ 0 ], params ) container.read() root = container.getRoot() vba = VBAContainer( root ) vba.dump() exit(0)
def main(args): params = globals.Params() dumper = DOCDumper(args[1], params) dumper.dump()