This requirement arose when I started to see spam registrations from a ycykly.com. ycykly.com seems to be either hacked by spammers who are using domain to spam registrations or the domain owner is spamming by himself.
In Drupal it is very easy to block registration or access from a specific domain.
This is done by using Access Rule.
From Admin -> User Management -> Access Rules click on Add Rule to add a new rule
Check Deny under Access Type
And select E-mail under Rule type
In the Mask field add the domain name. In this example I’ve added %ycykly.com which will block registration/access from ycykly.com domain.
Next time this spammer tries to register from ycykly.com domain, he will be greeted with following message
The e-mail address firstname.lastname@example.org has been denied access.