Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

206
Vistas
How to specify a whitelist for HTTP basic authentication (to except certain paths from requiring a password)?

Here's the essential part of my current configuration, where I protect my entire website using HTTP basic authentication:

<VirtualHost *:443>
  <Location "/">
    AuthType Basic
    AuthName "Protected Area"

    AuthBasicProvider file
    AuthUserFile /path/to/passwords_file

    Require valid-user
  </Location>
</VirtualHost>

However, I want to except certain paths so they are publicly available, specifically robots.txt, favicon.ico, manifest.json. How to do this?

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Adding the following configuration block after the existing Location one will except the specified paths from requiring a password:

<Location ~ "^/favicon\.ico$|^/manifest\.json$|^/robots\.txt$">
    Require all granted
</Location>

This one uses a single regex matching string for all files, but you could also specify each of them individually, one at a time, without using regex:

<Location "/favicon.ico">
    Require all granted
</Location>

<Location "/manifest.json">
    Require all granted
</Location>

<Location "/robots.txt">
    Require all granted
</Location>
over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda