The utility module is a collection of utility useful for the module developer.
Feel free to inspect the code and modify it. Send me a patch if you did it.
A module that allows you to disable login to specified roles and also prevent new registrations and disable new password requests.
I have several sites that have a fallback solution (using dnsmadeeasy) that when the master server is unavailable for a specified period of time users are automatically rerouted to my backup server, but as they are ecommerce sites I want uses to be able to browse the site (and store) but not login and or make any changes because when the master site comes back online, I dont want to have to reconcile the data from backup to master (the master data is copied to the backup nightly). Because of the issue with the master overwriting data on the backup I have allowed configuration of what roles can login and what can not login based on the server IP (and the data is identical on each server so wont get overwritten).
This module can also be used for disabling login on a normal site (ie not a fallback situation) Just set the master server IP to that of your server and ignore the slave settings. You can then manually disable login access (and also prevent password request/account creation) and can do it for a specific role or all roles (except admin).
The current version is for drupal 7 but it should not be too difficult to mod for 6.