A Python module written by Richard Penman to perform whois lookup.
Questions tagged [pywhois]
29 questions
4
votes
1 answer
How to find out programmatically if a domain name is registered or not
I use pywhois to determine if a domain name is registered or not. Here is my source code. (all permutations from a.net to zzz.net)
#!/usr/bin/env python
import whois #pip install python-whois
import string
import itertools
def main():
…

SparkAndShine
- 17,001
- 22
- 90
- 134
4
votes
5 answers
Doing a whois with a list of domain names
I've got a file of domain names e.g. equivalent to 2500.
I would like to do a whois on these domain names.
Issue is I've never done that and don't know where to start. If you have any ideas, I'm all ears.
TIA.

Andy K
- 4,944
- 10
- 53
- 82
3
votes
2 answers
In Python, Getting More Info About An IP Address
I know about gethostbyaddr in Python and that is somewhat useful for me. I would like to get even more info about an ip address like one can find at various websites such as who hosts that ip address, the country of origin, ..., etc. I need to…

demongolem
- 9,474
- 36
- 90
- 105
3
votes
1 answer
AttributeError: module 'whois' has no attribute 'whois'
I am running my ML code and getting this error-
Enter website name=> www.google.com
Traceback (most recent call last):
File "Dphishing.py", line 12, in
p2.category2(website)
File "C:\xampp\htdocs\Detect_Phishing_Website\p2.py",…

weirdo 2045
- 31
- 1
- 3
3
votes
2 answers
AttributeError: 'module' object has no attribute 'whois'
I tried to execute this code:
import whois
w = whois.whois('webscraping.com')
print w
And I got the error above.
Why?

shira stenmetz
- 297
- 1
- 6
- 11
3
votes
2 answers
error when using pywhois
I tryed to use pywhois to check domain availability:
import pywhois
try:
w = pywhois.whois('domain_name')
message='Domain is available'
except:
message='Domain is not available'
but I get this error:
'module' object has no…

Asma Gheisari
- 5,794
- 9
- 30
- 51
2
votes
1 answer
Installing a Python module in Windows
I'm trying to install a Python module on my Windows computer. I installed the development version of the NetBeans IDE to use as my Python editor, and it seems that they install Jython 2.5 under their own program folder, and force you to use that…

MarathonStudios
- 2,849
- 4
- 20
- 18
2
votes
0 answers
Want to find domain age of bulk domains using python
i am working on project where i am supposed to find domain age of bulk domains using python.
in python i found library called python-whois it works fine with small number of domains upto 8 domains much precisely ,after that it gives some error like…

Sahil Hussain Dar
- 21
- 3
1
vote
0 answers
Why do I get none instead of getting the data? How do I fix this?
I use python whois #https://pypi.org/project/python-whois/
In most cases, I get None. Help please
How to solve this problem?
import whois
w = whois.whois('job.kg')
print(w.domain_name, w.creation_date, w.expiration_date)
print(w)
JOB.KG Fri Oct…

Creator X
- 41
- 6
1
vote
1 answer
How to use WHOIS queries from python script when port 43 is likely not accessible
Im very new to network programming and faced a following problem:
Im working on VMware CentOS7 virtual machine on Windows10 host.
My script should send WHOIS queries and parse their output (e.g. expiration date).
However, an attempt to send a query…

data sherlock
- 13
- 3
1
vote
1 answer
Getting error with pywhois package
I am creating a python script which iterates over a list containing domain names, in most cases it is working well (with package downloaded from https://bitbucket.org/richardpenman/pywhois), but sometimes i got error saying: Socket Error: [Errno…

IamK
- 2,753
- 5
- 30
- 39
1
vote
2 answers
How to avoid program freezing when connecting to server
I have a little script which filters those domain names which are not registred yet. I use pywhois module. The problem is that it suddenly freeze and do nothing after several (sometimes hundreds) of requests. I think it is not a ban because I can…

Milano
- 18,048
- 37
- 153
- 353
1
vote
0 answers
No whois server is known for this kind of object
I get the error message when calling from PHP:
$content= exec("whois sanei-office.com");
I get the message:
No whois server is known for this kind of object
But when calling from terminal (same linux server), the request works.

Ploetzeneder
- 1,281
- 4
- 20
- 34
1
vote
4 answers
Datetime object
How do I get the year and month from a datetime.datetime object? Here is the code
I have problems with:
w = whois.whois('http://stackoverflow.com')
datatime = w.expiration_date
print datatime
the printed object is:
[datetime.datetime(2015, 12, 26,…

Brana
- 1,197
- 3
- 17
- 38
1
vote
1 answer
Django Buildout recipe for pywhois (not on pypi)
I Am trying to create a buildout recipe for pywhois on google code.
The site of which is here:
http://code.google.com/p/pywhois/
Note: if you use easy_install pywhois it installs another package from pypi (python package index) :…

michel.iamit
- 5,788
- 9
- 55
- 74