Commit graph

152 commits

Author SHA1 Message Date
William Pitcock
dbc4e92509 activitypub: transmogrifier: do not clobber the addressing on relayed announcements 2019-01-17 23:21:31 +00:00
sxsdv1
868034375c Add likes to activitypub object representation
Top level of the likes OrderedCollection is inlined to get immediate
access to totalItems. Because the count can be returned without scanning
the database for like activities the extra query is saved when the
client only wants to display the total.
2019-01-12 20:24:41 +01:00
sxsdv1
1eb7318831 Prepare all types objects before serialising
Activities returned from inbox can include other types of objects like
Article
2019-01-12 20:24:32 +01:00
William Pitcock
980b5288ed update copyright years to 2019 2018-12-31 15:41:47 +00:00
William Pitcock
2791ce9a1f add license boilerplate to pleroma core 2018-12-23 20:56:42 +00:00
William Pitcock
71f6d9f418 transmogrifier: significantly rework handling of peertube videos, add test 2018-12-23 13:31:08 +00:00
Haelwenn (lanodan) Monnier
3aff8067e4 transmogrifier: When it’s a Video move "url" to "attachment" 2018-12-23 13:00:25 +00:00
Maksim Pechnikov
074fa790ba fix compile warnings 2018-12-09 20:50:08 +03:00
lain
8f1fffebc6 Fix transmogrifier test. 2018-11-30 17:31:05 +01:00
lain
40d9d2098c Fix user updating from AP. 2018-11-18 22:15:03 +01:00
William Pitcock
dfcfb184b1 activitypub: transmogrifier: make deletes secure 2018-11-17 21:22:57 +00:00
William Pitcock
daa8ec3d62 activitypub: factor out AP object fetching to it's own function and add ID-based containment 2018-11-17 20:15:59 +00:00
William Pitcock
97e50f3191 activitypub: transmogrifier: sanitize internal representation details from outgoing objects
this causes JSON-LD parsers to get upset and has also lead to developer confusion from outside
projects which tried to parse our internal data.  accordingly, it seems better to just remove
it.
2018-11-10 12:24:20 +00:00
William Pitcock
6b4064fa5d activitypub: transmogrifier: unify mention extraction 2018-11-08 19:41:36 +00:00
William Pitcock
3e33479c05 activitypub: transmogrifier: only consider to users as mention targets 2018-11-08 18:58:27 +00:00
lambda
59cf7cf235 Merge branch 'small-jsonld-refactor' into 'develop'
Small jsonld refactor

See merge request pleroma/pleroma!433
2018-11-08 16:23:58 +00:00
lain
34bd411781 Unify json ld header handling. 2018-11-08 16:39:38 +01:00
href
5bb88fd174
Runtime configuration
Related to #85

Everything should now be configured at runtime, with the exception of
the `Pleroma.HTML` scrubbers (the scrubbers used can be
changed at runtime, but their configuration is compile-time) because
it's building a module with a macro.
2018-11-06 19:41:15 +01:00
William Pitcock
9f03b5c4f7 activitypub: transmogrifier: add support for Page objects 2018-11-01 09:59:43 +00:00
Haelwenn (lanodan) Monnier
b2da5262ea
Pleroma.Web.ActivityPub.Transmogrifier: fix_url when not a string/empty
Thanks prismo.news, I hate it
2018-11-01 09:56:37 +01:00
William Pitcock
5383887bd4 transmogrifier: do not try to contain origin of something which doesn't have one 2018-10-25 04:27:33 +00:00
William Pitcock
8ce217776d activitypub transmogrifier: better manage follow state 2018-10-05 23:30:34 +00:00
Haelwenn (lanodan) Monnier
c739737998
transmogrifier: get_actor called without casting attributedTo in actor and actor is nil 2018-09-27 20:00:48 +02:00
Haelwenn (lanodan) Monnier
9446b02bdf
transmogrifier: Just make attachement maps into a list and reroll 2018-09-27 20:00:48 +02:00
Haelwenn (lanodan) Monnier
e53da692fb
transmogrifier: Use the correct variable and prefer inspect in case of a bad type being passed on 2018-09-27 20:00:48 +02:00
William Pitcock
d830a243a3
transmogrifier: more robustly handle dereferencing pointer URIs 2018-09-27 20:00:48 +02:00
Haelwenn (lanodan) Monnier
4c3a80de96
transmogrifier: Use oneliners when applicable 2018-09-27 20:00:47 +02:00
William Pitcock
ed8dfa3029
transmogrifier: reformat cond block by hand 2018-09-27 20:00:47 +02:00
Haelwenn (lanodan) Monnier
eebe33e86a
transmogrifier: Add support for array-less hashtags, add broken announce, harden get_actor 2018-09-27 20:00:47 +02:00
Haelwenn (lanodan) Monnier
f3291acc91
transmogrifier: pro-actively add support for Hashtag without array in tag 2018-09-27 20:00:47 +02:00
Haelwenn (lanodan) Monnier
22927f3a34
transmogrifier: Use a cond, add proactive support for arrays 2018-09-27 20:00:46 +02:00
Haelwenn (lanodan) Monnier
0aac72f1d3
[Pleroma.Web.ActivityPub.Transmogrifier]: quick fix when tag is a Map 2018-09-27 20:00:46 +02:00
Haelwenn (lanodan) Monnier
28e8a8ab36
[Pleroma.Web.ActivityPub.Transmogrifier]: fix emoji in tag when it’s not in a array [kroeg]
Also simplified the code for name trimming.

