Commit Graph

1002 Commits

Author SHA1 Message Date
Michael c364a77d63 Always use direct DFRN transport on local contacts 2019-09-21 12:39:07 +00:00
Hypolite Petovan 888f7ffd1c Use correct data key to compare authors before appending mention in Protocol\Diaspora 2019-09-15 07:05:47 -04:00
Hypolite Petovan 69752fd945 Prevent prepending implicit mention if replied to item is ours in Protocol\Diaspora 2019-09-14 17:42:02 -04:00
Michael 3c1380fdcc Fix enduring follow requests to Pleroma 2019-09-11 16:54:13 +00:00
Michael 33006d8455 Merge remote-tracking branch 'upstream/2019.09-rc' into performance 2019-09-03 15:02:16 +00:00
Michael 52d8b618f0 Type hints 2019-09-03 03:59:46 +00:00
Michael Vogel 046b5a1eac Fix performance issues due to relay contact requests 2019-09-02 15:11:07 +02:00
Michael 6af4c90dff Fix delivery counter / archive relay contacts 2019-09-02 03:25:05 +00:00
Michael Vogel ef02a1cb7b Check fpr duplicated contacts upon inserting them 2019-08-29 06:07:07 +02:00
Michael Vogel 9b7432781b Don't transmit content to already archived contacts 2019-08-27 21:01:11 +02:00
Tobias Diekershoff 1c3a5e1e6f added USE statement and changed statement as requested in #7305#discussion_r296461181 2019-08-27 07:10:51 +02:00
Hypolite Petovan 20a6b368fb Replace mb_convert_encoding with html_entity_decode for feed item title conversion
- Prevents already UTF-8 strings to be corrupted
2019-08-22 06:00:21 -04:00
Hypolite Petovan 9de59d5c4d Add entry title HTML entities conversion in Protocol\Feed
- Prevents literal entities display in generated post title
2019-08-18 09:37:36 -04:00
Hypolite Petovan cf8177461e Prune unavailable contacts from AP envelope 2019-08-17 00:00:49 -04:00
Philipp Holzer 08be92a862
Moved BaseURL to App namespace (because similar type as Arguments/Modules/Modes) 2019-08-15 17:23:00 +02:00
Hypolite Petovan 2e6b72ba62
Revert "Reworked contact-id generation" 2019-08-01 20:39:42 -04:00
Michael 8ddcd8417d Reworked contact-id generation 2019-07-30 22:02:32 +00:00
Michael 7d79d48f6e Fix: The field "contact-id" now contains the correct contact id again 2019-07-30 13:08:14 +00:00
Michael bcc8ed378c ActivityPub: We now do support transmitting alternative image descriptions 2019-07-29 05:09:11 +00:00
Michael ab7db9944d ActivityPub: Support for incoming picture descriptions 2019-07-29 04:35:13 +00:00
Hypolite Petovan 8b344141da
Merge pull request #7434 from annando/contact-protocol
New functions to check if a contact supports that protocol
2019-07-27 17:47:54 -04:00
Michael f5cb6148cf Improved documentation 2019-07-27 21:45:36 +00:00
Michael 975ff86bae Fix: The $contact error is expected to be a single row array 2019-07-27 15:40:43 +00:00
Michael 264936100f New functions to check if a contact supports that protocol 2019-07-27 11:09:12 +00:00
Hypolite Petovan 1d8b809227
Merge pull request #7414 from annando/fetch-diaspora
Fetch Diaspora posts by url
2019-07-22 07:01:42 -04:00
Michael 105378f5a4 Changed regexp 2019-07-22 06:03:18 +00:00
Michael 53ffe5a2e1 Fetch Diaspora posts by url 2019-07-21 07:37:50 +00:00
Michael a11206dbcd Issue 6675: Improved check for follower, removed global setting 2019-07-21 05:56:57 +00:00
Michael 23830dc45f Preparation for quoted reshares on AP 2019-07-20 21:32:19 +00:00
Michael c771c575a7 Fix PR 7399: Added missing "use" 2019-07-18 06:12:43 +00:00
Michael e247a14d2b Added the option to only receive top level posts from people you follow 2019-07-17 21:37:13 +00:00
Michael a80a6bec74 Preparation for being able to fetch AP posts by proving the URL 2019-07-17 19:36:32 +00:00
Michael 8c2f50eb72 Issue 7315: Set the forum's contact id for forum posts 2019-07-16 05:07:26 +00:00
Michael 1a213bd8e8 Issue 7315: Changed handling of "Group" posts 2019-07-15 20:05:36 +00:00
Michael 9ba3ee13a8 Use an insert to avoid duplicates and for analyzing 2019-07-14 10:22:19 +00:00
Michael 5bba0e7d39 Hopefully avoiding duplicated relay entries 2019-07-13 23:53:15 +00:00
Michael c34204cf50 Merge remote-tracking branch 'upstream/develop' into contact-update 2019-07-12 20:51:27 +00:00
Michael 8cbdc7939e Fetch more comtact data from probing, remove duplicated contacts 2019-07-12 14:55:23 +00:00
Michael Vogel 807d2665ea Use standard function to update the contact to avoid SQL errors 2019-07-11 22:11:51 +02:00
Michael Vogel 6b25fd5b2f added logging 2019-07-10 05:19:54 +02:00
Michael Vogel 54d96da94a Fix fatal error with incomplete contact data upon delivery 2019-07-10 05:16:50 +02:00
Michael d1435bef61 Add ActivityPub related fields to the "uri" function 2019-07-08 12:00:11 +00:00
Michael 6bb418c5a7 Use "received" instead of "created" when displaying posts in creation order 2019-07-07 21:30:33 +00:00
Michael be0a102333 Simplified the Contact update 2019-07-04 21:19:23 +00:00
Michael c9666a9f1d We don't update inside the probing anymore 2019-07-04 19:40:48 +00:00
Michael 8d6aa9914c We now handling the contact type 2019-07-04 19:31:42 +00:00
Michael ef5be9668f New fields in contact table / don't update on probe 2019-07-04 04:08:55 +00:00
Michael 6041f74df6 New constant for federated protocols 2019-07-01 18:00:55 +00:00
Michael 0a15222576 Collect data about used protocols for delivery 2019-06-28 09:03:58 +00:00
Hypolite Petovan fa191bd821
Merge pull request #7305 from deantownsley/imageauthfix
Make authentication work for local private images
2019-06-23 15:18:15 -04:00
Dean Townsley 0c6a0942cc Clarify comment and log message 2019-06-22 19:08:34 -05:00
Dean Townsley 9dff3d2b6d Use User:: API insteadd of direct database read 2019-06-22 18:56:33 -05:00
Michael Vogel 449305e527 Fix the processing of event activities 2019-06-23 00:38:52 +02:00
Dean Townsley 042fcfeb50 Enable multi-auth in dfrn autoRedir
Update checks to account for a user being authenticated to multiple
contacts on the local server at the same time.
It was also necessary to remove a looping procection to make this work
correcly with browsers that open multiple connections because the
information about what contacts are authenticated is stored in the PHP
session.
2019-06-22 12:34:54 -05:00
Hypolite Petovan f0849b0a93
Merge pull request #7284 from annando/fix-fatal
Don't send activities to "null" endpoints
2019-06-19 23:42:21 -04:00
Michael 2e4e8bdf0a Don't send activities to "null" endpoints 2019-06-20 03:06:34 +00:00
Michael 4ab772ed67 Issue 6477: Automatically repair self contact avatar 2019-06-19 17:05:29 +00:00
Michael 496910e750 Issue #5983: Ignore reshares from blocked and ignored contacts 2019-06-17 11:55:19 +00:00
Hypolite Petovan 75894fa275 Use item created date if edited doesn't exist in Protocol\Diaspora::buildStatus
- Addresses https://github.com/friendica/friendica/issues/6918#issuecomment-502347886
2019-06-15 17:11:01 -04:00
Michael Vogel 097ecdd106
Merge pull request #7266 from MrPetovan/bug/notices
Add type-hint in ActivityPub\Receiver::fetchObject to catch wrong type coercion
2019-06-14 15:03:30 +02:00
Hypolite Petovan 95094aa53d Check for existing protocols.inbound value in Protocol\PortableContact 2019-06-14 06:25:44 -04:00
Michael e4efddbabb Avoid a notice in AP Receiver 2019-06-14 02:58:40 +00:00
Hypolite Petovan 66d4f1d40b Add type-hint in ActivityPub\Receiver::fetchObject to catch wrong type coercion 2019-06-13 19:07:39 -04:00
Hypolite Petovan 94a70f54d1 Normalize the datetime format of received activity before DB insertion in ActivityPub\Processor
- Restore private message storage
2019-06-12 21:02:37 -04:00
Hypolite Petovan 9e24b8c55f Fix formatting and PHPDoc in ActivityPub\Processor
Add expected return value to postMail method
2019-06-12 21:01:44 -04:00
Michael a11b258fd6 Issue 7223: Don't strip links 2019-06-11 20:34:21 +00:00
Michael 9d8f01c49c Fix another fatal error 2019-06-11 06:02:18 +00:00
Hypolite Petovan d7d44e1af7
Merge pull request #7245 from annando/unify-constants
Fix delivery counter for poking / unify delivery commands
2019-06-10 11:59:40 -04:00
Michael 41dc243186 Fix delivery counter for poking / unify delivery commands 2019-06-10 14:19:24 +00:00
Hypolite Petovan 165607ffe7
Merge pull request #7242 from nupplaphil/bugs/6917-php_warning
Add typed parameter for methods in `Friendica\Util\Network`
2019-06-10 09:22:27 -04:00
Philipp Holzer cc7444d84d
Move internal recursion-counter to the end of all cur/fetchUrl parameters 2019-06-10 14:34:54 +02:00
Philipp Holzer 236c0dc248
Check $contact['id']
- see https://github.com/friendica/friendica/issues/6918#issuecomment-498043313
2019-06-10 12:36:42 +02:00
Michael 44a49a8d7d Ensure that pokes are always send only via DFRN 2019-06-06 04:26:02 +00:00
Michael ecf809c7ae The delivery counter now counts only successful deliveries 2019-06-01 06:54:47 +00:00
Michael 19e95ebdda Fix edited messages for Diaspora 2019-05-30 18:56:31 +00:00
Michael Vogel 64f51d337f
Merge pull request #7204 from MrPetovan/bug/notices
Check for array index existence
2019-05-29 07:04:46 +02:00
Michael 824d35774b Fix "Undefined index: protocol" 2019-05-29 04:30:01 +00:00
Hypolite Petovan 8a0c568fe1 Check for href existence for links in Protocol\PortableContact
See https://github.com/friendica/friendica/issues/6918#issuecomment-495198587
2019-05-28 21:27:13 -04:00
Philipp 32b8c6f65e
Merge pull request #7200 from annando/tag-process
Process incoming tag add requests
2019-05-28 19:43:23 +02:00
Michael ecf4789cc4 Process incoming tag add requests 2019-05-26 11:20:03 +00:00
Philipp 6ceb74c365
Merge pull request #7184 from annando/add-tag
AP: We now transmit "add tag" activity
2019-05-26 08:14:18 +02:00
Michael 32b1f75ece AP: We now transmit "add tag" activity / On Diaspora this is now supressed 2019-05-25 19:33:58 +00:00
Philipp 5c2cca432f
Merge pull request #7170 from MrPetovan/bug/6981-contact-request-blocked
Contact requests blocked
2019-05-25 20:20:36 +02:00
Hypolite Petovan 7bbaf0757f Revert sending ActivityPub follow reject on Model\Contact::addRelationship failure 2019-05-20 16:33:09 -04:00
Hypolite Petovan ea77f214d7 Add return value to Model\Contact::addRelationship to remove protocol-specific code from it 2019-05-20 15:29:20 -04:00
Hypolite Petovan 10dfe4347b Ensure follow reject/accept object IDs are strings to avoid JsonLD normalize errors in ActivityPub\Transmitter 2019-05-20 15:29:20 -04:00
Hypolite Petovan 3114754f4b Refactor Model\Contact::addRelationship
- Remove unused parameter $item
- Replace q() call with DBA::insert
- Update check on $contact that can only be an array now
- Add moethod doc block
2019-05-20 15:29:20 -04:00
Hypolite Petovan 709eba6ce3 Move /viewcontacts to /profile/{nickname}/contacts[/{type}]
- Add contact relationship filter to profile contacts page
- Include feed contacts in contacts page and contact widget
2019-05-20 14:50:09 -04:00
Hypolite Petovan 58d5c6610c
Merge pull request #7168 from annando/suggest-receive
Suggestions can be processed again
2019-05-19 14:58:30 -04:00
Michael Vogel a3c95eeaab Suggestions can be processed again 2019-05-19 19:58:20 +02:00
Hypolite Petovan fc312e4c98
Merge pull request #7153 from annando/ap-mail-delivery
Fix receiver list for mails
2019-05-18 11:50:10 -04:00
Michael Vogel 69e38c2bbd Missing arrrrr! 2019-05-18 17:34:44 +02:00
Michael Vogel f3c2eb5b11 Fix receiver list for mails / only deliver mail via DFRN to legacy contacts 2019-05-18 11:09:13 +02:00
Michael 490e850b48 Fix for receiving direct messages from Mastodon 2019-05-18 07:00:57 +00:00
Michael d81b7c840e Adding missing spaces 2019-05-17 18:00:00 +00:00
Michael f6fc70c4e2 Make AP "direct messages" more compatible to Mastodon 2019-05-17 17:58:42 +00:00
Hypolite Petovan 1cf9a1ab7c Allow null $tags parameter in ActivityPub\Processor::constructTagString 2019-05-16 18:10:42 -04:00
Michael 3f55f93606 AP: We can now receive "direct messages" (aka "mails") as well 2019-05-16 05:44:59 +00:00
Michael 87b98b8249 Sending direct messages via AP does work now - receiving is pending 2019-05-14 17:50:45 +00:00
Michael 9e31b1b486 Don't attach images to the body if it was from a Friendica system 2019-05-13 19:56:46 +00:00
Michael 55557a8f18 Contacts with protocol = AP are now delivered only via AP 2019-05-11 05:58:22 +00:00
Michael b8a23369b6 Mail storing is now centralized 2019-05-08 05:44:22 +00:00
Hypolite Petovan e17db489ee
Merge pull request #7095 from annando/ap-connect
Switching from legacy DFRN connect to ActivityPub
2019-05-05 09:37:43 -04:00
Michael 74a25707e1 Filling the protocol on ap contact action 2019-05-05 11:02:19 +00:00
Michael Vogel 2365193691 AP: Support of request messages 2019-05-05 11:17:45 +02:00
Michael Vogel 56d2df04f0 Don't switch Friendica contacts to AP 2019-05-03 07:10:02 +02:00
Hypolite Petovan e6bf97777f Remove /display/{nick}/{id} URL structure publishing
- Remove support for defunct Friendica F-Droid app
2019-05-02 17:04:17 -04:00
Michael 9941c33123 Removing a contact request needn't to be one not approved requests 2019-05-02 20:04:15 +00:00
Hypolite Petovan 41f781c52a Replace System::httpExit() by HTTPException throwing 2019-05-02 11:37:09 -04:00
Michael 8adf0e6e5c Removed test logging 2019-05-02 13:46:12 +00:00
Michael 28f316b7e4 Replace the legacy DFRN connection process with AP 2019-05-02 13:05:31 +00:00
Michael Vogel 581895c07d Preparation for switching the connect mechanism from DFRN to AP 2019-04-30 20:07:20 +02:00
Michael eef85584c2 AP: Parsing of messages from Pleroma should work now again 2019-04-26 06:17:37 +00:00
Hypolite Petovan 6a2c0b3cc7
Merge pull request #6989 from nupplaphil/task/basePath_baseUrl_fix
Automatic BaseURL determination fix
2019-04-11 04:07:20 -04:00
Philipp Holzer 318a3ca785
Create own base URL class which holds the whole base url business logic 2019-04-09 08:31:16 +02:00
Michael f387d85cdb Fetch profile data from different contact tables when we won't or can't probe via network 2019-04-08 20:41:18 +00:00
Michael 46a99a05a1 Remove the queue from the core 2019-04-05 18:04:39 +00:00
Michael 01bb05b502 Avoid repeated transmitting of profile updates 2019-04-05 04:42:04 +00:00
Hypolite Petovan 26c2290fed
Merge pull request #6972 from annando/queue-to-worker
Use deferred workers instead of the queue mechanism
2019-04-04 17:29:16 -04:00
Michael e3caf0f4f5 Use deferred workers instead of the queue mechanism 2019-04-04 20:51:12 +00:00
Michael Vogel c439cb656a
Merge pull request #6957 from MrPetovan/bug/6943-add-tombstone
Send AP Tombstone activity on deleted profiles
2019-04-04 22:27:49 +02:00
Hypolite Petovan 5b12bccb45 Move user tombstone activity data to ActivityPub\Transmitter 2019-04-04 07:38:40 -04:00
Michael e66e2adf5f AP: Incoming announces are now stored as activities 2019-04-02 21:10:49 +00:00
Michael 455616b52c Add "announce" activity for incoming Diaspora reshares 2019-04-01 22:07:23 +00:00
Michael 198e150ba8 Archive inboxes after 5 days of delivery failures 2019-03-25 21:51:32 +00:00
Michael 2788995ab0 The "summary" field seems to be interpreted as plain text only 2019-03-18 22:38:10 +00:00
Michael 2cdd5a4940 Fixes errors/notices 2019-03-17 22:13:17 +00:00
Michael f78c148013 Clarified return values 2019-03-17 15:49:21 +00:00
Michael 75ec384fc3 Added logging since this exixted before 2019-03-17 13:56:47 +00:00
Michael cec094c5b1 Centralise the item content processing in a single function 2019-03-17 13:50:14 +00:00
Michael 0104da3c93 Summary has to be converted to HTML / Don't use summary when we have the source 2019-03-17 00:06:31 +00:00
Michael ce2e98ea68 Adding a line feed looks nicer 2019-03-16 11:18:36 +00:00
Michael 14b56ce0cc Adding the "abstract" element to the imported feed 2019-03-16 10:59:11 +00:00
Michael dfcf1b1e6f We now send a summary via AP. This partially fixes the problem with Mastodon and Articles 2019-03-16 08:46:33 +00:00
Michael 4ff837488f Issue 6167: Don't publish non visible content 2019-03-15 20:31:07 +00:00
Michael cd0d6cb626 Forums now are working with AP as well 2019-03-14 18:44:41 +00:00
Hypolite Petovan d0b2ed7966 Remove test code in ActivityPub\Processor 2019-03-09 09:04:43 -05:00
Hypolite Petovan 70782b3977 Fix implicit mention detection regular expression flags in ActivityPub\Processor 2019-03-09 09:04:11 -05:00
Hypolite Petovan 704cb052ca Add server block provision to Diaspora::postAllow 2019-03-08 22:40:08 -05:00
Michael a911baf8e5 Avoid transmitting a deletion message when we don't have a key 2019-03-04 06:52:43 +00:00
Hypolite Petovan 3e290da8c2 Code standards: Add missing space in ActivityPub\Processor 2019-02-25 03:16:18 -05:00
Hypolite Petovan 1f6e0f168c Add missing author contact in ActivityPub\Processor
- Add logging for future occurrences
- Addresses https://github.com/friendica/friendica/issues/6338#issuecomment-466812104
2019-02-24 15:52:03 -05:00
Michael Vogel 4c6c5786ad
Merge pull request #6752 from MrPetovan/bug/notices
Fix various notices
2019-02-24 21:30:07 +01:00
Hypolite Petovan e66768a058 Add empty entry author if contact query fails in DFRN
- Addresses https://github.com/friendica/friendica/issues/6338#issuecomment-462722599
2019-02-24 14:00:40 -05:00
Hypolite Petovan 0888850702 Fix missing avatar key in DFRN
- Addresses https://github.com/friendica/friendica/issues/6338#issuecomment-456839092
2019-02-24 13:40:04 -05:00
Hypolite Petovan 42c06506ce Stop appending entry when parent is missing in OStatus
- Addresses https://github.com/friendica/friendica/issues/6338#issuecomment-455785854
2019-02-24 13:36:37 -05:00
Hypolite Petovan 458064ddde
Merge pull request #6749 from nupplaphil/6386-php_fatal
Fixing appending child at DFRN without a parent id.
2019-02-24 12:55:34 -05:00
Philipp Holzer 5d13b94761
update phpdoc 2019-02-24 16:31:16 +01:00
Philipp Holzer bf6a765beb
Fixing appending child at DFRN without a parent id. 2019-02-24 16:30:09 +01:00
Michael Vogel efe358c617
Merge pull request #6746 from nupplaphil/issue/6338-notices
Fixing notices
2019-02-24 15:44:54 +01:00