Re: Reply_boby_size_max

2005-01-26 Por tôpico Paulo Ricardo Bruck
Em Qua, 2005-01-26 às 10:23 -0300, Marlo - Raidbr escreveu:
 Dae pessoal, 

Olá Marlo
  
 To precisando bloquear no squid downloads maiores que 20 MB, vi que o
 squid tem a opção  reply_boby_size_max mas nao consegui aplicar no
 squid 2.5, só da pau .. alguem ja usou ou conhece outra forma de
 bloquear 
  
humm o que vc quer dizer com so deu pau 
seguindo a espec do squid:

#  TAG: request_body_max_size   (KB)
#   This specifies the maximum size for an HTTP request body.
#   In other words, the maximum size of a PUT/POST request.
#   A user who attempts to send a request with a body larger
#   than this limit receives an Invalid Request error message.
#   If you set this parameter to a zero (the default), there will
#   be no limit imposed.
#
#Default:
# request_body_max_size 0 KB


se vc colocar a linha no squid.conf como:
request_body_max_size 2 KB
deve funcionar, se não funcionar poste as 30 ultimas linhas do
seu /var/log/squid/cache.log aqui

ats


 Abraço
-- 
Paulo Ricardo Bruck - consultor
Contato Global Solutions
tel 011 5031-4932  fone/fax 011 5034-1732  cel 011 9235-4327


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: Reply_boby_size_max

2005-01-26 Por tôpico Marcos Vinicius Lazarini
On Wed, 26 Jan 2005, Paulo Ricardo Bruck wrote:

 Em Qua, 2005-01-26 às 10:23 -0300, Marlo - Raidbr escreveu:
  Dae pessoal, 
 
 Olá Marlo
   
  To precisando bloquear no squid downloads maiores que 20 MB, vi que o
  squid tem a opção  reply_boby_size_max mas nao consegui aplicar no
  squid 2.5, só da pau .. alguem ja usou ou conhece outra forma de
  bloquear 
   
 humm o que vc quer dizer com so deu pau 
 seguindo a espec do squid:
 
 #  TAG: request_body_max_size   (KB)
 #   This specifies the maximum size for an HTTP request body.
 #   In other words, the maximum size of a PUT/POST request.
 #   A user who attempts to send a request with a body larger
 #   than this limit receives an Invalid Request error message.
 #   If you set this parameter to a zero (the default), there will
 #   be no limit imposed.
 #
 #Default:
 # request_body_max_size 0 KB
 
 
 se vc colocar a linha no squid.conf como:
 request_body_max_size 2 KB
 deve funcionar, se não funcionar poste as 30 ultimas linhas do
 seu /var/log/squid/cache.log aqui

Lendo a msg acima, estou com uma duvida: ao fazer download nao seria um 
'GET request'? 'PUT/POST' eh quando nos enviamos algo para o servidor, 
tipo anexo de um email, acessando o webmail... Ou estou muito por fora?

(Na verdade, lendo o texto de novo, um HTTP request eh o que voce manda
pro servidor, e um HTTP 'answer' seria o que ele te manda, no caso o
download)

-- 
Marcos



Re: Reply_boby_size_max

2005-01-26 Por tôpico Marcos Vinicius Lazarini
Paulo Ricardo Bruck wrote:
Olá Mrcos
Em Qua, 2005-01-26 às 11:41 -0200, Marcos Vinicius Lazarini escreveu:
On Wed, 26 Jan 2005, Paulo Ricardo Bruck wrote:

Em Qua, 2005-01-26 às 10:23 -0300, Marlo - Raidbr escreveu:
Dae pessoal, 
Olá Marlo
To precisando bloquear no squid downloads maiores que 20 MB, vi que o
squid tem a opção  reply_boby_size_max mas nao consegui aplicar no
squid 2.5, só da pau .. alguem ja usou ou conhece outra forma de
bloquear 

humm o que vc quer dizer com so deu pau 
seguindo a espec do squid:
#  TAG: request_body_max_size   (KB)
#   This specifies the maximum size for an HTTP request body.
#   In other words, the maximum size of a PUT/POST request.
#   A user who attempts to send a request with a body larger
#   than this limit receives an Invalid Request error message.
#   If you set this parameter to a zero (the default), there will
#   be no limit imposed.
#
#Default:
# request_body_max_size 0 KB
se vc colocar a linha no squid.conf como:
request_body_max_size 2 KB
deve funcionar, se não funcionar poste as 30 ultimas linhas do
seu /var/log/squid/cache.log aqui
Lendo a msg acima, estou com uma duvida: ao fazer download nao seria um 
'GET request'? 'PUT/POST' eh quando nos enviamos algo para o servidor, 
tipo anexo de um email, acessando o webmail... Ou estou muito por fora?

