#social 2017-08-25

2017-08-25 UTC
#
cwebber2
ActivityStreams got published and we still don't have unique links for actor vs Actor :P
#
xmpp-social
[ajordan] cwebber2: as in type vs standard prop name?
#
xmpp-social
[ajordan] I thought Actor as a type got dropped
#
cwebber2
oh wait
#
cwebber2
no wonder
#
cwebber2
yeah you're right ajordan
#
cwebber2
object and Object collide
#
cwebber2
so do image and Image
#
xmpp-social
[ajordan] :P
#
Loqi
[cwebber] #428 "Activity Vocabulary" document has fragment id name collisions for eg "object", "Object"
#
Gargron
why would they collide if the casing is different?
#
Gargron
variable names/class names/type names are not case insensitive as a rule, in programming languages
#
cwebber2
Gargron: it's just the links on that page
#
cwebber2
not the actual Object vs object in the real vocabulary
#
cwebber2
what it *should* have been was #dfn-Object was the Object
#
cwebber2
and #dfn-Image etc
#
cwebber2
so not a spec problem in terms of real protocol stuff
#
cwebber2
but still annoying
#
xmpp-social
[ajordan] cwebber2: are fragments case-sensitive?
#
xmpp-social
[ajordan] I mean I guess duh, I just never thought of that lol
#
cwebber2
ajordan: they don't have to be
#
cwebber2
it's a bug in the spec html
#
cwebber2
#dfn-Object vs #dfn-object def possible
#
cwebber2
dfn-itely ;)
#
xmpp-social
[ajordan] cwebber2: what do you mean they don't have to be? Either the HTML spec says they are or it says they aren't?
#
xmpp-social
[ajordan] Or it says "whatever we'll punt to implementations"
#
cwebber2
ajordan: I mean, they aren't in HTML, so that spec should take advantage of it
xmpp-social joined the channel
#
cwebber2
"ActivityPub: from decentralized to distributed social networks"
#
Loqi
[Gargron] #4687 Add handling of Linked Data Signatures in payloads
#
Gargron
of course, once again mapping to storage is tricky since we're not using document storage. our signatures will probably be generated on the fly, and if we need to forward payloads, we will forward them immediately rather than storing the signatures somewhere
#
Gargron
btw i think there might be an issue where https://www.w3.org/ns/activitystreams does not return the actual json-ld document even with the right Accept headers, unless you use https://www.w3.org/ns/activitystreams.jsonld instead
#
Loqi
[Amy Guy] ActivityStreams 2.0 Terms
#
rhiaro
Gargron what accept headers are you using? That should all work
#
Gargron
not me, the ruby json-ld gem
#
rhiaro
curl -H"Accept: application/ld+json" https://www.w3.org/ns/activitystreams gave me JSON-LD
#
Loqi
[Amy Guy] ActivityStreams 2.0 Terms
#
Gargron
hmm, okay. then some problem with the gem.
#
Gargron
in any case i am intending to use json-ld-preloaded (which also has a bug i already reported and was promised to be fixed today)
#
Gargron
basically i don't want my code to fire up any http requests while parsing json, because that's unpredictable and slow and i'd rather not
#
Gargron
json-ld-preloaded has all of the popular contexts cached
#
jaywink
Gargron++ for pushing for signatures ?
#
Loqi
gargron has 7 karma
#
cwebber2
Gargron: will review :)
#
cwebber2
Gargron: oh that's a PR in mastodon
#
cwebber2
btw jaywink, Gargron did you look at the paper I linked last night?
#
cwebber2
making the case for signatures is one thing that's an easy thing to do immediately, and then it starts to go into more out-there things ;)
#
jaywink
I saved it to pocket. So almost like reading ?.. I'll get to it soon
#
cwebber2
jaywink: :)
#
Gargron
cwebber2: yes i read your paper
#
Gargron
i almost finished implementing both verifying and signing with LDS
#
cwebber2
Gargron: *awesome*
#
cwebber2
SO GREAT :D
#
dlongley
Gargron: see? :)
#
Gargron
nice
#
dlongley
mostly just lurk in here though.
#
cwebber2
dlongley: haha I didn't even know you were here ;)
#
Loqi
cwebber2: lol
#
cwebber2
headpats Loqi
#
cwebber2
Loqi: botsnack
#
cwebber2
aaronpk: how does Loqi not know botsnack???
#
aaronpk
gives Loqi a botsnack
#
Loqi
gives back the botsnack
#
xmpp-social
[ajordan] cwebber2: am I missing some standard internet joke? I've no idea what botsnack is
#
xmpp-social
[ajordan] Side note I love how indignant you are lol
#
cwebber2
ajordan: botsnack is a common irc bot command
#
xmpp-social
[ajordan] Ahhhh
#
xmpp-social
[ajordan] pumabot also doesn't know that
#
xmpp-social
[ajordan] I souls teach them
#
xmpp-social
[ajordan] s/souls/should/
#
cwebber2
when a bot does good you do "botname: botsnack" and the bot can say some silly response, like "*catches the botsnack in midair*" or "yum!" or etc
#
Gargron
you can probably just define a text response?
#
Gargron
its not a complicated function, its keyword -> static response
#
ajordan
Gargron: lol yeah
#
ajordan
but #lazy
#
ajordan
I'll write a module for other people to use too
#
puckipedia
oh no I'm gonna have to implement LD signatures now :<
#
Gargron
you don't have to
#
Gargron
they have a limited use case
#
Gargron
use case 1) once you receive a reply to one of your posts, forward it to all your followers
#
Gargron
use case 2) if you receive a delete for a remote post, and you have reblogged that post, forward the delete to all your followers
#
puckipedia
hm. though you do sign the entire document
#
Gargron
oh sure, but you can just ignore that?
#
Gargron
its just an extra signature property.
#
puckipedia
eh. I think if we do proper JSON-LD signatures we'll probably have to figure out a consistent way of signing
#
Gargron
its in the spec
#
Gargron
it's pretty definite actually
#
Gargron
but again, the primary authentication is still with http sigs
#
puckipedia
I don't think LD signatures are in the spec already?
#
Gargron
you can ignore LDS for most purposes
#
Gargron
they dont have to be in the spec
#
Gargron
they are json-ld, and AP is json-ld
#
Gargron
you add an extra @context, and a signature property
#
puckipedia
well then we have to determine how flattening should work
#
cwebber2
puckipedia: LD signatures are described in the spec
#
cwebber2
in a non-normative section
#
cwebber2
and linked data signatures already does the fattening for you
#
cwebber2
you can use an existing library, it's already done
#
cwebber2
json-ld libraries usually already have it bundled
#
puckipedia
I mean. generating LD signatures for an object {type: Create, object: {type: Note, content: Hello}}
#
puckipedia
is different than generating LD signatures for {type: Create, object: objectId} and {type: Note, id: objectId, content: Hello}
#
puckipedia
there's pros and cons to both of these approaches
#
puckipedia
e.g. the pro to signing the entire document is that you sign that you created *that* content at that point in time
#
puckipedia
con: you have to keep previous versions of the object, and you have to restore the objects into the exact same document
#
Gargron
signature goes on the entire json document, not any subset
#
Gargron
afaik.
#
puckipedia
it does. though with JSON-LD api you can easily split up the documents into its constituent objects
#
cwebber2
this one's a bit easier to get stuck in the weeds on
#
cwebber2
you've got three routes
#
cwebber2
- just reference a "child" object by its id, and it doesn't matter if that object changes, but it's harder to assert what you're actually referencing was a specific thing
#
cwebber2
- store for a recursive embedding of child objects, and signing the whole thing. If the object changes, oh well, your old signatures don't hold up but maybe you're already done passing those around??
#
cwebber2
- probably not gonna be done by Masto, but seems like the Best Design from a structual standpoint: when you store an object, actually store a "revision" of that object and do content addressed hashing of that object. Then when you're storing the object you can pull up an old revision, with that version of its signature, even if your reference to it mutated. Unfortunately unlikely to work nicely with a design like Masto's relational
#
cwebber2
structure
#
cwebber2
but it sounds like masto's passing around of these things is going to be more on-demand and short-lived for now, so option 2 is probably fine
#
puckipedia
hm. I could try storing revisions once I move to a tuple database
#
Loqi
[cwebber] #7 Storing information on whether a child object is referenced by id or included recursively
#
cwebber2
I'm hesitant to push this too much though because I think it could be overwhelming for masto's current use case
#
cwebber2
note that I was looking at how salmon does it, and effectively that "solution" seems not too unlike doing an object store's embedding of things right?
#
cwebber2
because effectively you've base64 encoded and serialized the signed message in to an envelope for unpacking later
#
puckipedia
Salmon just signs the entire object as it is passed through, right?
#
cwebber2
well at that point you're effectively including a recursive object
#
puckipedia
though you still can't pass it on because of the way the attribution works
#
cwebber2
puckipedia: yeah, but signing a signed object
#
puckipedia
ehm, audience*
#
puckipedia
bbiab
#
ajordan
update: I've now wasted ~30 minutes implementing botsnack
#
ajordan
I wrote the actual module in about 10 seconds and then started trying to figure out how to test random responses before giving up and having the test suite retry 3 times
ben_thatmustbeme and wilkie joined the channel
#
cwebber2
I updated the paper to clarify decentralized / distributed terminology and add a bit about great being the enemy of good and pointing towards incremental improvement https://gitlab.com/dustyweb/talks/blob/master/activitypub/rwot/even_more_distributed_activitypub.org https://gitlab.com/dustyweb/talks/raw/master/activitypub/rwot/even_more_distributed_activitypub.pdf
timbl joined the channel