Signature: I was meaning here that it checks a signature of the server alone. It is not imperative but it would make sure that the server has issued such a link.
I don’t get what you mean by that. Our server is only manipulating encrypted data, it does not know the content of the file which doesn’t leave collaborators’ computers. Basically: what do you propose to sign?
Which comes back to your further remark:
however as is, nothing could prevent someone you shared your document to share it “with opengraph enabled” and thus breaks the security for all contributors. We cannot allow this.
Why would this be a problem? The same problem occurs if someone shares an editing link, for example: everyone accessing the URL can edit.
The server is not aware of the key and cannot derive anything besides the document type (to load the correct app). There is extra information that a semi-honest server can try to derive, but nothing compromising.
In your proposal, upon deriving a “link with preview”, you have to give access to (part) of the plaintext to the server for it to be able to serve these data, which can contain sensitive data (such as the document title). Indeed sharing the link gives access to those with the link (except when using an extra password on the document), however the server remains oblivious to which data it’s serving.
I understand that you want it to be “upon request”. However, my point is that once shared, it’ll be hard to avoid one of the collaborator having the link from creating such a link. As such, it may potentially be leaking sensitive data to the server without you knowing the better.
That parts of the contents (title, start) is shared is, of course, not possible to deliver from the server by decrypting the contents (we know it cannot). It would be included in the link!
The information have to be encoded somehow in the link, which is already pretty long…
Thus the role of the sever of the shared link would be, besides executing the sharing link with javascript functions to get you to view or edit as desired, to represent the information given in the URL (before the "#") within the meta tags if the checkbox "add title and description" was checked.
Unfortunately, as I already said, providing these pieces of information to the server breaks our threat model as it gives potentially sensitive information to the server.
I agree that it would be an interesting feature from a UX perspective, however we cannot compromise on data privacy for that.
Regards,
– Fabrice