And not copying the Map.merge part as it looks buggy.
See: https://queer.hacktivis.me/objects/a9f21ebc-9a12-4a6c-89d5-3d46955c6ee8
2018-09-27 20:00:46 +02:00
Haelwenn (lanodan) Monnier
f8a0cb9c0b
[Pleroma.Web.ActivityPub.Transmogrifier]: fix when attachment contain is just a Map [kroeg] 2018-09-27 20:00:46 +02:00
Haelwenn (lanodan) Monnier
a4abb124ea
[Pleroma.Web.ActivityPub.Transmogrifier]: Fix when inReplyTo is a inlined post [kroeg] 2018-09-27 20:00:46 +02:00
William Pitcock
d3248e13e3 activitypub: transmogrifier: allow profile updates from bots 2018-09-10 01:57:03 +00:00
William Pitcock
03e92977cb transmogrifier: fix peertube/plume actor handling 2018-09-01 23:44:19 +00:00
William Pitcock
0b2c051a04 activitypub: fix possibility of spoofing by containing remote objects to the same domain as their actor 2018-09-01 23:20:02 +00:00
William Pitcock
52b44184b4 transmogrifier: reject activities lacking a valid ID 2018-08-23 01:25:26 +00:00
Haelwenn (lanodan) Monnier
f5b056e3ce
[Pleroma.Web.ActivityPub.Transmogrifier]: Fix likes 2018-08-21 18:26:12 +02:00
Haelwenn (lanodan) Monnier
74c74decf5
Basic peertube support. 2018-08-21 18:24:09 +02:00
Haelwenn (lanodan) Monnier
ef4f982e2c
Pleroma.Web.ActivityPub.Transmogrifier: Fix actor being a list of objects (Peertube) 2018-08-21 18:24:06 +02:00
William Pitcock
f446e75577 activitypub: transmogrifier: add necessary translations for kroeg 2018-08-14 17:09:11 +00:00
Haelwenn (lanodan) Monnier
7501481db4
[Pleroma.Web.ActivityPub.Transmogrifier] Add Person finding 2018-07-12 23:37:07 +02:00
Haelwenn (lanodan) Monnier
8472fba2a7
[Pleroma.Web.ActivityPub.Transmogrifier]: Fix actor key outside of object
The code here is copied from feature/peertube by lain.

Co-authored-by: lain <lain@soykaf.club>
2018-07-12 23:37:00 +02:00
lambda
d93789dfde Merge branch 'feature/object-normalization' into 'develop'
object normalization

See merge request pleroma/pleroma!238
2018-07-12 16:48:15 +00:00
William Pitcock
590d4df77c activitypub: more robustly handle object-to-actor associations 2018-07-12 16:39:03 +00:00
William Pitcock
971bb4f2bd activity interpretation: formatting 2018-06-27 13:38:19 +00:00
William Pitcock
c42f28b82c transmogrifier: accept Article activities 2018-06-27 13:37:26 +00:00
William Pitcock
7c63e70de1 activitypub: use Activity.normalize() in several places instead of using Activity.get_by_ap_id() directly. 2018-06-27 13:08:12 +00:00