DonatShell
Server IP : 180.180.241.3  /  Your IP : 216.73.216.252
Web Server : Microsoft-IIS/7.5
System : Windows NT NETWORK-NHRC 6.1 build 7601 (Windows Server 2008 R2 Standard Edition Service Pack 1) i586
User : IUSR ( 0)
PHP Version : 5.3.28
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  C:/Program Files (x86)/MySQL/MySQL Workbench 6.1 CE/python/lib/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : C:/Program Files (x86)/MySQL/MySQL Workbench 6.1 CE/python/lib//urllib.pyc

'Sc@sdZddlZddlZddlZddlZddlZddlmZdddddd	d
ddd
ddddddddddddddddddgZ	d Z
d!Zejd"krdd#l
mZmZn:ejd$krdd#lmZmZnd%Zd&Zeaeed'Zeeed(Zd)ZyddlZWn
eZnXeZd*efd+YZiZdfd,YZdefd-YZead.Z ea!d/Z"ea#d0Z$ea%d1Z&d2fd3YZ'd4fd5YZ(d6e(fd7YZ)d8e(fd9YZ*d:e(fd;YZ+ye,Wne-k
r}d<Z.n
Xd=Z.d>Z/d?Z0ea1d@Z2ea3dAZ4ea5dBZ6ea7dCZ8ea9dDZ:ea;ddEZ<ea=dFZ>ea?dGZ@dHZAeaBdIZCdJZDeEdKeDDZFdLZGdMZHdNZIiZJxfeKeLdOeMeNeLdOD]=\ZOZPeOdPkoePeIkrePndQjQeOeJeP<qWiZRdRdSZSdTdUZTdVdWZUdXZVdYZWejXdZkrWdd[lYmZZZm[Z[d\Z\d]Z]d^Z^d_Z_nBejd"krd`Z`daZ_dbZadcZ^neVZ_eWZ^ddZbdeZcgdfZddgZeefdhkreendS(isOpen an arbitrary URL.

See the following document for more info on URLs:
"Names and Addresses, URIs, URLs, URNs, URCs", at
http://www.w3.org/pub/WWW/Addressing/Overview.html

See also the HTTP spec (from which the error codes are derived):
"HTTP - Hypertext Transfer Protocol", at
http://www.w3.org/pub/WWW/Protocols/

Related standards and specs:
- RFC1808: the "relative URL" spec. (authoritative status)
- RFC1738 - the "URL standard". (authoritative status)
- RFC1630 - the "URI spec". (informational status)

The object returned by URLopener().open(file) will differ per
protocol.  All you know is that is has methods read(), readline(),
readlines(), fileno(), close() and info().  The read*(), fileno()
and close() methods work like those of open files.
The info() method returns a mimetools.Message object which can be
used to query various info about the object, if available.
(mimetools.Message objects are queried with the getheader() method.)
iN(turljointurlopent	URLopenertFancyURLopenerturlretrievet
urlcleanuptquotet
quote_plustunquotetunquote_plust	urlencodeturl2pathnametpathname2urltsplittagt	localhosttthishostt	ftperrorstbasejointunwrapt	splittypet	splithostt	splitusertsplitpasswdt	splitportt
splitnportt
splitqueryt	splitattrt
splitvaluet
getproxiess1.17i
tnt(RRtriscoscCs
t|S(sOS-specific conversion from a relative URL of the 'file' scheme
        to a file system path; not recommended for general use.(R(tpathname((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR2scCs
t|S(sOS-specific conversion from a file system path to a relative URL
        of the 'file' scheme; not recommended for general use.(R(R((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR7scCsddlm}|ddd|dk	r>td|}ntsVt}|ant}|dkru|j|S|j||SdS(s=Create a file-like object for the specified URL to read from.i(twarnpy3ksMurllib.urlopen() has been removed in Python 3.0 in favor of urllib2.urlopen()t
stacklevelitproxiesN(twarningsR tNoneRt
_urlopenertopen(turltdataR"R topener((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyREs			
cCs(tstantj||||S(N(R%Rtretrieve(R'tfilenamet
reporthookR(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRWscCs+trtjntjtjdS(N(R%tcleanupt
_safe_quoterstcleartftpcache(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR\s

tContentTooShortErrorcBseZdZRS(cCstj||||_dS(N(tIOErrort__init__tcontent(tselftmessageR4((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3ls(t__name__t
__module__R3(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR1kscBseZdZdZdeZddZdZdZ	dZ
dZddZddZ
dd	Zdddd
ZddZddZd
ZerddZndZdZdZddZRS(s,Class to open URLs.
    This is a class rather than just a subroutine because we may need
    more than one set of global protocol-specific options.
    Note -- this is a base class for those who don't want the
    automatic handling of errors type 302 (relocated) and 401
    (authorization needed).sPython-urllib/%scKs|dkrt}nt|ds3td||_|jd|_|jd|_d|jfg|_	g|_
tj|_
d|_t|_dS(Nthas_keysproxies must be a mappingtkey_filet	cert_files
User-Agent(R$RthasattrtAssertionErrorR"tgetR:R;tversiont
addheaderst_URLopener__tempfilestostunlinkt_URLopener__unlinkt	tempcacheR0(R5R"tx509((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3~s			cCs|jdS(N(tclose(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt__del__scCs|jdS(N(R-(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRGscCsi|jrLx6|jD]+}y|j|Wqtk
r=qXqW|j2n|jre|jjndS(N(RARDtOSErrorRER/(R5tfile((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR-s	

	cGs|jj|dS(sdAdd a header to be used by the HTTP interface only
        e.g. u.addheader('Accept', 'sound/basic')N(R@tappend(R5targs((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt	addheaderscCstt|}t|dd}|jrn||jkrn|j|\}}t|d}t|||St|\}}|sd}n||jkr|j|}t|\}}	t|	\}
}|
|f}nd
}d|}||_
|jdd}t||sD|r1|j
|||S|j||Sny9|d
krft|||St||||SWn2tjk
r}
td|
ftjd	nXd
S(s6Use URLopener().open(file) instead of open(file, 'r').tsafes%/:=&?~#+!$,;'@()*[]|trbRJtopen_t-t_ssocket erroriN(RttoBytesRRER&t
addinfourlRR"RR$ttypetreplaceR<topen_unknown_proxytopen_unknowntgetattrtsocketterrorR2tsystexc_info(R5tfullurlR(R+theaderstfpturltypeR'tproxyt	proxyhostthosttselectortnametmsg((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR&s8	

	cCs(t|\}}tdd|fdS(s/Overridable interface to open unknown URL type.s	url errorsunknown url typeN(RR2(R5R^R(RUR'((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRXscCs,t|\}}tdd||fdS(s/Overridable interface to open unknown URL type.s	url errorsinvalid proxy for %sN(RR2(R5RbR^R(RUR'((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRWsc
Cstt|}|jr5||jkr5|j|St|\}}|dkr|sf|dkryC|j|}|j}|jtt	|d|fSWqt
k
rqXn|j||}z|j}	|rt|d}
nddl}t|\}}
t	|
p#d\}}
t
|
p;d\}
}t|
pSd\}
}tjj|
d}|j|\}}|jj|tj|d}
z||	f}|jdk	r||j|<nd
}d}d	}d	}|r*d
|	krt|	d}n||||nxb|j|}|dkrLPn|t|7}|
j||d7}|r-||||q-q-Wd|
jXWd|jX|d	kr||krtd||f|n|S(stretrieve(url) returns (filename, headers) for a local object
        or (tempfilename, headers) for a remote object.RJitwbiNtiiiscontent-lengthsContent-Lengths1retrieval incomplete: got only %i out of %i bytesi (RRSRERR$topen_local_filetinfoRGRRR2R&ttempfileRRRBtpathtsplitexttmkstempRARKtfdopentinttreadtlentwriteR1(R5R'R+R,R(RUturl1R`thdrsR_ttfpRltgarbageRmtsuffixtfdtresulttbstsizeRrtblocknumtblock((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR*sj



cCs=ddl}d}d}t|trit|\}}|r`t|\}}t|}n|}n|\}}t|\}}t|\}	}
|
}d}|	jdkrd}n^t|
\}}
|rt|\}}n|r	d|	||
f}nt	|r|}n|s0t
dn|rZddl}|j|j
}nd}|rddl}|j|j
}
nd}
|j|}|dk	r|jd||jdd	|jd
dt|n|jd||r|jd
d|n|
r2|jdd|
n|rK|jd|nx|jD]}|j|qUW|j||j\}}}|j}|dkr|r|jnt
dnd|kodknrt||d||S|dkr|j|||||S|j||||||SdS(sUse HTTP protocol.iNthttps	%s://%s%ss
http errors
no host giventPOSTsContent-Types!application/x-www-form-urlencodedsContent-Lengths%dtGETsProxy-AuthorizationsBasic %st
AuthorizationtHostshttp protocol errorisgot a bad status lineii,shttp:(s
http errors
no host given(shttp protocol errorisgot a bad status lineN(thttplibR$t
isinstancetstrRRRRtlowertproxy_bypassR2tbase64t	b64encodetstriptHTTPt
putrequestt	putheaderRsR@t
endheaderstgetreplytgetfileRGRTt
http_error(R5R'R(Rtuser_passwdtproxy_passwdRdRetrealhostRatrestRt
proxy_authtauththRLterrcodeterrmsgR_R`((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt	open_httpsx			

	c
Csd|}t||rwt||}|dkrO||||||}	n|||||||}	|	rw|	Sn|j|||||S(sHandle http errors.
        Derived class can override this, or provide specific handlers
        named http_error_DDD where DDD is the 3-digit error code.s
http_error_%dN(R<RYR$thttp_error_default(
R5R'R`RRR_R(RftmethodR{((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRhs
cCs/|j}|jtd|||fdS(s>Default error handler: close the connection and raise IOError.s
http errorN(RrRGR2(R5R'R`RRR_tvoid((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRws
cCs=ddl}d}d}t|trit|\}}|r`t|\}}t|}n|}n|\}}t|\}}t|\}	}
|
}d}|	jdkrd}nIt|
\}}
|rt|\}}n|r	d|	||
f}n|st	dn|rEddl
}|j|j}nd}|ruddl
}|j|j}
nd}
|j
|dd|jd	|j}|dk	r|jd
||jdd|jd
dt|n|jd||r|jdd|n|
r2|jdd|
n|rK|jd|nx|jD]}|j|qUW|j||j\}}}|j}|dkr|r|jnt	dnd|kodknrt||d||S|dkr|j|||||S|j||||||SdS(sUse HTTPS protocol.iNthttpss	%s://%s%sshttps errors
no host giveniR:R;RsContent-Types!application/x-www-form-urlencodedsContent-Lengths%dRsProxy-AuthorizationsBasic %sRRshttp protocol errorsgot a bad status lineii,shttps:(shttps errors
no host given(shttp protocol errorisgot a bad status lineN(RR$RRRRRRRR2RRRtHTTPSR:R;RRRsR@RRRRGRTR(R5R'R(RRRRdReRRaRRRRRRLRRR_R`((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt
open_https~s|				

	cCsut|tstd
n|d dkrd|dd!dkrd|dd!jdkrd|j|S|j|Sd	S(s/Use local file or FTP depending on form of URL.s
file errors9proxy support for file protocol currently not implementedis//it/is
localhost/N(s
file errors9proxy support for file protocol currently not implemented(RRR2Rtopen_ftpRj(R5R'((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt	open_files
<
cCsddl}ddl}ddl}yddlm}Wn!tk
r[ddlm}nXt|\}}t|}ytj	|}	Wn.t
k
r}
t|
j|
j
|
jnX|	j}|jj|	jdt}|j|d}
|j|d|
p
d||f}|s_|}|d d	krFd
|}ntt|d||St|\}}|rtj|ttfkr|}|d d	krd
|}ntt|d||StddS(sUse local file.iN(tStringIOtusegmtis6Content-Type: %s
Content-Length: %d
Last-modified: %s
s
text/plainiRsfile://ROslocal file errorsnot on local host(slocal file errorsnot on local host(t	mimetypest	mimetoolstemail.utilst	cStringIORtImportErrorRRRBtstatRIR2terrnotstrerrorR+tst_sizetutilst
formatdatetst_mtimetTruet
guess_typetMessageRTR&RRZt
gethostbynameRR(R5R'RRtemailRRdRJt	localnametstatsteR}tmodifiedtmtypeR_turlfiletport((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRjs@$
		

!

c
Cst|tstdnddl}ddl}yddlm}Wn!tk
rjddlm}nXt|\}}|stdnt	|\}}t
|\}}|rt|\}}	nd}	t
|}|pd}|	pd}	tj|}|s%ddl}
|
j}nt|}t|\}}t
|}|jd}|d |d}}
|r|d	r|d
}n|r|d	rd|d	<n|||dj|f}t|jtkr,xJ|jjD]6}||kr|j|}|j|=|jqqWny?||jkr`t||	||||j|<n|
sod}nd}xM|D]E}t|\}}|jd
kr||dkr||j}q|q|W|j|j|
|\}}|j d|d	}d}|r|d|7}n|dk	rA|d	krA|d|7}n|j!||}t"||d|SWn2t#k
r}td|ft$j%dnXdS(sUse FTP protocol.s	ftp errors8proxy support for ftp protocol currently not implementediN(Rs
no host givenRiRiitDtIRUtatAtitdsftp:sContent-Type: %s
sContent-Length: %d
i(s	ftp errors8proxy support for ftp protocol currently not implemented(s	ftp errors
no host given(RRRRRR(&RRR2RRRRRRRRRR$RRZRtftplibtFTP_PORTRqRtsplittjoinRsR0tMAXFTPCACHEtkeysRGt
ftpwrapperRRtuppertretrfileRRRTRR\R](R5R'RRRRdRmRtusertpasswdRtattrstdirsRJtkeytktvRUtattrtvalueR`tretrlenRR_Rg((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRsx




"	
cCst|tstdnddl}yddlm}Wn!tk
r^ddlm}nXy|jdd\}}Wntk
rtdnX|sd	}n|j	d
}|dkrd||kr||d}|| }nd
}g}|j
dtjdtj
tj|j
d||dkr`ddl}	|	j|}nt|}|j
dt||j
d
|j
|dj|}||}
|j|
d}t|
||S(sUse "data" URL.s
data errors9proxy support for data protocol currently not implementediN(Rt,isbad data URLstext/plain;charset=US-ASCIIt;it=RisDate: %ss%a, %d %b %Y %H:%M:%S GMTsContent-type: %sRsContent-Length: %ds
(s
data errors9proxy support for data protocol currently not implemented(s
data errorsbad data URL(RRR2RRRRRt
ValueErrortrfindRKttimetstrftimetgmtimeRtdecodestringRRsRRRT(R5R'R(RRRUtsemitencodingRgRtfR_((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt	open_data0sB


	


N(R7R8t__doc__R$RAt__version__R?R3RHRGR-RMR&RXRWR*RRRt	_have_sslRRRjRR(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRqs*
				$AI	H			#	>cBseZdZdZdZddZdZddZddZ	ddZ
ddZdd	Zdd
Z
ddZddZdd
ZddZdZRS(s?Derived class with handlers for errors we can handle (perhaps).cOs2tj|||i|_d|_d|_dS(Nii
(RR3t
auth_cachettriestmaxtries(R5RLtkwargs((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3bs		cCst||d||S(s3Default error handling -- don't raise an exception.shttp:(RT(R5R'R`RRR_((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRhsc	Cs|jd7_|jrm|j|jkrmt|drE|j}n	|j}d|_|||dd|S|j||||||}d|_|S(s%Error 302 -- relocated (temporarily).ithttp_error_500iis)Internal Server Error: Redirect Recursion(RRR<RRtredirect_internal(	R5R'R`RRR_R(tmethR{((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pythttp_error_302ls		
		c	Cssd|kr|d}nd|kr2|d}ndS|j}|jt|jd||}|j|S(Ntlocationturit:(RrRGRRUR&(	R5R'R`RRR_R(tnewurlR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR|s


cCs|j||||||S(s*Error 301 -- also relocated (permanently).(R(R5R'R`RRR_R(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pythttp_error_301scCs|j||||||S(s;Error 303 -- also relocated (essentially identical to 302).(R(R5R'R`RRR_R(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pythttp_error_303scCsE|dkr(|j||||||S|j|||||SdS(s1Error 307 -- relocated, but turn POST into error.N(R$RR(R5R'R`RRR_R(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pythttp_error_307sc
Csd|kr+tj||||||n|d}ddl}|jd|}	|	sxtj||||||n|	j\}
}|
jdkrtj||||||nd|jd}|dkrt||||St|||||SdS(s_Error 401 -- authentication required.
        This function supports Basic authentication only.swww-authenticateiNs![ 	]*([^ 	]+)[ 	]+realm="([^"]*)"tbasictretry_t_basic_auth(	RRtretmatchtgroupsRRUR$RY(
