Documentation contents

Link previews and safety checks

By default, the server blocks domains on the CERT Polska warning list. You can enable page previews separately.

A preview shows the page title, description and image below a message containing a link. Only the server fetches the page. The apps do not connect to linked sites.

Enable previews at both the server and workspace levels.

1. Server. Edit /etc/gadka/gadka.yaml.

link_previews:
  enabled: true

Restart the server with sudo systemctl restart gadka.

2. Workspace. An owner or administrator opens Admin, selects Link previews and chooses one of the following settings.

  • Enabled for all links
  • Selected domains only (one per line, including their subdomains)
  • Disabled

Previews stay off in the workspace until someone saves the policy.

KeyDefaultPurpose
link_previews.enabledfalseEnables previews for the installation
link_previews.proxyEmptyOptional outbound proxy, such as http://proxy.example.com:3128
link_previews.timeout3sFetch timeout
link_previews.max_page_bytes524288Maximum page size
link_previews.max_image_bytes1048576Maximum image size

Previews appear for messages sent or edited after previews are enabled, with up to 3 link previews per message.

Whenever someone clicks a link in a message, the server checks it against the CERT Polska warning list. Gadka blocks listed domains and all their subdomains. The user sees Link blocked.

KeyDefaultPurpose
link_safety.enabledtrueSet to false to disable checks
link_safety.sourcehttps://hole.cert.pl/domains/v2/domains.txtURL of the list, which contains one domain per line
link_safety.interval5mHow often the server fetches the list (from 1m to 6h)
link_safety.timeout30sFetch timeout
link_safety.max_bytes16777216Maximum list size
link_safety.proxyEmptyOptional outbound proxy

Owners and administrators can see the list status on the Link previews page, for example CERT Polska Warning List: up to date.

Servers without internet access

  • Set link_safety.source to an internal copy of domains.txt that you refresh from a network with internet access.
  • Set link_safety.enabled: false.

If the server has been unable to refresh the list for 24 hours, links open without a safety check. The server logs link safety: list update failed.