Package dns :: Module flags
[show private | hide private]
[frames | no frames]

Module dns.flags

DNS Message Flags.
Function Summary
int edns_from_text(text)
Convert a space-separated list of EDNS flag text values into a EDNS flags value.
string edns_to_text(flags)
Convert an EDNS flags value into a space-separated list of EDNS flag text values.
int from_text(text)
Convert a space-separated list of flag text values into a flags value.
string to_text(flags)
Convert a flags value into a space-separated list of flag text values.
  _from_text(text, table)
  _order_flags(table)
  _to_text(flags, table, order)

Variable Summary
int AA = 1024                                                                  
int AD = 32                                                                    
int CD = 16                                                                    
int DO = 32768                                                                 
int QR = 32768                                                                 
int RA = 128                                                                   
int RD = 256                                                                   
int TC = 512                                                                   
dict _by_text = {'AA': 1024, 'QR': 32768, 'AD': 32, 'CD': 16,...
dict _by_value = {1024: 'AA', 32768: 'QR', 32: 'AD', 128: 'RA...
dict _edns_by_text = {'DO': 32768}
dict _edns_by_value = {32768: 'DO'}
list _edns_flags_order = [(32768, 'DO')]
list _flags_order = [(32768, 'QR'), (1024, 'AA'), (512, 'TC')...

Function Details

edns_from_text(text)

Convert a space-separated list of EDNS flag text values into a EDNS flags value.
Returns:
int

edns_to_text(flags)

Convert an EDNS flags value into a space-separated list of EDNS flag text values.
Returns:
string

from_text(text)

Convert a space-separated list of flag text values into a flags value.
Returns:
int

to_text(flags)

Convert a flags value into a space-separated list of flag text values.
Returns:
string

Variable Details

AA

Type:
int
Value:
1024                                                                  

AD

Type:
int
Value:
32                                                                    

CD

Type:
int
Value:
16                                                                    

DO

Type:
int
Value:
32768                                                                 

QR

Type:
int
Value:
32768                                                                 

RA

Type:
int
Value:
128                                                                   

RD

Type:
int
Value:
256                                                                   

TC

Type:
int
Value:
512                                                                   

_by_text

Type:
dict
Value:
{'AA': 1024, 'QR': 32768, 'AD': 32, 'CD': 16, 'RD': 256, 'RA': 128, 'T\
C': 512}                                                               

_by_value

Type:
dict
Value:
{1024: 'AA', 32768: 'QR', 32: 'AD', 128: 'RA', 256: 'RD', 16: 'CD', 51\
2: 'TC'}                                                               

_edns_by_text

Type:
dict
Value:
{'DO': 32768}                                                          

_edns_by_value

Type:
dict
Value:
{32768: 'DO'}                                                          

_edns_flags_order

Type:
list
Value:
[(32768, 'DO')]                                                        

_flags_order

Type:
list
Value:
[(32768, 'QR'),
 (1024, 'AA'),
 (512, 'TC'),
 (256, 'RD'),
 (128, 'RA'),
 (32, 'AD'),
 (16, 'CD')]                                                           

Generated by Epydoc 2.1 on Sun Jan 30 10:41:36 2005 http://epydoc.sf.net