[Feature] URL Preview
Description
URL Preview from Matrix API to show Image / Metadate of a linked URL.
Example: /_matrix/media/r0/preview_url?url=https%3A%2F%2Fmatrix.org&ts=1510610716656 HTTP/1.1
Output
{
"og:title": "Matrix Blog Post",
"og:description": "This is a really cool blog post from matrix.org",
"og:image": "mxc://example.com/ascERGshawAWawugaAcauga",
"og:image:type": "image/png",
"og:image:height": 48,
"og:image:width": 48,
"matrix:image:size": 102400
}
I guess this could also mean direct links to images would be shown? Then it may be a half-way solution for inline gifs even.
It would also be interesting to be able to disable this function, as vulnerabilities have recently been revealed using cloaking.
I think there is a property that can be set on a per room basis whether or not you want url previews.
- https://spec.matrix.org/latest/client-server-api/#get_matrixmediav3preview_url
Naturally the migration ate the spec link.
It would also be interesting to be able to disable this function, as vulnerabilities have recently been revealed using cloaking.
What vulnerabilities and user cloaking are you referring to?
Note that URL previews shouldn't be performed on client side regardless of the insecurity nightmare Element is requested and performs.
- https://github.com/element-hq/element-meta/issues/1138#issuecomment-1966165279
- https://github.com/element-hq/element-meta/discussions/2309
- https://github.com/krille-chan/fluffychat/issues/912
+1
Will this ever be implemented?
Hey, at the moment we're uncomfortable implementing this feature because it can easily bypass end-to-end encryption. As soon as there's a solution or a good alternative, we'll address it.
Why don't you implement it similarly to the element client? There you have a setting on room level. That setting is already part of the standard room setting data. There you can deactivate previews for the whole room.
As other clients already implement this you gain no security as the chat partners might already be generating previews.