[squid-users] 答复: [squid-users] 答复: [squid-users] How to set different maxconn number of proxy_auth user from default maxconn?

From: Jiang Wen Dong <wendong.jiang_at_td-tech.com>
Date: Mon, 5 Mar 2012 17:38:51 +0800

Thank you.
But there's still a problem, !proxy_auth user will see a auth dialog window, that is not what I want.
I want !proxy_auth user pass trough, without auth dialog window.

------------------------------------------------
Jiang Wendong (姜文栋)
IT Dept.
Tel: 010-5822-3486/3481
Mobile: 13811249966
E-Mail: wendong.jiang_at_td-tech.com / jiangwendong_at_huawei.com



-----邮件原件-----
发件人: Amos Jeffries [mailto:squid3_at_treenet.co.nz]
发送时间: 2012年3月5日 17:11
收件人: squid-users_at_squid-cache.org
主题: Re: [squid-users] 答复: [squid-users] How to set different maxconn number of proxy_auth user from default maxconn?

On 5/03/2012 8:33 p.m., Jiang Wen Dong wrote:
> This is not what I want.
> I want proxy_auth user maxconn=100, others maxconn=50.

Yes. That is what the config I wrote does.

# if user has connections >= 100, deny even if logged in # else if user is logged in, allow (up to 100) # else if connections >= 50, deny more than 50 connections

(extra lines are for good security, allowing random person on The Internet 50 connections is not good) # else other local clients, allow # else deny

Amos

> -----邮件原件-----
> 发件人: Amos Jeffries
>
> On 05.03.2012 14:16, Jiang Wen Dong wrote:
>> My English is not good, hope you can understand what I'm saying.
>>
>> I want to set default maxconn=50, and maxconn=100 for proxy_auth user.
>>
>> If I set default maxconn before proxy_auth, then proxy_auth user get
>> maxconn=50, not maxconn=100.
>>
>> If I set default maxconn after proxy_auth, every user get a auth
>> dialog window, which I do not want it show for !proxy_auth user.
>>
>> How to set different maxconn number of proxy_auth user from default
>> maxconn?
>>
> You are thinking about this backwards. Place the widest "everybody"
> limitations first. Then the highest privileged allow permissions. Then repeat as you gradually restrict things.
>
> Like this:
>
> acl login proxy_auth REQUIRED
> acl 100cc maxconn 100
> acl 50cc maxconn 50
>
> # nobody allowed more than 100 connections
> http_access deny 100cc
>
> # login users the only ones allowed more than 50
> http_access allow login
> http_access deny 50cc
>
> # then other LAN clients...
> http_access allow localnet
>
> # everything not permitted yet is not trusted for any access.
> http_access deny all
>
> Amos
>

CAUTION: This message may contain privileged and confidential information intended only for the use of the addressee named above. If you are not the intended recipient of this message you are hereby notified that any use, distribution or reproduction of this message is prohibited. If you have received this message in error please notify the sender of this message immediately. ( ©TD Tech Co.,Ltd)
重要提示:此邮件及附件具保密性质,包含商业秘密、受法律保护不得泄露。如果您意外收到此邮件,特此提醒您此邮件的机密性,请立即通知我们并从您的系统中删除此邮件及附件。如果您不是此邮件应当的收件人,请注意不可对此邮件及其附件进行利用、复制或向他人透露其内容。 ( ©TD Tech Co.,Ltd)
Received on Mon Mar 05 2012 - 09:39:03 MST

This archive was generated by hypermail 2.2.0 : Mon Mar 05 2012 - 12:00:02 MST