1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-13 13:18:06 +03:00
samba-mirror/lib/dnspython/examples/mx.py
Jelmer Vernooij 4bbc3ff037 s4-python: Move dnspython to lib/, like the other Python modules
This also avoids it from being installed if it's already present on the
system.
2010-03-29 18:05:29 +02:00

8 lines
185 B
Python
Executable File

#!/usr/bin/env python
import dns.resolver
answers = dns.resolver.query('nominum.com', 'MX')
for rdata in answers:
print 'Host', rdata.exchange, 'has preference', rdata.preference