> For the complete documentation index, see [llms.txt](https://docs.videsk.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.videsk.io/es-developers/seguridad/cabeceras.md).

# Cabeceras

Dependiendo de la configuración de tu sitio web y dónde esté alojado deberás configurar ciertas cabeceras en tu servidor web.

{% hint style="info" %}
**Las cabeceras son opcionales**, pero son sugeridas para añadir mayor seguridad a tu sitio web. **Si no posees ninguna de ellas no es obligatorio añadirlas.**
{% endhint %}

## Feature-Policy o Permissions-Policy

Esta cabecera define donde y que tipos de características del navegador se pueden utilizan en tu sitio, como cámara, micrófono, GPS, giroscopio, batería, etc. Si tienes activada esta cabecera deberás añadir al listado:

```
Feature-Policy: microphone 'self'; camera 'self'; autoplay 'self'; fullscreen 'self'; picture-in-picture 'self'
Permissions-Policy: autoplay=(self), camera=(self), fullscreen=(self), microphone=(self), picture-in-picture=(self)
```

## X-Frame-Options

Esta cabecera es vital en términos de seguridad, evita que embeban tu sitio web en uno externo suplantando tu identidad y potencialmente extraer datos de tus usuarios. Por ello, te sugerimos añadirla como mínimo en `SAMEORIGIN`.

```
X-Frame-Options: SAMEORIGIN;
```

{% hint style="info" %}
Si configuras el valor en `DENY` podrías perder ciertas funcionalidades de Videsk.
{% endhint %}

## Content-Security-Policy

Esta cabecera (CSP) permite definir que tipo de contenido se tiene permitido cargar para cada servicio y tipo de recursos registrados en esta cabecera.

```
Content-Security-Policy: media-src 'self' *.videsk.io; connect-src 'self' *.videsk.io; default-src 'self' 'unsafe-inline' *.videsk.io
```

{% hint style="warning" %}
Sin `connect-src 'self' *videsk.io` provocarás que las conexiones WebSocket sean bloqueadas.
{% endhint %}

## Content-Security-Policy-Report-Only

Esta cabecera permite experimentar con ciertas políticas de cabeceras antes de implementar oficialmente, sin generar necesariamente un impacto real sobre tu sitio, dando así la opción de monitorear el comportamiento.

Te sugerimos añadir lo mismo que en Content-Security-Policy (CSP).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.videsk.io/es-developers/seguridad/cabeceras.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
