Commit graph

48 commits

Author SHA1 Message Date
Egor Kislitsyn
a37bd5c255 Change log level 2019-12-10 15:08:57 +07:00
rinpatch
9f29930440 fetcher: move local object checking into a reusable function 2019-11-23 22:55:41 +03:00
lain
e835cd97f6 Containment: Add a catch-all clause to contain_origin. 2019-11-12 12:07:17 +01:00
Ariadne Conill
5b60d82592 object containment: handle all cases where ID is invalid (missing, nil, non-string) 2019-11-08 14:51:28 -06:00
rinpatch
32afa07995 Fetcher: fix local check returning unwrapped object
This resulted in error messages about failed refetches being logged.
2019-11-07 01:40:55 +03:00
rinpatch
54746c6c26 Object Fetcher: set cache after reinjecting
Probably fixes the issue hj had, where polls would have different
counters between endpoints.
2019-11-06 14:00:03 +03:00
stwf
2ab072f949 object fetcher error handling 2019-10-24 12:08:34 -04:00
Ariadne Conill
44e64af5e7 object: containment: simplify the pattern match for OStatus testsuite hack 2019-10-18 15:39:15 +00:00
Ariadne Conill
e99fdfc32d object: containment: only allow OStatus references in test suite environment 2019-10-18 15:37:14 +00:00
Ariadne Conill
3c785b85a6 object: fetcher: fix up formatting 2019-10-18 14:50:10 +00:00
Ariadne Conill
7295a05cee object: containment: also allow OStatus object IDs through when comparing origins 2019-10-18 14:50:10 +00:00
Ariadne Conill
a177f22e02 object: fetcher: improve error reporting 2019-10-18 14:50:10 +00:00
Ariadne Conill
bf2107743f object: containment: don't try to contain ostatus objects 2019-10-18 14:50:10 +00:00
Ariadne Conill
6f110fc04c object fetcher: fix up error handling 2019-10-18 14:50:09 +00:00
Ariadne Conill
48059c03c9 fix up some tests 2019-10-18 14:50:09 +00:00
Ariadne Conill
d379b48769 kill almost all of the OStatus module 2019-10-18 14:50:09 +00:00
Maksim Pechnikov
d4ed3a35b8 Merge branch 'develop' into test/activity_pub/transmogrifier.ex 2019-09-19 07:35:34 +03:00
rinpatch
5028b7b578 Fix credo issues 2019-09-18 22:09:03 +03:00
rinpatch
c096dd86e5 Do not refetch local objects 2019-09-18 20:01:26 +03:00
rinpatch
eb87a86b5b Preserve internal fields when reinjecting 2019-09-18 19:53:51 +03:00
rinpatch
e3f902b3a1 Set updated_at even if the object stayed the same 2019-09-18 19:07:25 +03:00
rinpatch
7ef575d11e Initial poll refresh support
Implement refreshing the object with an interval and call the function
when getting the poll.
2019-09-18 18:13:21 +03:00
Maksim Pechnikov
fcf604fa43 added tests 2019-09-11 07:23:33 +03:00
Maksim Pechnikov
8dc6a6b210 fix /inbox for Relay 2019-08-22 22:48:07 +03:00
rinpatch
196cad46f3 Resolve merge conflicts 2019-07-20 22:04:47 +03:00
rinpatch
c3ecaea64d Apply suggestion to lib/pleroma/object/fetcher.ex 2019-07-20 18:53:00 +00:00
Ariadne Conill
399acd4c42 fetcher: sign object fetches if configured 2019-07-17 22:58:46 +00:00
Ariadne Conill
739bbe0d3b security: detect object containment violations at the IR level
It is more efficient to check for object containment violations at the IR
level instead of in the protocol handlers.  OStatus containment is especially
a tricky situation, as the containment rules don't match those of IR and
ActivityPub.

Accordingly, we just always do a final containment check at the IR level
before the object is added to the IR object graph.
2019-07-14 17:47:08 +00:00
Haelwenn (lanodan) Monnier
2592934480
Object.Fetcher: Keep the with-do block as per kaniini proposition 2019-07-14 17:28:25 +02:00
Haelwenn (lanodan) Monnier
e1c08a67d6
Object.Fetcher: Fallback to OStatus only if AP actually fails 2019-07-14 17:05:31 +02:00
Haelwenn (lanodan) Monnier
40d0a198e2
Object.Fetcher: Handle error on Containment.contain_origin/2 2019-07-14 14:58:47 +02:00
rinpatch
e8fa477793 Refactor Follows/Followers counter syncronization
- Actually sync counters in the database instead of info cache (which got
overriden after user update was finished anyway)
- Add following count field to user info
- Set hide_followers/hide_follows for remote users based on http status
codes for the first collection page
2019-07-13 19:27:49 +03:00
93a0eeab16 Add license/copyright to all project files 2019-07-10 05:13:23 +00:00
Ivan Tashkinov
5b7b1040b3 [#161] Limited replies depth on incoming federation in order to prevent memory leaks on recursive replies fetching. 2019-06-29 20:04:50 +03:00
Egor
58a094b605 Add copyright info to containment.ex 2019-06-14 09:26:36 +00:00
Egor Kislitsyn
30e54fd7e2 Handle HTTP 404 response 2019-06-13 17:13:35 +07:00
Egor Kislitsyn
afae3ada22 Handle HTTP "410 Gone" response 2019-06-13 16:34:03 +07:00
William Pitcock
9bec891eb4 kill @httpoison 2019-05-25 04:24:21 +00:00
William Pitcock
73df9d690d object: fetcher: add support for reinjecting pruned objects 2019-05-21 21:38:56 +00:00
William Pitcock
e71ddf23ba containment: remove pointless moduledoc line 2019-05-07 16:11:22 +00:00
Haelwenn (lanodan) Monnier
69a5074893
Remove H1 in @moduledoc 2019-05-06 04:53:12 +02:00
rinpatch
d21d921def Replace Object.normalize(activity.data[object] with Object.normalize(acitivty) to benefit from preloading 2019-04-22 11:27:29 +03:00
rinpatch
35ac672b8d Remove containment tests from transmogrifier and fix thread visibility solver 2019-04-17 17:59:15 +03:00
rinpatch
e7c3c36766 Update functions in object fetcher for tesla and set up a proper mock for tests 2019-04-17 14:21:39 +03:00
rinpatch
627e5a0a49 Merge branch 'develop' into feature/database-compaction 2019-04-17 12:22:32 +03:00
William Pitcock
fed9b5404c object: rework Object.normalize() a bit to support transparent fetching 2018-12-04 04:52:09 +00:00
William Pitcock
f85949cc69 object: factor out fetching functions into Pleroma.Object.Fetcher module 2018-12-04 04:52:09 +00:00
William Pitcock
e8caecb5c7 object: move object containment out of transmogrifier into it's own module 2018-12-04 04:52:09 +00:00