Skip to content

Piero Bosio Social Web Site Personale Logo Fediverso

Social Forum federato con il resto del mondo. Non contano le istanze, contano le persone

Adjusting #Enigmatick's previously built functions to align with the #ActivityPub #E2EE draft.

General Discussion
8 3 25
  • Adjusting #Enigmatick's previously built functions to align with the #ActivityPub #E2EE draft.

    KeyPackage collection on the Actor object

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt | jq '.keyPackages'
    

    Response

    "https://enigmatick.social/user/jdt/keys"
    

    Retrieve the KeyPackage Collection

    These are populated by the client (the browser using the wasm module loaded in the Svelte SPA). I had a different mechanism in place for managing this (using the instrument field on Activities) but am updating it to use the Add flow for the Collection as specified by the draft.

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt/keys | jq
    

    Response

    {
      "@context": "https://www.w3.org/ns/activitystreams",
      "type": "Collection",
      "id": "https://enigmatick.social/user/jdt/keys",
      "totalItems": 39,
      "next": "https://enigmatick.social/user/jdt/keys?mkp=true"
    }
    

    Follow the next link to retrieve a KeyPackage

    This will mark the KeyPackage as distributed and would typically link it to the Actor that signed the request (that's temporarily disabled for testing).

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt/keys?mkp=true | jq
    

    Response

    {
      "@context": [
        "https://www.w3.org/ns/activitystreams",
        "https://purl.archive.org/socialweb/mls"
      ],
      "type": "Collection",
      "totalItems": 1,
      "items": [
        {
          "type": "KeyPackage",
          "id": "https://enigmatick.social/key-package/cfde7b54-8d08-41e9-8eb5-d997a12e9347",
          "attributedTo": "https://enigmatick.social/user/jdt",
          "to": [
            "https://www.w3.org/ns/activitystreams#Public"
          ],
          "mediaType": "message/mls",
          "encoding": "base64",
          "content": "AAEAASCOWe7uxA8tPeI01nDP8ka2irEhgfkK2qM81/o+tEKPEiCz2h2Vv6VVuGSx/C0WINQCuazZm4rQAymxd1JdHGVvaSDurWzIE3z5eXUFz5coFGv9db7DxZDx0arb/gyRuidCAgABImh0dHBzOi8vZW5pZ21hdGljay5zb2NpYWwvdXNlci9qZHQCAAEIAAEAAgADAE0KAAEAAgADAAQABQwAAQACAAMABAAFAAcCAAEBAAAAAGeDNwsAAAAAZ/IDGwBAQJUffd/8/Efgt0ITBeMWfJYcb7S8E5U7yyUINiIUfqmsGwcvTyam6C+9F+k64NBEs0rXjGMjPA6AgiZ2oR4/1wwAQECliseeQfQb0zgq755ZiiujRqLkEWt8WOTJSsBXHK6hey6bNs4wet782NL8k92h1BNuPZDzxHaHXdXe1wgBO6QJ"
        }
      ]
    }
    
  • Adjusting #Enigmatick's previously built functions to align with the #ActivityPub #E2EE draft.

    KeyPackage collection on the Actor object

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt | jq '.keyPackages'
    

    Response

    "https://enigmatick.social/user/jdt/keys"
    

    Retrieve the KeyPackage Collection

    These are populated by the client (the browser using the wasm module loaded in the Svelte SPA). I had a different mechanism in place for managing this (using the instrument field on Activities) but am updating it to use the Add flow for the Collection as specified by the draft.

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt/keys | jq
    

    Response

    {
      "@context": "https://www.w3.org/ns/activitystreams",
      "type": "Collection",
      "id": "https://enigmatick.social/user/jdt/keys",
      "totalItems": 39,
      "next": "https://enigmatick.social/user/jdt/keys?mkp=true"
    }
    

    Follow the next link to retrieve a KeyPackage

    This will mark the KeyPackage as distributed and would typically link it to the Actor that signed the request (that's temporarily disabled for testing).

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt/keys?mkp=true | jq
    

    Response

    {
      "@context": [
        "https://www.w3.org/ns/activitystreams",
        "https://purl.archive.org/socialweb/mls"
      ],
      "type": "Collection",
      "totalItems": 1,
      "items": [
        {
          "type": "KeyPackage",
          "id": "https://enigmatick.social/key-package/cfde7b54-8d08-41e9-8eb5-d997a12e9347",
          "attributedTo": "https://enigmatick.social/user/jdt",
          "to": [
            "https://www.w3.org/ns/activitystreams#Public"
          ],
          "mediaType": "message/mls",
          "encoding": "base64",
          "content": "AAEAASCOWe7uxA8tPeI01nDP8ka2irEhgfkK2qM81/o+tEKPEiCz2h2Vv6VVuGSx/C0WINQCuazZm4rQAymxd1JdHGVvaSDurWzIE3z5eXUFz5coFGv9db7DxZDx0arb/gyRuidCAgABImh0dHBzOi8vZW5pZ21hdGljay5zb2NpYWwvdXNlci9qZHQCAAEIAAEAAgADAE0KAAEAAgADAAQABQwAAQACAAMABAAFAAcCAAEBAAAAAGeDNwsAAAAAZ/IDGwBAQJUffd/8/Efgt0ITBeMWfJYcb7S8E5U7yyUINiIUfqmsGwcvTyam6C+9F+k64NBEs0rXjGMjPA6AgiZ2oR4/1wwAQECliseeQfQb0zgq755ZiiujRqLkEWt8WOTJSsBXHK6hey6bNs4wet782NL8k92h1BNuPZDzxHaHXdXe1wgBO6QJ"
        }
      ]
    }
    

    If the private keys are stored on the instance, how is this any better than what we have now?

  • If the private keys are stored on the instance, how is this any better than what we have now?

    @rimu@piefed.social What makes you think it's a private key? (It's not.)

    Here's some information with examples of how the keys are used and exchanged.

  • If the private keys are stored on the instance, how is this any better than what we have now?

    @rimu@piefed.social And no, the instance admin cannot decrypt the communications. The KeyPackage is a public key used to start an encrypted message exchange. But it cannot be used to decrypt any of the messages.

  • @rimu@piefed.social And no, the instance admin cannot decrypt the communications. The KeyPackage is a public key used to start an encrypted message exchange. But it cannot be used to decrypt any of the messages.

    Ah I see, thanks 👍

  • Ah I see, thanks 👍

    @rimu@piefed.social No problem!

  • Adjusting #Enigmatick's previously built functions to align with the #ActivityPub #E2EE draft.

    KeyPackage collection on the Actor object

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt | jq '.keyPackages'
    

    Response

    "https://enigmatick.social/user/jdt/keys"
    

    Retrieve the KeyPackage Collection

    These are populated by the client (the browser using the wasm module loaded in the Svelte SPA). I had a different mechanism in place for managing this (using the instrument field on Activities) but am updating it to use the Add flow for the Collection as specified by the draft.

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt/keys | jq
    

    Response

    {
      "@context": "https://www.w3.org/ns/activitystreams",
      "type": "Collection",
      "id": "https://enigmatick.social/user/jdt/keys",
      "totalItems": 39,
      "next": "https://enigmatick.social/user/jdt/keys?mkp=true"
    }
    

    Follow the next link to retrieve a KeyPackage

    This will mark the KeyPackage as distributed and would typically link it to the Actor that signed the request (that's temporarily disabled for testing).

    Request

    > curl -H "Accept: application/activity+json" https://enigmatick.social/user/jdt/keys?mkp=true | jq
    

    Response

    {
      "@context": [
        "https://www.w3.org/ns/activitystreams",
        "https://purl.archive.org/socialweb/mls"
      ],
      "type": "Collection",
      "totalItems": 1,
      "items": [
        {
          "type": "KeyPackage",
          "id": "https://enigmatick.social/key-package/cfde7b54-8d08-41e9-8eb5-d997a12e9347",
          "attributedTo": "https://enigmatick.social/user/jdt",
          "to": [
            "https://www.w3.org/ns/activitystreams#Public"
          ],
          "mediaType": "message/mls",
          "encoding": "base64",
          "content": "AAEAASCOWe7uxA8tPeI01nDP8ka2irEhgfkK2qM81/o+tEKPEiCz2h2Vv6VVuGSx/C0WINQCuazZm4rQAymxd1JdHGVvaSDurWzIE3z5eXUFz5coFGv9db7DxZDx0arb/gyRuidCAgABImh0dHBzOi8vZW5pZ21hdGljay5zb2NpYWwvdXNlci9qZHQCAAEIAAEAAgADAE0KAAEAAgADAAQABQwAAQACAAMABAAFAAcCAAEBAAAAAGeDNwsAAAAAZ/IDGwBAQJUffd/8/Efgt0ITBeMWfJYcb7S8E5U7yyUINiIUfqmsGwcvTyam6C+9F+k64NBEs0rXjGMjPA6AgiZ2oR4/1wwAQECliseeQfQb0zgq755ZiiujRqLkEWt8WOTJSsBXHK6hey6bNs4wet782NL8k92h1BNuPZDzxHaHXdXe1wgBO6QJ"
        }
      ]
    }
    

    @jdt

    >ActivityPub E2EE draft.

    Do you see any merit in that document?

    Looks like boilerplate to me.

  • @jdt

    >ActivityPub E2EE draft.

    Do you see any merit in that document?

    Looks like boilerplate to me.

    @silverpill@mitra.social it seems like a fair starting point to establish some common formats. There's clearly a lot of work still to be done.

    There are some choices that seem questionable to me; the document seems to imply that KeyPackages as an attribute of the Actor objects can be retrieved without much control. I think that's problematic. They're only usable one time and they could easily be exhausted if distribution isn't controlled (they have to be replenished by the client and the client has to maintain all active packages in its key store).

    I gate access behind a verified signature and record who is given which package at the server to establish some limits.


Gli ultimi otto messaggi ricevuti dalla Federazione
Post suggeriti
  • 1 Votes
    1 Posts
    5 Views
    ActivityPub e il Fediverso: WordPress alla conquista del mondo (WordCamp Pisa 2025) @fediverso@diggita.com @fediverso@feddit.it Cos'è il Fediverso, come funziona ActivityPub su WordPress, pro e contro. WordCamp Pisa, 22 novembre 2025. #activitypub #fediverso #mastodon #WCPISA #WordCamp #WordPress @wpbot https://wptoots.social/@wpbot/115723238240284031
  • 0 Votes
    2 Posts
    14 Views
    I mean... technically, any public post is kind of a global shoutbox?
  • 0 Votes
    1 Posts
    23 Views
    Week in Fediverse 2025-10-03Servers- flohmarkt v0.12.1- Gush! v0.0.23- NodeBB v4.6.0- ActivityPub for WordPress v7.5.0- Ktistec v2.4.15- Hollo v0.6.12- tootik v0.19.6- NeoDB v0.12.3- Vernissage Server v1.23.0- PieFed v1.2.3- September 2025 (Bandwagon)- ONI news for September (Oni)- Bonfire Social 1.0rc3- ActivityBot: A Simple ActivityPub Bot Server in a Single PHP FileClients- Fedilab v3.35.1- Pachli v3.0.0For developers- ActivityPub Fuzzer: Emulates known Fediverse software, helping solve the problem where developers have to manually test compatibility with other projectsArticles- Getting started with Mastodon's Quote Posts - technical implementation details for servers- Fediverse Report – #136-----#WeekInFediverse #Fediverse #ActivityPubPrevious edition: https://mitra.social/objects/019987c8-484d-f913-d511-5e8329f9741f
  • 0 Votes
    1 Posts
    17 Views
    Release v2.4.14 of Ktistec is small in terms of features and fixes, but it improves in two areas where I thought Ktistec was weak: light/dark mode support and autosave.I'm not hardcore dark mode, but I do prefer it in some cases. Ktistec selects light or dark mode based on the browser or system setting—there is currently no means to select the mode directly. A nice side effect of light/dark mode support is that custom theming support comes nearly for free.Figure 1: Ktistec editor showing the Dracula themeKtistec was meant for writing. I post my fair share of one-line bits of wisdom, but I started building Ktistec because I wanted a space to write long form, and existing Fediverse platforms were more for social interaction. When writing long form, autosaving is an essential feature. Ktistec will now autosave draft posts and replies. If you navigate away before publishing, you can always find the incomplete draft in the Drafts collection which is accessible from your timeline page.AddedAdd design system page for previewing UI elements.Support custom themes with automatic light/dark mode switching.Add autosave functionality for new posts, draft posts, and replies.ChangedAdd external link indicators.#ktistec #fediverse #activitypub #crystallang