选择文件�文件大�最�修改时间�作
[📄] 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
ó ¢báWc@sŠdZddlZddlZddlZddlZddlZddlZddlZddl m Z dej j fd„ƒYZ dS(sDNS Dynamic Update SupportiÿÿÿÿNi(t string_typestUpdatecBs€eZejjd d ejjd„Zd d d„Z d„Z d„Z d„Z d„Z d„Zd d„Zd dd „ZRS( c Csått|ƒjƒ|jtjjtjjƒO_t|t ƒrXtj j |ƒ}n||_ t|t ƒr…tj j |ƒ}n||_|j|j|j |tjjdtdtƒ|dk rá|j||d|ƒndS(säInitialize a new DNS Update object. @param zone: The zone which is being updated. @type zone: A dns.name.Name or string @param rdclass: The class of the zone; defaults to dns.rdataclass.IN. @type rdclass: An int designating the class, or a string whose value is the name of a class. @param keyring: The TSIG keyring to use; defaults to None. @type keyring: dict @param keyname: The name of the TSIG key to use; defaults to None. The key must be defined in the keyring. If a keyring is specified but a keyname is not, then the key used will be the first key in the keyring. Note that the order of keys in a dictionary is not defined, so applications should supply a keyname when a keyring is used, unless they know the keyring contains only one key. @type keyname: dns.name.Name or string @param keyalgorithm: The TSIG algorithm to use; defaults to dns.tsig.default_algorithm. Constants for TSIG algorithms are defined in dns.tsig, and the currently implemented algorithms are HMAC_MD5, HMAC_SHA1, HMAC_SHA224, HMAC_SHA256, HMAC_SHA384, and HMAC_SHA512. @type keyalgorithm: string tcreatet force_uniquet algorithmN(tsuperRt__init__tflagstdnstopcodetto_flagstUPDATEt isinstanceRtnamet from_texttorigint rdataclasst zone_rdclasst find_rrsettquestiont rdatatypetSOAtTruetNonetuse_tsig(tselftzonetrdclasstkeyringtkeynamet keyalgorithm((s./usr/lib/python2.7/site-packages/dns/update.pyRs!  !  c Csb|dkr|j}n|jƒ}|j|||j|j||ttƒ}|j||ƒdS(s&Add a single RR to the update section.N(Rt authoritytcoversRRtrdtypeRtadd(RR tttltrdtdeletingtsectionR trrset((s./usr/lib/python2.7/site-packages/dns/update.pyt_add_rrEs    c Gs¿t|tƒr'tjj|dƒ}nt|dtjjƒr�xx|D]O}|ri|j||j ƒnx*|D]"}|j ||j |d|ƒqpWqGWnt |ƒ}t |jdƒƒ}t|dtjjƒr$|r÷|j||dj ƒnxÁ|D]}|j |||d|ƒqþWn—|jdƒ}t|tƒrWtjj|ƒ}n|rp|j||ƒnxH|D]@} tjj|j|| |jƒ}|j |||d|ƒqwWdS(sœAdd records. The first argument is the replace mode. If false, RRs are added to an existing RRset; if true, the RRset is replaced with the specified contents. The second argument is the section to add to. The third argument is always a name. The other arguments can be: - rdataset... - ttl, rdata... - ttl, rdtype, string...iR&N(R RRR RRtrdatasettRdatasettdeleteR!R(R#tlisttinttpoptrdatatRdataRRR( RtreplaceR&R targstrdsR$R#R!ts((s./usr/lib/python2.7/site-packages/dns/update.pyt_addOs0   '     cGs|jt|j||ŒdS(sÁAdd records. The first argument is always a name. The other arguments can be: - rdataset... - ttl, rdata... - ttl, rdtype, string...N(R5tFalseR(RR R2((s./usr/lib/python2.7/site-packages/dns/update.pyR"ws c Gsöt|tƒr'tjj|dƒ}nt|ƒdkry|j|j|tj j tj j tj j tj j t t ƒnyt|dtjjƒrÓx]|D]3}x*|D]"}|j|d|tj j ƒq¦Wq™Wnt|ƒ}t|dtjjƒr(x÷|D]"}|j|d|tj j ƒqÿWnÊ|jdƒ}t|tƒr[tj j|ƒ}nt|ƒdkr¤|j|j||j|tj j tj j t t ƒnNxK|D]C}tjj|j|||jƒ}|j|d|tj j ƒq«WdS(sÚDelete records. The first argument is always a name. The other arguments can be: - I{nothing} - rdataset... - rdata... - rdtype, [string...]iN(R RRR RRtlenRRRtANYRtNONERR)R*R(R,R/R0R.RR(RR R2R3R$R!R4((s./usr/lib/python2.7/site-packages/dns/update.pyR+‚s6   '  #      cGs|jt|j||ŒdS(sQReplace records. The first argument is always a name. The other arguments can be: - rdataset... - ttl, rdata... - ttl, rdtype, string... Note that if you want to replace the entire node, you should do a delete of the name followed by one or more calls to add.N(R5RR(RR R2((s./usr/lib/python2.7/site-packages/dns/update.pyR1­s c Gsnt|tƒr'tjj|dƒ}nt|ƒdkrs|j|j|tj j tj j tj j dt t ƒn÷t|dtjjƒs·t|dtjjƒs·t|ƒdkr t|dtjjƒsït|ƒ}|jddƒn|jt|j||Œn_|d}t|tƒr9tj j|ƒ}n|j|j|tj j |tj j dt t ƒdS(sBRequire that an owner name (and optionally an rdata type, or specific rdataset) exists as a prerequisite to the execution of the update. The first argument is always a name. The other arguments can be: - rdataset... - rdata... - rdtype, string...iiN(R RRR RRR7RtanswerRR8RR9RR)R*R/R0R,tinsertR5R6(RR R2R!((s./usr/lib/python2.7/site-packages/dns/update.pytpresent¼s*       c CsÆt|tƒr'tjj|dƒ}n|dkrm|j|j|tjj tj j tj j dt t ƒnUt|tƒr‘tj j|ƒ}n|j|j|tjj |tj j dt t ƒdS(s‚Require that an owner name (and optionally an rdata type) does not exist as a prerequisite to the execution of the update.N( R RRR RRRR:RR9RR8R(RR R!((s./usr/lib/python2.7/site-packages/dns/update.pytabsentàs     iÿÿcCs1|dkr|j}ntt|ƒj||ƒS(scReturn a string containing the update in DNS compressed wire format. @rtype: stringN(RRRRtto_wire(RRtmax_size((s./usr/lib/python2.7/site-packages/dns/update.pyR>ós  N(t__name__t __module__RRtINRttsigtdefault_algorithmRR(R5R"R+R1R<R=R>(((s./usr/lib/python2.7/site-packages/dns/update.pyRs % ( +  $ (t__doc__t dns.messageRtdns.namet dns.opcodet dns.rdatatdns.rdataclasst dns.rdatasettdns.tsigt_compatRtmessagetMessageR(((s./usr/lib/python2.7/site-packages/dns/update.pyts