Use cases of fep-8b32: Object Integrity Proofs

In theory FEP-8b32 may unlock content-addressing, but I haven’t figured out how to introduce it without breaking compatibility with existing software.

In ActivityPub, id property is required, but one can’t know the hash of the object before hashing it. Possible workaround: sign everything except the id:

{
    "type": "Note",
    "attributedTo": "https://test.example/users/alice",
    "content": "Example",
    "proof": {
        "excludedProperties": "id",
        ...FEP-8b32 proof
    }
}

Let’s assume that IPFS CID of this object is bafybeihc4hti5ix4ds2tefhy35qd. The content URI will be ipfs://bafybeihc4hti5ix4ds2tefhy35qd.

The AP server should also work as IPFS gateway and use /ipfs/<cid> template to generate the ID:

{
    "id": "https://test.example/ipfs/bafybeihc4hti5ix4ds2tefhy35qd"
    "type": "Note",
    "attributedTo": "https://test.example/users/alice",
    "content": "Example",
    "proof": {
        "excludedProperties": "id"
        ...FEP-8b32 proof
    }
}

Implementations that support content addressing can ignore the host name and load object directly from IPFS, they will also know how to re-create ID. Everyone else will fetch it via HTTP. The server may even insert id property when serving objects via HTTP to provide backwards compatibility.

That might work. Unfortunately, Data Integrity spec doesn’t support partial signing, and there’s no such parameter as excludedProperties.