Created
August 22, 2013 15:29
-
-
Save tomasfejfar/6308726 to your computer and use it in GitHub Desktop.
hostname resolver
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import socket | |
| def resolve(hostname): | |
| return socket.gethostbyname(hostname) |
socket.getaddrinfo may be a better choice ever since GHOST vulnerability was disclosed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I is possible to integrate it to asible teplates?