Commit Graph

94 Commits

Author SHA1 Message Date
Michael 990eea2c4e We now store uncommon endpoints 2022-04-25 13:45:03 +00:00
Hypolite Petovan 4eecf733e1
Merge pull request #11389 from nupplaphil/feat/http_client_arg
Introduce explicit HttpClient "Accept" parameter
2022-04-08 15:05:40 -04:00
Michael a1dd299eb3 Preparations for "featured" posts 2022-04-06 13:34:11 +00:00
Michael 61abc6377d Preparation for "Featured" collection added 2022-04-04 23:07:44 +00:00
Philipp Holzer 73c3b21665
Move ACCEPT constants to own "enum" class 2022-04-02 20:26:11 +02:00
Michael ff70f74952 "accept" constants introduced and used 2022-03-28 10:33:06 +00:00
Hypolite Petovan 7b9e62198e Suppress a couple MemcachedException
- Replace URL by uri-id in apcontact
- Replace date with a space and nurl by nick and Zulu time in mod/poco
2022-03-15 10:54:00 -04:00
Balázs Úr e56a53647b Update copyright 2022-01-02 08:27:47 +01:00
Philipp Holzer 68046573a4
Restructure Cache to follow new paradigm 2021-10-26 22:11:06 +02:00
Michael f1e2ceb32c Issue 10747: Improved check for blocked domains 2021-10-02 10:25:50 +00:00
Michael ce46ab2573 The Matrix and XMPP address is now transported via AP as well 2021-08-10 23:49:09 +00:00
Hypolite Petovan dfb043ce60 Add Exception for empty User::getOwnerDataById(0 return case in Protocol\ActivityPub\Transmitter::getProfile()
- Address https://github.com/friendica/friendica/issues/10473#issuecomment-882781552
- Add try-catch blocks to all references of Protocol\ActivityPub\Transmitter::getProfile()
2021-07-27 16:46:08 -04:00
RealKinetix cf32a4b7cc Sanitize negative status count on APContact
Similar to PR #10499, Mastodon apparently has some counting flaws and
can present a negative status count for a user, causing Friendica to
fail (at least under PHP 8) with:

[20-Jul-2021 16:35:18 UTC] PHP Fatal error:  Uncaught PDOException: SQLSTATE[22003]: Numeric value out of range: 1264 Out of range value for column 'statuses_count' at row 1 in /home/friendicadev/friendica/src/Database/Database.php:560
Stack trace:
  thrown in /home/friendicadev/friendica/src/Database/Database.php on line 560

This change prevents values lower than 0 from being assigned to
statuses_count.
2021-07-20 10:11:04 -07:00
Michael aa6313dee6 Improved detection for a local contact 2021-07-19 04:15:57 +00:00
Michael 424a85bb94 Fetch local data without HTTP requests 2021-07-18 18:54:25 +00:00
Michael d8bf9c4601 Prevent loop also when fetching the outbox 2021-07-18 16:42:55 +00:00
RealKinetix a0107be2af Negative numbers in following is a thing too
Check & sanitize 'following' as well, as per:
https://mastodon.social/@BLUW
2021-07-14 13:51:30 -07:00
RealKinetix f16b1df83f Adjust where the code is to avoid empty warning
Shifted the code to avoid:
PHP Warning:  Undefined array key "totalItems" in /home/friendicadev/friendica/src/Model/APContact.php on line 277
2021-07-14 13:46:38 -07:00
RealKinetix c1db1c980e Fix indent to standards 2021-07-14 12:17:03 -07:00
RealKinetix 2ebebe9abc Sanitize negative followers count on APContact
Please see
https://github.com/friendica/friendica/issues/9498#issuecomment-818894106
and related discussion regarding this - it appears it's possible for AP
users, maybe just Mastodon users, to have a negative followers count.
This causes fatal errors in Friendica, so I think we should sanitize
this input.
2021-07-14 10:15:19 -07:00
Michael 0735a22cdd Fix notice "undefined index: uri" 2021-07-09 14:52:22 +00:00
Michael 6e79da0b0c The uri-id is now in all contact tables 2021-07-09 07:09:33 +00:00
Michael e2dc36a691 AP: Support "discoverable" 2021-06-30 05:40:11 +00:00
Michael fe07dc828b Fix noscrape publishing and pulling, added header 2021-06-17 11:23:32 +00:00
Michael 09f29cd577 Avoid notices because of empty fields 2021-05-25 13:11:23 +00:00
Michael da8d5f5015 Issue 9926: Limit the length of data to store in the apcontact table 2021-05-24 19:44:24 +00:00
Michael 48d703d278 Fiy missing "in" 2021-05-17 06:03:14 +00:00
Michael 2e6cf056c1 Whitespace removed 2021-05-17 06:01:47 +00:00
Michael cb7206d92f Reverted yesterdays panic coding 2021-05-17 05:59:41 +00:00
Hypolite Petovan a44cf44708
Remove duplicated conditions, improve variables names in Model\APContact 2021-05-16 16:10:22 -04:00
Michael 6f2fcd2859 Don't use compacted data when parsing accounts 2021-05-16 16:41:07 +00:00
Hypolite Petovan 48ac619599 Check unparseURL parameter type in APContact::getByURL
- Address https://github.com/friendica/friendica/issues/10167#issuecomment-832421258
2021-05-10 21:52:26 -04:00
Balázs Úr 054c301ef0 Update copyright 2021-03-29 08:40:20 +02:00
Michael a331a8cf0a Delete removed contacts 2020-12-15 22:56:46 +00:00
Michael 495252690b available is not vital 2020-11-24 07:49:36 +00:00
Michael e4e9a20ac8 Don't transmit to archived inboxes 2020-11-23 19:25:22 +00:00
Michael 73a7df85f7 Issue 9303: Detect AP accesses as backend, prevent ping pong 2020-10-02 09:31:39 +00:00
Michael a0cb6b409d Avoid "Duplicate entry" error in apcontact 2020-09-06 09:39:47 +00:00
Michael 44ee4a54b4 Replace "insert" with "replace" 2020-08-27 21:35:08 +00:00
nupplaPhil 5344efef71 Move post/curl/fetchUrl/fetchUrlFull to own class "Network\HTTPRequest" 2020-07-21 02:56:10 -04:00
Michael 7374104f29 Fix Notice "Undefined index: subscribe" 2020-06-05 10:44:36 +00:00
Michael 7b70eefbb6 Remove the "addr" when webfinger fails 2020-06-04 22:08:31 +00:00
Michael 62217735f0 Use webfinger in apcontact fetch 2020-06-04 21:55:14 +00:00
Michael e379698227 Issue 8675: reduce requests of foreign pages 2020-06-01 21:52:31 +00:00
Michael ba9cf32f36 The "item-activity" is removed 2020-05-26 05:18:50 +00:00
Michael 21ab11ac18 Only fetch the gsid when it had been empty before 2020-05-22 11:29:58 +00:00
Michael 95b4f35a12 Improved server detection / gsid introduced 2020-05-22 04:19:32 +00:00
Michael 2ba4333f70 Exchange "part" with "fragment" 2020-03-28 15:18:12 +00:00
Michael 3761e9ee51 Issue 8254: Some more fixes for too long data for columns 2020-03-28 15:14:40 +00:00
Michael 1fef1ef6e9 Issue 7771: Funkwhale support 2020-03-24 23:12:53 +00:00