(Na verdade, lendo o texto de novo, um HTTP request eh o que voce manda
pro servidor, e um HTTP 'answer' seria o que ele te manda, no caso o
download)
veja o que fala o aruivo de conf do squid.conf 2.5.7-3  ( este mais
completo)
#  TAG: reply_body_max_size bytes allow|deny acl acl...
#This option specifies the maximum size of a reply body in
bytes.
#   It can be used to prevent users from downloading very large
files,
#   such as MP3's and movies. When the reply headers are recieved,
#   the reply_body_max_size lines are processed, and the first line
with
#   a result of allow is used as the maximum body size for this
reply.
#   This size is checked twice. First when we get the reply headers,
#   we check the content-length value.  If the content length value
exists
#   and is larger than the allowed size, the request is denied and
the
#   user receives an error message that says the request or reply
#   is too large. If there is no content-length, and the reply
#   size exceeds this limit, the client's connection is just closed
#   and they will receive a partial reply.
#
#   WARNING: downstream caches probably can not detect a partial
reply
#   if there is no content-length header, so they will cache
#   partial responses and give them out as hits.  You should NOT
#   use this option if you have downstream caches.
#
#   If you set this parameter to zero (the default), there will be
#   no limit imposed.
#
#Default:
# reply_body_max_size 0 allow all
entao voltando se vc quer bloquear dowloads maiores que 20M, coloque
reply_body_max_size 2000 allow all
e veja que se vc quizer pode fazer isto incluindo com alguma acl
específica bache estes caras do squid são bão.80)
Ah, agora esse comentário está bem mais claro, citando inclusive que 
bloqueia download, como o Marlo queria. É, me parece que o squid era bom, 
mas a documentação não era tão boa assim... :-) Ainda bem que isso mudou pra 
melhor hj em dia.

--
Marcos
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]


Re: Reply_boby_size_max

2005-01-26 Por tôpico rolim




Paulo Ricardo Bruck escreveu:

  Ol Mrcos

Em Qua, 2005-01-26 s 11:41 -0200, Marcos Vinicius Lazarini escreveu:
  
  
On Wed, 26 Jan 2005, Paulo Ricardo Bruck wrote:



  Em Qua, 2005-01-26 s 10:23 -0300, Marlo - Raidbr escreveu:
  
  
Dae pessoal, 

  
  Ol Marlo
  
  
 
To precisando bloquear no squid downloads maiores que 20 MB, vi que o
squid tem a opo " reply_boby_size_max" mas nao consegui aplicar no
squid 2.5, s da pau .. alguem ja usou ou conhece outra forma de
bloquear 
 

  
  humm o que vc quer dizer com "so deu pau" 
seguindo a espec do squid:

#  TAG: request_body_max_size   (KB)
#   This specifies the maximum size for an HTTP request body.
#   In other words, the maximum size of a PUT/POST request.
#   A user who attempts to send a request with a body larger
#   than this limit receives an "Invalid Request" error message.
#   If you set this parameter to a zero (the default), there will
#   be no limit imposed.
#
#Default:
# request_body_max_size 0 KB


se vc colocar a linha no squid.conf como:
request_body_max_size 2 KB
deve funcionar, se no funcionar poste as 30 ultimas linhas do
seu /var/log/squid/cache.log aqui
  

Lendo a msg acima, estou com uma duvida: ao fazer download nao seria um 
'GET request'? 'PUT/POST' eh quando nos enviamos algo para o servidor, 
tipo anexo de um email, acessando o webmail... Ou estou muito por fora?

(Na verdade, lendo o texto de novo, um HTTP request eh o que voce manda
pro servidor, e um HTTP 'answer' seria o que ele te manda, no caso o
download)


  
  veja o que fala o aruivo de conf do squid.conf 2.5.7-3  ( este mais
completo)

#  TAG: reply_body_max_size bytes allow|deny acl acl...
#This option specifies the maximum size of a reply body in
bytes.
#   It can be used to prevent users from downloading very large
files,
#   such as MP3's and movies. When the reply headers are recieved,
#   the reply_body_max_size lines are processed, and the first line
with
#   a result of "allow" is used as the maximum body size for this
reply.
#   This size is checked twice. First when we get the reply headers,
#   we check the content-length value.  If the content length value
exists
#   and is larger than the allowed size, the request is denied and
the
#   user receives an error message that says "the request or reply
#   is too large." If there is no content-length, and the reply
#   size exceeds this limit, the client's connection is just closed
#   and they will receive a partial reply.
#
#   WARNING: downstream caches probably can not detect a partial
reply
#   if there is no content-length header, so they will cache
#   partial responses and give them out as hits.  You should NOT
#   use this option if you have downstream caches.
#
#   If you set this parameter to zero (the default), there will be
#   no limit imposed.
#
#Default:
# reply_body_max_size 0 allow all

entao voltando se vc quer bloquear dowloads maiores que 20M, coloque

reply_body_max_size 2000 allow all

e veja que se vc quizer pode fazer isto incluindo com alguma acl
especfica bache estes caras do squid so bo.80)


[]s

  

existe alguma maneira de somente liberar downloads maiores que 20mb
somente com autorizao?, tipo, uma senha que o administrador conceda
ao usuario para que ele possa baixar o arquivo? tipo um vdeo
educativo. 

E existindo esta possibilidade, amplio mais ainda a minha pergunta,
como eu poderia liberar o acesso a internet atraves de senhas? vou dar
um exemplo de minha situacao, tenho um ambiente de trabalho, que possui
2 tipos de pessoas, os que tem acesso restrito e os que tem acesso
completo, mas pelo fato de nao saber dar acesso somente quela pessoa q
tem acesso completo, eu acabo bloqueando a maquina para acessar somente
as paginas basicas, sem a possibilidade de dar acesso completo ao que
precisa do completo (a nao ser se eu der um computador exclusivo para o
acesso completo mas ai ficaria dispendiosos pra mim), entao a unica
solucao seria pela senha, mas desta maneira nao sei como fazer isso.

atenciosamente rolim