MOON
Server: Apache/2.2.34 (Unix) mod_ssl/2.2.34 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4 FrontPage/5.0.2.2635
System: Linux server.asjudinet.com 2.6.32-042stab141.3 #1 SMP Fri Nov 15 22:45:34 MSK 2019 i686
User: asjudine (504)
PHP: 5.2.17
Disabled: NONE
Upload Files
File: //proc/3/root/usr/lib/python2.4/site-packages/dns/tsig.pyc
mò
*}Rc@sÜdZdkZdkZdkZdkZdkZdkZdkZdei	i
fd„ƒYZdei	i
fd„ƒYZdei	i
fd„ƒYZ
de
fd	„ƒYZd
e
fd„ƒYZde
fd
„ƒYZde
fd„ƒYZeiidƒZeiidƒZeiidƒZeiidƒZeiidƒZeiidƒZeZdZdZdZdZde e!ed„Z"de e!ed„Z#de e!d„Z$da%d„Z&d„Z'd„Z(dS( sDNS TSIG support.NtBadTimecBstZdZRS(sBRaised if the current time is not within the TSIG's validity time.(t__name__t
__module__t__doc__(((t,/usr/lib/python2.4/site-packages/dns/tsig.pyRstBadSignaturecBstZdZRS(s-Raised if the TSIG signature fails to verify.(RRR(((RRst	PeerErrorcBstZdZRS(s;Base class for all TSIG errors generated by the remote peer(RRR(((RR#st
PeerBadKeycBstZdZRS(s.Raised if the peer didn't know the key we used(RRR(((RR'stPeerBadSignaturecBstZdZRS(s4Raised if the peer didn't like the signature we sent(RRR(((RR+stPeerBadTimecBstZdZRS(s/Raised if the peer didn't like the time we sent(RRR(((RR	/stPeerBadTruncationcBstZdZRS(sGRaised if the peer didn't like amount of truncation in the TSIG we sent(RRR(((RR
3ssHMAC-MD5.SIG-ALG.REG.INTs	hmac-sha1shmac-sha224shmac-sha256shmac-sha384shmac-sha512iiiic
CsRt|ƒ\}}|o\ti|d|ƒ}	t	|ƒ}|djo*|	it
id|ƒƒ|	i|ƒqunt
id|ƒ}|	i|ƒ|	i|dƒ|oO|	i|iƒƒ|	it
idtiiƒƒ|	it
iddƒƒn|d}
|
d?d@}|
d	@}t
id
|||ƒ}||}t	|ƒ}|djot dƒ‚nt
id
||ƒ|}|o|	i|ƒ|	i|ƒn|	i|ƒ|	i#ƒ}t
idt	|ƒƒ}|||||}|
oKti|d|ƒ}	t	|ƒ}|	it
id|ƒƒ|	i|ƒnd}	|||	fS(sjReturn a (tsig_rdata, mac, ctx) tuple containing the HMAC TSIG rdata
    for the input parameters, the HMAC MAC calculated by applying the
    TSIG signature algorithm, and the TSIG digest context.
    @rtype: (string, string, hmac.HMAC object)
    @raises ValueError: I{other_data} is too long
    @raises NotImplementedError: I{algorithm} is not supported
    t	digestmodis!His!Ili lÿlÿÿs!HIHiÿÿs TSIG Other Data is > 65535 bytess!HHN()t
get_algorithmt	algorithmtalgorithm_nameRtfirstthmactnewtsecrettctxtlentrequest_mactmltupdatetstructtpacktoriginal_idtidtwiretkeynamet
to_digestabletdnst
rdataclasstANYttimet	long_timet
upper_timet
lower_timetfudgettime_mactpre_mact
other_datatolt
ValueErrorterrortpost_mactdigesttmactmpackt
tsig_rdatatmultitNone(RRRR"R&RR,R)RRR2RR
R#RRR%R$R'R1R/R0RR(R*RR-((RtsignGsL	







c

Cs.t||||||||||	|
||ƒ
S(N(R4RRRR"R&RR,R)RRR2RR
(
RRRR"R&RR,R)RRR2RR
((Rthmac_md5zscCsotid|dd!ƒ\}|djotii‚n|d8}|dd!tid|ƒ|d|!}|}
tii
||
ƒ\}}|
|}
tid||
|
d!ƒ\}}}}|dd>|d}|
d7}
||
|
|!}|
|7}
tid	||
|
d
!ƒ\}}}|
d
7}
||
|
|!}|
|7}
|
||jotii‚n|djop|tjo
t‚qã|tjo
t‚qã|tjo
t ‚qã|t!jo
t"‚qãt#d|ƒ‚n||}||}||jp
||jo
t'‚nt(|||||||||||	|
|ƒ
\}}}||jo
t1‚n|S(
s*Validate the specified TSIG rdata against the other input parameters.

    @raises FormError: The TSIG is badly formed.
    @raises BadTime: There is too much time skew between the client and the
    server.
    @raises BadSignature: The TSIG signature did not validate
    @rtype: hmac.HMAC objects!Hi
iiis!HIHHli s!HHHisunknown TSIG error code %dN(2RtunpackRtadcountRt	exceptiont	FormErrorRt
tsig_starttnew_wireR1tcurrenttnamet	from_wiretanametusedR$R%R&tmac_sizeR"R/RR,t
other_sizeR)t
tsig_rdlentBADSIGRtBADKEYRtBADTIMER	tBADTRUNCR
Rttime_lowt	time_hightnowRR4RRRRR2Rtjunktour_macR(RRRRJRR:R1RCRR2RRLR)R<R%R$R7R&RHRKR@R"RIRBR/RR;R?R,RA((Rtvalidate€sP

(
)

&













	

cCs4ytii|ƒt|<Wntj
onXdS(N(Rthashtgetthash_algt_hashesttsig_algtKeyError(RRRP((Rt_maybe_add_hash·scCsXhattdƒttdƒttdƒttdƒttdƒttdƒdS(NtSHA224tSHA256tSHA384tSHA512tSHA1tMD5(RQRTtHMAC_SHA224tHMAC_SHA256tHMAC_SHA384tHMAC_SHA512t	HMAC_SHA1tHMAC_MD5(((Rt
_setup_hashes½s




cCsØtdjotƒnt|ttfƒotii	|ƒ}nt
idjo8|tjp
|t
jotdt|ƒdƒ‚ny|iƒt|fSWn-tj
o!tdt|ƒdƒ‚nXdS(sÊReturns the wire format string and the hash module to use for the
    specified TSIG algorithm

    @rtype: (string, hash constructor)
    @raises NotImplementedError: I{algorithm} is not supported
    isTSIG algorithm s requires Python 2.5.2 or laters is not supportedN(RQR3Rat
isinstanceR
tstrtunicodeRR=t	from_texttsyst
hexversionR]R^tNotImplementedErrorRRS(R
((RRÇs
*()RRRRft
dns.exceptionRtdns.hashtdns.rdataclasstdns.nameR8tDNSExceptionRRRRRR	R
R=ReR`R_R[R\R]R^tdefault_algorithmRDRERFRGR3tFalsetTrueR4R5RMRQRTRaR(RnRR4RRER^R5RRFRR[RR	RGR]RfR`RMRTRR\R
RaRR_RRDR((Rt?s@							35