R5R'R`RRR_R(tstuffRRtschemetrealmRf((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pythttp_error_401s"
c
Csd|kr+tj||||||n|d}ddl}|jd|}	|	sxtj||||||n|	j\}
}|
jdkrtj||||||nd|jd}|dkrt||||St|||||SdS(seError 407 -- proxy authentication required.
        This function supports Basic authentication only.sproxy-authenticateiNs![ 	]*([^ 	]+)[ 	]+realm="([^"]*)"Rtretry_proxy_R(	RRRRRRRUR$RY(
R5R'R`RRR_R(RRRRRRf((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pythttp_error_407s"
cCs	t|\}}d||}|jd}t|\}}	t|	\}	}
|	jdd}|	|}	|j|	||\}}
|p|
sdSt|dddt|
ddd|	}	d|	|
|jd<|dkr|j|S|j||SdS(Nshttp://Rt@iRNRiR(RR"Rtfindtget_user_passwdR$RR&(R5R'RR(RdReRRbRaRct
proxyselectorRRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytretry_proxy_http_basic_auths

.
cCs	t|\}}d||}|jd}t|\}}	t|	\}	}
|	jdd}|	|}	|j|	||\}}
|p|
sdSt|dddt|
ddd|	}	d|	|
|jd<|dkr|j|S|j||SdS(Nshttps://RRiRNRiR(RR"RRRR$RR&(R5R'RR(RdReRRbRaRcRRRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytretry_proxy_https_basic_auths

.
c
Cst|\}}|jdd}||}|j|||\}}|pS|sZdSt|dddt|ddd|}d||}	|dkr|j|	S|j|	|SdS(NRiRNRiRshttp://(RRRR$RR&(
R5R'RR(RdReRRRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytretry_http_basic_auths
.
c
Cst|\}}|jdd}||}|j|||\}}|pS|sZdSt|dddt|ddd|}d||}	|dkr|j|	S|j|	|SdS(NRiRNRiRshttps://(RRRR$RR&(
R5R'RR(RdReRRRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytretry_https_basic_auths
.
icCs|d|j}||jkrD|r6|j|=qD|j|Sn|j||\}}|sh|r~||f|j|<n||fS(NR(RRtprompt_user_passwd(R5RdRtclear_cacheRRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRs
cCsfddl}y@td||f}|jd|||f}||fSWntk
raHdSXdS(s#Override this in a GUI environment!iNsEnter username for %s at %s: s#Enter password for %s in %s at %s: (NN(tgetpasst	raw_inputtKeyboardInterruptR$(R5RdRRRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR
s	
	
N(R7R8RR3RR$RRRRRRRR	R
RRRR
(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR_s 			


cCs"tdkrtjdantS(s8Return the IP address of the magic hostname 'localhost'.RN(t
_localhostR$RZR(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRscCs(tdkr$tjtjantS(s*Return the IP address of the current host.N(t	_thishostR$RZRtgethostname(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR$scCs(tdkr$ddl}|jantS(s1Return the set of errors raised by the FTP class.iN(t
_ftperrorsR$Rt
all_errors(R((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR,scCsytdkruddl}yddlm}Wn!tk
rOddlm}nX|j|datjjntS(s)Return an empty mimetools.Message object.iN(Ri(	t
_noheadersR$RRRRRR`RG(RR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt	noheaders5s
RcBsAeZdZejdZdZdZdZdZ	RS(s;Class used by open_ftp() for cache of open FTP connections.cCsD||_||_||_||_||_||_|jdS(N(RRRdRRttimeouttinit(R5RRRdRRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3Hs						cCsddl}d|_|j|_|jj|j|j|j|jj|j	|j
x!|jD]}|jj|qfWdS(Nii(
RtbusytFTPtftptconnectRdRRtloginRRRtcwd(R5Rtdir((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRRs	c	Csddl}|j|dkr1d}d}nd|}d}y|jj|Wn.|jk
r|j|jj|nXd}|r
|r
y d|}|jj|}Wq
|jk
r}t	|d	 d
krt
d|ftjdqq
Xn|s|jjd|r|jj
}zMy|jj|Wn2|jk
r}t
d|ftjdnXWd|jj|Xd
|}nd}|jj|}nd|_t|djd|j|dfS(NiRRsTYPE AisTYPE isRETR it550s	ftp errorisLIST tLISTRO(RR(RtendtransferRtvoidcmdRRR$tntransfercmdt
error_permRR2R\R]tpwdR Rtaddclosehooktmakefile(	R5RJRURtcmdtisdirtconntreasonR(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR[sH
	



&$
	cCsB|js
dSd|_y|jjWntk
r=nXdS(Ni(RRtvoidrespR(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR$s		cCs6|jy|jjWntk
r1nXdS(N(R$RRGR(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRGs

(
R7R8RRZt_GLOBAL_DEFAULT_TIMEOUTR3RRR$RG(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyREs				(		taddbasecBs)eZdZdZdZdZRS(s(Base class for addinfo and addclosehook.cCs||_|jj|_|jj|_t|jdrK|jj|_nt|jdro|jj|_nd|_t|jdr|jj|_t|jdr|jj|_qndS(Nt	readlinestfilenocSsdS(N(R$(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt<lambda>st__iter__tnext(R`RrtreadlineR<R2R3R5R6(R5R`((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3s	cCs d|jjt||jfS(Ns<%s at %r whose fp = %r>(t	__class__R7tidR`(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt__repr__scCsJd|_d|_d|_d|_|jr=|jjnd|_dS(N(R$RrR7R2R3R`RG(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRGs					(R7R8RR3R:RG(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR1s		R)cBs eZdZdZdZRS(s*Class to add a close hook to an open file.cGs&tj||||_||_dS(N(R1R3t	closehookthookargs(R5R`R;R<((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3s	cCs?tj||jr;|j|jd|_d|_ndS(N(R1RGR;R<R$(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRGs

		(R7R8RR3RG(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR)s	taddinfocBs eZdZdZdZRS(s.class to add an info() method to an open file.cCstj||||_dS(N(R1R3R_(R5R`R_((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3scCs|jS(N(R_(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRks(R7R8RR3Rk(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR=s	RTcBs5eZdZddZdZdZdZRS(s9class to add info() and geturl() methods to an open file.cCs/tj||||_||_||_dS(N(R1R3R_R'tcode(R5R`R_R'R>((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR3s		cCs|jS(N(R_(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRkscCs|jS(N(R>(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytgetcodescCs|jS(N(R'(R5((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytgeturlsN(R7R8RR$R3RkR?R@(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRTs
		cCsdS(Ni((tx((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt_is_unicodescCs
t|tS(N(Rtunicode(RA((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRBscCsTt|rPy|jd}WqPtk
rLtdt|dqPXn|S(stoBytes(u"URL") --> 'URL'.tASCIIsURL s contains non-ASCII characters(RBtencodetUnicodeErrortrepr(R'((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRSs
cCsi|j}|d dkrB|ddkrB|dd!j}n|d dkre|dj}n|S(s8unwrap('<URL:type://host/path>') --> 'type://host/path'.it<it>isURL:(R(R'((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRs cCsvtdkr*ddl}|jdantj|}|rl|jd}|j|t|dfSd|fS(s:splittype('type:opaquestring') --> 'type', 'opaquestring'.iNs
^([^/:]+):i(t	_typeprogR$RtcompileRtgroupRRs(R'RRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR	scCstdkr*ddl}|jdantj|}|r|jd}|jd}|r|jdrd|}n||fSd|fS(s;splithost('//host[:port]/path') --> 'host[:port]', '/path'.iNs^//([^/?]*)(.*)$iiR(t	_hostprogR$RRKRRLt
startswith(R'RRt	host_portRm((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRs

cCsYtdkr*ddl}|jdantj|}|rO|jddSd|fS(sJsplituser('user[:passwd]@host[:port]') --> 'user[:passwd]', 'host[:port]'.iNs^(.*)@(.*)$ii(t	_userprogR$RRKRRL(RdRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR(scCs_tdkr0ddl}|jd|jantj|}|rU|jddS|dfS(s/splitpasswd('user:passwd') -> 'user', 'passwd'.iNs^([^:]*):(.*)$ii(t_passwdprogR$RRKtSRRL(RRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR4scCsYtdkr*ddl}|jdantj|}|rO|jddS|dfS(s*splitport('host:port') --> 'host', 'port'.iNs^(.*):([0-9]+)$ii(t	_portprogR$RRKRRL(RdRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRAscCstdkr*ddl}|jdantj|}|r|jdd\}}y"|sltdnt|}Wntk
rd}nX||fS||fS(sSplit host and port, returning numeric port.
    Return given default port if no ':' found; defaults to -1.
    Return numerical port if a valid number are found after ':'.
    Return None if ':' but not a valid number.iNs^(.*):(.*)$iis	no digits(t
_nportprogR$RRKRRLRRq(RdtdefportRRRtnport((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRMs


cCsYtdkr*ddl}|jdantj|}|rO|jddS|dfS(s/splitquery('/path?query') --> '/path', 'query'.iNs^(.*)\?([^?]*)$ii(t
_queryprogR$RRKRRL(R'RR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRcscCsYtdkr*ddl}|jdantj|}|rO|jddS|dfS(s)splittag('/path#tag') --> '/path', 'tag'.iNs^(.*)#([^#]*)$ii(t_tagprogR$RRKRRL(R'RR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR
oscCs!|jd}|d|dfS(sksplitattr('/path;attr1=value1;attr2=value2;...') ->
        '/path', ['attr1=value1', 'attr2=value2', ...].Rii(R(R'twords((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRzscCsYtdkr*ddl}|jdantj|}|rO|jddS|dfS(s-splitvalue('attr=value') --> 'attr', 'value'.iNs^([^=]*)=(.*)$ii(t
_valueprogR$RRKRRL(RRR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRst0123456789ABCDEFabcdefccs?|]5}tD](}||tt||dfVq
qdS(iN(t_hexdigtchrRq(t.0Rtb((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pys	<genexpr>scCs|jd}t|dkr%|S|d}x|dD]{}y|t|d |d7}Wq:tk
r|d|7}q:tk
r|tt|d d|d7}q:Xq:W|S(s"unquote('abc%20def') -> 'abc def'.t%iiii(RRst	_hextochrtKeyErrortUnicodeDecodeErrortunichrRq(tstrestitem((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRs


-cCs|jdd}t|S(s%unquote('%7e/abc+def') -> '~/abc def't+t (RVR(Re((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR	ssAABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_.-iis%{:02X}RcCs|s%|dkr!tdn|S|tf}yt|\}}Wnftk
rtj}|jg|D]}||f^qn|j}t|}||ft|<nX|j	|s|Sdj
t||S(squote('abc def') -> 'abc%20def'

    Each part of a URL, e.g. the path info, the query, etc., has a
    different set of reserved characters that must be quoted.

    RFC 2396 Uniform Resource Identifiers (URI): Generic Syntax lists
    the following reserved characters.

    reserved    = ";" | "/" | "?" | ":" | "@" | "&" | "=" | "+" |
                  "$" | ","

    Each of these characters is reserved in some component of a URL,
    but not necessarily in all of them.

    By default, the quote function is intended for quoting the path
    section of a URL.  Thus, it will not encode '/'.  This character
    is reserved, but in typical usage the quote function is being
    called on a path where the existing slash characters are used as
    reserved characters.
    sNone object cannot be quotedRiN(R$t	TypeErrortalways_safeR.Rbt	_safe_maptcopytupdatet__getitem__trstripRtmap(ReRNtcachekeytquotertsafe_maptc((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRs 
&	
RicCs<d|kr/t||d}|jddSt||S(s9Quote the query fragment of a URL; replacing ' ' with '+'RiRh(RRV(ReRN((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRsic	Cst|dr|j}nby-t|rJt|dtrJtnWn2tk
rtj\}}}td|nXg}|sxc|D]E\}}tt	|}tt	|}|j
|d|qWnx|D]\}}tt	|}t|t	r7t|}|j
|d|qt|rst|jdd}|j
|d|qyt|Wn8tk
rtt	|}|j
|d|qXx/|D]'}|j
|dtt	|qWqWdj
|S(svEncode a sequence of two-element tuples or dictionary into a URL query string.

    If any values in the query arg are sequences and doseq is true, each
    sequence element is converted to a separate parameter.

    If the query arg is a sequence of two-element tuples, the order of the
    parameters in the output will match the order of parameters in the
    input.
    titemsis1not a valid non-string sequence or mapping objectRRDRVt&(R<RvRsRttupleRjR\R]RRRKRBRER(	tquerytdoseqttytvattbtlRRtelt((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR
s< 



)cCs]i}xPtjjD]?\}}|j}|r|ddkr|||d <qqW|S(sReturn a dictionary of scheme -> proxy server URL mappings.

    Scan the environment for variables named <scheme>_proxy;
    this seems to be the standard convention.  If you need a
    different way, you can pass a proxies dictionary to the
    [Fancy]URLopener constructor.

    it_proxy(RBtenvironRvR(R"RfR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytgetproxies_environments	cCstjjddp'tjjdd}|dkr:dSt|\}}x?|jdD].}|r\|j|s|j|r\dSq\WdS(sTest if proxies should not be used for a particular host.

    Checks the environment for a variable named no_proxy, which should
    be a list of DNS suffixes separated by commas, or '*' for all hosts.
    tno_proxyRitNO_PROXYt*iRi(RBRR>RRtendswith(RdRthostonlyRRf((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytproxy_bypass_environment/s*$tdarwin(t_get_proxy_settingst_get_proxiesc
Csddl}ddl}ddlm}t|\}}d}t}d|kri|dritSnd}x'|jdd
D]}	|	sqn|jd|	}
|
dk	r|dkry|j	|}||}Wq|j
k
rqqXn||
jd	}|
jd
}|dkrMd|
jd	jdd	}nt
|d	}d|}||?||?krtSq|||	rtSqWtS(s
        Return True iff this host shouldn't be accessed using a proxy

        This function uses the MacOSX framework SystemConfiguration
        to fetch the proxy information.
        iN(tfnmatchcSsy|jd}tt|}t|dkrM|ddddgd }n|dd>|dd>B|dd>B|d	BS(
Nt.iiiiiiii(RRqRqRs(tipAddrtparts((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytip2numSs
Rtexclude_simplet
exceptionss(\d+(?:\.\d+)*)(/\d+)?iiii ((RRZRRRRR$R>RRR[RLtcountRqtFalse(
RdRRZRRRRtproxy_settingsthostIPRtmtbasetmask((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytproxy_bypass_macosx_sysconfFs@		

#
cCstS(sReturn a dictionary of scheme -> proxy server URL mappings.

        This function uses the MacOSX framework SystemConfiguration
        to fetch the proxy information.
        (R(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytgetproxies_macosx_sysconfscCs!trt|St|SdS(N(RRR(Rd((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRs	
cCstptS(N(RR(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRsc	Csmi}yddl}Wntk
r*|SXy!|j|jd}|j|dd}|rAt|j|dd}d|krx|jdD]Y}|jdd	\}}ddl}|jd
|sd||f}n|||<qWqA|d d
kr||d<qAd||d<d||d<d||d<n|j	Wnt
ttfk
rhnX|S(sxReturn a dictionary of scheme -> proxy server URL mappings.

        Win32 uses the registry to store proxies.

        iNs;Software\Microsoft\Windows\CurrentVersion\Internet SettingstProxyEnableitProxyServerRRis^([^/:]+)://s%s://%sishttp:Rs	http://%ss
https://%sRsftp://%sR(
t_winregRtOpenKeytHKEY_CURRENT_USERtQueryValueExRRRRtClosetWindowsErrorRRj(	R"RtinternetSettingstproxyEnabletproxyServertptprotocoltaddressR((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytgetproxies_registrys:
		

cCstptS(sReturn a dictionary of scheme -> proxy server URL mappings.

        Returns settings gathered from the environment, if specified,
        or the registry.

        (RR(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRscCsyddl}ddl}Wntk
r0dSXyK|j|jd}|j|dd}t|j|dd}Wntk
rdSX|s|rdSt|\}}|g}y/t	j
|}||kr|j|nWnt	jk
rnXy/t	j
|}	|	|kr2|j|	nWnt	jk
rInX|jd}x|D]}
|
dkrd|krd	Sn|
jdd
}
|
jdd}
|
jd
d}
x*|D]"}|j|
||jrd	SqWq`WdS(Niis;Software\Microsoft\Windows\CurrentVersion\Internet SettingsRt
ProxyOverrideRs<local>Ris\.Rs.*t?(RRRRRRRRRRZRRKR[tgetfqdnRRVRR(RdRRRRt
proxyOverridetrawHostRtaddrtfqdnttesttval((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytproxy_bypass_registrysT
		

	

cCs!trt|St|SdS(sReturn a dictionary of scheme -> proxy server URL mappings.

        Returns settings gathered from the environment, if specified,
        or the registry.

        N(RRR(Rd((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyRs	
cCsd}x$tdD]}|t|}qW|d}tj}t|}t|}tj}||kr{dGHnt|GHt|GHt|GHt||dGdGHdS(NRiiisWrong!itsec(trangeR]RRRRGtround(ReRtt0tqstuqstt1((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyttest1s
cCsd|||fGHdS(Ns0Block number: %d, Block size: %d, Total size: %d((R~t	blocksizet	totalsize((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR, scCs7|s=dddddg}ttdr=|jdq=nzx|D]}dG|GdGHt|dt\}}|GH|rd
GHx%|jD]}|dG||GHqWd
GHnt|d}|j}WdQXd
|kr	t	j
dd}|j|d
}n|GHd\}}qGWddGHWdtXdS(Ns/etc/passwdsfile:/etc/passwdsfile://localhost/etc/passwdsftp://ftp.gnu.org/pub/READMEs http://www.python.org/index.htmlRs!https://synergy.as.cmu.edu/~geek/RQi
s======RROs
Rii(s
----------s
----------(NN(
R<RRKRR$R,RR&Rrtstringt	maketranst	translateR(RLR'tfnRRR`R(ttable((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyR&s6	


c	Csddl}ddl}y#|j|jdd\}}Wn!|jk
r^}|GHdGHdSXd}xK|D]C\}}|dkr|d}n|dkrldGHd	Gd
GHdSqlW|r|dkrtnt|n/|sdGHnx|D]}t|jGqWdS(NiitthsUse -h for helpis-ts-hs&Usage: python urllib.py [-t] [url ...]s-t runs self-test;s'otherwise, contents of urls are printed(tgetoptR\targvR[RRRRr(	RR\toptsRLRgtttoRR'((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pytmainEs0#



t__main__(gRRRZRBRR\turlparseRRt__all__RRRft
nturl2pathRRt
rourl2pathR$R%RRRtsslRRRR2R1R0RRRRRRRRRRRR1R)R=RTRCt	NameErrorRBRSRRJRRMRRPRRQRRSRRTRRWRRXR
RRZRR\tdictRaRR	RkRltziptxrangeRt	bytearrayRRutformatR.RRR
RRtplatformt_scproxyRRRRRRRRRR,RRR7(((sHC:\Program Files (x86)\MySQL\MySQL Workbench 6.1 CE\Python\Lib\urllib.pyt<module>s			
	
				N
"

				
									
		45'@			;			.			4			

Anon7 - 2022
AnonSec Team