403Webshell
Server IP : 61.19.30.66  /  Your IP : 216.73.216.15
Web Server : Apache/2.2.22 (Ubuntu)
System : Linux klw 3.11.0-15-generic #25~precise1-Ubuntu SMP Thu Jan 30 17:39:31 UTC 2014 x86_64
User : www-data ( 33)
PHP Version : 5.3.10-1ubuntu3.48
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
MySQL : ON  |  cURL : OFF  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : OFF
Directory :  /usr/lib/python2.7/dist-packages/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/lib/python2.7/dist-packages/problem_report.pyc
ó
ˆ5„Oc@s7dZddlZddlZddlZddlZddlZddlZddlZddlm	Z	ddl
mZddlm
Z
ddlmZyddlmZWn!ek
rÑddlmZnXyddlmZWn!ek
r	dd	lmZnXd
dd„ƒYZdefd
„ƒYZdS(s(Store, load, and handle problem reports.iÿÿÿÿN(t
encode_base64(t
MIMEMultipart(tMIMEBase(tMIMEText(tStringIO(tUserDict(tIterableUserDicttCompressedValuecBsJeZdZddd„Zd„Zd„Zd„Zd„Zd„Z	RS(s9Represent a ProblemReport value which is gzip compressed.cCs5d|_||_t|_|r1|j|ƒndS(sAInitialize an empty CompressedValue object with an optional name.N(tNonet	gzipvaluetnametFalsetlegacy_zlibt	set_value(tselftvalueR
((s2/usr/lib/python2.7/dist-packages/problem_report.pyt__init__!s
			cCsJtƒ}tj|jddd|ƒj|ƒ|jƒ|_t|_dS(sSet uncompressed value.tmodetwbtfileobjN(	RtgziptGzipFileR
twritetgetvalueR	RR(RRtout((s2/usr/lib/python2.7/dist-packages/problem_report.pyR
.s	%cCsE|js
dS|jr&tj|jƒStjdt|jƒƒjƒS(sReturn uncompressed value.RN(	R	RRtzlibt
decompressRRRtread(R((s2/usr/lib/python2.7/dist-packages/problem_report.pyt	get_value6s
		cCs‡|jst‚|jr5|jtj|jƒƒdStjdt|jƒƒ}x0t	r‚|j
dƒ}|srPn|j|ƒqSWdS(s5Write uncompressed value into given file-like object.NRi(R	tAssertionErrorRRRRRRRtTrueR(Rtfiletgztblock((s2/usr/lib/python2.7/dist-packages/problem_report.pyR@s		cCsI|jst‚|jr(t|jƒƒSttjd|jdƒdƒS(s$Return length of uncompressed value.s<Liüÿÿÿi(R	RRtlenRtinttstructtunpack(R((s2/usr/lib/python2.7/dist-packages/problem_report.pyt__len__Ps	cCs|jƒjƒS(s.Behaves like splitlines() for a normal string.(Rt
splitlines(R((s2/usr/lib/python2.7/dist-packages/problem_report.pyR'XsN(
t__name__t
__module__t__doc__RRR
RRR&R'(((s2/usr/lib/python2.7/dist-packages/problem_report.pyRs
		
		t
ProblemReportcBsƒeZddd„Zed„Zd„Zd„Zed„Z	ed„Z
diddd„Zd	„Zd
„Z
ed„ƒZRS(
tCrashcCsB|dkrtjƒ}ni|d6|d6|_tƒ|_dS(sÞInitialize a fresh problem report.

        type can be 'Crash', 'Packaging', 'KernelCrash' or 'KernelOops'.
        date is the desired date/time string; if None (default), the
        current local time is used.
        tProblemTypetDateN(Rttimetasctimetdatatsettold_keys(Rttypetdate((s2/usr/lib/python2.7/dist-packages/problem_report.pyR^sc	Cs“|jjƒd}d}t}d}x3|D]+}|jdƒrž|rT|rTq,n|dkrl|dksrt‚|rKtj|ƒ}|r£||j|ƒ7}q›|dkrì|j	dkrÚ|jdƒrÚt
|_n|j	|7_	q›|jdƒr)tj
tjƒ}|j|j|ƒƒ}q›tj
ƒ}||j|ƒ7}qWt|ƒdkrj|d7}n|jdƒr||dd!7}qW||d7}q,|rÌ|r½||jƒ7}nt}d}n|rô|dksät‚||j|<n|jd	dƒ\}}|jƒ}|d
kr,|dkrHt|ƒ}d|_	nd}t
}q,q,W|dkrw||j|<nt|jjƒƒ|_dS(sWInitialize problem report from a file-like object.

        If binary is False, binary data is not loaded; the dictionary key is
        created, but its value will be an empty string. If it is true, it is
        transparently uncompressed and available as dictionary string values.
        If binary is 'compressed', the compressed value is retained, and the
        dictionary value will be a CompressedValue object. This is useful if
        the compressed value is still useful (to avoid recompression if the
        file needs to be written back).

        Files are in RFC822 format.
        t t
compressedts‹is
iiÿÿÿÿt:tbase64N(R1tclearRRt
startswithRR:t	b64decodeRR	RRRt
decompressobjt	MAX_WBITSt_strip_gzip_headerR"tendswithtflushtsplittstripRR2tkeysR3(	RRtbinarytkeyRt	b64_blocktbdtlinetl((s2/usr/lib/python2.7/dist-packages/problem_report.pytloadls^




	
cCsd|jƒkS(s~Check if the report has any keys which were not loaded.

        This could happen when using binary=False in load().
        R8(t
itervalues(R((s2/usr/lib/python2.7/dist-packages/problem_report.pythas_removed_fields¹scCs2x+|D]#}|dkr|jƒrtSqWtS(s0Check if the given strings contains binary data.R6(tisspaceRR(Rtstringtc((s2/usr/lib/python2.7/dist-packages/problem_report.pyt
_is_binaryÀs
c
Csg}g}xÇ|jjƒD]¶}|r=||jkr=qn|j|}t|dƒrˆ|j|ƒrx|j|ƒqÒ|j|ƒqt|tƒrÅt|ƒdkrÅ|drÅ|j|ƒq|j|ƒqW|j	ƒd|kr|j
dƒ|jddƒn|j	ƒx|D]•}|j|}t|dƒs(t|ƒdkrn|ddkrn|d}nd}t|ƒdko|d}t|ddƒr¶|dj
ƒ}nt|dƒj
ƒ}|r÷t|ƒdkr÷td	|ƒ‚n|dkr(t|ƒ|kr(|j|=qq(ntjjd
ƒr^t|tƒr^|jdƒ}q^nd|kr›|jd
|ƒ|jd|jddƒƒq|jd||fƒqWxN|D]F}|j|}d}d}	|jƒ}
|j|dƒt|tƒr4|jtj|jƒƒ|jdƒq½nd|d}|jtj|ƒƒ|jdƒtjdƒ}tjdtjtjtj dƒ}
t|dƒr|	t|ƒ7}	tj||ƒ}|
j!|ƒ}|r|jtj|ƒƒ|jdƒqnyt|ƒdkr7|ddkr7|d}nt|ddƒrW|d}nt|dƒ}xÉt"r2|j
dƒ}|	t|ƒ7}	tj||ƒ}|dkrê|	|krê|j#|
ƒ|j$|
ƒ|j|=d}Pqên|r.|
j!|ƒ}|r/|jtj|ƒƒ|jdƒq/qjPqjWt|ƒdkr|dr|	dkrtd|t%|dƒfƒ‚qn|s”|	|kr½|
j&ƒ}|rÝ|t'j(d|d@ƒ7}|t'j(d|	d@ƒ7}n|jtj|ƒƒ|jdƒq½q½WdS(sŠWrite information into the given file-like object.

        If only_new is True, only keys which have been added since the last
        load() are written (i. e. those returned by new_keys()).

        If a value is a string, it is written directly. Otherwise it must be a
        tuple of the form (file, encode=True, limit=None, fail_on_empty=False).
        The first argument can be a file name or a file-like object,
        which will be read and its content will become the value of this key.
        'encode' specifies whether the contents will be
        gzip compressed and base64-encoded (this defaults to True). If limit is
        set to a positive integer, the file is not attached if it's larger
        than the given limit, and the entire key will be removed. If
        fail_on_empty is True, reading zero bytes will cause an IOError.

        Files are written in RFC822 format.
        tfindiiR-iiiRsdid not get any data for field t2sUTF-8s
s%s:
s %s
s
 s%s: %s
s
: base64
 s
‹ÿtR8i	is)did not get any data for field %s from %ss<LIÿÿÿÿN()R1RER3thasattrRRtappendt
isinstanceRR"tsorttremovetinsertRRtopentIOErrortsystversionR<tunicodetencodeRtreplacettellR:t	b64encodeR	Rtcrc32tcompressobjtDEFLATEDR?t
DEF_MEM_LEVELtcompressRtseekttruncatetstrRBR$tpack(RRtonly_newtasckeystbinkeystktvtlimitt
fail_on_emptytsizetcurr_postgzip_headertcrctbctoutblocktfR!((s2/usr/lib/python2.7/dist-packages/problem_report.pyRÈs¾
-




"

	 



"

	


&cCs‰tj|ƒ}z:t|dƒ}tj|dƒ|j|ƒ|jƒWd|rqtj||j|jfƒntj||j	ƒXdS(sAdd this report's data to an already existing report file.

        The file will be temporarily chmod'ed to 000 to prevent frontends
        from picking up a hal-updated report file. If keep_times
        is True, then the file's atime and mtime restored after updating.
        taiN(
toststatR\tchmodRtclosetutimetst_atimetst_mtimetst_mode(Rt
reportfilet
keep_timeststR{((s2/usr/lib/python2.7/dist-packages/problem_report.pytadd_to_existingds
ic
Csƒt|jjƒƒ}d}g}d|krM|jdƒ|jddƒn|r£d}	xG|D]<}
|
|kr`|j|
ƒ|j|	|
ƒ|	d7}	q`q`Wnx3|D]+}|rÈ||krÈqªn|j|}d}
t|tƒrö|j}
nt	|dƒsÓd}
t	|ddƒr+|d}nt
|dƒ}|jdƒrY|jƒ}
nmt
ƒ}tj|dd	d
|ƒ}x:tr¹|jdƒ}|r«|j|ƒq€|jƒPq€W|jƒ}
|jƒn<|j|ƒr|jdƒrú|}
qt||ƒj}
n|
rtdd
ƒ}|jdƒrL|jddd|ƒn|jddd|dƒ|j|
ƒt|ƒ|j|ƒqªt|ƒ}t|ƒtdƒkrÆ|jddƒ}nt|tƒsÛt‚|jdƒ}t|j ƒƒ}|dkr7|dkr7|j!ƒ}|d||f7}qª|dkrœ||krœ|d|7}|jdƒsy|d7}n||j"ƒj#ddƒd7}qªt$|ddƒ}|jddd|dƒ|j|ƒqªWt$|ddƒ}|jddƒ|jd|ƒt%ƒ}x*|j&ƒD]\}}|j||ƒq!Wx|D]}|j'|ƒqHW|j|j(ƒƒ|jdƒdS(seWrite MIME/Multipart RFC 2822 formatted data into file.

        file must be a file-like object, not a path.

        If a value is a string or a CompressedValue, it is written directly.
        Otherwise it must be a tuple containing the source file and an optional
        boolean value (in that order); the first argument can be a file name or
        a file-like object, which will be read and its content will become the
        value of this key.  The file will be gzip compressed, unless the key
        already ends in .gz.

        attach_treshold specifies the maximum number of lines for a value to be
        included into the first inline text part. All bigger values (as well as
        all non-ASCII ones) will become an attachment, as well as text
        values bigger than 1 kB.

        Extra MIME preamble headers can be specified, too, as a dictionary.

        skip_keys is a set/list specifying keys which are filtered out and not
        written to the destination file.

        priority_fields is a set/list specifying the order in which keys should
        appear in the destination file.
        R8R-iiRSRs.gzRRRitapplicationsx-gzipsContent-Dispositiont
attachmenttfilenamesUTF-8Rbiès%s: %s
s%s:
 s
s
 t_charsets.txttinlineN()tsortedR1RERZR[RRXRR	RVR\RARRRRRRR€RRRRt
add_headertset_payloadRRWR"R4tdecodeR`RRaR'trstripRDRbRRtitemstattacht	as_string(RRtattach_tresholdt
extra_headerst	skip_keystpriority_fieldsREttexttattachmentstcountertpriority_fieldRqRrtattach_valueR{tiotgfR!tattRutlinestmsgR|((s2/usr/lib/python2.7/dist-packages/problem_report.pyt
write_mimevs˜





		

	


#	
c
Csñt|dƒst‚|jddƒjddƒjddƒjƒsKt‚t|tƒsÞt|dƒsÞt|dƒrØt|ƒdks²t|ƒdkrØ|dttfkrØt|d	dƒsÞt|d	d
ƒsÞt‚|j	j
||ƒS(Ntisalnumt.R8t-t_t__getitem__iiiR(RVRRbR¥RXRR"RRR1t__setitem__(RRqRr((s2/usr/lib/python2.7/dist-packages/problem_report.pyRªûs6:,cCst|jjƒƒ|jS(s‘Return newly added keys.

        Return the set of keys which have been added to the report since it
        was constructed or loaded.
        (R2R1RER3(R((s2/usr/lib/python2.7/dist-packages/problem_report.pytnew_keysscCsÐt|dƒ}d}|d@r5|||d7}n|d@rsx$t||ƒdkre|d7}qBW|d7}n|d@r±x$t||ƒdkr£|d7}q€W|d7}n|d@rÈ|d7}n||S(	s0Strip gzip header from line and return the rest.ii
iiiiii(tord(tklassRJtflagstoffset((s2/usr/lib/python2.7/dist-packages/problem_report.pyR@s






N(R(R)RRRRLRNRRRRRˆR¤RªR«tclassmethodR@(((s2/usr/lib/python2.7/dist-packages/problem_report.pyR+]sM		œ„		((R*RR:R/R^RR$R}temail.encodersRtemail.mime.multipartRtemail.mime.baseRtemail.mime.textRt	cStringIORtImportErrorRŸtcollectionsRRRR+(((s2/usr/lib/python2.7/dist-packages/problem_report.pyt<module>sT

?

Youez - 2016 - github.com/yon3zu
LinuXploit