选择文件�文件大�最�修改时间�作
[📄] 36r5hq6kq6.74 KB2026-10-03 04:04:28
[📄] assets_ee72a41.php3.45 KB2026-09-30 15:33:41
[📄] dpack.php7.91 KB2026-10-03 05:40:27
[📄] filemanager_rcttbwr.php43.54 KB2026-10-02 09:50:09
[📄] image_3ff7dc4.php5.57 KB2026-09-30 15:27:22
ó zfc @sGdZdZdZdZdZdZdZddlmZ dd l Z dd l Z dd l Z dd l Z dd lZdd lZdd lZdd lZdd lZdd lZydd lZdd lZWnek rëeZZnXd d d d gZdZdZedZdZdZdZdZdZ dZ!dZ"dZ#dZ$dZ%dZ&dZ'dZ(dZ)dZ*dZ+dZ,d Z-d!Z.d"Z/d#Z0d$Z1d%Z2e1Z3e!e"e#e$e'e(e)e%e&e*e+e,f Z4e!e"e)e,fZ5e*e+e,fZ6d&d'd(d)d*d+d,d-fZ7ie8d.6e8d/6e8d)6e9d*6e9d+6e9d(6Z:d0Z;d1Z<d2Z=d3Z>d4Z?d5Z@d6ZAd7ZBdZCd8ZDd9ZEd:ZFd;ZGd<ZHd=ZId>ZJd%ZKd$ZLe jMƒZNeNekrÐe jOƒZNnd?„ZPd@„ZQdA„ZRd=e3dB„ZSdC„ZTdD„ZUedE„ZVe;dFfe<dGfe=dHfe>dIfe?dJfe@dKffeDdLffeEdMffeFeABdNfeAdfeFd ffeGdLffeHdMffeIeBBdNfeBdfeId ffeJdLffeKdMffeLeCBdOfeCdPfeLd fff ZWdQ„ZXd eYfdR„ƒYZZdSeZfdT„ƒYZ[dUeZfdV„ƒYZ\dWeZfdX„ƒYZ]dYeZfdZ„ƒYZ^d[eZfd\„ƒYZ_d]e_fd^„ƒYZ`d_e_fd`„ƒYZadae_fdb„ƒYZbdce_fdd„ƒYZcdee_fdf„ƒYZddgfdh„ƒYZedifdj„ƒYZfdkegfdl„ƒYZhdmegfdn„ƒYZidoegfdp„ƒYZjdqegfdr„ƒYZkd egfds„ƒYZld egfdt„ƒYZmdufdv„ƒYZndwfdx„ƒYZodyeofdz„ƒYZpd{eofd|„ƒYZqd}erfd~„ƒYZsd#Ztd=Zudfd€„ƒYZvd�„ZwemjZd S(‚s,Read from and write to tar format archives. s$Revision: 85213 $s0.9.0s!Lars Gustäbel (lars@gustaebel.de)s$Date$s$Id$s3Gustavo Niemeyer, Niels Gustäbel, Richard Townsend.iÿÿÿÿ(topenNtTarFiletTarInfot is_tarfiletTarErrorsiisustar sustar00idi›t0t1t2t3t4t5t6t7tLtKtStxtgtXiiitpathtlinkpathtsizetmtimetuidtgidtunametgnametatimetctimei i€i`i@i iiiii€i@i iiicCs|| |t|ƒtS(s@Convert a python string to a null-terminated string buffer. (tlentNUL(tstlength((s/usr/lib64/python2.7/tarfile.pytstn¨scCs'|jdƒ}|dkr|S|| S(s?Convert a null-terminated string field to a python string. siÿÿÿÿ(tfind(Rtp((s/usr/lib64/python2.7/tarfile.pytnts­s cCs«|dtdƒkr^y%tt|ƒjƒp1ddƒ}Wq§tk rZtdƒ‚q§XnId}x@tt|ƒdƒD](}|dK}|t||dƒ7}q{W|S(s/Convert a number field to a python number. ii€Risinvalid headerli( tchrtintR$tstript ValueErrortInvalidHeaderErrortxrangeRtord(Rtnti((s/usr/lib64/python2.7/tarfile.pytnti¶s%  cCsòd|kod|dknr?d|d|ft}n¯|tks_|d|dkrntdƒ‚n|dkrŸtjdtjd|ƒƒd}nd }x6t|dƒD]$}t|d @ƒ|}|dL}q¶Wtd ƒ|}|S( s/Convert a python number to a number field. iiis%0*oisoverflow in number fieldR tltiÿi€(Rt GNU_FORMATR(tstructtunpacktpackR*R%(R,tdigitstformatRR-((s/usr/lib64/python2.7/tarfile.pytitnÇs $  %cCs³|dkrŸy|j|dƒSWq¯tk r›g}xU|D]M}y|j|j|dƒƒWq=tk r‰|j|jdƒƒq=Xq=Wdj|ƒSXn|j||ƒSdS(s*Convert a unicode object to a string. sutf-8tstricttutf8R0N(tencodetUnicodeEncodeErrortappendtjoin(RtencodingterrorsRtc((s/usr/lib64/python2.7/tarfile.pytutsâs    cCsxdttjd|d ƒtjd|dd!ƒƒ}dttjd|d ƒtjd|dd!ƒƒ}||fS( s¨Calculate the checksum for a member's header by summing up all characters except for the chksum field which is treated as if it was filled with spaces. According to the GNU tar sources, some tars (Sun and NeXT) calculate chksum with signed char, which will be different if there are chars in the buffer with the high bit set. So we calculate two checksums, unsigned and signed. it148Bi”t356Biœit148bt356b(tsumR2R3(tbuftunsigned_chksumt signed_chksum((s/usr/lib64/python2.7/tarfile.pyt calc_chksumsös 77cCsï|dkrdS|dkr0tj||ƒdSd}t||ƒ\}}xQt|ƒD]C}|j|ƒ}t|ƒ|krŽtdƒ‚n|j|ƒqXW|dkrë|j|ƒ}t|ƒ|krÛtdƒ‚n|j|ƒndS(sjCopy length bytes from fileobj src to fileobj dst. If length is None, copy the entire content. iNiisend of file reachedi@( tNonetshutilt copyfileobjtdivmodR*treadRtIOErrortwrite(tsrctdstR tBUFSIZEtblockst remaindertbRG((s/usr/lib64/python2.7/tarfile.pyRMs$   R/t-RWtdR@R#trtwRtttTcCsig}xStD]K}xB|D]-\}}||@|kr|j|ƒPqqW|jdƒq Wdj|ƒS(scConvert a file's mode to a string of the form -rwxrwxrwx. Used by TarFile.list() RXR0(tfilemode_tableR<R=(tmodetpermttabletbittchar((s/usr/lib64/python2.7/tarfile.pytfilemode7s  cBseZdZRS(sBase exception.(t__name__t __module__t__doc__(((s/usr/lib64/python2.7/tarfile.pyRFst ExtractErrorcBseZdZRS(s%General exception for extract errors.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRhIst ReadErrorcBseZdZRS(s&Exception for unreadable tar archives.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRiLstCompressionErrorcBseZdZRS(s.Exception for unavailable compression methods.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRjOst StreamErrorcBseZdZRS(s=Exception for unsupported operations on stream-like TarFiles.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRkRst HeaderErrorcBseZdZRS(s!Base exception for header errors.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRlUstEmptyHeaderErrorcBseZdZRS(sException for empty headers.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRmXstTruncatedHeaderErrorcBseZdZRS(s Exception for truncated headers.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRn[stEOFHeaderErrorcBseZdZRS(s"Exception for end of file headers.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRo^sR)cBseZdZRS(sException for invalid headers.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyR)astSubsequentHeaderErrorcBseZdZRS(s3Exception for missing and invalid extended headers.(ReRfRg(((s/usr/lib64/python2.7/tarfile.pyRpdst _LowLevelFilecBs2eZdZd„Zd„Zd„Zd„ZRS(s‰Low-level file object. Supports reading and writing. It is used instead of a regular file object for streaming access. cCsgitjd6tjtjBtjBd6|}ttdƒrK|tjO}ntj||dƒ|_dS(NRZR[tO_BINARYi¶( tostO_RDONLYtO_WRONLYtO_CREATtO_TRUNCthasattrRrRtfd(tselftnameR_((s/usr/lib64/python2.7/tarfile.pyt__init__qs cCstj|jƒdS(N(RstcloseRy(Rz((s/usr/lib64/python2.7/tarfile.pyR}zscCstj|j|ƒS(N(RsRORy(RzR((s/usr/lib64/python2.7/tarfile.pyRO}scCstj|j|ƒdS(N(RsRQRy(RzR((s/usr/lib64/python2.7/tarfile.pyRQ€s(ReRfRgR|R}RORQ(((s/usr/lib64/python2.7/tarfile.pyRqks   t_StreamcBs€eZdZd„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z d d „Z dd „Z d „Zd „ZRS(s˜Class that serves as an adapter between TarFile and a stream-like object. The stream-like object only needs to have a read() or write() method and is accessed blockwise. Use of gzip or bzip2 compression is possible. A stream-like object could be for example: sys.stdin, sys.stdout, a socket, a tape device etc. _Stream is intended to be used only internally. cCsÒt|_|dkr0t||ƒ}t|_n|dkrWt|ƒ}|jƒ}n|p`d|_||_||_ ||_ ||_ d|_ d|_ t|_yú|dkr)yddl}Wntk rãtdƒ‚nX||_|jdƒd@|_|d kr|jƒqž|jƒnu|d kržyddl}Wntk rdtd ƒ‚nX|d krŒd|_|jƒ|_qž|jƒ|_nWn,|js¾|j jƒnt|_‚nXdS( s$Construct a _Stream object. t*R0ltgziÿÿÿÿNszlib module is not availablelÿÿRZtbz2sbz2 module is not available(tTruet _extfileobjRKRqtFalset _StreamProxyt getcomptypeR{R_tcomptypetfileobjtbufsizeRGtpostclosedtzlibt ImportErrorRjtcrc32tcrct _init_read_gzt_init_write_gzR�tdbuftBZ2Decompressortcmpt BZ2CompressorR}(RzR{R_R‡RˆR‰RŒR�((s/usr/lib64/python2.7/tarfile.pyR|ŽsP                        cCs*t|dƒr&|j r&|jƒndS(NR‹(RxR‹R}(Rz((s/usr/lib64/python2.7/tarfile.pyt__del__ÂscCsÐ|jjd|jj|jj |jjdƒ|_tjdtt j ƒƒƒ}|j d|ƒt |j ƒt kr“|j jddƒ|_ n|j jdƒr¸|j d |_ n|j |j tƒd S( s6Initialize for writing with gzip compression. i is(t __class__ReR{tid(Rz((s/usr/lib64/python2.7/tarfile.pyt__repr__ÉscCs i |jd6|jd@d6|jd6|jd6|jd6|jd6|jd6|jd 6|jd 6|j d 6|j d 6|j d 6|j d6}|d t krÃ|djdƒ rÃ|dcd7R?tinfotkey((s/usr/lib64/python2.7/tarfile.pytget_infoÌs(            $ !R8cCss|j||ƒ}|tkr+|j|ƒS|tkrD|j|ƒS|tkrc|j|||ƒStdƒ‚dS(s<Return a tar header as a string of 512 byte blocks. sinvalid formatN(Rèt USTAR_FORMATtcreate_ustar_headerR1tcreate_gnu_headert PAX_FORMATtcreate_pax_headerR((RzR6R>R?Ræ((s/usr/lib64/python2.7/tarfile.pyttobufès     cCsyt|dn||j||ƒ}y|jd ƒWntk r¦|||nXt||ƒ|kr>|||q>Wx—ddddfD]ƒ\}} ||kr d||R?RÜR{thnameR tvalR5RG((s/usr/lib64/python2.7/tarfile.pyRís6       4cCs|j|dtƒS(sAReturn the object as a pax global header block sequence. RŸ(RþtXGLTYPE(tclsRÜ((s/usr/lib64/python2.7/tarfile.pytcreate_pax_global_headerDscCs�|td }x$|r4|ddkr4|d }qW|t|ƒ}|d }| sht|ƒtkrwtdƒ‚n||fS(sUSplit a name longer than 100 chars into a prefix and a name part. iiÿÿÿÿRäsname is too long(t LENGTH_PREFIXRRóR((RzR{Rð((s/usr/lib64/python2.7/tarfile.pyRôJs cCs»t|jddƒdƒt|jddƒd@d|ƒt|jddƒd|ƒt|jd dƒd|ƒt|jd dƒd |ƒt|jd dƒd |ƒd |jdtƒt|jddƒdƒt|jdtƒdƒt|jddƒdƒt|jddƒdƒt|jddƒd|ƒt|jddƒd|ƒt|jddƒdƒg}tjdtdj|ƒƒ}t |t ƒd}|d d||d}|S(s„Return a header block. info is a dictionary with file information, format must be one of the *_FORMAT constants. R{R0idR_iiÿiRRRi Rs RŸRÙRïRi RRÚRÛRði›s%dsi”þÿÿs%06oi›þÿÿ( R!tgetR7RØRñR2R4R°R=RJ(RæR6tpartsRGR×((s/usr/lib64/python2.7/tarfile.pyRõYs&cCs@tt|ƒtƒ\}}|dkr<|t|t7}n|S(sdReturn the string payload filled with zero bytes up to the next 512 byte border. i(RNRR°R(tpayloadRURV((s/usr/lib64/python2.7/tarfile.pyt_create_payloadus cCs[|t7}i}d|d<||d|j|ƒS|jtttfkrc|j |ƒS|j |ƒSdS(sYChoose the right processing method depending on the type and call it. N( RŸRùRøt _proc_gnulongtGNUTYPE_SPARSEt _proc_sparsetXHDTYPERtSOLARIS_XHDTYPEt _proc_paxt _proc_builtin(RzRÊ((s/usr/lib64/python2.7/tarfile.pyRós   cCsx|jjƒ|_|j}|jƒs6|jtkrO||j|jƒ7}n||_|j |j |j |j ƒ|S(sfProcess a builtin type or an unknown type which will be treated as a regular file. ( RˆR«RÈtisregRŸtSUPPORTED_TYPESt_blockRR»t_apply_pax_infoRÜR>R?(RzRÊR»((s/usr/lib64/python2.7/tarfile.pyRs  cCs£|jj|j|jƒƒ}y|j|ƒ}Wntk rPtdƒ‚nX|j|_|jt kr~t |ƒ|_ n!|jt krŸt |ƒ|_ n|S(sSProcess the blocks that hold a GNU longname or longlink member. s missing or bad subsequent header(RˆROR RRRlRpR»RŸRùR$R{RøRÙ(RzRÊRGtnext((s/usr/lib64/python2.7/tarfile.pyRs  c Css|j}tƒ}d}d}d}x¿tdƒD]±}y6t|||d!ƒ}t||d|d!ƒ} Wntk r�PnX||kr«|jt|||ƒƒn|jt|| |ƒƒ|| 7}|| }|d7}q1Wt|dƒ} t|dd!ƒ} xú| d kr|j j t ƒ}d }x¿td ƒD]±}y6t|||d!ƒ}t||d|d!ƒ} Wntk r�PnX||kr·|jt|||ƒƒn|jt|| |ƒƒ|| 7}|| }|d7}q=Wt|d ƒ} q W|| kr/|jt|| |ƒƒn||_ |j j ƒ|_|j|j|jƒ|_| |_|S( s8Process a GNU sparse header plus extra headers. i‚lii iiâiãiïiiiiø(RGt _ringbufferR*R.R(R<t_holeRÄR+RˆROR°R¼R«RÈR RR»( RzRÊRGtspRŠtlastposRÅR-R»tnumbytest isextendedtorigsize((s/usr/lib64/python2.7/tarfile.pyR'sT             c Csë|jj|j|jƒƒ}|jtkr9|j}n|jjƒ}tj dtj ƒ}d}x¼t r!|j ||ƒ}|sˆPn|j ƒ\}}t|ƒ}|dkrÁtdƒ‚n||jdƒd|jdƒ|d!} |jdƒ}| jdƒ} | ||<||7}qfWy|j|ƒ} Wntk rTtdƒ‚nX|jttfkrç| j||j|jƒ|j| _d|krç| j} | jƒs¿| jtkrØ| | j| jƒ7} n| |_qçn| S( sVProcess an extended or global header as described in POSIX.1-2001. s(\d+) ([^=]+)=isinvalid headeriiR9s missing or bad subsequent headerR(RˆROR RRŸRRÜRûtretcompiletUR‚tmatchtgroupsR&R)tendtstartRüRRlRpRRR!R>R?R»RÈRR( RzRÊRGRÜtregexRŠR-R R R R"R»((s/usr/lib64/python2.7/tarfile.pyR_s@    +     cCs¿x©|jƒD]›\}}|tkr+q n|dkrI|jdƒ}n|tkr†yt||ƒ}Wq˜tk r‚d}q˜Xnt|||ƒ}t|||ƒq W|jƒ|_dS(soReplace fields with supplemental information from a previous pax extended or global header. RRäiN( R t PAX_FIELDSRtPAX_NUMBER_FIELDSR(RAtsetattrRûRÜ(RzRÜR>R?R R ((s/usr/lib64/python2.7/tarfile.pyR!›s     cCs0t|tƒ\}}|r(|d7}n|tS(s_Round up a byte count by BLOCKSIZE and return it, e.g. _block(834) => 1024. i(RNR°(RzRRURV((s/usr/lib64/python2.7/tarfile.pyR ²s cCs |jtkS(N(RŸt REGULAR_TYPES(Rz((s/usr/lib64/python2.7/tarfile.pyR»scCs |jƒS(N(R(Rz((s/usr/lib64/python2.7/tarfile.pytisfile½scCs |jtkS(N(RŸRå(Rz((s/usr/lib64/python2.7/tarfile.pyR¿scCs |jtkS(N(RŸtSYMTYPE(Rz((s/usr/lib64/python2.7/tarfile.pytissymÁscCs |jtkS(N(RŸtLNKTYPE(Rz((s/usr/lib64/python2.7/tarfile.pytislnkÃscCs |jtkS(N(RŸtCHRTYPE(Rz((s/usr/lib64/python2.7/tarfile.pytischrÅscCs |jtkS(N(RŸtBLKTYPE(Rz((s/usr/lib64/python2.7/tarfile.pytisblkÇscCs |jtkS(N(RŸtFIFOTYPE(Rz((s/usr/lib64/python2.7/tarfile.pytisfifoÉscCs |jtkS(N(RŸR(Rz((s/usr/lib64/python2.7/tarfile.pytissparseËscCs|jtttfkS(N(RŸR;R=R?(Rz((s/usr/lib64/python2.7/tarfile.pytisdevÍs(/ReRfRgR|RÝRÞtpropertyRRßRàRRãRètDEFAULT_FORMATtENCODINGRîRêRëRít classmethodRRôt staticmethodRõRR÷RRþRRRRRRRR!R RR6RR8R:R<R>R@RARB(((s/usr/lib64/python2.7/tarfile.pyRœsP         3  .   8 <          c BsHeZdZdZeZeZdZeZ e Z d2Z eZeZd2dd2d2d2d2d2d2d2d2d2d2d„ Zd„Zd„ZeeeƒZed2dd2ed„ƒZedd2d„ƒZedd2d d „ƒZedd2d d „ƒZid d 6dd6dd6Zd„Zd„Zd„Z d„Z!d2d2d2d„Z"e#d„Z$d2e#d2d2d„Z%d2d„Z&dd2d„Z'dd„Z(d„Z)d„Z*d „Z+d!„Z,d"„Z-d#„Z.d$„Z/d%„Z0d&„Z1d'„Z2d(„Z3d)„Z4d2ed*„Z5d+„Z6d2d,„Z7d-„Z8d.„Z9d/„Z:d0„Z;d1„Z<RS(3s=The TarFile Class provides an interface to tar archives. iiRZc CsÒidd6dd6dd6} || kr6tdƒ‚n||_| ||_|s§|jdkr‰tjj|ƒ r‰d|_d|_nt||jƒ}t|_nN|d krÎt |dƒrÎ|j }nt |d ƒrì|j|_nt |_|r tjj |ƒnd |_ ||_|d k r7||_n|d k rO||_n|d k rg||_n|d k r||_n|d k r—||_n| d k r¯| |_n!|dkrÇd |_n d |_| d k r÷|jtkr÷| |_n i|_| d k r| |_n| d k r0| |_nt|_g|_t|_|jjƒ|_i|_y9|jdkr“d |_|j ƒ|_n|jdkr7x’t r3|jj!|jƒy&|jj"|ƒ}|jj#|ƒWq¥t$k r |jj!|jƒPq¥t%k r/}t&t'|ƒƒ‚q¥Xq¥Wn|jd kržt |_|jrž|jj(|jj)ƒƒ}|jj*|ƒ|jt+|ƒ7_qžnWn,|js¾|jj,ƒnt |_‚nXd S(sÖOpen an (uncompressed) tar archive `name'. `mode' is either 'r' to read from an existing archive, 'a' to append data to an existing file or 'w' to create a new file overwriting an existing one. `mode' defaults to 'r'. If `fileobj' is given, it is used for reading or writing data. If it can be determined, `mode' is overridden by `fileobj's mode. `fileobj' is not closed, when TarFile is closed. trbRZsr+btatwbR[smode must be 'r', 'a' or 'w'R{R_sutf-8R8tawN(-R(R_t_modeRsRtexistst bltn_openR„RƒRKRxR{R‚tabspathRˆR6RËt dereferencet ignore_zerosR>R?RìRÜtdebugt errorlevelR‹tmemberst_loadedR«R»tinodest firstmemberR"R¬RR<RoRlRiR RRûRQRR}(RzR{R_RˆR6RËRPRQR>R?RÜRRRStmodesteRG((s/usr/lib64/python2.7/tarfile.pyR|ësŽ    "     !                                 cCs |jtkS(N(R6Ré(Rz((s/usr/lib64/python2.7/tarfile.pyt _getposixRscCs>ddl}|jdtdƒ|r1t|_n t|_dS(Niÿÿÿÿs use the format attribute insteadi(twarningstwarntDeprecationWarningRéR6R1(RzR R[((s/usr/lib64/python2.7/tarfile.pyt _setposixTs    c sO| r| rtdƒ‚n|dkrê‡fd†}x tˆjd|ƒD]‰}tˆˆj|ƒ}|dk r…|jƒ} ny||d||�SWqNttfk rÖ} |dk rN|j| ƒqNqNqNXqNWtdƒ‚nUd|krq|j ddƒ\} }| pd} |p#d }|ˆjkrNtˆˆj|ƒ}ntd |ƒ‚||| ||�Sd |kr|j d dƒ\} }| pžd} |pªd }| dkrÈtd ƒ‚nt || |||ƒ} yˆ|| | |�} Wn| j ƒ‚nXt | _ | S|dkr?ˆj||||�Stdƒ‚dS(s|Open a tar archive for reading, writing or appending. Return an appropriate TarFile class. mode: 'r' or 'r:*' open for reading with transparent compression 'r:' open for reading exclusively uncompressed 'r:gz' open for reading with gzip compression 'r:bz2' open for reading with bzip2 compression 'a' or 'a:' open for appending, creating the file if necessary 'w' or 'w:' open for writing without compression 'w:gz' open for writing with gzip compression 'w:bz2' open for writing with bzip2 compression 'r|*' open a stream of tar blocks with transparent compression 'r|' open an uncompressed stream of tar blocks for reading 'r|gz' open a gzip compressed stream of tar blocks 'r|bz2' open a bzip2 compressed stream of tar blocks 'w|' open an uncompressed stream for writing 'w|gz' open a gzip compressed stream for writing 'w|bz2' open a bzip2 compressed stream for writing snothing to openRZsr:*csˆj|dkS(Nttaropen(t OPEN_METH(R‡(R(s/usr/lib64/python2.7/tarfile.pytnot_compressed†sRçs%file could not be opened successfullyt:iR£sunknown compression type %rt|R[smode must be 'r' or 'w'RIsundiscernible modeN(RZsr:*(RZR[(RIR[(R(tsortedR`R´RKR«RiRjR¬tsplitR~R}R„RƒR_(RR{R_RˆR‰tkwargsRaR‡tfunct saved_posRYRdtstreamR\((Rs/usr/lib64/python2.7/tarfile.pyRisP              cKs.|dkrtdƒ‚n|||||�S(sCOpen uncompressed tar archive name for reading or writing. RZRIR[smode must be 'r', 'a' or 'w'(RZRIR[(R((RR{R_RˆRf((s/usr/lib64/python2.7/tarfile.pyR_·s i cKs*|dkrtdƒ‚nyddl}|jWn#ttfk rWtdƒ‚nXy|j||||ƒ}Wn;tk r±|dk r«|dkr«tdƒ‚n‚nXy|j ||||�}WnLt k r |j ƒ|dkrtdƒ‚n‚n|j ƒ‚nXt |_ |S( skOpen gzip compressed tar archive name for reading or writing. Appending is not allowed. RZR[smode must be 'r' or 'w'iÿÿÿÿNsgzip module is not availablesnot a gzip file(RZR[(R(tgziptGzipFileR�tAttributeErrorRjtOSErrorRKRiR_RPR}R„Rƒ(RR{R_Rˆt compresslevelRfRjR\((s/usr/lib64/python2.7/tarfile.pytgzopen¿s2         cKsÿ|d krtdƒ‚nyddl}Wntk rJtdƒ‚nX|dk rit||ƒ}n|j||d|ƒ}y|j||||�}WnRtt fk rÞ|j ƒ|dkrØt dƒ‚n‚n|j ƒ‚nXt |_ |S( slOpen bzip2 compressed tar archive name for reading or writing. Appending is not allowed. RZR[smode must be 'r' or 'w'.iÿÿÿÿNsbz2 module is not availableRnsnot a bzip2 file(RZR[(R(R�R�RjRKR³tBZ2FileR_RPtEOFErrorR}RiR„Rƒ(RR{R_RˆRnRfR�R\((s/usr/lib64/python2.7/tarfile.pytbz2openás*       R_R£RoR€RrR�cCs·|jr dSt|_z€|jdkr•|jjttdƒ|jtd7_t|jt ƒ\}}|dkr•|jjtt |ƒq•nWd|j s²|jj ƒnXdS(slClose the TarFile. In write-mode, two finishing zero blocks are appended to the archive. NRKii( R‹R‚R_RˆRQRR°R»RNt RECORDSIZERƒR}(RzRURV((s/usr/lib64/python2.7/tarfile.pyR} s   " cCs2|j|ƒ}|dkr.td|ƒ‚n|S(sReturn a TarInfo object for member `name'. If `name' can not be found in the archive, KeyError is raised. If a member occurs more than once in the archive, its last occurrence is assumed to be the most up-to-date version. sfilename %r not foundN(t _getmemberRKtKeyError(RzR{RË((s/usr/lib64/python2.7/tarfile.pyt getmembers cCs'|jƒ|js |jƒn|jS(sŽReturn the members of the archive as a list of TarInfo objects. The list has the same order as the members in the archive. (t_checkRUt_loadRT(Rz((s/usr/lib64/python2.7/tarfile.pyt getmembers*s   cCs g|jƒD]}|j^q S(s‹Return the members of the archive as a list of their names. It has the same order as the list returned by getmembers(). (RyR{(RzRË((s/usr/lib64/python2.7/tarfile.pytgetnames4sc Cs\|jdƒ|d k r%|j}n|d kr:|}ntjj|ƒ\}}|jtjdƒ}|jdƒ}|j ƒ}||_ |d krÔt tdƒrÂ|j rÂtj |ƒ}qétj|ƒ}ntj|jƒƒ}d}|j}tj|ƒr�|j|jf} |j rj|jdkrj| |jkrj||j| krjt} |j| }qt} | dr||j| slink toN(RwRdR_RRRRR<R>RÚRÛRR�t localtimeRR{RR8RÙR:(RztverboseRË((s/usr/lib64/python2.7/tarfile.pytlist�s&      c Csù|jdƒ|dkr"|}n|dk rtddl}|jdtdƒ||ƒrt|jdd|ƒdSn|jdk r¶tjj |ƒ|jkr¶|jdd|ƒdS|jd|ƒ|j ||ƒ}|dkrü|jdd |ƒdS|dk r;||ƒ}|dkr;|jdd|ƒdSn|j ƒrrt |d ƒ�}|j ||ƒWdQXnƒ|jƒrè|j |ƒ|rõxQtj|ƒD]=}|jtjj||ƒtjj||ƒ|||ƒq¡Wqõn |j |ƒdS( s~Add the file `name' to the archive. `name' may be any type of file (directory, fifo, symbolic link, etc.). If given, `arcname' specifies an alternative name for the file in the archive. Directories are added recursively by default. This can be avoided by setting `recursive' to False. `exclude' is a function that should return True for each filename to be excluded. `filter' is a function that expects a TarInfo object argument and returns the changed TarInfo object, if it returns None the TarInfo object will be excluded from the archive. RKiÿÿÿÿNsuse the filter argument insteadistarfile: Excluded %rstarfile: Skipped %ristarfile: Unsupported type %rRH(RwRKR[R\R]t_dbgR{RsRROR�RRNtaddfileRtlistdirtaddR=( RzR{R˜t recursivetexcludetfilterR[RËtf((s/usr/lib64/python2.7/tarfile.pyR¤ºsB        *       *cCsô|jdƒtj|ƒ}|j|j|j|jƒ}|jj|ƒ|jt |ƒ7_|dk ràt ||j|j ƒt |j tƒ\}}|dkrÊ|jjtt|ƒ|d7}n|j|t7_n|jj|ƒdS(smAdd the TarInfo object `tarinfo' to the archive. If `fileobj' is given, tarinfo.size bytes are read from it and added to the archive. You can create TarInfo objects directly, or by using gettarinfo(). On Windows platforms, `fileobj' should always be opened with mode 'rb' to avoid irritation about the file size. RKiiN(RwRûRîR6R>R?RˆRQR»RRKRMRRNR°RRTR<(RzRËRˆRGRURV((s/usr/lib64/python2.7/tarfile.pyR¢÷s    t.cCs3g}|dkr|}nxR|D]J}|jƒr\|j|ƒtj|ƒ}d|_n|j||ƒq"W|jdtjdƒƒ|j ƒx™|D]‘}t j j ||j ƒ}y4|j||ƒ|j||ƒ|j||ƒWqštk r*}|jdkr‚q+|jdd|ƒqšXqšWdS(sMExtract all members from the archive to the current working directory and set owner, modification time and permissions on directories afterwards. `path' specifies a different directory to extract to. `members' is optional and must be a subset of the list returned by getmembers(). iÀRçR{is tarfile: %sN(RKRR<RûR_textracttsorttoperatort attrgettertreverseRsRR=R{tchowntutimetchmodRhRSR¡(RzRRTt directoriesRËtdirpathRY((s/usr/lib64/python2.7/tarfile.pyt extractalls*        R0cCs7|jdƒt|tƒr.|j|ƒ}n|}|jƒr^tjj||jƒ|_ ny&|j |tjj||j ƒƒWn¬t k r÷}|j dkr«‚q3|jdkrÔ|jdd|jƒq3|jdd|j|jfƒn<tk r2}|j dkr‚q3|jdd|ƒnXdS(s#Extract a member from the archive to the current working directory, using its full name. Its file information is extracted as accurately as possible. `member' may be a filename or a TarInfo object. You can specify a different directory using `path'. RZiis tarfile: %sstarfile: %s %rN(RwRÃt basestringRvR:RsRR=RÙt _link_targett_extract_memberR{tEnvironmentErrorRStfilenameRKR¡tstrerrorRh(RztmemberRRËRY((s/usr/lib64/python2.7/tarfile.pyRª6s$  &#cCsÉ|jdƒt|tƒr.|j|ƒ}n|}|jƒrP|j||ƒS|jtkro|j||ƒS|jƒs‡|j ƒrÁt|j t ƒr¨t dƒ‚qÅ|j |j|ƒƒSndSdS(sëExtract a member from the archive as a file object. `member' may be a filename or a TarInfo object. If `member' is a regular file, a file-like object is returned. If `member' is a link, a file-like object is constructed from the link's target. If `member' is none of the above, None is returned. The file-like object is read-only and provides the following methods: read(), readline(), readlines(), seek() and tell() RZs'cannot extract (sym)link as file objectN(RwRÃRµRvRt fileobjectRŸRR:R8RˆR~Rkt extractfilet_find_link_targetRK(RzR»RË((s/usr/lib64/python2.7/tarfile.pyR½Ws  cCsÕ|jdƒ}|jdtjƒ}tjj|ƒ}|r_tjj|ƒ r_tj|ƒn|jƒsw|j ƒrš|j dd|j |j fƒn|j d|j ƒ|j ƒrÌ|j||ƒnÆ|jƒrë|j||ƒn§|jƒr |j||ƒnˆ|jƒs"|jƒr5|j||ƒn]|jƒsM|j ƒr`|j||ƒn2|jtkr‚|j||ƒn|j||ƒ|j||ƒ|j ƒsÑ|j||ƒ|j||ƒndS(s\Extract the TarInfo object tarinfo to a physical file called targetpath. Räis%s -> %sN(RR—RsRRtdirnameRMtmakedirsR:R8R¡R{RÙRtmakefileRtmakedirR@tmakefifoR<R>tmakedevtmakelinkRŸRt makeunknownR¯R±R°(RzRËt targetpatht upperdirs((s/usr/lib64/python2.7/tarfile.pyR·}s2#    cCsFytj|dƒWn+tk rA}|jtjkrB‚qBnXdS(s,Make a directory called targetpath. iÀN(RstmkdirR¸terrnotEEXIST(RzRËRÇRY((s/usr/lib64/python2.7/tarfile.pyR¬s cCsJ|j|ƒ}z)t|dƒ�}t||ƒWdQXWd|jƒXdS(s'Make a file called targetpath. RJN(R½RNRMR}(RzRËRÇtsourcettarget((s/usr/lib64/python2.7/tarfile.pyRÁ·s cCs+|j||ƒ|jdd|jƒdS(sYMake a file from a TarInfo object with an unknown type at targetpath. is9tarfile: Unknown file type %r, extracted as regular file.N(RÁR¡RŸ(RzRËRÇ((s/usr/lib64/python2.7/tarfile.pyRÆÁs cCs/ttdƒrtj|ƒn tdƒ‚dS(s'Make a fifo called targetpath. tmkfifosfifo not supported by systemN(RxRsRÎRh(RzRËRÇ((s/usr/lib64/python2.7/tarfile.pyRÃÉscCsŠttdƒ s ttdƒ r/tdƒ‚n|j}|jƒrT|tjO}n |tjO}tj||tj |j |j ƒƒdS(s<Make a character or block device called targetpath. tmknodRÄs'special devices not supported by systemN( RxRsRhR_R>R�tS_IFBLKtS_IFCHRRÏRÄRÚRÛ(RzRËRÇR_((s/usr/lib64/python2.7/tarfile.pyRÄÑs     cCs ttdƒrËttdƒrË|jƒrbtjj|ƒrLtj|ƒntj|j|ƒqtjj|j ƒr¯tjj|ƒr™tj|ƒntj |j |ƒq|j |j |ƒ|ƒn=y|j |j |ƒ|ƒWnt k rtdƒ‚nXdS(sµMake a (symbolic) link called targetpath. If it cannot be created (platform limitation), we try to make a copy of the referenced file instead of a link. tsymlinktlinks%unable to resolve link inside archiveN(RxRsR8RtlexiststunlinkRÒRÙRMR¶RÓR·R¾RuRh(RzRËRÇ((s/usr/lib64/python2.7/tarfile.pyRÅàs  cCstrttdƒrtjƒdkrytj|jƒd}Wntk r]|j}nXytj |j ƒd}Wntk r”|j }nXyZ|j ƒrÉttdƒrÉtj |||ƒn%tjdkrîtj|||ƒnWqtk r}tdƒ‚qXndS(s6Set owner of targetpath according to tarinfo. tgeteuidiitlchowntos2emxscould not change ownerN(R“RxRsRÖR•tgetgrnamRRuRtgetpwnamRRR8R×tsystplatformR¯R¸Rh(RzRËRÇRtuRY((s/usr/lib64/python2.7/tarfile.pyR¯ùs '    cCsOttdƒrKytj||jƒWqKtk rG}tdƒ‚qKXndS(sASet file permissions of targetpath according to tarinfo. R±scould not change modeN(RxRsR±R_R¸Rh(RzRËRÇRY((s/usr/lib64/python2.7/tarfile.pyR± s cCsYttdƒsdSy tj||j|jfƒWntk rT}tdƒ‚nXdS(sBSet modification time of targetpath according to tarinfo. R°Ns"could not change modification time(RxRsR°RR¸Rh(RzRËRÇRY((s/usr/lib64/python2.7/tarfile.pyR° s  cCs%|jdƒ|jdk r2|j}d|_|S|j|jjƒkr…|jj|jdƒ|jjdƒs…tdƒ‚q…nd}xkt røy|j j |ƒ}WnGt k rú}|j rô|jdd|j|fƒ|jt7_qŽqônútk rk}|j rD|jdd|j|fƒ|jt7_qŽqô|jdkrôtt|ƒƒ‚qôn‰tk r™|jdkrôtdƒ‚qôn[tk rÏ}|jdkrôtt|ƒƒ‚qôn%tk ró}tt|ƒƒ‚nXPqŽW|dk r|jj|ƒn t |_|S( s¨Return the next member of the archive as a TarInfo object, when TarFile is opened for reading. Return None if there is no more available. traisunexpected end of datais0x%X: %sis empty fileN(RwRWRKR»RˆR«R¬RORiR‚RËRRoRQR¡R°R)R RmRnRpRTR<RU(RztmRËRY((s/usr/lib64/python2.7/tarfile.pyR"# sL          cCs›|jƒ}|dk r.||j|ƒ }n|rItjj|ƒ}nxKt|ƒD]=}|rztjj|jƒ}n |j}||krV|SqVWdS(s}Find an archive member by name from bottom to top. If tarinfo is given, it is used as the starting point. N(RyRKtindexRsRtnormpathtreversedR{(RzR{RËt normalizeRTR»t member_name((s/usr/lib64/python2.7/tarfile.pyRtY s    cCs6x&tr(|jƒ}|dkrPqqWt|_dS(sWRead through the entire archive file and look for readable members. N(R‚R"RKRU(RzRË((s/usr/lib64/python2.7/tarfile.pyRxp s    cCsW|jr"td|jjƒ‚n|dk rS|j|krStd|jƒ‚ndS(snCheck if TarFile is still open, and if the operation's mode corresponds to TarFile's mode. s %s is closedsbad operation for mode %rN(R‹RPRáReRKR_(RzR_((s/usr/lib64/python2.7/tarfile.pyRwz s cCs’|jƒrEdjtdtjj|jƒ|jfƒƒ}d}n|j}|}|j |d|dt ƒ}|dkrŽt d|ƒ‚n|S(sZFind the target member of a symlink or hardlink member in the archive. RäRËRãslinkname %r not foundN( R8R=R§RKRsRR¿R{RÙRtR‚Ru(RzRËRÙtlimitR»((s/usr/lib64/python2.7/tarfile.pyR¾ƒ s 0   cCs$|jrt|jƒSt|ƒSdS(s$Provide an iterator object. N(RUtiterRTtTarIter(Rz((s/usr/lib64/python2.7/tarfile.pyRÖ– s  cCs#||jkrtj|IJndS(s.Write debugging output to sys.stderr. N(RRRÛtstderr(Rztleveltmsg((s/usr/lib64/python2.7/tarfile.pyR¡ž scCs|jƒ|S(N(Rw(Rz((s/usr/lib64/python2.7/tarfile.pyt __enter__¤ s cCs?|dkr|jƒn"|js2|jjƒnt|_dS(N(RKR}RƒRˆR‚R‹(RzRŸR t traceback((s/usr/lib64/python2.7/tarfile.pyt__exit__¨ s    N(=ReRfRgRRR„RPRQRSRDR6RER>RKR?RRËRÇR¼R|RZR^RCtposixRFRsRR_RoRrR`R}RvRyRzR�R‚R R¤R¢R´RªR½R·RÂRÁRÆRÃRÄRÅR¯R±R°R"RtRxRwR¾RÖR¡RëRí(((s/usr/lib64/python2.7/tarfile.pyRÑst  e   M!   c = % ! & /      6    RçcBs)eZdZd„Zd„Zd„ZRS(sMIterator Class. for tarinfo in TarFile(...): suite... cCs||_d|_dS(s$Construct a TarIter object. iN(RÊRà(RzRÊ((s/usr/lib64/python2.7/tarfile.pyR|º s cCs|S(s Return iterator object. ((Rz((s/usr/lib64/python2.7/tarfile.pyRÖ¿ scCs¶|jdkr3|jjdk r3|jjƒ}np|jt|jjƒkrd|jj|j}n?|jjs�|jjƒ}|s£t|j_t ‚q£nt ‚|jd7_|S(s€Return the next item using TarFile's next() method. When all members have been read, set TarFile as _loaded. iiN( RàRÊRWRKR"RRTRUR‚t StopIteration(RzRË((s/usr/lib64/python2.7/tarfile.pyR"à s!   (ReRfRgR|RÖR"(((s/usr/lib64/python2.7/tarfile.pyRç³ s  t_sectioncBs eZdZd„Zd„ZRS(s$Base class for _data and _hole. cCs||_||_dS(N(R»R(RzR»R((s/usr/lib64/python2.7/tarfile.pyR|Ý s cCs%|j|ko"|j|jkSS(N(R»R(RzR»((s/usr/lib64/python2.7/tarfile.pyt __contains__à s(ReRfRgR|Rñ(((s/usr/lib64/python2.7/tarfile.pyRðÚ s RÄcBseZdZd„ZRS(s/Represent a data section in a sparse file. cCs tj|||ƒ||_dS(N(RðR|RÅ(RzR»RRÅ((s/usr/lib64/python2.7/tarfile.pyR|æ s(ReRfRgR|(((s/usr/lib64/python2.7/tarfile.pyRÄã sR$cBseZdZRS(s/Represent a hole section in a sparse file. (ReRfRg(((s/usr/lib64/python2.7/tarfile.pyR$ê sR#cBs eZdZd„Zd„ZRS(sMRingbuffer class which increases performance over a regular list. cCs d|_dS(Ni(tidx(Rz((s/usr/lib64/python2.7/tarfile.pyR|ó scCsu|j}x\trg||}||kr,Pn|d7}|t|ƒkrQd}n||jkr dSq W||_|S(Nii(RòR‚RRK(RzR»Ròtitem((s/usr/lib64/python2.7/tarfile.pyR"õ s       (ReRfRgR|R"(((s/usr/lib64/python2.7/tarfile.pyR#ï s t TarFileCompatcBsteZdZded„Zd„Zd„Zd„Zd„Zd„Z d„Z d d d „Z d „Z d „ZRS( sRTarFile class compatible with standard module zipfile's ZipFile class. RZcCsßddlm}|dddƒ|tkrDtj||ƒ|_n0|tkrhtj||ƒ|_n tdƒ‚|dd!d krÛ|jj ƒ}xB|D]7}|j |_ |j |_ tj|jƒd |_q�WndS( Niÿÿÿÿ(twarnpy3ks6the TarFileCompat class has been removed in Python 3.0t stacklevelisunknown compression constantiiRZi(R[Rõt TAR_PLAINRR_RÊt TAR_GZIPPEDRoR(RyR{R¹Rt file_sizeR�tgmtimeRt date_time(RztfileR_t compressionRõRTRß((s/usr/lib64/python2.7/tarfile.pyR| s       cCstd„|jƒƒS(NcSs|jS(N(R{(Rß((s/usr/lib64/python2.7/tarfile.pyt R0(tmaptinfolist(Rz((s/usr/lib64/python2.7/tarfile.pytnamelist scCstd„|jjƒƒS(NcSs |jtkS(N(RŸR5(Rß((s/usr/lib64/python2.7/tarfile.pyRþ R0(R§RÊRy(Rz((s/usr/lib64/python2.7/tarfile.pyR s cCs|jjƒdS(N(RÊR (Rz((s/usr/lib64/python2.7/tarfile.pytprintdir" scCsdS(N((Rz((s/usr/lib64/python2.7/tarfile.pyttestzip$ scCs|jj|ƒS(N(RÊRv(RzR{((s/usr/lib64/python2.7/tarfile.pytgetinfo& scCs"|jj|jj|ƒƒjƒS(N(RÊR½RvRO(RzR{((s/usr/lib64/python2.7/tarfile.pyRO( scCs|jj||ƒdS(N(RÊR¤(RzR¹R˜t compress_type((s/usr/lib64/python2.7/tarfile.pyRQ* scCs”yddlm}Wn!tk r7ddlm}nXddl}t|jƒ}t|ƒ|_|j|j ƒ|_ |j j |||ƒƒdS(Niÿÿÿÿ(tStringIO( t cStringIORR�tcalendarRR¹RRttimegmRûRRÊR¢(RztzinfotbytesRRttinfo((s/usr/lib64/python2.7/tarfile.pytwritestr, s  cCs|jjƒdS(N(RÊR}(Rz((s/usr/lib64/python2.7/tarfile.pyR}6 sN(ReRfRgR÷R|RRRRRRORKRQR R}(((s/usr/lib64/python2.7/tarfile.pyRô s       cCs7yt|ƒ}|jƒtSWntk r2tSXdS(sfReturn True if name points to a tar archive that we are able to handle, else return False. N(RR}R‚RR„(R{R\((s/usr/lib64/python2.7/tarfile.pyR= s    (xRgt __version__tversiont __author__t__date__t __cvsid__t __credits__t __builtin__RRNRÛRsRLR�RÊR�R2RûR*R¬R•R“R�RKt__all__RR°RsRöRñRóRòRRØRR9R7R;R=RåR?tCONTTYPERùRøRRRRRéR1RìRDRR5RR2RýR&R3tS_IFLNKtS_IFREGRÐtS_IFDIRRÑtS_IFIFOtTSUIDtTSGIDtTSVTXtTUREADtTUWRITEtTUEXECtTGREADtTGWRITEtTGEXECtTOREADtTOWRITEtTOEXECtgetfilesystemencodingREtgetdefaultencodingR!R$R.R7RARJRMR^Rdt ExceptionRRhRiRjRkRlRmRnRoR)RpRqR~tobjectR…R³RºRÇRRRçRðRÄR$R R#R÷RøRôR(((s/usr/lib64/python2.7/tarfile.pyts.                                               ëARƒÿÿ7ÿÿÿå' 4