Module Usermanager
About the module
The Usermanager module allows you to implement user access restriction based on the switch (allow / deny).
Capabilities
- Limiting user access to the Internet.
Using
Go to the "Manager modules", find the Usermanager and click on the "Install" link.
After installation, automatically all aliases will be copied to the module. If in the process of work, you delete the alias or add in order to access it in the Usermanager module, you will need to go into this module and click on the "Refresh" link.
To implement access restrictions, the userlock.pl script is placed in the module directory. It must be added as a helper in squid.conf.
As with other Screen Squid perl scripts, you need to configure a database connection.
The additional parameter "typeid" must be set according to how you bound the aliases.
- If aliases are tied to the login, then you need to set the value to 0 (default).
- If aliases are tied to an IP address, then you need to set the value to 1
Next, you need to make changes to squid.conf.
№ p / p | Value typeid | Instructions for squid.conf |
---|---|---|
1 | 0 | #acl section external_acl_type e_lock ttl = 10 negative_ttl = 10% LOGIN /path/to/script/userlock.pl acl a_block external e_lock |
2 | 1 | #acl section external_acl_type e_lock ttl = 10 negative_ttl = 10% SRC /path/to/script/userlock.pl acl a_block external e_lock |
Remember to specify the correct / path / to / script.
For both typeid values, add a rule:
#http rules section http_access allow a_lock
Reboot Squid.
By default, access is denied. You can go to the Usermanager module, select the required user and set the flag to the "Active" property. After a few seconds, access for this user will be open.
Ideas, bugs, questions?
Feel free to contact us http://t.me/screensquid