|i dZdZddlZddlZddlZejejeje Z ejej e dZ e ejvrej de ddlZddlmZddlmZddlmZdZd Zed kr edSdS) aV olemeta.py olemeta is a script to parse OLE files such as MS Office documents (e.g. Word, Excel), to extract all standard properties present in the OLE file. Usage: olemeta.py olemeta project website: http://www.decalage.info/python/olemeta olemeta is part of the python-oletools package: http://www.decalage.info/python/oletools z0.54Nz..)xglob) tablestream)ensure_stdout_handles_unicodec8|}ttdtjddgddg}|jD]/}t ||}||||gddg0|td td tjddgddg}|j D]/}t ||}||||gddg0|dS) Nz.Properties from the SummaryInformation stream:PropertyValue) header_rowyellow)colorsz6Properties from the DocumentSummaryInformation stream:) get_metadatarprintr TableStreamSUMMARY_ATTRIBSgetattr write_rowcloseDOCSUM_ATTRIBS)olemetatpropvalues >C:\PYTHON\_runtimes\venv\Lib\site-packages\oletools/olemeta.py process_olerWs<     D"### :;;;Rj'5JKKKA$ @ @d##   KKu tX.>K ? ? ?GGIII "III BCCCRj'5JKKKA# @ @d##   KKu tX.>K ? ? ?GGIIIIIctdtztdtdd}tj|}|dddd |d d d ddd|dddddd|\}}t |dkr;tt|tj tj ||j |j|jD]\}}}|r|dr|r|d|n|}tdtd|z|t#j|}nt#j|}t'||dS)Nz1olemeta %s - http://decalage.info/python/oletoolsz3THIS IS WORK IN PROGRESS - Check updates regularly!zGPlease report any issue at https://github.com/decalage2/oletools/issuesz3usage: olemeta [options] [filename2 ...])usagez-r store_true recursivez)find files recursively in subdirectories.)actiondesthelpz-zz--zip zip_passwordstrzhif the file is a zip archive, open all files from it, using the provided password (requires Python 2.6+))r$typedefaultr%z-fz --zipfname zip_fname*zoif the file is a zip archive, file(s) to be opened within the zip. Wildcards * and ? are supported. (default:*)r)r"r&r*/z in zO===============================================================================z FILE: %s )r __version__optparse OptionParser add_option parse_argslen__doc__ print_helpsysexitr iter_filesr"r&r*endswitholefile OleFileIOrr) r parseroptionsargs containerfilenamedata full_namers rmainrBs = KLLL @AAA TUUU AE  " / / /F drSs;  h '""27??27??83L3L#M#MNNgrw||OTBBCC chHOOA{###%%%%%%777777EEEEEE (((Z+++Z zDFFFFFr