Compare commits

...

5176 Commits
5.0 ... master

Author SHA1 Message Date
Mario
deb4c54ebf version 11.2.1 2026-05-20 07:53:27 +02:00
Mario
281f518705 update changelog
(cherry picked from commit 496dade675)

Co-authored-by: Mario <mario@mariovavti.com>
2026-05-20 05:51:49 +00:00
Mario
a8d9747b12 test variable before using it
(cherry picked from commit 82b8ed2652)

Co-authored-by: Mario <mario@mariovavti.com>
2026-05-20 05:49:33 +00:00
Mario
4b15b07b8b update changelog
(cherry picked from commit 2625fe9527)

Co-authored-by: Mario <mario@mariovavti.com>
2026-05-20 05:43:42 +00:00
Mario
607a5488d6 Improve detecting suspicious ActivityStreams keys
Using string comparison on the whole key does not work, as some keys
will be given prefixes during expansion. We need to check if the payload
has keys that _contain_ the suspicious keywords we're looking for.


(cherry picked from commit 0c7731bb76)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2026-05-18 19:06:06 +00:00
Mario
519b52ccdc check for currently unsafe json-ld constructs
(cherry picked from commit 67d73f74ac)

45460e99 check for currently unsafe constructs
5ebb8546 move the jsonld unsafe keys check up a little so that it will actually terminate if positive.
363e2ab5 fix invalid json
b2362c8c only expand and check jsonld if verifying
d21ac6ef jsonld: refactor and hard fail on normalisation or expansion error
2e64496e Merge branch 'dev' into json-ld
c0918861 revert always hard fail

Co-authored-by: Mario <mario@mariovavti.com>
2026-05-18 19:05:16 +00:00
Mario
99fd2e1cb9 tests: Use minimal channel for LDSignature tests
Move the channel keypair and other fields needed by the
LDSignature::verify function to the test case itself. This makes the
test case independent on any potential future changes to the fixtures.


(cherry picked from commit 8d283e0be5)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2026-05-18 19:03:59 +00:00
Mario
a69c460ee6 tests: Add basic test for LDSignature::verify
(cherry picked from commit 0cd682d85e)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2026-05-18 19:03:11 +00:00
Mario
71ba6406e3 tests: Fix invalid keypair for channel fixture
(cherry picked from commit 9aff1d4024)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2026-05-18 19:02:48 +00:00
Mario
4922acb18a actually there is no need to set App::$profile here because it will be set in profile_load() if applicable
(cherry picked from commit 0376b5d442)

Co-authored-by: Mario <mario@mariovavti.com>
2026-05-18 19:01:04 +00:00
Mario
a0ea19e51c do not set App::$profile for removed channels and minor cleanup
(cherry picked from commit b20ed4f455)

Co-authored-by: Mario <mario@mariovavti.com>
2026-05-18 19:00:15 +00:00
Mario
8c4457db8b messageFilter: make sure we do not choke if we expect a string but an array is given 2026-03-27 21:53:04 +00:00
Mario
89a1af1794 Merge branch '11.2RC' 2026-03-26 08:08:37 +00:00
Mario
d5e0c24e13 version 11.2 2026-03-26 08:06:51 +00:00
Mario
8fe73d73ce Merge branch 'dev' into 11.2RC 2026-03-26 08:05:53 +00:00
Mario
7559d6bb5c update changelog 2026-03-26 08:05:06 +00:00
Mario
6c40576f94 Merge branch 'dev' into 11.2RC 2026-03-26 07:50:56 +00:00
Mario
1c9c0dc70e update changelog 2026-03-26 07:50:08 +00:00
Mario
bf4227bfef Merge branch 'drop-private-members-from-apidocs' into 'dev'
Remove private members from API docs

See merge request hubzilla/core!2275
2026-03-25 18:12:54 +00:00
Mario
c296d4bbed Merge branch 'drop-custom-ca-certs' into 'dev'
Remove custom CA certs

See merge request hubzilla/core!2274
2026-03-25 18:12:21 +00:00
Harald Eilertsen
68452fb07b Remove private members from API docs
Private class members are internal implementation details, and should
not be in public API documentation.
2026-03-25 18:29:38 +01:00
Harald Eilertsen
7f98cd606b Remove custom CA certs
The included collection of CA certificates has not been updated since
2021, which means it's outdated and possibly a security risk. Also it
should not be necessary, as curl is able to find the system installed CA
certs which is more likely to be up to date and safer.
2026-03-25 18:06:39 +01:00
Mario
d0ae7a0493 Merge branch 'route-apidoc-fixes' into 'dev'
Zotlabs\Extend\Route: API docs and visibility/type fixes

See merge request hubzilla/core!2273
2026-03-25 15:18:27 +00:00
Harald Eilertsen
81e79eec04 Zotlabs\Extend\Route: Add type annotations
Make the code safer by adding type annotations for parameters and return
values.
2026-03-25 15:34:24 +01:00
Harald Eilertsen
7d70f2f0f2 Zotlabs\Extend\Route: Set method visibility
Make `Route::set()` private. It is not referenced outside of the class
itself, and is also unsafe as it uncritically replaces the system routes
with whatever value it was passed.

The remaining functions are set to public visibility.
2026-03-25 12:45:44 +01:00
Harald Eilertsen
016a11ad27 Zotlabs\Extend\Route: Add API docs + licence info 2026-03-25 12:33:11 +01:00
Mario
1637e61681 update changelog 2026-03-25 10:30:27 +00:00
Mario
1ec0e91405 fix issue in route and widget unregister: we should remove only if both arguments are different. Also only register routes and widgets if they are not yet registered 2026-03-25 10:16:49 +00:00
Mario
3ab52a060b add sleep intervals when adding worker tasks in a loop in Activity::init_background_fetch()
(cherry picked from commit 955ee217e3)

Co-authored-by: Mario <mario@mariovavti.com>
2026-03-25 07:54:51 +00:00
Mario
866cd52073 Convo: fetched collections can be huge - add a slight delay between storing items if we did not fetch them from the network to allow the DB to do its thing
(cherry picked from commit 6d8bfe58ef)

Co-authored-by: Mario <mario@mariovavti.com>
2026-03-25 07:52:33 +00:00
Mario
1774140307 Storage/Directory: fix issue where we returned a partial path instead of throwing exception if a directory of a path could not be found 2026-03-23 20:57:46 +00:00
Mario
698dce044d rc2 2026-03-18 09:13:58 +00:00
Mario
bf0d73515e Merge branch 'dev' into 11.2RC 2026-03-18 09:13:23 +00:00
Mario
8152da1275 update changelog 2026-03-18 09:13:00 +00:00
Mario
01de48b994 Merge branch 'dev' into 11.2RC 2026-03-18 09:02:20 +00:00
Mario
eb10820195 Merge branch 'daemon-externals-endless-loop' into 'dev'
Daemon/Externals: Shorten endless loop

See merge request hubzilla/core!2272
2026-03-18 09:01:32 +00:00
Harald Eilertsen
9d33456c89 Daemon/Externals: Shorten endless loop
If the query towards the hubloc table don't return any entries, the loop
would continue without modifying any of the variables that could
possibly make the loop end.
2026-03-17 21:42:28 +01:00
Mario
56c7f76230 Merge branch 'dev' into 11.2RC 2026-03-17 11:47:27 +00:00
Mario
3dd9559d9f fix spdx info and remove superfluous use statements 2026-03-17 06:24:03 +00:00
Mario Vavti
51ac502d97 refactor drop_query_params() to deal with array params and add test 2026-03-16 10:32:59 +01:00
Mario
955ee217e3 add sleep intervals when adding worker tasks in a loop in Activity::init_background_fetch() 2026-03-14 19:58:09 +00:00
Mario
6d8bfe58ef Convo: fetched collections can be huge - add a slight delay between storing items if we did not fetch them from the network to allow the DB to do its thing 2026-03-14 19:41:26 +00:00
Mario
f98f540256 update changelog 2026-03-14 19:37:37 +00:00
Mario
54c7319075 fix version 2026-03-14 10:33:06 +00:00
Mario
72c930f964 remove accent color test 2026-03-14 10:31:32 +00:00
Mario
ce24b86841 fix fatal error in italian hstrings.php 2026-03-14 10:29:48 +00:00
Mario
f63ba541d7 bump dev version 2026-03-13 16:14:46 +00:00
Mario
a9f54473db version and strings and move hmessages.po to hmessages.pot 2026-03-13 16:11:13 +00:00
Mario
eb5ea6536b fix php warning 2026-03-11 19:05:39 +00:00
Mario
2e9b64347d Merge branch 'gettext-updates' into 'dev'
util/run_xgettext: Rename template to .pot and force PHP matching

See merge request hubzilla/core!2271
2026-03-11 18:48:47 +00:00
Mario
4fcff43fb5 Merge branch 'tests-make-loadFixtures-public' into 'dev'
tests: Make loadFixtures public

See merge request hubzilla/core!2270
2026-03-11 18:41:24 +00:00
Harald Eilertsen
260b61ba3b util/run_xgettext: Use PHP matching rules
Explicitly tell xgettext to use PHP matching rules to find translatable
strings.

Project......: Improve Superblock Addon
Sponsored-by.: NLnet NGI0 Commons Fund
2026-03-11 11:51:35 +01:00
Harald Eilertsen
d0b7e4ea79 util/run_xgettext: Rename template to .pot
Renaming the translation template to *.pot, works better with some
tooling like poedit and lokalize.

Project......: Improve Superblock Addon
Sponsored-by.: NLnet NGI0 Commons Fund
2026-03-11 11:48:09 +01:00
Harald Eilertsen
33c95c810a tests: Make loadFixtures public
Some tests will need to load their own database fixtures. By making this
API public we make it easy for them to do so.

This change is needed by the tests for the Superblock addon.

Project......: Improve Superblock Addon
Sponsored-by.: NLnet NGI0 Commons Fund
2026-03-11 11:40:31 +01:00
Mario
81105ff9de Merge branch 'null-date-fix' into 'dev'
Remove use of NULL_DATE constant in core

See merge request hubzilla/core!2269
2026-03-08 17:07:41 +00:00
Harald Eilertsen
ced3113516 Remove unneccessary use statements 2026-03-07 12:00:56 +01:00
Harald Eilertsen
cbd208eea3 Remove use of NULL_DATE constant in core
The NULL_DATE constant is defined conditionally in the DBA static class.
This causes issues with static analyzing tools like PHPStan, because
they can not really know if the constant is defined or not.

We could make PHPStan ignore this, but since there already is a
`get_null_date()` method on the `dba_driver` class, this patch
changes the code to use this method instead.

We could also use the public static attribute `$null_date` on the DBA
class directly, but using a method feels cleaner, and allows for making
the attribute private, or even removing it completely at some later
time.

I'm not removing the NULL_DATE constant for now, in case it is in use by
any extensions.
2026-03-07 11:15:46 +01:00
Mario Vavti
ad85825cab remove composer dev stuff 2026-03-04 18:34:45 +01:00
Mario Vavti
2fb816139a guzzlehttp/psr7 has been removed from the HttpSigner library because it is not required there, hubzilla still needs it 2026-03-04 18:29:33 +01:00
DDEV User
c9166b26c5 update composer libs 2026-03-04 17:51:14 +01:00
Mario Vavti
86d58065b3 deal with leading or missing @ and add more tests 2026-03-04 10:25:32 +01:00
Mario
1f265cc6d5 fix tests (hopefully) 2026-03-04 08:44:09 +00:00
Mario
4474fdd4f9 introduce parse_webbie() with basic tests 2026-03-04 08:34:45 +00:00
Mario
f71eeab5be fix php warning 2026-03-03 11:27:01 +00:00
Mario
b3526415f9 allow to override curl useragent 2026-03-03 10:59:11 +00:00
Mario
471ded3efa Merge branch 'sys_stat_fixes' into dev 2026-03-03 09:19:09 +00:00
Mario
e954d8c55e mod network: dismiss privacy filter for various filter options - fix issue #1973 2026-03-03 09:17:56 +00:00
Mario
70f82c3967 stop duplicating content in reactions - fix issue #1970 2026-03-03 07:57:39 +00:00
Mario
707e07bbbc Merge branch 'sys_stat_fixes' into 'dev'
Only poll perfstats if the widget is actually visible

See merge request hubzilla/core!2267
2026-03-02 13:47:51 +00:00
Mario
e89eb04427 Merge branch 'dev' into sys_stat_fixes 2026-03-02 08:59:45 +00:00
Mario
ae0e82ee3a wait for domn content loaded 2026-03-02 08:48:14 +00:00
Mario
9ea5d20a3d use JS listener instead of jquery 2026-03-02 08:45:42 +00:00
Mario
fd69008484 this probably should not be const but keep it non global anyway 2026-03-02 08:05:31 +00:00
Mario
3256aa8be9 only poll perfstats if the widget id actually visible (the widget is mostly hidden when viewing content in HQ) 2026-03-02 07:34:43 +00:00
Mario
add26a5b5f fix Queue::count() return value 2026-03-01 19:12:01 +00:00
Mario
dc03263bef Merge branch 'system-status-activity-widget' into 'dev'
Add system status activity widget to HQ for admins

See merge request hubzilla/core!2266
2026-03-01 18:42:54 +00:00
Harald Eilertsen
1897cd0b1b Make system status widget a bit more snappy
Fetch the initial data when the widget loads, and then update every five
sec after that. Also better indication of uninitialized values.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-03-01 11:47:39 +01:00
Harald Eilertsen
ba24958b37 Remove some debug logging in system status widget
Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-03-01 11:38:07 +01:00
Harald Eilertsen
52a2a0d89a Pass loadavg as array from Perfstats
There's no reason we should format the data into a string in the
Perfstats module. Let the recipient do what they want with it instead.

As an example, we reduce the precision of the loadavg stats in the
system status widget. 3 digits precision should be more than enough for
this type of status display.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-03-01 11:34:28 +01:00
Harald Eilertsen
91944da69e Report queries/sec in system status widget
The total number of queries is not that interesting for performance
measurements, so let's do queries pr/second instead. Adds a timestamp
column to the dataset, which could be useful for other purposes as well
(like making a graph over time etc.)

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-03-01 11:16:05 +01:00
Harald Eilertsen
78e30a4d32 Simplify stats for getting size of output queue
Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-26 16:28:59 +01:00
Harald Eilertsen
ccd6d1a38c Move db stats to separate classes for each db type
Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-26 16:19:17 +01:00
Mario
f14c1be963 Some projects use double typing for its objects (bandwagon in this case) - we do not support this, hence go with the first entry and hope for the best. 2026-02-26 11:31:56 +00:00
Harald Eilertsen
db5e92b72d Remove unused/incomplete function
Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:34:04 +01:00
Harald Eilertsen
3d3580b23f Validate requests to perfstats
Make some stricter rules for accessing the perfstats module. We only
want to respond to GET request for json data made by a site admin.

This means we also need to pass along the credentials in the request.
Didn't immediately figure out how to do that using `z_fetch_url`, so we
just fall back to using the JavaScript to populate the widget. This
makes it idle for about 5 sec before it gets the first data sample.

I think that's probably OK.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:21:09 +01:00
Harald Eilertsen
04d44c9965 Remove link from system status widget title
At least for now, there's no sensible link target, so it's better to not
link anywhere.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:21:09 +01:00
Harald Eilertsen
82bd91d9d7 Log error if system status can't load
Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:21:09 +01:00
Harald Eilertsen
492533729d Human labels for system status widget
Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:21:09 +01:00
Harald Eilertsen
283b606c09 Update system status activity widget periodically
Adds a bit of javascript that requests the performance stats every 5
seconds.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:21:09 +01:00
Harald Eilertsen
b0b5523f2b Add perfstat module
Moves collecting performance statistics for the system status activity
widget to a separate module. This will make it easier to get the data
from JavaScript or external monitoring tools.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:21:09 +01:00
Harald Eilertsen
738797467d Turn dba_driver params into attributes
To allow for inspecting the params used to connect to the database, we
now save the params in the dba_driver object instance as readonly
attributes. An exception is made to the $pass parameter which is set to
protected access, to make it slightly harder to accidentally leak it.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 21:20:52 +01:00
Harald Eilertsen
a2ee5705f4 Add System Status panel to HQ for admins
Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 20:15:58 +01:00
Harald Eilertsen
cc1713b69a Add Queue::get_undelivered() helper function
Returns the number of undelivered messages in the outq.

Instead of having direct database queries at various places in the code,
I thought it would be better to keep them in a more logical place.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 20:15:06 +01:00
Harald Eilertsen
6f5e4c5c2e Add QueueWorkerStats class
A simple class to fetch and hold queueworker stats.

Project......: Performance Profiling
Sponsored-by.: NLnet NGI0 Commons Fund
2026-02-23 20:13:33 +01:00
Mario
3e0b9c01b6 Merge branch 'channel-manage-tpl' into 'dev'
move manage channel alert to tpl

See merge request hubzilla/core!2265
2026-02-17 09:22:07 +00:00
SK
25218fea43 move manage channel alert to tpl
allows a way to customize appearance of html for channel manager alerts
2026-02-15 06:42:35 +05:30
Mario
c907e569f1 fix wrong var after refactor 2026-02-14 10:41:52 +00:00
Mario
b6bec6f7b7 reverse logic 2026-02-14 10:29:14 +00:00
Mario
31b5cfe7ef if the event timezone is different from the channel timezone, display the timezone we have adjusted to instead of the actual event timezone. Otherwise we might create UX confusion about if the displayed time is already timezone adjusted or not. 2026-02-13 08:50:25 +00:00
Mario
0efb3c5c95 comment out deprecated use of tags and attachments in activities 2026-02-13 08:25:05 +00:00
Mario
d88f3169c8 fix possibly duplicated terms in activity object 2026-02-13 08:22:19 +00:00
Mario
3772e910df fixup after testing to get a minimalistic working config 2026-02-12 20:12:18 +00:00
Mario
e995d45b53 Merge branch 'patch-1' into 'dev'
Updated the nginx config example to meet the more modern approach.

See merge request hubzilla/core!2249
2026-02-12 19:45:21 +00:00
spirillen
669136bce7 Updated the nginx config example to meet the more modern approach. 2026-02-12 19:45:20 +00:00
Mario
2448e6df27 Merge branch 'fix-undefined-var-issues' into 'dev'
Fix various possibly undefined var issues

See merge request hubzilla/core!2264
2026-02-12 18:30:59 +00:00
Mario
4c0b37db66 fix required $x variable overwritten with attach_mkdirp() data on update 2026-02-12 18:18:00 +00:00
Mario Vavti
85d42cebe2 Merge branch '11.0RC' 2026-01-30 14:21:21 +01:00
Mario Vavti
fcafaef190 version 11.0 2026-01-30 14:20:12 +01:00
Mario
6fa8deddb5 update changelog
(cherry picked from commit 0ea3f3d36d)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-30 13:18:14 +00:00
Mario Vavti
0ea3f3d36d update changelog 2026-01-30 14:14:11 +01:00
Mario
1ef7fcda0a Remove capability to update xchan entries via api. If this functionality is required it should be implemented over a channel endpoint where xchan and channel info would be updated after verification.
(cherry picked from commit cb7dc2059a)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-30 13:00:39 +00:00
Mario Vavti
cb7dc2059a Remove capability to update xchan entries via api. If this functionality is required it should be implemented over a channel endpoint where xchan and channel info would be updated after verification. 2026-01-30 13:34:54 +01:00
Harald Eilertsen
e988bc9fae Fix various possibly undefined var issues
These are all cases where a variable is used where it may possibly be
undefined at the time of use. Typically the var is defined within a
conditional block, but is used outside of that block, or even within
other conditional blocks.

In the common case the variables will most likely be defined, but it is
possible to reach the code where they are used without the variable
being defined.

All issues discovered with PHPStan at level 1.
2026-01-29 22:31:16 +01:00
Mario
bbd60c1a31 update changelog
(cherry picked from commit cb23a9e235)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-29 16:28:59 +00:00
Mario
951187e540 fix issue where reply-to button is not diplayed for anonymous visitors allthough permission is granted
(cherry picked from commit 8d9623674d)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-29 16:28:37 +00:00
Mario Vavti
cb23a9e235 update changelog 2026-01-29 17:27:29 +01:00
Mario Vavti
8d9623674d fix issue where reply-to button is not diplayed for anonymous visitors allthough permission is granted 2026-01-29 17:25:45 +01:00
Mario
0c835c3403 update changelog
(cherry picked from commit 6d181ee69e)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-29 15:57:25 +00:00
Mario Vavti
6d181ee69e update changelog 2026-01-29 16:56:58 +01:00
Mario
0b491a6626 fix wrong icon class
(cherry picked from commit 2d97f8fa25)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-29 15:55:11 +00:00
Mario
1a0684cc55 fix issue deleting multiple files
(cherry picked from commit 98a3c97820)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-29 15:54:48 +00:00
Mario Vavti
2d97f8fa25 fix wrong icon class 2026-01-29 16:45:27 +01:00
Mario Vavti
98a3c97820 fix issue deleting multiple files 2026-01-29 16:36:07 +01:00
Mario
081a61a276 update changelog
(cherry picked from commit 89e1328ed0)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-29 11:39:34 +00:00
Mario Vavti
89e1328ed0 update changelog 2026-01-29 12:38:59 +01:00
Mario
3b516f2ded another hotfix for an issue which requires investigation
(cherry picked from commit 99a1569d07)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-29 11:36:21 +00:00
Mario
8c386191fa move html from search module to tpl
(cherry picked from commit a0cb5fcb3f)

Co-authored-by: SK <sk@utsukta.org>
2026-01-29 11:17:49 +00:00
Mario
5cb4db0353 Merge branch 'dev-send_reg_approval' into 'dev'
(Re?)enable email to user after account approval

See merge request hubzilla/core!2263
2026-01-29 10:45:25 +00:00
Mario
dc43cd9a85 Merge branch 'dev-fix-approve-email' into 'dev'
Add new send_reg_approval_email_from_register function

See merge request hubzilla/core!2262
2026-01-29 10:42:21 +00:00
Mario
5a6a7386a8 Merge branch 'more-xchan-tests' into 'dev'
tests: A few more xchan tests

See merge request hubzilla/core!2261
2026-01-29 10:38:35 +00:00
Mario
4f545e31dd Merge branch 'tests-add-ajax-request-helper' into 'dev'
tests: Add ajax request helper to module test case

See merge request hubzilla/core!2260
2026-01-29 10:35:43 +00:00
Mario
437c0a8913 Merge branch 'search-module-tpl' into 'dev'
move html from search module to tpl

See merge request hubzilla/core!2258
2026-01-29 10:33:05 +00:00
ltning
268fccdb30 Fix SQL in send_reg_confirmation_email_from_register 2026-01-28 20:06:59 +00:00
ltning
bb7689be93 Return boolean instead of nonexistent array 2026-01-28 02:51:58 +00:00
ltning
bd63af69b2 (Re?)enable email to user after account approval
Existing function account_allow() does not seem to be used a whole
lot, and certainly not when approving a registration request.

Created new function send_reg_confirmation_email_from_register
(going for longest-function-name-in-Hubzilla) which attempts to
send such a confirmation email, and also a new email template.

Plugged this into the create_account_from_register function.

Open question: Should the sending of this email be among the success
criteria for the create_account_from_register function?
2026-01-28 02:51:46 +00:00
ltning
e5d4358d61 Clean up send_reg_approval_email_from_register, new email template
Since there is no easy way to produce direct links to approve/reject
registrations, create new email template which simply links to the
Accounts admin page.

In response to comments:
 - Add type annotations
 - Simplify some 'if' statements
 - add and fix some whitespace
 - simplify input arguments to the function
2026-01-27 16:32:16 +00:00
ltning
0fa4962620 Clean up some whitespace confusion in the previous commit 2026-01-27 16:32:16 +00:00
ltning
fe4d6229a4 Add new send_reg_approval_email_from_register function
Current send_reg_approval_email function expects account to already
exist, and does not seem to be called anywhere. New function takes
necessary information from the register table.

Added call to new function in Regate.php after verification is
done. Will fail and roll back if the function call fails or if no
admin accounts were found to notify (delivered<1).
2026-01-27 16:32:16 +00:00
Mario
10c5de4f6e another hotfix for an issue which requires investigation
(cherry picked from commit 99a1569d07)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-27 11:27:01 +00:00
Mario Vavti
99a1569d07 another hotfix for an issue which requires investigation 2026-01-27 12:26:06 +01:00
Harald Eilertsen
9fb5cd12be tests: A few more xchan tests 2026-01-27 09:43:44 +01:00
Harald Eilertsen
d85c737db7 tests: Add ajax request helper to module test case
This is a bit crude, but serves the purpose for now. To emulate an AJAX
request we set the `Content-Type` header to `application/json`, and json
encode the params in the body of the request.
2026-01-26 23:03:07 +01:00
Mario Vavti
9657fc50e9 Merge branch 'dev' into 11.0RC 2026-01-25 13:06:34 +01:00
Mario
de468a29b0 hotfix for issue with the potential to stuff up the queuewrker
(cherry picked from commit 794b456b8a)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2026-01-25 12:05:49 +00:00
Mario Vavti
794b456b8a hotfix for issue with the potential to stuff up the queuewrker 2026-01-25 13:02:15 +01:00
SK
a0cb5fcb3f move html from search module to tpl 2026-01-22 15:26:20 +05:30
Mario
0d382634ec Merge branch 'access_dropdown-tpl' into 'dev'
move html from accesslist module to tpl

See merge request hubzilla/core!2257
2026-01-21 13:24:35 +00:00
SK
225c83dfbe move html from accesslist module to tpl 2026-01-19 14:00:39 +05:30
Mario Vavti
083c4c95d1 Merge branch 'dev' into 11.0RC 2026-01-18 13:07:17 +01:00
Mario Vavti
e736945f1d update changelog 2026-01-18 13:06:42 +01:00
Mario Vavti
4a2e5add36 update changelog 2026-01-18 12:56:59 +01:00
Mario Vavti
067a79a778 Merge branch 'dev' into 11.0RC 2026-01-17 13:02:37 +01:00
Mario
cb0102b971 Merge branch 'channel-activities-header' into 'dev'
move channel-activities header to its tpl

See merge request hubzilla/core!2254
2026-01-17 11:44:55 +00:00
Saiwal K
8b46767d30 move channel-activities header to its tpl 2026-01-17 11:44:54 +00:00
Mario Vavti
26b5dabe72 Merge branch 'dev' into 11.0RC 2026-01-16 12:38:41 +01:00
Mario Vavti
3f39d0d249 fix cloud root folder shows unknown error 2026-01-16 12:38:02 +01:00
Mario Vavti
2b4d2baa7b version 2026-01-16 10:35:29 +01:00
Mario Vavti
3130a94a4c bump redbasic min/max version 2026-01-16 10:27:54 +01:00
Mario Vavti
d44c004bd0 bump dev version 2026-01-15 17:24:39 +01:00
Mario Vavti
c655046e1f version, strings and updated util/run_xgettext.sh 2026-01-15 17:13:32 +01:00
Mario Vavti
b32c1c1e22 composer update 2026-01-15 14:50:39 +01:00
Mario
38f040f9b5 Merge branch 'minor-test-improvements' into 'dev'
tests: Make addonname/tests base addon tests dir

See merge request hubzilla/core!2250
2026-01-15 10:53:57 +00:00
Mario
7dcaebf281 Merge branch 'italian-translation' into 'dev'
Italian translation

See merge request hubzilla/core!2253
2026-01-15 10:53:04 +00:00
Mario
fad5f98405 Merge branch 'bookmarks-layout-tpl' into 'dev'
move html from bookmarks module to its tpl

See merge request hubzilla/core!2255
2026-01-15 10:48:01 +00:00
SK
ea07bd1693 move html from bookmarks module to its tpl 2026-01-15 02:15:26 +05:30
Mario
4a7b2e92a5 make sure we deal with a string
(cherry picked from commit b6153edf6b)

Co-authored-by: Mario <mario@mariovavti.com>
2026-01-08 19:50:31 +00:00
Mario Vavti
deaab14c5f revert revert 2026-01-07 11:37:22 +01:00
Mario Vavti
8258b8b088 revert 2026-01-07 10:52:22 +01:00
Mario Vavti
db5c217a21 reuse the stored filetype 2026-01-07 10:48:11 +01:00
prealpinux
724ee7dbab Italian translation 2026-01-06 22:40:30 +01:00
Mario Vavti
fb9fe0d3c4 bump version 2026-01-05 15:43:32 +01:00
Mario Vavti
9019636449 update attach.filetype field length to match photo.mimetype field length and attempt to find mimetype with finfo class if applicable. 2026-01-05 15:34:42 +01:00
Mario Vavti
933b4fbcfe bump version 2026-01-05 12:21:55 +01:00
Mario Vavti
7675ed0145 add (not exactly correct -> see fixme) mime types for docx and xlsx 2026-01-05 12:14:01 +01:00
Mario
73e7f0aad2 Escape args in xchan_fetch
(cherry picked from commit cedc6c4230)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2026-01-04 19:58:46 +00:00
Mario
f25211d7ff Merge branch 'xchan-fetch-escape-args' into 'dev'
Escape args in xchan_fetch

See merge request hubzilla/core!2252
2026-01-04 19:53:51 +00:00
Mario
30cf6d827c Merge branch 'issue-1960-fix-grammar-in-enotify' into 'dev'
Fix grammar in Enotify::submit

See merge request hubzilla/core!2251
2026-01-04 19:49:42 +00:00
Mario
1323ea8e18 Merge branch 'dev' into 'dev'
move shared post formatting to its own tpl

See merge request hubzilla/core!2248
2026-01-04 19:36:06 +00:00
Saiwal K
9f98f6bbd5 move shared post formatting to its own tpl 2026-01-04 19:36:06 +00:00
Harald Eilertsen
cedc6c4230 Escape args in xchan_fetch 2026-01-04 14:55:03 +01:00
Mario Vavti
b6a58fbf6e make sure editor init also works from the tiles view 2026-01-03 19:31:56 +01:00
Mario Vavti
e295765bef fix typo and wrongedited timestamp. also add data-{id, type} to cloud directory listings 2026-01-02 15:31:54 +01:00
Harald Eilertsen
141dc2fdb7 Fix grammar in Enotify::submit
Fixes issue #1960: https://framagit.org/hubzilla/core/-/issues/1960
2025-12-29 20:37:20 +01:00
Harald Eilertsen
c051c4d0aa tests: Make addonname/tests base addon tests dir
This makes it easier to treat anything under tests/ as namespaced for
PSR-4 autoloading.
2025-12-21 11:05:37 +01:00
Harald Eilertsen
e289078f82 tests: Fix content-type/length in Module\TestCase 2025-12-21 11:04:25 +01:00
Mario
87f79381d9 MessageFilter: move decoding to the caller and also check the summary field 2025-12-19 08:24:22 +00:00
Mario
98840ae1d0 fix deprecation warning 2025-12-16 12:07:20 +00:00
Mario
28746891c8 curl_close() is deprected and noop since PHP version 8.0 2025-12-16 11:47:10 +00:00
Mario
e5d0ef79ef GD imagedestroy() is deprected and noop since PHP version 8.0 2025-12-16 11:16:28 +00:00
Mario Vavti
2eb51233f6 fix hashtag and mentions count after fixing encoding and add tests 2025-12-12 19:15:28 +01:00
Mario Vavti
5432819788 add test for encoded filter entry 2025-12-12 18:51:53 +01:00
Mario
c03f543b54 encoding issue 2025-12-12 17:44:27 +00:00
Mario
de6506eb57 bump version 2025-12-12 11:53:31 +00:00
Mario
fb48bbe2c1 fix replies id reference 2025-12-12 11:52:05 +00:00
Mario
65132c8fdc Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-12-12 11:44:45 +00:00
Mario
2c0936187a improved replies id detection 2025-12-12 11:44:08 +00:00
Mario Vavti
48dbba2f4d implement new version of MessageFilter derived from forte and add some more tests 2025-12-12 12:42:01 +01:00
Mario
16068af0bb remove sodium-plus 2025-12-10 18:42:08 +00:00
Mario
d09b01245f generate password hash with PBKDF2 instead of built in hash function based on argon2 which too resource heavy for our usecase (see comments) also the nonsumo library is almost half in size - we ship both libs now but only use the nonsumo. This fixes crypto for chromium mobile versions. drawback: this change is not backward compatible. 2025-12-10 18:37:18 +00:00
Mario
bdd0b0a6fb sodium-plus is not maintained anymore - use https://github.com/jedisct1/libsodium.js (sumo version because it contains the crypto_pwhash() function) directly instead 2025-12-10 09:41:25 +00:00
Mario
48030617ab check for sodium in decrypt function 2025-12-10 07:34:36 +00:00
Mario
bb49a51be3 feed: fix channel links and check for top=0. also filter out Add and Remove activities when building the feed (we should probably do this in fetch_items() but that will require some refactoring 2025-12-09 12:05:19 +00:00
Mario
da266f5739 Merge branch 'dev' into 'dev'
add active themes list to siteinfo

See merge request hubzilla/core!2247
2025-12-09 11:34:05 +00:00
Mario
f6a4997d6f fix issue #1954 2025-12-09 11:29:51 +00:00
Mario
7a99089204 refactor module feed to allow a (for now) hidden pconfig to allow switching between simple (toplevels only) and complete activity feed, defaulting to simple. Also reomve option for json formatted feed since it is not supported in the backend - issue #1953 2025-12-09 10:51:07 +00:00
Mario
2e55973da2 remove ofeed and ochannel modules which were here to serve deprecated and removed ostatus 2025-12-09 10:02:00 +00:00
Mario
80f4eea9e9 remove support for deprecated AS1 verbs and objects in the network stream filters - improves performance 2025-12-09 08:26:41 +00:00
Mario
be5c8aa2a3 more work on determining whether an event should be adjusted is an all-day event 2025-12-09 08:24:53 +00:00
Mario
643d25b34b simplify and be slightly more strict to define allday events 2025-12-05 22:38:20 +00:00
Mario Vavti
c29d79854e Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-12-05 22:24:33 +01:00
Mario
2834544451 an attempt to better deal with events that have no endTime and events that inline timezone offset in the timestamp 2025-12-05 21:16:30 +00:00
Mario Vavti
60eb8aa42b provide the event hash and timezone in the event object 2025-12-05 22:04:52 +01:00
Mario
aff39521cd revert removing of iconfig parsing (it is still required for events for now). Dismiss activitypub.rawmsg and diaspora.fields from parsing 2025-12-05 19:24:28 +00:00
Mario
f19ad4b087 bump version 2025-12-05 09:26:19 +00:00
Mario
fc243196d9 store the object cache right on and remove some commented out code 2025-12-05 09:19:26 +00:00
SK
42e78d9666 add active themes list to siteinfo
Helps choosing instance when creating clones for compatible themes.
2025-12-05 07:36:13 +05:30
Mario
26d1653bfb Merge branch 'hooks-update-api-docs' into 'dev'
Update API docs for Hook interface

See merge request hubzilla/core!2245
2025-12-04 18:41:02 +00:00
Mario Vavti
f39ccab6c1 update composer libs 2025-12-04 14:24:20 +01:00
Mario
a0e6dcbb77 allow the post_mail permission to work independend from the send_stream/post_comment permissions and leave the post_mail perm limit at PERMS_SPECIFIC for the public channel role - issue #1951 2025-12-04 12:31:04 +00:00
Mario
320a0c1b62 only reset obj cache if edited timestamp has changed 2025-12-03 21:02:16 +00:00
Mario
84d52a9ad1 Merge branch 'improve-test-isolation' into 'dev'
Improve test isolation

See merge request hubzilla/core!2246
2025-12-03 19:33:27 +00:00
Mario
dc298ce6c1 bump version 2025-12-03 19:31:11 +00:00
Mario
b464cd6181 this is somehow delicate: make sure we will not relay an item again in case it comes back to us from a channel that sources our channel 2025-12-03 19:05:17 +00:00
Harald Eilertsen
4eb7e29bab Improve test isolation
To ensure tests don't step on each others toes, make sure we back up
the static properties of the global App class before running tests that
modify any of these properties.
2025-12-02 19:58:41 +01:00
Mario
63243808b8 add quoteUri for mastodon which seems to have removed support for quoteUrl 2025-12-02 12:23:38 +00:00
Mario
f271448767 also remove the comment now that we do not use the effective_uid param anymore 2025-12-02 11:57:51 +00:00
Mario
3915164bb4 we do not need to decode iconfig anymore 2025-12-02 10:24:54 +00:00
Harald Eilertsen
94e5aa172c Update API docs for hooks 2025-11-29 22:52:30 +01:00
Harald Eilertsen
ff68bee174 Doxygen: New tag @sideeffect
Use this tag to document unexpected side effects of an API.
2025-11-29 22:49:54 +01:00
Mario
25aa7d5738 fix activity signer not set 2025-11-27 10:10:24 +00:00
Mario
07e3a218cb only check author and owner mismatch 2025-11-27 09:59:33 +00:00
Mario
e6ad00dabc lookup only one item 2025-11-26 10:07:10 +00:00
Mario
23d781e348 improved checks 2025-11-26 08:39:34 +00:00
Mario
b53cacd54c bump version 2025-11-26 07:38:46 +00:00
Mario
ade3da4d89 dismiss objects where the force flag is set for now 2025-11-25 22:50:47 +00:00
Mario
1e5f614a5e Revert "more check possible ownership mismatch"
This reverts commit 159c8dbd5f.
2025-11-25 11:03:27 +00:00
Mario
159c8dbd5f more check possible ownership mismatch 2025-11-25 10:23:03 +00:00
Mario
5faa285f6f version 2025-11-25 08:38:53 +00:00
Mario
c9af19cdb2 check possible ownership mismatch 2025-11-25 08:38:05 +00:00
Mario
3e74e4784c move ObjCache::Set() from Activity::decode_note() to Activity::store() and Libzot::import() where we have already gathered more infos 2025-11-24 22:34:29 +00:00
Mario
bcbd7f4f6d bump version 2025-11-24 07:53:41 +00:00
Mario
7ead6086dc remove trailing slash 2025-11-24 07:49:30 +00:00
Mario
4685568e0d item links will be replaced at the sync receiver side - use the channel url of the current site when storing. fixes issue #1932 2025-11-24 07:48:54 +00:00
Mario
ec57f8293a refine shre to quote conversion 2025-11-23 10:50:21 +00:00
Mario
9e5344d624 fix typo in last commit 2025-11-22 19:57:28 +00:00
Mario
4c122fd3b3 do not attempt tag delivery if not item type post - fix issue #1941 2025-11-22 19:54:58 +00:00
Mario
d318a1b807 make postgres happy
(cherry picked from commit 7959dd9f57)

Co-authored-by: Mario <mario@mariovavti.com>
2025-11-21 22:05:10 +00:00
Mario
7959dd9f57 make postgres happy 2025-11-21 21:54:15 +00:00
Mario
fde03c7ae0 remove commented out code 2025-11-21 20:50:14 +00:00
Mario
7fcc770fbf rename (un)serialise() -> json_(un)serialize() 2025-11-21 20:43:35 +00:00
Mario Vavti
dcb09a8b39 update smarty and base58 2025-11-21 16:45:54 +01:00
Mario
57c22f4d0f fix test 2025-11-21 10:45:45 +00:00
Mario
ed1cfa5c7b fix block/unblock account - issue #1947 2025-11-21 09:25:51 +00:00
Mario
3878dbd6bd show viewsource link for pubstream items 2025-11-21 08:27:53 +00:00
Mario Vavti
e80de634d3 version 10.6.1 2025-11-21 08:10:44 +01:00
Mario
536f80e50b update changelog
(cherry picked from commit 554577fad7)

Co-authored-by: Mario <mario@mariovavti.com>
2025-11-21 07:08:50 +00:00
Mario
554577fad7 update changelog 2025-11-21 07:04:28 +00:00
Mario
3eeb173efd fix insufficient target attribution for forums - channel_url() requires the channel array not the address
(cherry picked from commit 7cadb43029)

Co-authored-by: Mario <mario@mariovavti.com>
2025-11-21 06:53:05 +00:00
Mario
3ac99479fe Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-11-20 23:06:02 +00:00
Mario
7cadb43029 fix insufficient target attribution for forums - channel_url() requires the channel array not the address 2025-11-20 23:05:12 +00:00
Mario
f25ac63f18 Merge branch 'fix-warnings-in-owatest' into 'dev'
Set content type/length for module test requests

See merge request hubzilla/core!2244
2025-11-20 21:20:27 +00:00
Mario
8a79d8d06f Merge branch 'more-tests+speedups' into 'dev'
More tests + speed improvements

See merge request hubzilla/core!2243
2025-11-20 20:49:55 +00:00
Harald Eilertsen
ddf7fad82f Set content type/length for module test requests
Just use default values of 'text/html' and 0 for now. Should probably be
set to more realistic values at some point, but for now it seems to
work.

This fixes warnings in the OwaTest.
2025-11-20 21:48:53 +01:00
Mario
6a9d569d5a singleton object cache - initial commit 2025-11-20 20:41:40 +00:00
Mario
ad017baaa6 singleton object cache - initial commit 2025-11-20 20:41:20 +00:00
Mario
b5d673c102 Merge branch 'test-reload-fixtures-from-db' into 'dev'
Reload fixures from db

See merge request hubzilla/core!2242
2025-11-20 07:21:16 +00:00
Mario Vavti
d7fa707f00 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-11-20 08:02:58 +01:00
Mario Vavti
b4b7ec1693 cross protocol message payload restructuring - initial commit 2025-11-20 07:58:50 +01:00
Harald Eilertsen
6f8b7f177d Replace use of create_identity in MagicTest
Use db fixtures instead. Make the test much snappier.
2025-11-19 22:01:42 +01:00
Harald Eilertsen
7a2a621309 Add hubloc test db fixture
Added entries in the hubloc table to correspond to the channel entries
in channel.yml. These would normally be created by `create_identity`, so
some code expects them to be there.
2025-11-19 21:59:45 +01:00
Harald Eilertsen
fe25bab3a7 Stub crypto calls from CreateIdentityTest
This speeds up the test runs significantly.
2025-11-19 16:58:08 +01:00
Harald Eilertsen
3abd764512 Drop create_identity from Zotfinger test 2025-11-16 22:14:33 +01:00
Harald Eilertsen
dc255a4ecf Begin tests for Profiles module 2025-11-15 11:26:23 +01:00
Harald Eilertsen
fc201ae067 Fix warnings in profile_edit template 2025-11-15 11:26:23 +01:00
Harald Eilertsen
de5455b401 Fix warnings for optional args in field templates 2025-11-15 11:26:22 +01:00
Harald Eilertsen
1243207b8f Fix undefined vars in Profiles module 2025-11-15 11:26:22 +01:00
Harald Eilertsen
39f4a56348 Begin tests for Zotfinger module 2025-11-15 11:26:11 +01:00
Mario
d48c9ce562 only unserialis(z)e if we deal with a string 2025-11-14 18:34:25 +00:00
Mario
6ced694b53 more streamline with jsalmon signature removal 2025-11-14 14:10:46 +00:00
Mario
bc128c604b streamline with jsalmon signature removal 2025-11-14 12:35:29 +00:00
Mario
a2168870b9 add a hint vor cahed state 2025-11-14 12:20:27 +00:00
Mario
c0197b698e fix undefined var 2025-11-14 12:01:58 +00:00
Mario
f2ae99f64e adapt mod viewsrc 2025-11-14 10:06:19 +00:00
Mario
14f6667687 more json serialisation for iconfig 2025-11-14 10:05:59 +00:00
Mario Vavti
6f9348540e Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-11-14 10:45:29 +01:00
Mario Vavti
51b667020e use json serialisation for iconfig 2025-11-14 10:44:56 +01:00
Mario
c6d54d03de try to provide the complete raw object in viewsrc 2025-11-13 20:43:56 +00:00
Harald Eilertsen
8e35ef2faa Add test db fixtures for channel table
Add the system user and a test user to the table for use by tests.
2025-11-13 19:51:39 +01:00
Harald Eilertsen
b74a2dff9e Reload test fixtures from db
Reload inserted rows from the DB when loading the test fixtures. This
ensures that we get all default fields and id columns initialized and
validated. Some code under test will require this to work as expected.
2025-11-13 19:51:39 +01:00
Harald Eilertsen
6400bcc81f Set logged in shannel for delete account test
If the logged in account is not set, it triggers a warning.
2025-11-13 19:51:39 +01:00
Harald Eilertsen
4abe0703d7 tests: Use root passwd to set up MySQL test db 2025-11-13 19:51:39 +01:00
Mario
4b389ddba9 Merge branch 'dba-fix-insert' into 'dev'
Improve dba_pdo::insert function

See merge request hubzilla/core!2241
2025-11-13 16:14:06 +00:00
Harald Eilertsen
1e92aeb7f9 Improve dba_pdo::insert function 2025-11-13 16:14:05 +00:00
Mario
b6153edf6b make sure we deal with a string 2025-11-13 09:50:46 +00:00
Mario
93c333a9bc bump version 2025-11-11 11:49:23 +00:00
Mario
43142dde9f OWA2: initial commit 2025-11-11 11:47:57 +00:00
Mario
63bc905061 wrong order of args 2025-11-10 21:03:22 +00:00
Mario
573c6f3df3 shares kiss 2025-11-10 19:50:10 +00:00
Mario
28692b867c nesting shares will be too messy in regard to interop. so when sharing a post with shares, just pick the shares. 2025-11-10 09:25:31 +00:00
Mario
74b8f1f240 Revert "correctly parse and display nested shares"
This reverts commit 0be74299ca.
2025-11-10 09:01:38 +00:00
Mario
0be74299ca correctly parse and display nested shares 2025-11-10 08:01:18 +00:00
Mario
e90fc6d714 fix quote issue with forums
(cherry picked from commit 866d88de53)

Co-authored-by: Mario <mario@mariovavti.com>
2025-11-07 20:30:35 +00:00
Mario
866d88de53 fix quote issue with forums 2025-11-07 20:29:51 +00:00
Mario
69acee497d bump dev version 2025-11-07 19:57:49 +00:00
Mario Vavti
6c74672d40 bump composer PHP version to 8.2 and update libs 2025-11-07 20:55:45 +01:00
Mario
6320506c27 update install document 2025-11-07 19:36:56 +00:00
Mario
1ee0f3ce1d remove unused sprintf.js 2025-11-07 19:23:53 +00:00
Mario
0730d31c22 move twitteroauth to addon_common 2025-11-07 19:04:04 +00:00
Mario
a2a8b2e9fb move slinky to addon_common 2025-11-07 18:57:18 +00:00
Mario
8821fa9a0e this is only used by the openid addon. move it there. 2025-11-07 18:40:14 +00:00
Mario
363100a612 this is only used by the wppost addon. move it there. 2025-11-07 15:09:08 +00:00
Mario
1f7ac5e787 this is only usewd by the wiki addon. move it there. 2025-11-07 14:59:16 +00:00
Mario
2233a0317e remove bootbox lib and unused code 2025-11-07 14:52:30 +00:00
Mario
498ef78e6f remove unused images 2025-11-07 14:45:12 +00:00
Mario
8a606365c8 update path 2025-11-07 14:42:52 +00:00
Mario
9c27f94709 move language specific folders into its own subfolder in /view 2025-11-07 14:38:55 +00:00
Mario
a99e067b91 remove deprecated sjcl library and references 2025-11-07 12:39:58 +00:00
Mario
831f4324ae fix fullscreen button class 2025-11-07 11:59:54 +00:00
Mario
ad205abd90 Merge branch 'profile-visibility-editor-tpl' into 'dev'
updated profile visibility editor to use tpl file for layout

See merge request hubzilla/core!2240
2025-11-07 11:13:38 +00:00
Mario
231f4a28eb remove deprecated code 2025-11-05 20:47:38 +00:00
Mario
95b52b6aa9 adapt mod dreport to the changes in 385c23a2b 2025-11-05 20:43:50 +00:00
Mario
385c23a2b6 fix delivery report when syncing cloned channels 2025-11-05 20:29:29 +00:00
Mario
3a81edbcb0 bump version 2025-11-04 10:45:55 +00:00
Mario
2f377089e6 deprecate outbound JSalmon signatures 2025-11-04 10:45:15 +00:00
Mario
6427e84053 release date 2025-11-04 09:29:51 +00:00
Mario
f1def0c03a Merge branch '10.6RC' 2025-11-04 09:26:29 +00:00
Mario
b8a5ebe0f7 version 10.6 2025-11-04 09:24:43 +00:00
Mario
24a9ad6260 Merge branch 'dev' into 10.6RC 2025-11-03 21:12:42 +00:00
Mario
88577e1e97 Fix encoding for webpage, layout and block title and body when editing - issue #1946 2025-11-03 21:12:04 +00:00
Mario
38225aabc9 Merge branch 'dev' into 10.6RC 2025-11-03 20:43:12 +00:00
Mario
3653ae1af0 fix typo in sql query and some missing data which prevented files and photos to be updated correctly via dav - issue #1944 2025-11-03 09:31:45 +00:00
Mario
f2aa42f18a fix typo 2025-11-03 08:51:21 +00:00
Mario
aa5bd9bbfc do not allow observer posting files to wall if they do not have permission - issue #1940 part two 2025-11-03 08:50:39 +00:00
SK
73b931ed14 updated building profile visibility editor to use tpl file for layout 2025-11-01 01:47:30 +05:30
Mario
42f75842c6 Merge branch 'dev' into 10.6RC 2025-10-30 21:46:41 +00:00
Mario
73fafd9f2b update changelog 2025-10-30 21:46:13 +00:00
Mario
13c51e519d Merge branch 'dev' into 10.6RC 2025-10-30 21:42:38 +00:00
Mario
ef05cecaeb make sure to only call init_contact_edit() on pageload if we have a fragment and are in /connections. this is to prevent fragment hijacking for other pages 2025-10-30 21:37:41 +00:00
Mario
5b6d70fd60 Revert "make sure to only call init_contact_edit() on pageload if we have a fragment and are in /connections. this is to prevent fragment hijacking for other pages"
This reverts commit cfb8bf3ab9.
2025-10-30 21:37:08 +00:00
Mario
cfb8bf3ab9 make sure to only call init_contact_edit() on pageload if we have a fragment and are in /connections. this is to prevent fragment hijacking for other pages 2025-10-30 21:32:30 +00:00
Mario Vavti
3cf7e09609 switch from mmccooks php-json-canonicalization library to root23s which, according to mike, better deals with floating point values 2025-10-30 21:30:18 +01:00
Mario Vavti
a127f76bad Merge branch 'dev' into 10.6RC 2025-10-30 19:37:25 +01:00
Mario Vavti
d11b05de71 unserialise is being called in the get method now 2025-10-30 19:36:01 +01:00
Mario
a03b440139 Merge branch 'dev' into 10.6RC 2025-10-30 10:12:31 +00:00
Mario
2865dc45eb update changelog 2025-10-30 10:12:06 +00:00
Mario
923e80d143 fix merge conflict 2025-10-30 09:58:55 +00:00
Mario
ba96b2ce85 Merge branch 'upgrade-ci-php-82' into 'dev'
CI: Upgrade images to php8.2

See merge request hubzilla/core!2239
2025-10-30 09:41:12 +00:00
Mario
d9f467f215 Merge branch 'fix-test-deprecation' into 'dev'
Fix deprecation notice in MessageWidgetTest

See merge request hubzilla/core!2238
2025-10-30 09:39:44 +00:00
Harald Eilertsen
23a8c2f0a8 CI: Upgrade images to php8.2
PHP 8.1 is is reaching end-of-life in about two months, so to prepare
for setting PHP 8.2 as minimum supported version we upgrade the CI
runners right away.

PostgreSQL 13 is also reaching EOL in mid november, so upgrade that as
well.
2025-10-29 22:21:51 +01:00
Mario
76856188e1 remove not in abook restriction for convo operations. it is not required anymore since we run convo on fetched items only 2025-10-29 11:02:53 +00:00
Harald Eilertsen
f3d8838256 Fix deprecation notice in MessageWidgetTest
Creating dynamic properties in an object is deprecated in PHP 8.2.

Reference: https://www.php.net/manual/en/migration82.deprecated.php
2025-10-29 10:33:06 +01:00
Mario
2871ef2897 fix another case where the whole URL was punified 2025-10-28 11:55:32 +00:00
Mario
aa7358c837 bump version 2025-10-27 21:13:13 +00:00
Mario
57b553a79f no need for is_sys_channel() here - we already have the complete channel. Saves a DB lookup. 2025-10-27 21:12:20 +00:00
Mario
f08498440a further improve how and in which cases we will attempt fetching the replies collection 2025-10-27 21:03:26 +00:00
Mario
e9c07c554a move the connected check to Activity::init_background_fetch() to omit redundant abook queries in each Activity::store() 2025-10-26 20:32:43 +00:00
Mario Vavti
a570ef4691 add test for ASCache::isCacheable() 2025-10-26 19:19:36 +01:00
Mario
7cf7aa397e refactor Lib/ASCache so that we can easily determine cacheable activities (we will not cache limited activities anymore), refactor the Daemon/Convo so that we will not waste a process for each channel (similar to Daemon/Fetchparents) 2025-10-26 17:43:10 +00:00
Mario
8ba378bc6f Merge branch 'dev' into 10.6RC 2025-10-24 19:01:13 +00:00
Mario
03af9d415f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-10-24 18:37:08 +00:00
Mario
e5acf404ab punify() will turn everything to lower case. We should just use it on the host part, otherwise case senstive URLs will be rendered useless 2025-10-24 18:36:27 +00:00
Mario Vavti
2e89cfe5ed fix pattern to make tests happy again 2025-10-24 20:19:55 +02:00
Mario
21951ec5ee update changelog 2025-10-24 13:36:08 +00:00
Mario
10786336c5 Merge branch 'dev' into 10.6RC 2025-10-24 09:58:48 +00:00
Mario
9e33fa8ee2 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-10-24 09:52:52 +00:00
Mario
1658244b09 only match a single whitespace at the end when pasting a quote, lookup url for plink in question activities 2025-10-24 09:52:28 +00:00
Mario Vavti
3c60e33d74 fix rc version 2025-10-23 14:47:58 +02:00
Mario Vavti
5fb28cb51c fix setup checks 2025-10-23 14:46:04 +02:00
Mario
1677c664f0 bump dev version 2025-10-23 09:09:22 +00:00
Mario
d35a79515f version and strings 2025-10-23 09:06:01 +00:00
Mario
872fced729 bump version 2025-10-22 18:32:03 +00:00
Mario
4ae65a63c6 photo_upload(): moderate photo items where observer has write_storage perm but not post_wall perm - fix issue #1940 2025-10-22 18:31:49 +00:00
Mario
acc43bbbad fix not all notification icons updated and use anon function shortcut for consistency 2025-10-22 16:54:25 +00:00
Mario
947d827431 bump version 2025-10-22 07:35:59 +00:00
Mario
339f787b92 retrieve available notification types from dom element instead of passing them around (which had issues) 2025-10-22 07:35:29 +00:00
Mario
c71a6dbbd2 phpstan: remove conditional constants from ignoreErrors for level 0 2025-10-22 06:45:01 +00:00
Mario
cd5815dcdc install libgmp-dev in gitlab-ci 2025-10-22 06:38:09 +00:00
Mario
19c478421d add gmp extension to gitlab-ci 2025-10-22 06:21:13 +00:00
Mario
a5f311665c bump version 2025-10-21 20:53:06 +00:00
Mario
d8c14eec58 fix issue with notification on screen size where notifications are hidden and isVisible would always return false 2025-10-21 20:52:31 +00:00
Mario Vavti
4798fa79c3 update composer libs - requires gmp extension (in favor of bcmath) 2025-10-21 22:06:03 +02:00
Mario Vavti
b50aa43542 remove redundant args 2025-10-21 21:09:13 +02:00
Mario Vavti
6bf1b15666 remove redundant args 2025-10-21 21:08:28 +02:00
Mario Vavti
9d4f2c7817 email change logic is in Settings/Account 2025-10-21 19:05:27 +02:00
Mario Vavti
040b52a1d5 fix undefined constant 2025-10-21 18:57:15 +02:00
Mario
c8c9e4a901 fix some of the constant not found errors 2025-10-21 16:00:06 +00:00
Mario Vavti
b4f6241357 composer update macgirvin/http-message-signer to version 0.2.6 2025-10-21 16:01:28 +02:00
Mario
4ba414fb8d HTTPSig: return early if we got no key info 2025-10-21 10:23:47 +00:00
Mario
33718ff16f fix error in case when no forums are available 2025-10-21 10:02:43 +00:00
Mario
19437f45ef Merge branch 'helpindex-fix' into 'dev'
add support for json formatted table of contents and specific tpl for helpindex

See merge request hubzilla/core!2237
2025-10-21 09:31:38 +00:00
Harald Eilertsen
7a7ff97e63 Unbreak test failure in Helpindex test
We need to mock the call to `is_readable`, since the file requested in
the test does not actually exist in the file system.
2025-10-20 10:54:12 +02:00
Mario
ef7cedca2d implement ASCache in ASCollection to possibly prevent timeouts when fetching large collections 2025-10-19 09:07:16 +00:00
SK
cbb2cabd74 corrections with accordion id and data-bs-parent 2025-10-19 14:28:47 +05:30
SK
f7cc249b50 better accordion 2025-10-19 08:55:55 +05:30
SK
9530b5b313 removed else conditional 2025-10-19 08:31:45 +05:30
SK
f91409a9ec removed unused toc.html 2025-10-19 08:18:53 +05:30
SK
4330e0bb94 add support for json formatted table of contents and specific tpl
Allows for precise control over layout of table of contents so that
theme specific changes can be implemented. Introduced a new layout file
help-index.tpl.
Table of contents is stored in json format within toc.json, support for
toc.html is retained since other languages still use it but can be
migrated to json if needed.
2025-10-19 08:18:43 +05:30
Mario
6ad561dc4c remove deprecated conv_list.tpl 2025-10-17 05:49:36 +00:00
Mario
70c7817a5c fix undefined variable 2025-10-16 13:11:39 +00:00
Mario
cc9237c7ce more work on notification: mark seen for pubstream, hidden configs for inverted notifications order and count limit (issue #1917) 2025-10-16 12:08:29 +00:00
Mario
e75e8ed8f1 add missing changelog 2025-10-16 08:40:51 +00:00
Mario
2e85852a9c fix en string as per @ferret 2025-10-16 08:20:55 +00:00
Mario
c49a646bef fix undefined var warning 2025-10-16 08:15:24 +00:00
Mario
c130c3ee45 enable filters and mark-all-seen button to forum notifications 2025-10-16 07:55:05 +00:00
Mario
c96fe501ef bump version 2025-10-15 16:52:06 +00:00
Mario
2f0f7b9df6 make sure we add the channel address to the url field 2025-10-15 16:51:08 +00:00
Mario
9fec396fa2 whitespace 2025-10-15 06:41:15 +00:00
Mario
bf774caf0e we should probably also handle image/gif here 2025-10-15 06:37:43 +00:00
Mario
f08b0edad2 only request quality for types that have support for it. otherwise getQuality() will choke with
UnhandledMatchError
2025-10-15 06:35:42 +00:00
Mario Vavti
63e41c233f the correct mime type for .jpg images is image/jpeg 2025-10-15 07:55:08 +02:00
Mario
48433c9479 Merge branch 'some-photo-cleanup' into 'dev'
Some cleanup in Zotlabs\Photo\PhotoGd

See merge request hubzilla/core!2236
2025-10-14 06:28:04 +00:00
Mario
4691bd37c9 Merge branch 'compile-templates-in-ci' into 'dev'
Improve compile_smarty3 script, and add CI check

See merge request hubzilla/core!2235
2025-10-14 06:22:06 +00:00
Mario
d24a3a2713 fix issue where not all seen items where removed from the notifications 2025-10-13 19:58:12 +00:00
Harald Eilertsen
57af09ad47 Simplify PhotoGd::imageString
Since the validity of the image type is checked upon construction, we
can assume that the functions for writing the valid types are already
available, and we don't need to check it again here.
2025-10-13 18:49:17 +02:00
Harald Eilertsen
c5fc4827c8 Refactor PhotoGd::imageString to reduce complexity 2025-10-13 18:47:46 +02:00
Harald Eilertsen
3c89c7d4f4 Add ImageQuality class to hold quality values 2025-10-13 18:43:13 +02:00
Harald Eilertsen
2a3dc6cc50 Fix trivial phpcs warnings in PhotoGD 2025-10-13 17:05:19 +02:00
Mario
c748d3f0f8 remove logging 2025-10-13 06:14:39 +00:00
Mario
9b2ea44000 fix regression setting the offset and fix js error if notify_menu is null (can happen when forum notifications are ddisabled) 2025-10-13 06:11:24 +00:00
Mario
83f6846143 properly implement forum notifications 2025-10-12 15:29:50 +00:00
Harald Eilertsen
3b2311f356 CI: Check that templates compile
Introduce a quick test to check that templates compile in the pretest
stage. This is to prevent merge requests unintentionally breaking
templates like in issue #1938.

https://framagit.org/hubzilla/core/-/issues/1938
2025-10-11 10:54:27 +02:00
Harald Eilertsen
ea0229dcfc Return with error code if precompile_smarty fails
The Smarty API for compiling templates don't return any meaningful error
status if a template fails, so we buffer the output and scan it for
error messages instead. If we find one, we return a non-zero error code
to signal the error to the shell or calling process.

Also added more detailed copyright headers.
2025-10-10 22:22:39 +02:00
Mario
3cdfa94c29 announced toplevel items will have type Announce in our case - possible fix for issue #1936 2025-10-10 15:47:49 +00:00
Mario
2fd5762125 wrong array key 2025-10-10 15:41:54 +00:00
Mario
52ecdb007f use space instead of EOL constant which contains HTML 2025-10-10 09:01:00 +00:00
Mario
9b8fed738b escape sequence must not contain spaces 2025-10-10 09:00:09 +00:00
Mario
ee3fafc9fb Merge branch 'ci-pretest-and-upgrade-psql' into 'dev'
CI: Add pretest CI step and run PHPStan

See merge request hubzilla/core!2233
2025-10-09 09:53:14 +00:00
Mario
47867a0993 Merge branch 'fix-phpunit-deprecation' into 'dev'
tests: Dataproviders should be static

See merge request hubzilla/core!2232
2025-10-09 09:51:52 +00:00
Mario Vavti
a2ba81afe1 version 10.4.4 2025-10-06 23:27:14 +02:00
Mario
a15254a1e2 remove check for current user and apply update 2025-10-06 23:16:22 +02:00
Mario
1a68dbccf1 remove check for current user and apply update 2025-10-06 20:42:27 +00:00
Harald Eilertsen
fc87ef282e CI: Upgrade to postgres 13
Postgres 12 has been EOL for almost a year!
2025-10-05 23:07:02 +02:00
Harald Eilertsen
ab0e5e3eee CI: Add pretest CI step and run PHPStan
The idea is to avoid the more expensive phpunit tests if a set of
simpler checks fail. These should check the code without actually
running it. For now we only run PHPStan, but this may expand in the
future.
2025-10-05 23:03:42 +02:00
Harald Eilertsen
356b6127d3 Better check if default_timezone is set 2025-10-05 23:03:42 +02:00
Harald Eilertsen
87c62db41e tests: Dataproviders should be static 2025-10-05 20:27:08 +02:00
Mario
0d3855cd63 whitespace 2025-10-05 15:48:21 +00:00
Mario Vavti
ffce0a705b added test for Activity::pasteQuote() 2025-10-05 15:43:42 +02:00
Mario
49e65902d7 improve placing quote in post and move it to separate function - test will follow 2025-10-05 13:19:26 +00:00
Mario
2e1fd79c7a implement as cache in get_quote() 2025-10-05 07:46:22 +00:00
Mario
0c577b5fd0 replace both variants 2025-10-04 20:22:10 +00:00
Mario
3178a96a89 improved quote handling 2025-10-04 18:49:21 +00:00
Mario
c1cec623bb this restriction should not be required anymore 2025-10-04 18:47:08 +00:00
Mario
d3cc098070 Revert "this restriction should not be required anymore"
This reverts commit 69e7812646.
2025-10-04 18:45:53 +00:00
Mario
69e7812646 this restriction should not be required anymore 2025-10-04 18:44:07 +00:00
Mario
d39320475c remove logging 2025-10-03 16:08:37 +00:00
Mario
0faf47b3ca deal with multiple quoteUrl's - just in case 2025-10-03 16:07:45 +00:00
Mario
660ff3da7b for consistency show webfinger addr instead of url like in the other tabs 2025-10-03 06:51:23 +00:00
Mario
7ec8a2267a we should also store the terms of a quote post for custom emojis, tags, etc. 2025-10-03 05:39:43 +00:00
Mario
4a35764e13 we must decode the entire message for attached images etc. 2025-10-02 17:35:38 +00:00
Mario
3a50b185ce fix heading
(cherry picked from commit 57e2904cc0)

Co-authored-by: Mario <mario@mariovavti.com>
2025-10-02 10:02:37 +00:00
Mario
57e2904cc0 fix heading 2025-10-02 10:01:38 +00:00
Mario
77866625cc fix path
(cherry picked from commit b49c844a23)

Co-authored-by: Mario <mario@mariovavti.com>
2025-10-02 09:58:06 +00:00
Mario
b49c844a23 fix path 2025-10-02 09:57:31 +00:00
Mario
f6275fdb79 Ãadd en tos which seems to have been lost in transition
(cherry picked from commit 2c55ee5a73)

Co-authored-by: Mario <mario@mariovavti.com>
2025-10-02 09:52:05 +00:00
Mario
2c55ee5a73 Ãadd en tos which seems to have been lost in transition 2025-10-02 09:17:07 +00:00
Mario
548b0c4931 Merge branch 'misc-phpstan-fixes' into 'dev'
Fix remaining issues flagged by PHPStan level 0

See merge request hubzilla/core!2228
2025-10-02 08:36:00 +00:00
Mario
8c61f89a14 get_quote_bbcode() > get_quote() 2025-10-02 08:16:39 +00:00
Mario
7cc0cb78a0 inbound support for mastodon quote posts and slightly improved rendering 2025-10-02 07:13:45 +00:00
Mario
6aa945cde1 Merge branch 'cherry-pick-357eabbe' into 'dev'
Update Spanish strings

See merge request hubzilla/core!2229
2025-10-01 09:25:38 +00:00
Mario
375b3f3f67 bump version 2025-10-01 08:55:42 +00:00
Mario
b68b5a60c5 fix issue where loadingPage state was not reset in some situations and return if we retry live update due to incomplete data 2025-10-01 08:55:15 +00:00
Manuel Jiménez Friaza
f4c29d13f4 Update Spanish strings
(cherry picked from commit 357eabbe9e2375a23715b12bcf22fe5b7b4b837a)

Co-authored-by: mjfriaza:4GF~eYj,-iAv <mjfriaza@disroot.org>
2025-09-15 16:42:01 +02:00
Mario
121fb74c6c tagcloud: remove redundant f arg 2025-09-15 07:12:09 +00:00
Mario
4a098cbeaf whitespace 2025-09-15 07:04:37 +00:00
Mario
6123fd2be8 archive widget: point url to module/channel_addr instead of App:$cmd and some cleanup - fix issue #1911 2025-09-15 07:04:00 +00:00
Harald Eilertsen
176a7cb9b5 Comment duplicate keys in xchan_change_key func
PHP arrays can't have duplicate keys, so adding an entry with the same
key again will replace the existing entry with the later one. This patch
comment out the entries that in any case are replaced, so functionally
it should be equivalent to what was before. (But still probably wrong!)
2025-09-12 21:51:24 +02:00
Harald Eilertsen
a7e734b700 Move named inner function out in po2php.php
While PHP seems to be able to handle this construct, PHPStan don't. In
this case there's also no reason for this to be an inner function, so
just move it out to the global scope.
2025-09-12 21:51:24 +02:00
Harald Eilertsen
b31123ae2f Fix missing return from translate_scope function
Also make sure the output is escaped wherever this function is used.
2025-09-12 21:51:24 +02:00
Harald Eilertsen
330c8ca890 Fix ref to undefined var in account.php 2025-09-12 21:51:24 +02:00
Harald Eilertsen
e645ea3bf0 Fix missing return warnings in Module\Request
As the Request module never returns a HTML payload it was changed to
override the Controller::init() method rather than Controlled::get().

The internal private functions were fixed accordingly, and return type
annotations fixed up as well.

Discovered with PHPStan.
2025-09-12 21:51:24 +02:00
Harald Eilertsen
50f439ae8e Fix precompile_smarty3.php
The Smarty class is in the Smarty namespace, and should not be loaded
manually, but through composer. This is taken care of by requiring
`boot.php`. Also make the script slightly more robust as to where it is
invoked from.
2025-09-12 21:51:24 +02:00
Harald Eilertsen
3a102d9dc3 Remove ref to undefined var in Module\Register
The $reg variable is defined in another if-statement further up the
function, but does not make sense in the part where it was referenced.
The code tried to switch to the registered users prefered language
before sending an email to the user, but as this part of the code don't
have a record for the registered user, this makes no sense.

Iow, we leave the currenly selected language alone, and hope for the
best.
2025-09-12 21:51:24 +02:00
Harald Eilertsen
bb4c08caf0 PHPStan: Ignore missing function make_xchan_hash
This function does not exist, but is called from a function that is
never used. For rationale for why this code is kept, see the discussion
here:

https://framagit.org/hubzilla/core/-/merge_requests/2209
2025-09-12 21:51:24 +02:00
Harald Eilertsen
f8795288a1 More misc fixes in verify_email_address 2025-09-12 21:51:24 +02:00
Harald Eilertsen
107b8e67d2 Fix/complete template args in verify_email_address 2025-09-12 21:51:24 +02:00
Harald Eilertsen
5a36a37b9f Fix template language in verify_email_address 2025-09-12 21:51:24 +02:00
Harald Eilertsen
0910ae0e52 Fix db query in verify_email_address 2025-09-12 21:51:24 +02:00
Harald Eilertsen
c6c5a8b5e0 Cleanup verify_email_address
- Add type annotations, and change arg to a string instead of array.
  Only the email address was used anyways.
- Fix indentation
- Improve API doc and remove unnecessary comments.
2025-09-12 21:51:24 +02:00
Harald Eilertsen
da2c57c432 Fix undefined var $hash in verify_email_address 2025-09-12 21:51:24 +02:00
Harald Eilertsen
e7523e7fc5 Remove ref to undefined variables in get_zcard() 2025-09-12 21:51:24 +02:00
Harald Eilertsen
e52d3639de Fix missing returns in plugin.php
Flagged by phpstan
2025-09-12 21:51:24 +02:00
Mario
1a27edf6dd Merge branch 'remove-dead-code-in-handle-tag' into 'dev'
Remove dead code in handle_tag function

See merge request hubzilla/core!2227
2025-09-12 16:35:32 +00:00
Mario
9750543157 Merge branch 'register_account_hook' into 'dev'
uncommented register_account hook

See merge request hubzilla/core!2226
2025-09-12 16:31:43 +00:00
Mario
95dab5c764 Merge branch 'test-include-extensions' into 'dev'
Include extensions in default PHPUnit config

See merge request hubzilla/core!2223
2025-09-12 16:31:10 +00:00
Mario
619df9ca22 fix for issue #1929 and updated wording 2025-09-12 16:24:22 +00:00
Mario
5442bac707 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-09-12 14:50:21 +00:00
Mario
99688cdde5 remove redundant variable and include 2025-09-12 14:49:22 +00:00
Harald Eilertsen
6b7478c5a5 Remove dead code in handle_tag function
Since $profile is only ever set in the other branch of the if/else
construct, this code will never execute.
2025-09-05 23:19:07 +02:00
SK
644e3b790c uncommented register_account hook
Hook is required for notify-admin addon to work.
2025-09-02 19:43:35 +05:30
Harald Eilertsen
c064cfde91 Look for unit tests for extensions as well as core 2025-09-02 08:38:50 +02:00
Harald Eilertsen
2826d030f4 Remove obsolete phpunit configurations
These are not in use, probably outdated, and just confusing.
2025-09-02 08:38:50 +02:00
Mario
1ab1da5816 CI: Tell mysql cli to skip ssl checks
(cherry picked from commit 120292bd6c)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2025-09-02 06:34:44 +00:00
Mario
05800a5ff3 Merge branch 'fix-ci' into 'dev'
CI: Tell mysql cli to skip ssl checks

See merge request hubzilla/core!2224
2025-09-02 06:29:23 +00:00
Harald Eilertsen
120292bd6c CI: Tell mysql cli to skip ssl checks 2025-08-31 11:20:03 +02:00
Mario
aaa863cda7 Merge branch 'dev' 2025-08-15 08:45:45 +00:00
Mario
3c722f9aa7 changelog 2025-08-15 08:45:05 +00:00
Mario
14f28907bc version 10.4.3 2025-08-15 08:38:40 +00:00
Mario
185f53d298 bump version 2025-08-14 17:46:21 +00:00
Mario
3ae42d471a vote: minor refactor tto catch dubble votes early 2025-08-12 09:13:55 +00:00
Mario
0a817f952e mark our own vote seen because it will not be marked seen later 2025-08-11 23:28:59 +00:00
Mario
bc7f8b15a8 dismiss our own votes from select query. they are not flagged with item_hidden because otherwise they would not be delivered to the poll owner. received votes are (and should be) flagged with item_hidden so that they are not being relayed. 2025-08-11 23:13:26 +00:00
Mario
02111ad649 start transition deprecated AS1 item.verb vocabulary to AS2 on demand 2025-08-11 22:36:35 +00:00
Mario
6f00964d47 fix regression in retrieving channel address in wtagblock() and whitespace fixes
(cherry picked from commit eafa1d56c3)

Co-authored-by: Mario <mario@mariovavti.com>
2025-08-08 17:49:10 +00:00
Mario
eafa1d56c3 fix regression in retrieving channel address in wtagblock() and whitespace fixes 2025-08-08 14:03:28 +00:00
Mario
44a0311798 Merge branch 'master' of https://framagit.org/hubzilla/core 2025-08-08 07:51:42 +00:00
Mario
2ac06fef9a version 10.4.2 2025-08-08 07:51:12 +00:00
Mario
5b6a38aa2d changelog 2025-08-08 07:48:14 +00:00
Mario
37b9919905 bump version 2025-08-07 22:53:26 +00:00
Mario
283c018d07 implement item_custom_display hook in mod HQ 2025-08-07 22:51:40 +00:00
Mario
51c79aecac make item_normal() deal with various item types and add missing reactions modal 2025-08-07 22:36:35 +00:00
Mario
9343f00918 improve memory consumption when deleting big threads 2025-08-07 19:05:58 +00:00
Mario
962b4e5b4c fix php error
(cherry picked from commit eeef6cfd00)

Co-authored-by: Mario <mario@mariovavti.com>
2025-08-07 14:57:11 +00:00
Mario
eeef6cfd00 fix php error 2025-08-07 14:55:00 +00:00
Mario
96c7912fa6 update the contact edit header so that both, image and text are linked to the profile 2025-08-02 11:48:50 +00:00
Mario
91f1f8ed7c version 10.4.1 2025-07-31 08:46:43 +00:00
Mario
3f7ed72ece changelogà 2025-07-31 08:43:31 +00:00
Mario
3385c694aa add delay before collapsing 2025-07-31 08:22:01 +00:00
Mario
a922f5ca6c bump version 2025-07-30 19:20:35 +00:00
Mario
88977a406c imagesLoaded() should not be required in updateConvItems() anymore since we call it before updateConvItems() already (famous last words). 2025-07-30 19:19:00 +00:00
Mario
e98f019b16 fix regression in pubstream tag view, use correct prefixes in pub_tagadelic() and some whitespace fixes 2025-07-30 16:22:08 +00:00
Mario
50f5fcb16b always update photo DB entries on move - fixes issue where photos were not found by photo picker after folder rename as reported by chris 2025-07-30 06:45:25 +00:00
Mario
bf35a661bf remove trailing comma 2025-07-29 11:02:43 +00:00
Mario
ecc94cdecd fix a weird rendering issue which was triggered by load events fireing after the timeout was already in action 2025-07-29 09:28:00 +00:00
Mario
e79a70d2b1 var > const and style 2025-07-27 10:24:53 +00:00
Mario
6916a825ee move the freshly created content to the center instead of top and use smooth scrolling 2025-07-27 10:23:23 +00:00
Mario
b5a798f068 fix comment preview and scroll to the just created comment after posting it 2025-07-27 09:52:48 +00:00
Mario
e5c54fadea Merge branch 'update-derived-theme-tutorial' into 'dev'
Update derived theme tutorial

See merge request hubzilla/core!2219
2025-07-27 08:15:15 +00:00
Mario
f2217e9016 Merge branch 'fix-pubstream-tagcloud-tpl' into 'dev'
Fix pubstream tagcloud and category cloud

See merge request hubzilla/core!2218
2025-07-27 08:14:41 +00:00
Saiwal K
4d6bebb846 Fix pubstream tagcloud and category cloud 2025-07-27 08:14:41 +00:00
Harald Eilertsen
2e9b1d25e1 Replace mention of theme_init function
The theme_init function is no longer needed, and the example isn't using
it. So we replace it with a bit more description of the theme info in
the comment, and how that works.
2025-07-24 12:50:50 +02:00
Harald Eilertsen
8604ba016e Update derived theme tutorial
Adds another lesson on customising the theme using styles and overriding
templates.

Also some minor language cleanup and add some introductory text before
lesson 1.
2025-07-24 12:40:13 +02:00
Mario
cc35afa4c9 bump version 2025-07-23 12:07:45 +00:00
Mario
f01c5ad0c1 remove logging 2025-07-23 12:07:21 +00:00
Mario
7b6a8fdba1 fix issue where reply modal would not show anymore after reactions loaded 2025-07-23 12:06:48 +00:00
Mario
2c9f184a09 tagcloud fixes 2025-07-23 08:19:40 +00:00
Mario
6f158f37c9 Merge branch 'improve-derived-themes' into 'dev'
Add 'extends' attribute to theme info

See merge request hubzilla/core!2217
2025-07-23 07:54:30 +00:00
Mario
f88d2ba0c4 Merge branch 'tag-cloud-tpl-fix' into 'dev'
Add tpl for tagcloud and directory keyword cloud

See merge request hubzilla/core!2216
2025-07-23 07:53:10 +00:00
Saiwal K
170f157aae Add tpl for tagcloud and directory keyword cloud 2025-07-23 07:53:09 +00:00
Mario
82817b4532 tagadelic: look up toplevels only
(cherry picked from commit 3eeaca4aab)

Co-authored-by: Mario <mario@mariovavti.com>
2025-07-22 10:34:19 +00:00
Mario
3eeaca4aab tagadelic: look up toplevels only 2025-07-22 10:32:57 +00:00
Mario
a3dd4a4d3d revert cleanup template
(cherry picked from commit c383e6af80)

Co-authored-by: Mario <mario@mariovavti.com>
2025-07-22 10:22:38 +00:00
Mario
c383e6af80 revert cleanup template 2025-07-22 10:21:34 +00:00
Mario
517e14cc38 cleanup template
(cherry picked from commit eb3dfb2488)

Co-authored-by: Mario <mario@mariovavti.com>
2025-07-22 10:17:05 +00:00
Mario
eb3dfb2488 cleanup template 2025-07-22 10:16:09 +00:00
Mario
70e8648d91 the item_wall directive is not required here since we are looking for parent items which we own - remove it since it will make the DB engine use the wrong index in certain cases. also remove duplication of item_type directive when looking up articles
(cherry picked from commit ae8e9bc353)

Co-authored-by: Mario <mario@mariovavti.com>
2025-07-22 09:33:34 +00:00
Mario
ae8e9bc353 the item_wall directive is not required here since we are looking for parent items which we own - remove it since it will make the DB engine use the wrong index in certain cases. also remove duplication of item_type directive when looking up articles 2025-07-22 09:32:20 +00:00
Harald Eilertsen
88227b9155 Rename derived theme tutorial file 2025-07-20 20:33:56 +02:00
Harald Eilertsen
ae77ab7f20 Add derived theme tutorial to help index 2025-07-20 20:28:39 +02:00
Harald Eilertsen
308380fe52 Add 'extends' attribute to theme info
To create a derived (or child) theme, the array held in
`App::$theme_info` must contain a key `extends` that contains the name
of the parent theme as a value.

The derived theme tutorial would suggest adding the key in the
`themename_init()` function, however this does not work. The theme info
is repopulated from the theme info file after the theme init function
has run, and so the `extends` key disappears.

This patch adds `extends` as a first class attribute for themes, so that
it can be specified directly in the theme info in the top file comment
block. It also updates the derived theme tutorial to reflect this
change.
2025-07-20 20:23:25 +02:00
Mario
ee7b982358 Merge branch '10.4RC' 2025-07-15 06:40:43 +00:00
Mario
2740f36259 version 10.4 2025-07-15 06:40:19 +00:00
Mario
ff16810e76 Merge branch 'dev' into 10.4RC 2025-07-15 06:35:47 +00:00
Mario
161cfcd64d update changelog 2025-07-15 06:33:41 +00:00
Mario
d16d1fdcd5 Merge branch 'more-nb-translation-and-fixes' into 'dev'
More translations and fix for Norwegian nb

See merge request hubzilla/core!2214
2025-07-15 06:13:46 +00:00
Harald Eilertsen
06c0652b05 More translations and fix for Norwegian nb
Wiki's and profiles both used the "Create new" button, so don't add what
is being created to the translation :)
2025-07-14 22:23:58 +02:00
Mario
a2fb2e04f3 add support for did:key verificationMethod in checkEddsaSignature() 2025-07-14 14:13:34 +00:00
Mario
b376f810bf strict check and whitespace 2025-07-14 13:56:51 +00:00
Mario
0c2bcda431 some documentation 2025-07-14 13:48:59 +00:00
Mario
22cb0d3c6b use a custom function to build the psr7 request to work around mod rewrite issues with ServerRequest::fromGlobals() 2025-07-14 13:45:23 +00:00
Mario Vavti
b6b4eb4c22 composer update http message signer to version 0.2.3 2025-07-14 15:35:03 +02:00
Mario
da1e0b965b Merge branch 'dev' into 10.4RC 2025-07-13 19:43:01 +00:00
Mario
d566199423 Merge branch 'update-nb-translations' into 'dev'
Update translations for Norsk Bokmål

See merge request hubzilla/core!2213
2025-07-13 19:40:28 +00:00
Mario
35be83c5f6 Merge branch 'fix-permission-context-help' into 'dev'
Fix context help link for permissions

See merge request hubzilla/core!2212
2025-07-13 19:39:21 +00:00
Harald Eilertsen
76eed3c06c Fix context help link for permissions
The target was changed when the new docs was merged.
2025-07-13 16:09:33 +02:00
Harald Eilertsen
d994e1be48 Update translations for Norsk Bokmål 2025-07-13 16:01:06 +02:00
Mario
24316bbb03 Merge branch 'dev' into 10.4RC 2025-07-13 10:32:55 +00:00
Mario
7b5a638e00 update changelog 2025-07-13 10:32:23 +00:00
Mario
fa4c86eabf update install document 2025-07-13 10:03:46 +00:00
Mario
9cf610280c add init_sys_channel utility to create the sys channel in case of headless installation - issue #1909 2025-07-13 09:57:26 +00:00
Mario
052341d24a Merge branch 'dev' into 10.4RC 2025-07-13 09:49:29 +00:00
Mario
a55bba7aa8 fix blog mode if threaded view is disabled 2025-07-13 09:47:38 +00:00
Mario
0244d9423a RC3 2025-07-10 12:02:15 +00:00
Mario
042c98cf2d Merge branch 'dev' into 10.4RC 2025-07-10 12:00:53 +00:00
Mario
2958ea8c89 update changelog 2025-07-10 12:00:32 +00:00
Mario
81a12be654 changelog 2025-07-10 11:59:27 +00:00
Mario
9f99e401bc Merge branch 'fix-markdown-mentions' into 'dev'
Prevent mentions from mangling by markdown parser

See merge request hubzilla/core!2211
2025-07-10 11:43:10 +00:00
Mario
48ef490f50 Merge branch 'dev' into 10.4RC 2025-07-10 11:40:58 +00:00
Mario Vavti
d782229ba0 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-07-10 11:37:01 +02:00
Mario Vavti
52291fd371 update macgirvin/http-message-signer to version 2.2 2025-07-10 11:36:38 +02:00
Mario
e0298a4378 add logging and catch exception 2025-07-09 08:00:52 +00:00
Mario
08b7eb52c7 remove unneeded code from test 2025-07-09 08:00:27 +00:00
Mario
43ebf69d09 trim the value 2025-07-08 10:47:44 +00:00
Mario
18ae629f19 remove the check for supported protocols. we can store them all because we check later if we support one of them 2025-07-08 10:46:40 +00:00
Mario
8deedd1979 remove long deprecated crypto functions 2025-07-08 10:01:10 +00:00
Mario Vavti
525594d529 update to phpseclib3 which is now a requirement for the http signer library 2025-07-08 11:35:56 +02:00
Mario Vavti
1162615c52 missing file from http-message-signer 2025-07-07 13:17:55 +02:00
Mario Vavti
c462c928e0 composer update to phpseclib version 3 2025-07-07 13:17:14 +02:00
Mario
fcb0ef9633 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-07-06 21:22:53 +00:00
Mario
8a4273a2f5 for now only attempt RFC9421 verification if we have the request 2025-07-06 21:22:32 +00:00
Mario Vavti
3014ae2071 update macgirvin/http-message-signer to version 2.0 2025-07-06 22:58:09 +02:00
Mario Vavti
d396043faf composer dump-autoload 2025-07-06 22:42:55 +02:00
Mario Vavti
2054359f6c testing and fixes 2025-07-06 22:41:02 +02:00
Mario
9a3735cd37 tests for Activity::get_actor_protocols() 2025-07-06 18:32:08 +00:00
Mario
222b74ec05 extend get_actor_protocols() to also check fep-fb2a actor metadata 2025-07-06 18:06:28 +00:00
Harald Eilertsen
cb491c53f7 Prevent mentions from mangling by markdown parser
Mentioning people whose handles include valid markdown would not survive
markdown to bbcode conversion wihout being mangled. An example that
brought this to my attention was a handle similar to this:

    _someuser_@testsite.example

The underscores would be interpreted as emphasis in markdown, and
converted to:

    [i]someuser[/i]@testsite.example

This patch should fix this, and hopefully any other issue with mentions
being mangled.
2025-06-28 13:35:05 +02:00
Mario
37f0074674 Merge branch 'dev' into 10.4RC 2025-06-26 08:58:56 +00:00
Mario Vavti
e6c8c47721 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-06-26 10:55:31 +02:00
Mario Vavti
0a98a49eeb composer update macgirvin/http-message-signer 2025-06-26 10:54:42 +02:00
Mario
7bd4217dd8 Merge branch 'dev' into 10.4RC 2025-06-26 08:12:28 +00:00
Mario
af5733888c changelog 2025-06-26 08:11:46 +00:00
Mario
c346210735 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-06-26 08:08:31 +00:00
Mario
6028f0490e minor refactor to get rid of the $webpage variable (it does not cut it anymore) and use $item_type instead 2025-06-26 08:08:08 +00:00
Mario Vavti
890a5942d6 Merge branch 'dev' into 10.4RC 2025-06-25 17:43:52 +02:00
Mario Vavti
7782183ae3 changelog 2025-06-25 17:40:55 +02:00
Mario Vavti
7ecbce691d RC2 2025-06-25 17:35:58 +02:00
Mario Vavti
2aeed27b9b emiting a notice from include/auth does not work. emit it from mod login if the login failed. 2025-06-25 17:33:35 +02:00
Mario Vavti
d636e71024 remove code that would never execute and make sure the first account to register is the admin account 2025-06-25 17:26:41 +02:00
Mario
2606517c1d changelog 2025-06-24 10:09:36 +00:00
Mario
0ab94d42f4 bump dev version 2025-06-24 07:58:19 +00:00
Mario
7c32b11605 update strings 2025-06-24 07:55:21 +00:00
Mario
7b6c76abf1 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-06-24 07:54:33 +00:00
Mario
0e31d61868 Merge branch 'some-account-cleanup' into 'dev'
A bit of cleanup for account functions

See merge request hubzilla/core!2210
2025-06-24 07:53:43 +00:00
Harald Eilertsen
66e02c5e3a A bit of cleanup for account functions 2025-06-24 07:53:42 +00:00
Mario
122747ae76 version 10.4RC1 2025-06-24 07:28:50 +00:00
Mario
9a410f57e6 fix php warnings 2025-06-24 07:25:56 +00:00
Mario
2047e9bca7 fix php warning 2025-06-23 20:06:07 +00:00
Mario
aeb54655a0 exit if we have not found anything 2025-06-23 09:24:10 +00:00
Mario
1a3ca49eba apply downstream fix from streams: do not sign (request-target) on response 2025-06-23 09:10:57 +00:00
Mario
579cf86335 rfc9421 verify: parse more fields if applicable 2025-06-23 09:03:05 +00:00
Mario
fcf42eeae0 Revert "rfc9421 verify: parse more fields if applicable"
This reverts commit 721c0b1e5b.
2025-06-23 09:02:08 +00:00
Mario
721c0b1e5b rfc9421 verify: parse more fields if applicable 2025-06-23 08:59:27 +00:00
Mario
82b2f06bdd bump version 2025-06-22 07:36:08 +00:00
Mario
b241e14c06 import App 2025-06-21 20:56:41 +00:00
Mario Vavti
89c17bac50 start verifying RFC9421 HTTP Signatures (hopefully) 2025-06-21 16:39:59 +02:00
Mario
e6bd5ef520 css fix 2025-06-20 19:08:27 +00:00
Mario
7320149fd8 only show the pin if we display the label and fix the test 2025-06-19 08:26:31 +00:00
Mario
7766e5d420 prepend geo links withe a pushpin emoji so that they can be distinguished from regular links 2025-06-19 08:18:25 +00:00
Mario
4a813c150c make sure to set the state on the correct button 2025-06-19 08:08:16 +00:00
Mario
44600c46c6 make sure there is a comment button before attempting to add a class to it 2025-06-18 17:01:26 +00:00
Mario
b5c7fff316 re-add check for sub thread wrapper 2025-06-18 16:49:33 +00:00
Mario
ce618facc8 properly set the comment button and sub-thread-wrapper state if we are loading a conversation in partly expanded mode 2025-06-18 15:55:15 +00:00
Mario Vavti
18016ab36a remove some redundant spaces in bbcode to html conversion and fix tests 2025-06-18 11:55:47 +02:00
Mario
d788233bd7 handle naked geo URIs and add tests 2025-06-18 09:18:11 +00:00
Mario
86ebef7e08 allow geo: uri and be more specific when checking uri schemes also remove zhttp which is not used anymore and ftp which is not supported by most browsers anymore 2025-06-17 09:29:27 +00:00
Mario
37159937d7 bump version 2025-06-14 10:51:48 +00:00
Mario
4d6d3befa0 leave zoom handling to the comment button click handler 2025-06-14 10:51:18 +00:00
Mario
a21785980d Merge branch 'remove-obsolete-funcs' into 'dev'
Remove obsolete functions in account.php

See merge request hubzilla/core!2208
2025-06-14 10:29:14 +00:00
Mario
14fe08240f Merge branch 'fix-album-widgets' into 'dev'
Fix undefined variable in album widgets

See merge request hubzilla/core!2207
2025-06-14 10:28:33 +00:00
Mario
73d50d8294 Merge branch 'remove-xref-module' into 'dev'
Remove unused Xref module

See merge request hubzilla/core!2206
2025-06-14 10:27:50 +00:00
Mario
767eeee6fe invert the verb query part 2025-06-13 09:42:09 +00:00
Mario
abd864a762 css fixes 2025-06-13 09:20:30 +00:00
Mario
25dba4423b bump version 2025-06-13 08:07:53 +00:00
Mario
2046abf26f trick sql to use a better suited index 2025-06-13 08:05:05 +00:00
Mario
ad7871270c add EmojiReact to the countable comment verbs 2025-06-12 11:57:13 +00:00
Mario
66512f4e51 blog mode fixes 2025-06-12 11:51:01 +00:00
Mario
71a06af8a9 consistent naming 2025-06-12 10:47:04 +00:00
Mario
14088b4b2e do not expand all 3 thread levels even if the content is already there. This would be inconsistent behaviour. 2025-06-12 08:02:52 +00:00
Mario
ec2c4fe673 css fixes 2025-06-12 07:02:14 +00:00
Mario
49a065e50b bump version 2025-06-11 19:35:40 +00:00
Mario
391c8d7cba implement indenting of already expanded but flattened items and add dblclick info badge 2025-06-11 19:35:17 +00:00
Mario
76296e72be refactor TLL to zoom in on every expansion and better maintainable code 2025-06-11 11:34:08 +00:00
Mario
d36f806ece more autoexpand iterations fixes 2025-06-10 09:06:48 +00:00
Mario
d3d8c088f3 bump version 2025-06-10 08:46:24 +00:00
Mario
4e01e21230 fix autoexpand iterations 2025-06-10 08:46:01 +00:00
Mario
673790126b dismiss summary if it is equal to content and css fixes 2025-06-09 19:09:32 +00:00
Mario
9eecd0aa3c css fixes 2025-06-09 14:11:20 +00:00
Mario
f8fb1bc3b4 use a more prominent color 2025-06-09 09:30:31 +00:00
Mario
340f5bb791 do not count iterations where we have not found a new thread 2025-06-09 08:11:41 +00:00
Mario
5504c8650e do not call preview twice and not at all if we are in modal action 2025-06-08 21:18:53 +00:00
Mario
9405f2e2d3 bump version 2025-06-08 21:09:51 +00:00
Mario
3de0d304fd fix comment image embed after transition to modal 2025-06-08 21:09:27 +00:00
Harald Eilertsen
0e4924d7c5 Remove obsolete verify_email_addressNOP function 2025-06-08 22:46:26 +02:00
Mario
20377c1ca1 css fixes 2025-06-08 19:05:58 +00:00
Mario
8af9bbb75e slightly darker colors 2025-06-08 18:53:36 +00:00
Mario
34c3a77db4 improved thread lense 2025-06-08 17:07:14 +00:00
Mario
dbc3613af5 more cleanup 2025-06-08 15:13:45 +00:00
Mario
e1d395b6ed more cleanup and introduce the thread lense 2025-06-08 09:06:01 +00:00
Harald Eilertsen
5316ebfe7c Remove obsolete functions in account.php 2025-06-08 09:43:14 +02:00
Harald Eilertsen
13755060d7 Fix undefined variable in album widgets
The Album and Portfolio widgets would reference the undefined
$phototypes array to determine the file extensions of the image sources.

It appears that the extension is not really necessary, but for
completeness I fixed the issue so that the appropriate extension will be
used by for the image source attribute.
2025-06-07 23:09:46 +02:00
Harald Eilertsen
eeb8a124fc Remove unused Xref module
See discussion here:
https://hubzilla.org/item/c611090c-1a5e-5fa5-8836-06f393fd71ef
2025-06-07 22:14:22 +02:00
Mario
5db855abfe it is hard to keep the overview with more than 3 levels 2025-06-07 09:11:12 +00:00
Mario
ab14743146 bump version 2025-06-06 12:04:47 +00:00
Mario
409c062c4f reset indents for possible followup autoexpand 2025-06-06 12:04:32 +00:00
Mario
1b494cdd27 bump version 2025-06-06 11:11:06 +00:00
Mario
f5f853cdfe improved autoexpand 2025-06-06 11:10:36 +00:00
Mario
37aa16a6c0 bump version 2025-06-05 19:43:42 +00:00
Mario
a4ebf93cb8 cleanup, fix iteration counter and bump literations to 10 2025-06-05 19:43:19 +00:00
Mario
358e7c9512 bump version 2025-06-05 16:08:44 +00:00
Mario
11b42a371e revert to previous color generation logic 2025-06-05 16:08:22 +00:00
Mario
61da32dc3f Merge branch 'new-de-docs' into 'dev'
New de docs

See merge request hubzilla/core!2205
2025-06-05 15:50:22 +00:00
Mario
5f26e77785 Merge branch 'more-phpstan-fixes' into 'dev'
More PHPStan fixes

See merge request hubzilla/core!2204
2025-06-05 15:48:17 +00:00
Mario
1d289e619e Merge branch 'crash-in-jcxeddsa2022-sign' into 'dev'
Throw if channel keys missing in JcsEddsa2022::sign

See merge request hubzilla/core!2201
2025-06-05 15:45:47 +00:00
Harald Eilertsen
0c41265613 Throw if channel keys missing in JcsEddsa2022::sign 2025-06-05 15:45:46 +00:00
Mario
b5ad0589cb bump version 2025-06-05 15:44:25 +00:00
Mario
9e87070f86 iterate only 3 levels when autoexpanding, improve color generation to get more random colors 2025-06-05 15:44:01 +00:00
Mario
3da16a4bae bump version 2025-06-05 15:09:23 +00:00
Mario
1ad76ec83f fix other reactions buttons and bring some color to indents 2025-06-05 15:09:03 +00:00
Mario
fa67852278 better center the gt 2025-06-05 08:16:51 +00:00
Mario
d9ebd880be more better center the dash 2025-06-05 08:13:19 +00:00
Mario
9d7c5d2fe2 better center the dash 2025-06-05 08:05:46 +00:00
Mario
8c268d24df version 2025-06-05 08:03:52 +00:00
Mario
f8fb550255 threading: implement manual indent and collapse 2025-06-05 08:03:33 +00:00
Mario
c1aa5a2954 bump version 2025-06-04 19:55:42 +00:00
Mario
342f736eb7 improved autoexpand 2025-06-04 19:55:05 +00:00
Mario
0283c77961 do not prevent default too early 2025-06-04 16:38:30 +00:00
Mario
7740a7501b improved indentation and its logic 2025-06-04 16:33:05 +00:00
Mario
ed97164f01 remove unused code 2025-06-04 14:35:35 +00:00
Mario
6649eca2bf move expand to item menu to get rid of the single click lag 2025-06-04 14:34:44 +00:00
Mario
64ae1eb5e8 add ability to auto-expand a comment reply thread 2025-06-03 08:31:19 +00:00
Mario
d42a89d4b5 disable reactions in pinned widget 2025-06-02 07:55:24 +00:00
Mario
bb05f520c1 fix pinned widget 2025-06-02 07:38:11 +00:00
Mario
f8afa77369 add internal follow and ignore verbs to the list of filtered verbs and add commented out code to display/count only one reaction per author. It appears there can be multiple. We should probably look into how this can happen and if we should prevent it earlier. 2025-06-01 18:48:16 +00:00
Mario
940fd26db7 add the thr_parents if we are in channel single view mode 2025-06-01 10:44:33 +00:00
Mario
fca6ddd35b change the animation so that it will not interfere with bootstrap stuff 2025-06-01 10:14:18 +00:00
Mario
a5ded5884c no need to set animation constant 2025-06-01 04:58:06 +00:00
Mario
d0686796cd it is the fill: both option that woes with dropdown visibility - set it to none 2025-06-01 04:57:05 +00:00
Mario
3ea323bfb0 handle intro notifications via /notify/view so that it will eventually be marked seen 2025-05-31 20:16:24 +00:00
Mario
c826b307c2 fix display issue 2025-05-31 18:43:07 +00:00
Mario
00edbe4393 bump version 2025-05-31 17:07:00 +00:00
Mario
525a45f69c make sure to load the profile when in channel module 2025-05-31 16:56:30 +00:00
Mario
e35d4b6be0 only show load more if total comments > loaded comments 2025-05-30 09:55:26 +00:00
Mario
83c963378e remove more redundant sql (perms for the given IDs MUST be checked at the calling module already) and update documentation 2025-05-29 19:47:53 +00:00
Mario
7705d7a87f this is not required because we already filter by a given set of ids here 2025-05-29 19:31:23 +00:00
Mario
3060126123 bump version 2025-05-29 19:12:27 +00:00
Mario
29f14ff96b only count comments if we are in threaded mode 2025-05-29 19:10:20 +00:00
Mario
8a8219fe72 improved wording 2025-05-29 18:38:11 +00:00
Mario
0aef9b486d fix typo 2025-05-29 17:58:48 +00:00
Mario
d584e4f7d5 fix queries in certain situations returning more results than we need producing unexpected rendering results 2025-05-29 17:58:04 +00:00
Mario
71fbc3ff5c bump version 2025-05-29 14:25:20 +00:00
Mario
3613257cdc pass permission sql to item_reaction_sql() in case we are a visitor and rename the variable 2025-05-29 14:24:53 +00:00
Mario
f61fd2d337 if we are not in threaded mode default comments limit to 1000 2025-05-29 11:55:02 +00:00
Mario
bd8ffcd28d bump version 2025-05-29 10:14:20 +00:00
Mario
20148d23f1 toplevel comments pagination: initial commit 2025-05-29 10:13:32 +00:00
Mario
bdcee46138 do not check for possibly unset var 2025-05-28 12:53:53 +00:00
Mario
bc40c3f7c0 bump version 2025-05-28 09:18:49 +00:00
Mario
7e3d86bc37 more refactor and streamline for re-usability and easier maintenance 2025-05-28 09:15:18 +00:00
PepeCyB
133ac409e3 remove unneeded files 2025-05-27 22:49:16 +02:00
PepeCyB
bda32015b9 new german help-files added 2025-05-27 22:48:54 +02:00
Mario
f0229c9f42 update todo 2025-05-27 09:02:52 +00:00
Mario
7cd44e2112 minor cleanup 2025-05-27 08:31:37 +00:00
Mario
3a3ae2b204 fix a undefined var warning and move some definitions closer to where the value is set for better readability 2025-05-27 08:12:33 +00:00
Mario
4df3c8d2a1 bump version 2025-05-27 08:06:20 +00:00
Mario
8d1fea7ec3 new version of items_by_parent_ids() and item_reaction_sql() with much better performance, streamline rsvp naming convention and some preparatory work for comment lazy loading (unfinshed) 2025-05-27 08:04:36 +00:00
Mario
3535cb3b96 remove the word only. the filter icon should be clear enough. 2025-05-25 17:56:38 +00:00
Mario
48af5b354d bump version 2025-05-25 14:16:47 +00:00
Mario
19df2f596b revert to previous iteration of the parents query function until performance issues will be resolved and adapt the modules accordingly 2025-05-25 14:05:08 +00:00
Harald Eilertsen
51cd6381a6 Ignore PHPStan warning of missing .htpreconfig
The existence of the file is checked in the if-statement wrapping the
include.
2025-05-24 10:52:29 +02:00
Harald Eilertsen
311e0159c9 Fix undefined static function in Zot6Handler
The static function `reply_rekey_request` did not exist, but a function
`rekey_request` that was never called did. Changed the call to use the
latter function instead.

Note: This is completely untested code, and probably needs some
validation. But then it did not work before either.
2025-05-24 10:43:39 +02:00
Harald Eilertsen
63c3f4dc20 Fix missing return in Render\Theme::current
Also made the function halt with a status 500 and log a message if no
theme was found.
2025-05-23 22:33:52 +02:00
Harald Eilertsen
b6e65a76ea Add App::$page_layouts attribute for comanche
Zotlabs\Render\Comanche::register_page_template assigns this variable in
App (for some reason), but it is not declared. As dynamic attributes are
deprecated, and will be removed in PHP 9, this patch fixes the issue by
defining the attribute in the App class.
2025-05-23 20:53:55 +02:00
Mario
d31221e61b use else instead of checking for $ret 2025-05-23 11:54:30 +00:00
Mario
043c1610fd refactor items_by_parent_ids() to accept $thr_parents as an array and stringify it here with the escape flag instead of in the caller modules 2025-05-23 11:35:10 +00:00
Mario
84a4927866 bump version 2025-05-23 10:01:18 +00:00
Mario
2c3ec1ae81 Merge branch 'phpstan-fixes' into 'dev'
Fix a selection of ussues reported by PHPStan

See merge request hubzilla/core!2203
2025-05-23 09:58:59 +00:00
Mario
5655962370 Merge branch 'update-doxygen-config' into 'dev'
Minor doxygen config update

See merge request hubzilla/core!2202
2025-05-23 09:55:15 +00:00
Mario
cd7fab3d37 refactor query in items_by_parent_ids() to prepare for pagination. Until pagination will be implemented we will load the last 100 comments. 2025-05-23 09:51:11 +00:00
Mario
980fedadc0 dba_pdo: return results when using common table expressions (CTE) 2025-05-23 09:47:25 +00:00
Harald Eilertsen
0121e4ed12 Fix undefined variables in Module/Regate.php 2025-05-22 19:03:06 +02:00
Harald Eilertsen
ea6893e3a3 Fix undefined var in Module/Invite.php
The variables $invexpire_n and $invexpire_u was undefined, but
references multiple times in a conditional. Just removed them which
should cause no changed behaviour.
2025-05-22 19:03:06 +02:00
Harald Eilertsen
8a211aff97 Remove unused code in Module/Invite.php
The $feedbk variable was set, but never used in the Module\Invite::get()
function.
2025-05-22 19:03:06 +02:00
Harald Eilertsen
daf8531804 Fix undefined var in Module/Invite.php
Fir ref to undefined $ihave variable in the Module\Invite::get() method.
The var was defined later in the method. Also refactor to fix some other
strange logic in the same area while I was there.

- Moved the logic to cound invites currently in use by a channel to a
  private function. This should probably be moved further to a Regiter
  class once we have these things more in order.
- Changed the logic checking the configuration for how many invites a
  channel can use at the same time to just return 4 (the default)
  instead of going via 'na' and then checking if it's 'na' to then use
  the default value.
- Dropped setting the config to the default if the module is visited by
  an admin. That belongs somewhere else.
2025-05-22 19:03:06 +02:00
Harald Eilertsen
961996a051 Remove duplicate array key in Lib/ThreadItem.php
The key `parent` was set twice in ThreadItem::get_template_data(), once
cast to an intvalue, and later raw from whatever type $item['parent']
held.

Since the value not converted to an int was the one used, this is what
has been kept in this patch, so as to not change existing behaviour.
2025-05-22 19:03:06 +02:00
Harald Eilertsen
0f8500244b Fix undefined variable in Lib/Activity.php
This looks like a simple typo, using camelCase instead of snake case for
the $is_collection_operation variable.

Note:
	However, as it has been undefined, this means it's been treated as
	always false until now, so this may change some behaviour.
2025-05-22 19:03:06 +02:00
Harald Eilertsen
5dcafde617 Fix exclude pattern in phpstan config 2025-05-22 19:03:06 +02:00
Harald Eilertsen
e101e4f511 Minor doxygen config update
- Enable dark mode toggle
- Remove empty footer that broke scrolling
2025-05-22 15:27:35 +02:00
Mario
a5e171a594 Revert "implement thread limit"
This reverts commit be35f612eb.
2025-05-21 11:11:21 +00:00
Mario
be35f612eb implement thread limit 2025-05-21 10:22:37 +00:00
Mario
6d306bc0b3 more return early if we have not got the required data 2025-05-21 09:24:48 +00:00
Mario
813a5b3621 return early if we have not got the required data 2025-05-21 09:23:23 +00:00
Mario
48162fc8d6 fix php warning 2025-05-21 09:13:58 +00:00
Mario
868f9a6b92 bump version 2025-05-20 20:43:10 +00:00
Mario Vavti
e022e59d0a check if function exists - aparently that is not always the case 2025-05-20 22:38:29 +02:00
Mario Vavti
9947f1ec99 add exif to extensions to install 2025-05-20 22:24:25 +02:00
Mario Vavti
6a2748724c guess_image_type(): fix minor issue and add some tests (guessing from getimagesize() and Imagick is not tested) 2025-05-20 22:10:52 +02:00
Mario
457cb74883 Merge branch 'messages-widget-tests' into 'dev'
Add a couple of tests for Widget\Messages

See merge request hubzilla/core!2200
2025-05-20 09:17:05 +00:00
Mario
90b8e08637 since photo_cache images depend on items uese default expire days instead of cache expire days otherwise they might be removed too early (if they have not been removed yet due to cache expire policy) 2025-05-19 22:00:03 +00:00
Mario
572b4a45da fix syntax error 2025-05-19 21:53:49 +00:00
Mario
2e7f806c15 add logging on failure 2025-05-19 21:52:29 +00:00
Mario
4ed8e7b469 refactor guess_image_type() 2025-05-19 21:50:20 +00:00
Harald Eilertsen
1eb3357584 Add a couple of tests for Widget\Messages
Just a couple of basic tests around listing file tags, to make sure the
code runs without any warnings.
2025-05-19 10:24:13 +02:00
Mario
3850cd9641 remove leftover after recent changes 2025-05-19 08:18:47 +00:00
Mario
6f501b37e8 Merge branch 'new-docs' into 'dev'
Replace english docs with pepecyb's docs

See merge request hubzilla/core!2189
2025-05-18 18:42:45 +00:00
Harald Eilertsen
456a741809 Replace english docs with pepecyb's docs 2025-05-18 18:42:45 +00:00
Mario
8a0c9648fe define variable 2025-05-18 16:56:12 +00:00
Mario
4625a8927c Revert "define variable"
This reverts commit a773ca8a24.
2025-05-18 16:55:55 +00:00
Mario
a773ca8a24 define variable 2025-05-18 16:55:20 +00:00
Mario
eb00fe3575 bump version 2025-05-17 18:43:42 +00:00
Mario
1666ca7cb7 actually fix thr_parent arrows 2025-05-17 18:42:42 +00:00
Mario
89aecbbc1c version 2025-05-17 16:21:26 +00:00
Mario
7b8e47b49d revert moving thr_parent retrieval to SQL in favor of a more simple solution (fixes SQL error in postgres and strict mysql) 2025-05-17 16:19:05 +00:00
Mario
cf317aa1a1 revert moving thr_parent retrieval to SQL in favor of a more simple solution (fixes SQL error in postgres and strict mysql)Zotlabs/Lib/ThreadItem.php 2025-05-17 16:18:20 +00:00
Mario
bd1e282499 bump version 2025-05-16 21:03:59 +00:00
Mario
d8a5e8c550 pinned item fixes 2025-05-16 20:43:04 +00:00
Mario
43d0e42425 refactor cache_embeds daemon to be called with uuid (instead of item id) so that it will only be processed once (the queueworker will dismiss duplicates) and add a hook for the photocache addon 2025-05-16 20:22:27 +00:00
Mario
c31b3b6b67 add avif support for php-gd 2025-05-16 07:19:50 +00:00
Mario
18be92ba22 version 2025-05-15 18:58:01 +00:00
Mario
2b38eca986 refactor sql_extra > permission_sql 2025-05-15 18:56:30 +00:00
Mario
4ec895b891 make sure sql_extra is prepared for the c table 2025-05-15 18:40:03 +00:00
Mario
757237cbb4 Revert "make sure sql_extra is prepared for the c table"
This reverts commit 869b047fde.
2025-05-15 18:39:05 +00:00
Mario
869b047fde make sure sql_extra is prepared for the c table 2025-05-15 18:38:42 +00:00
Mario
4bf6752982 implement extra sql for mod channel and display 2025-05-15 16:57:02 +00:00
Mario
5c3f2f9469 first part of cleanups for the conv libs and move thr_parent_uuid retrieval to sql 2025-05-15 12:55:44 +00:00
Mario
6e21be2d94 remove unused var 2025-05-15 11:10:21 +00:00
Mario
3e07eb78fd fix announce source title (addr) not correct 2025-05-15 11:00:18 +00:00
Mario
dceaee691f no need to scroll to toplevels 2025-05-15 07:41:22 +00:00
Mario
7cf380e390 bump version 2025-05-15 07:24:16 +00:00
Mario
9165f766c2 fix offset calculation if element position is relative and use inset box shadow for highlighting items plus some css fixes 2025-05-15 07:23:42 +00:00
Mario
d77d56dfb0 version 2025-05-14 18:54:47 +00:00
Mario
0ae938a4bf another attempt to fix collapsing 2025-05-14 18:54:14 +00:00
Mario
8a0ef4c809 Reapply "fix collapsing"
This reverts commit a3f37e2f1e.
2025-05-14 18:09:46 +00:00
Mario
a3f37e2f1e Revert "fix collapsing"
This reverts commit 948ceb3fac.
2025-05-14 17:57:08 +00:00
Mario
271b9f66ea revert css fixes for messages widget 2025-05-14 16:10:39 +00:00
Mario
4914438479 pinned item template fixes (requires more work) and minor css fixes 2025-05-14 16:07:42 +00:00
Mario
7a01eaa90f version 2025-05-14 11:01:17 +00:00
Mario
948ceb3fac fix collapsing 2025-05-14 11:00:47 +00:00
Mario
d26a3ec22b bump version 2025-05-14 09:41:31 +00:00
Mario
c4a3c7feb7 fix autosave for comments 2025-05-14 09:40:53 +00:00
Mario
6e8481e90e fix notfication issue with update activities 2025-05-14 08:57:47 +00:00
Mario
47d988419f bump version 2025-05-14 08:21:05 +00:00
Mario
a84e6e9747 streamline show more/less handling 2025-05-14 08:19:42 +00:00
Mario
aa9210921d exclude Add/Remove from network nouveau query 2025-05-13 08:49:58 +00:00
Mario
e91f8f3aef bump version 2025-05-13 08:21:20 +00:00
Mario
9b36c39eff remove and deprecate image preload setting - we will now always preload 2025-05-13 08:20:46 +00:00
Mario
a28dd9f2cf remove redundant var 2025-05-13 08:08:27 +00:00
Mario
bf79a2cf4f bump version 2025-05-13 08:05:56 +00:00
Mario
a03ca38409 use box-shadow instead of border to prevent layout moving 2025-05-13 08:05:30 +00:00
Mario
1b246e2ba5 remove redundant item_normal() from item_activity_sql() and use protect_sprintf() on thr_parents 2025-05-13 07:12:20 +00:00
Mario
f905266e4b fix php warning 2025-05-11 19:33:40 +00:00
Mario
e511220022 Merge branch 'remove-direct-access-to-app-observer' into 'dev'
Don't access App::$observer directly in core

See merge request hubzilla/core!2197
2025-05-11 18:08:16 +00:00
Mario
5655807337 fix wrong variable name 2025-05-11 17:56:46 +00:00
Mario
0930539ab4 Merge branch 'lazy' into 'dev'
Implement lazy loading of reactions and sub threads, default to threaded conversation view, some bugfixes and adjusted nomenclature

See merge request hubzilla/core!2198
2025-05-11 17:54:58 +00:00
Mario
b674a1869e undo introduction of new argument in get_template_data(). this can be accomplished more straightforward 2025-05-11 16:01:49 +00:00
Mario
16fafdbbb0 remove redundant query for stored item 2025-05-11 13:39:37 +00:00
Mario
b5acde1420 bump version for merge 2025-05-09 20:34:04 +00:00
Mario
4fa9f30189 cleanup, add some doco an add missing counts of observer event rsvps 2025-05-09 20:24:25 +00:00
Mario
57ae3325e0 allow to switch conv mode per channel 2025-05-09 19:13:49 +00:00
Harald Eilertsen
8141ef9511 Add some API docs for the observer file 2025-05-09 15:23:01 +02:00
Harald Eilertsen
e70870ce4e Move observer helper functions to separate source
The main goal was to move the functions out of the already overcrowded
`boot.php`. While I would ideally have liked to move them properly under
a namespace under `Zotlabs\`, that would break too much existing code at
this point.

Thus leaving it in include and under the global namespace for now.
2025-05-09 15:20:38 +02:00
Harald Eilertsen
7cb8a56b6a Don't access APP:$observer directly in core
Introduce helper functions to access the various fields of the xchan
stored in `App::$observer'. This removes direct access to the attribute
from core, with the aim of allowing further refactoring later.

We can not yet make the `App::$observer` attribute private, though, as
it is also accessed directly by some addons.
2025-05-09 15:15:35 +02:00
Mario
07ca5d54c8 version 2025-05-09 09:43:02 +00:00
Mario
dfde321a3b fix statObj 2025-05-09 09:42:29 +00:00
Mario
aab53c9fc9 provide owner uid for item_normal() in items_by_thr_parent() and set history.pushState when requesting a subthread 2025-05-09 09:35:31 +00:00
Mario
9def0f280f notification fixes 2025-05-09 08:53:47 +00:00
Mario
e71c95a5a5 refactor item_normal() to allow a profile_uid and a prefix as arguments 2025-05-08 12:05:31 +00:00
Mario
1be6c11bad implement moderation of reactions 2025-05-08 11:48:58 +00:00
Mario
030fe8c656 bump version 2025-05-08 10:36:45 +00:00
Mario
8f539e3707 fix announce action label and modal not closing 2025-05-08 10:35:32 +00:00
Mario
918377a67b provide commentable state and minor cleanup 2025-05-08 10:27:57 +00:00
Mario
25e29ec544 fix wrong order of args 2025-05-08 08:39:32 +00:00
Mario
71f80aa4d2 cleanup template 2025-05-07 19:23:21 +00:00
Mario
070d839ad9 version 2025-05-07 19:03:26 +00:00
Mario
ee9b53132e wording, fix comment preview and remove logging 2025-05-07 19:02:53 +00:00
Mario
ca4bb5927e whitespace 2025-05-07 12:36:40 +00:00
Mario
6ed56f9996 sess_data has been changed to mediumtext a while ago via update 2025-05-07 12:33:17 +00:00
Mario
ac5d22d514 refactor doreply() and move reply functionality to modal 2025-05-07 12:31:47 +00:00
Mario
21279b7d4e version 2025-05-06 09:14:17 +00:00
Mario
77c310e393 mark lazy loaded items read and minor cleanup 2025-05-06 09:13:35 +00:00
Mario
c5d75f23e5 fix title and summary converted to bbcode 2025-05-06 06:57:45 +00:00
Mario
a00db63b3e imagesLoaded() can deal with strings 2025-05-06 06:45:58 +00:00
Mario
1d60d38cdc version 2025-05-06 06:41:57 +00:00
Mario
0b42197a99 allow preloading images if dom element is not yet in page 2025-05-06 06:41:26 +00:00
Mario
07da20d00c fix verb and hash for notifications 2025-05-05 07:44:39 +00:00
Mario
d413cf8a30 wrong logic 2025-05-04 20:15:30 +00:00
Mario
1da0ea86f0 more wording 2025-05-04 19:45:57 +00:00
Mario
72f36920ef more on wording 2025-05-04 19:35:14 +00:00
Mario Vavti
7a4d568bfb fix query for postgres 2025-05-04 21:27:41 +02:00
Mario Vavti
0d1c5e26a7 do not add the item-highlight class to any toplevel item 2025-05-04 21:13:36 +02:00
Mario Vavti
ff0a5a0507 mod network fixes 2025-05-04 20:46:49 +02:00
Mario
da780e4e08 this got removed by accident 2025-05-04 16:06:58 +00:00
Mario
0c783773d8 more streamline wording 2025-05-04 15:41:43 +00:00
Mario
5edeb7bd53 remove uuid from mid queries (it is not needed) and slightly alter the query to fetch the parents 2025-05-04 15:40:17 +00:00
Mario
20c8f69efa use profile_uid for mod channel 2025-05-04 13:22:18 +00:00
Mario
b694ed6229 handle blog_mode in conv template 2025-05-04 04:36:12 +00:00
Mario
b4f7daadfb improved blog_mode query 2025-05-03 20:43:26 +00:00
Mario
fb3eae96ab implement blog_mode 2025-05-03 19:04:20 +00:00
Mario
cc91446c18 unseen items: only show announce activities but not the resulting item. also fix a missing operator 2025-05-03 18:03:24 +00:00
Mario
22bda936a5 more streamline wording 2025-05-03 15:58:04 +00:00
Mario
95a2de4da2 Reapply "streamline wording"
This reverts commit ee3fc54be6.
2025-05-03 15:55:13 +00:00
Mario
ee3fc54be6 Revert "streamline wording"
This reverts commit e2c477d775.
2025-05-03 15:52:30 +00:00
Mario
e2c477d775 streamline wording 2025-05-03 15:42:26 +00:00
Mario
6ddd31bfba bump version 2025-05-03 09:42:08 +00:00
Mario
3653f769d9 fix notification button for medium screen size (right aside collapsed) 2025-05-03 09:41:41 +00:00
Mario
261f0e4120 default ordering to created 2025-05-03 09:06:15 +00:00
Mario
6fce724f69 yet another refactor to cover unseen pubstream notifications 2025-05-03 08:32:01 +00:00
Mario
dedab1ad4f this performs way better 2025-05-02 16:48:34 +00:00
Mario
cf1a404945 bump version 2025-05-02 16:24:54 +00:00
Mario
ac4af6f9ef Ãfix marking read of reactions 2025-05-02 16:02:47 +00:00
Mario
69ade6d2cb cleanup 2025-05-02 14:03:45 +00:00
Mario
6db5236bf5 provide thr_parent uuid in the item array and make use of it in various places 2025-05-02 13:58:01 +00:00
Mario
b39fb945f5 move look up of thr_parents to separate function and minor fixes 2025-05-02 13:24:58 +00:00
Mario
3fcd5a0f0f fix display issue 2025-05-02 07:52:41 +00:00
Mario
62635aa803 version 2025-05-01 10:52:32 +00:00
Mario
32717d910c add counts for rsvp activities and some visual shenenigans 2025-05-01 10:52:15 +00:00
Mario
881f540e43 some visual changes 2025-04-30 19:31:31 +00:00
Mario
e5cd6330b3 default to threaded 2025-04-30 14:42:09 +00:00
Mario
e91021f648 rename wrapper class 2025-04-30 09:06:01 +00:00
Mario
1463c1a526 refactor 2025-04-30 08:28:47 +00:00
Mario
e195897dc7 slightly change the way we deal with perms 2025-04-29 21:18:53 +00:00
Mario
b6f0fe7583 refactor with permissions 2025-04-29 09:52:30 +00:00
Mario Vavti
377fe32795 add branch to version string 2025-04-26 22:41:35 +02:00
Mario Vavti
73d444bd8a some refactoring and implement subthread fetching 2025-04-26 22:33:32 +02:00
Mario Vavti
80415f6bd3 remove unused code 2025-04-26 14:33:45 +02:00
Mario Vavti
7ab531025c streamline sql functions 2025-04-26 12:19:04 +02:00
Mario Vavti
763a4f1fbb implement observer activity visibility 2025-04-26 10:46:48 +02:00
Mario Vavti
cde558a43f also remove the parent line from the query 2025-04-25 23:47:04 +02:00
Mario Vavti
bafbbc9d5b revert adding of id - we can not use it 2025-04-25 23:22:06 +02:00
Mario Vavti
ad4eec1145 kind of fix the like response 2025-04-25 23:02:28 +02:00
Mario Vavti
0584094f05 use normal size modal 2025-04-25 22:36:27 +02:00
Mario Vavti
c614f899b7 implement requesting of reactions 2025-04-25 22:35:13 +02:00
Mario Vavti
0940be57fd should compare against item.mid 2025-04-25 16:47:15 +02:00
Mario Vavti
7e148c1e30 the c table must also include item_normal() 2025-04-25 16:16:37 +02:00
Mario
babc3df364 this should not be required anymore 2025-04-25 12:53:47 +00:00
Mario
ba9637e129 lazy load - initial commit 2025-04-25 12:46:30 +00:00
Mario Vavti
a48a72d1cd use a separator 2025-04-24 10:05:00 +02:00
Mario Vavti
1edea291a4 we have update an existing result - do not create another result set for this action 2025-04-24 09:58:37 +02:00
Mario
b7ef3fab3c dreport: do not store dismissed create activities 2025-04-24 07:09:29 +00:00
Mario
afe31160db mod item: deprecate x() and use $_POST instead of $_REQUEST 2025-04-24 06:41:43 +00:00
Mario
4849d50610 add some styling to dreport 2025-04-23 20:17:02 +00:00
Mario
d5f7b620c4 fix regex to catch codeblocks with params like class etc 2025-04-23 19:37:57 +00:00
Mario
6515443957 more deprecate x() 2025-04-23 19:09:12 +00:00
Mario
8b352e4c64 more deprecate x() 2025-04-23 18:41:26 +00:00
Mario
7c59dd9fd7 more deprecate x() 2025-04-23 18:17:23 +00:00
Mario
118a223ee1 fix term.imgurl not stored in item_store_update() 2025-04-23 09:10:58 +00:00
Mario
481113f641 set $plink to null if not provided 2025-04-22 09:30:35 +00:00
Mario
bed929c966 define variable 2025-04-21 19:33:46 +00:00
Mario
10345a5418 more php warnings 2025-04-21 19:28:44 +00:00
Mario
efc9581798 comment out localize_item() in Enotify::submit() and fix some PHP warnings 2025-04-21 19:18:37 +00:00
Mario
005b9919d0 x() to !empty() 2025-04-21 17:25:20 +00:00
Mario
86e88c6bb0 also continue if we have not got a filepath for some reasonà 2025-04-21 15:27:55 +00:00
Mario
7505f7039a define variable 2025-04-21 11:52:34 +00:00
Mario
5a52b6afea define variable 2025-04-21 11:42:24 +00:00
Mario
86f8d8ecdf fix php warnings 2025-04-21 11:39:35 +00:00
Mario
81559e9bcf fix php warnings 2025-04-21 11:30:42 +00:00
Mario
1b458c7d65 missing include 2025-04-21 10:15:51 +00:00
Mario
d2177f27f9 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-04-21 10:09:54 +00:00
Mario
da6db54122 some cleanup for boot.php 2025-04-21 10:09:33 +00:00
Mario Vavti
1e41c83b35 fix test 2025-04-20 21:43:32 +02:00
Mario
8bc079aa3d cleanup Web/Router 2025-04-20 19:23:54 +00:00
Mario
a5a58d73ff cleanup Lib/WebServer 2025-04-20 18:42:26 +00:00
Mario
68967e93d6 wrong class 2025-04-20 16:16:15 +00:00
Mario Vavti
88f1a7d652 whitespace 2025-04-20 18:11:12 +02:00
Mario Vavti
21c2fabae0 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-04-20 18:06:03 +02:00
Mario Vavti
a36afc0bb7 rawurlencode the cloud paths - issue #1903 (second part) 2025-04-20 18:04:59 +02:00
Mario Vavti
7855aaf53c set App::$query_string from from server.request_uri instead of server.query_string because the latter will mostly be urldecoded by the server already - issue #1903 (first part) 2025-04-20 18:04:03 +02:00
Mario Vavti
6535475a99 add some padding for breadcrumb 2025-04-20 17:59:40 +02:00
Mario
ddaaac1103 Merge branch 'debian_install_20250415' into 'dev'
debian install script

See merge request hubzilla/core!2196
2025-04-19 05:45:17 +00:00
Mario
295266cb10 Merge branch 'refactor-language-selector' into 'dev'
Move lang_selector function to Lang module and refactor

See merge request hubzilla/core!2195
2025-04-19 05:43:26 +00:00
Harald Eilertsen
e800d176fb Move lang_selector function to Lang module and refactor 2025-04-19 05:43:25 +00:00
Mario Vavti
cace4c6c65 strtotime() accounts with the timezone - set it to UTC for the stored timestamp 2025-04-18 22:38:45 +02:00
Mario Vavti
d7aff9a4dd fix wrong logic 2025-04-18 21:19:38 +02:00
Mario Vavti
a4a7794315 implement until= in message filter 2025-04-18 21:00:33 +02:00
Mario Vavti
c1d87fa65d more doco 2025-04-18 10:27:13 +02:00
Mario Vavti
e69763f86d add more message filter tests 2025-04-18 10:21:16 +02:00
Mario Vavti
5db5a5cfe9 fixes and more test samples 2025-04-17 14:29:27 +02:00
Mario Vavti
24f71dfcf8 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-04-17 11:35:24 +02:00
Mario Vavti
6d62acb446 extend MessageFilter::test_condition() to deal with && and || conditions and add tests 2025-04-17 11:35:06 +02:00
Mario
32ab6344c4 use mb_strlen() instead of strlen() 2025-04-16 18:51:59 +00:00
Mario
60b4c003af $_REQUEST > $_POST 2025-04-16 11:07:03 +00:00
Mario
4c962417ff pÃrevent storing files/folder with filenames exceeding their max name length 2025-04-16 11:03:08 +00:00
Mario
d2aad8a41a stephenhill/base58 seems not maintained anymore and throws a deprecation warning - fix here for now 2025-04-16 08:36:10 +00:00
Mario
fd0f6d4fa8 check if the uuid is mapped before using it 2025-04-16 08:15:30 +00:00
Mario
87d68b175e fix undefined variable warning 2025-04-16 08:08:02 +00:00
Mario
64652c1d6e fix variable name 2025-04-16 07:51:22 +00:00
Mario
9342a92682 deal with link type attachments 2025-04-16 07:44:40 +00:00
Mario
443c5495e9 do not translate network to stream 2025-04-16 07:44:12 +00:00
OJ Randon
80f3892ba0 check if update script for selfHOST was downloaded 2025-04-15 17:39:14 +02:00
OJ Randon
16ee954048 use wget to download composer and checksum 2025-04-15 17:36:47 +02:00
OJ Randon
4e367e1e67 Merge remote-tracking branch 'official/dev' into fix_debianinstall 2025-04-15 17:31:28 +02:00
Mario
7f7763ee0c remove redundant var declaration 2025-04-15 14:38:28 +00:00
Mario
868a8ccfd9 fix more php warnings 2025-04-15 14:37:38 +00:00
Mario
b7b1a5574f fix more php warnings 2025-04-15 14:28:42 +00:00
Mario
aa0c8973fa fix more php warnings 2025-04-15 14:25:48 +00:00
Mario
f6b91f97bf this should be info instead of notice 2025-04-15 14:21:20 +00:00
Mario
d82e7c9f6c fix php warning 2025-04-15 14:20:27 +00:00
Mario
083b2b1bbc add suport for strong bbcode tag 2025-04-15 09:10:45 +00:00
Mario
805bbd1c3e fix color bbcode markup 2025-04-15 09:03:32 +00:00
Mario
077ca1aea5 change photo.filename to type text (some platforms have very long filenames for their profile photos) 2025-04-15 08:41:10 +00:00
Mario
1217ae3b3e remove it 2025-04-15 08:05:22 +00:00
Mario
17777981ac this should not be required because it only affects likes which are already handled before (reaction) 2025-04-15 07:43:11 +00:00
Mario
ddc4bdcebe set default value and add comment 2025-04-14 16:41:39 +00:00
Mario Vavti
126c7f9d62 improved tests 2025-04-14 17:35:35 +02:00
Mario
75d1be092e default to null 2025-04-14 14:34:21 +00:00
Mario Vavti
0d51ff1906 add test for Activity::getUUID() and Avtivity::getMessageID() methods 2025-04-14 13:23:49 +02:00
Mario
679b5098da provide methods to get mid and uuid from activity object, add quirks to retrieve markdown content 2025-04-14 09:24:20 +00:00
Mario
224b32e767 remove borders from some buttons 2025-04-14 07:25:08 +00:00
Mario
1f943474cb boxy: up padding left also for the itrm tools 2025-04-13 18:49:38 +00:00
Mario
6891db1b23 boxy: minor css fix 2025-04-13 13:55:11 +00:00
Mario
a19951528d minor css fix 2025-04-13 09:16:03 +00:00
Mario
a4ea4ecc3b video poster requires a single quote 2025-04-11 20:03:01 +00:00
Mario Vavti
8c182c9d68 version 10.2.3 2025-04-11 21:30:03 +02:00
Mario
384eea79dc changelog
(cherry picked from commit 6068c0e8c2)

Co-authored-by: Mario <mario@mariovavti.com>
2025-04-11 19:28:46 +00:00
Mario
c2a09434ca Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-04-11 19:28:01 +00:00
Mario
6068c0e8c2 changelog 2025-04-11 19:27:28 +00:00
Mario Vavti
f8bc755c20 fix bougus merge to master 2025-04-11 21:13:40 +02:00
Mario
fd86ccb4eb Merge branch 'increase-memory-limit-for-ci' into 'dev'
CI: Up the memory limit to allow for coverage reporting

See merge request hubzilla/core!2194
2025-04-11 09:38:16 +00:00
Mario
c36d159997 Merge branch 'fix_debianinstall' into 'dev'
Fix debianinstall

See merge request hubzilla/core!2192
2025-04-11 09:37:29 +00:00
OJ Random
efd61cb43a Fix debianinstall 2025-04-11 09:37:29 +00:00
Mario Vavti
aa38e8360a version 10.2.2 2025-04-11 10:45:43 +02:00
Mario
fdf6680b29 changelog
(cherry picked from commit b79c19c66d)

Co-authored-by: Mario <mario@mariovavti.com>
2025-04-11 08:44:37 +00:00
Mario
b79c19c66d changelog 2025-04-11 08:36:28 +00:00
Mario
8999a96ef0 cleanup deprecated forum queries and possibly improved performance 2025-04-11 10:23:46 +02:00
Mario
b5d2236a58 do not return success if Libzot::fetch() did not return anything useful and remove redundant parameter $hub
(cherry picked from commit 3550609d29)

Co-authored-by: Mario <mario@mariovavti.com>
2025-04-11 07:48:28 +00:00
Mario
91e59d3c4f make sure we have an encoded activity before we go on building the packet, do not json_encode() a possibly empty item.target
(cherry picked from commit fe8ae2f88e)

Co-authored-by: Mario <mario@mariovavti.com>
2025-04-11 07:45:24 +00:00
Mario
a6ff444e19 fix some plink for forum posts and comments
(cherry picked from commit a5a2d80c50)

Co-authored-by: Mario <mario@mariovavti.com>
2025-04-11 07:42:50 +00:00
Harald Eilertsen
ee4cc51a05 CI: Up the memory limit to allow for coverage reporting 2025-04-10 21:45:22 +02:00
Mario
29d4edb285 fix an obscure delivering issue which incidentally also fixes a delivering issue that required an ugly hack to work around
(cherry picked from commit 7c79ec9626)

Co-authored-by: Mario <mario@mariovavti.com>
2025-04-10 13:04:41 +00:00
Mario
7c79ec9626 fix an obscure delivering issue which incidentally also fixes a delivering issue that required an ugly hack to work around 2025-04-10 13:03:11 +00:00
Mario
66f793cb83 more fix downstream test for an upstream bug 2025-04-09 16:07:00 +00:00
Mario
6d926f4271 fix downstream test for an upstream bug 2025-04-09 15:47:21 +00:00
Mario Vavti
6ffd3fd9d4 composer update chillerlan/php-qrcode 2025-04-09 15:54:58 +02:00
Mario Vavti
3d204c782b --no-dev! 2025-04-09 15:47:23 +02:00
Mario Vavti
20f8239b44 composer update commerceguys/intl 2025-04-09 15:41:01 +02:00
Mario Vavti
10c2bd83d3 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-04-09 14:22:23 +02:00
Mario Vavti
4b02bd60cb composer update libs 2025-04-09 14:19:48 +02:00
Mario
50ea3afcb0 re-add red-koala.png which has been removed by accident 2025-04-09 10:43:57 +00:00
Mario
982d7540cc wrong ticks 2025-04-09 10:29:23 +00:00
Mario
b9aec78dde rename README > README.md 2025-04-09 10:26:00 +00:00
Mario
f5b1fda6b7 reorganize emojis and allow custom site emojis 2025-04-09 10:21:01 +00:00
Mario
4dfdb2b2e1 bump item.obj and item.target to mediumtext for mysql 2025-04-05 18:48:07 +00:00
Mario
a5a2d80c50 fix some plink for forum posts and comments 2025-04-05 15:55:58 +00:00
Mario
8da7fe8dbe whitespace 2025-04-04 15:44:04 +00:00
Mario
f64c5977f8 move weblink to after embedPhotos 2025-04-04 15:42:17 +00:00
Mario
a16e024b51 cleanup 2025-04-04 15:34:55 +00:00
Mario
860de5e28e bump version 2025-04-04 15:22:46 +00:00
Mario
b38da72535 move jot related functions to jot-header and some cleanup 2025-04-04 15:22:09 +00:00
Mario
2c4f1dcf03 use the syntax which allows image descriptions 2025-04-04 15:20:57 +00:00
Mario
0a1255518f bump version 2025-04-04 10:56:01 +00:00
Mario
a822e94f9b move jot popup handling to template, port photo selector to vanilla javascript and enable it for comments if applicable 2025-04-04 10:51:51 +00:00
Mario
484971c90a use png for hubzilla emoji 2025-04-04 07:15:23 +00:00
Mario
e11035acf4 optimize svg 2025-04-03 18:17:25 +00:00
Mario
3d522b99d8 add hubzilla emoji, make sure the compared term type is an integer 2025-04-03 18:12:23 +00:00
Mario
e62c4e6088 some emoji type tags do not have an id, we will use icon.url instead in those cases 2025-04-03 17:15:22 +00:00
Mario
703ccc2a9a this is required e.g. when relaying emoji reactions otherwise the relevant data will be missing 2025-04-03 12:01:11 +00:00
Mario
b2d09134c1 more smilies() fixes 2025-04-03 11:58:13 +00:00
Mario
de3f491966 make sure object actor is an array if we are going to use it 2025-04-03 11:57:25 +00:00
Mario
322a021765 for consistency use just the name as short name 2025-04-03 10:01:09 +00:00
Mario
d191b66bb8 move custom emoji rendering to smilies() 2025-04-03 09:55:59 +00:00
Mario
5241a159d2 bump version 2025-04-02 10:53:50 +00:00
Mario
fe8ae2f88e make sure we have an encoded activity before we go on building the packet, do not json_encode() a possibly empty item.target 2025-04-02 10:53:13 +00:00
Mario
3550609d29 do not return success if Libzot::fetch() did not return anything useful and remove redundant parameter $hub 2025-04-02 10:49:38 +00:00
OJ Randon
c6df3b0b97 fix stop of mysql 2025-04-02 11:38:22 +02:00
OJ Randon
e6ca21965b check if updates work 2025-04-01 13:39:41 +02:00
OJ Randon
c44c522d7d wording and confirmation that Raspi 5 is working 2025-04-01 01:10:16 +02:00
OJ Randon
f48bf8e366 fix certbot installation 2025-04-01 00:45:59 +02:00
OJ Randon
6e1cdebbf4 use https for selfhost updater (dyn dns) 2025-04-01 00:45:10 +02:00
Mario
eb592bb741 bump version 2025-03-28 20:49:27 +00:00
Mario
db5d67a4e0 cleanup deprecated forum queries and possibly improved performance 2025-03-28 20:46:17 +00:00
Mario
6e390a06e1 remove deprecated emojiReaction 2025-03-28 20:43:08 +00:00
Mario
295d5f06dc lazy load profile images for likes and remove zid function for the profile image src attribute
(cherry picked from commit 30d552255e)

Co-authored-by: Mario <mario@mariovavti.com>
2025-03-28 13:31:47 +00:00
Mario
30d552255e lazy load profile images for likes and remove zid function for the profile image src attribute 2025-03-28 13:29:43 +00:00
Mario
0522bd5593 include unapproved connections in deliverable_abook_xchans(). here is why: if they are at a hub, where an approved connection already exists, they will already receive the message since our defaultult permission allows view_stream. If view_stream is not allowed they will be filtered later in the process. We will however exclude blocked connections (approved or unapproved) already here now. 2025-03-27 12:43:53 +00:00
Mario
a46d837267 minor cleanup 2025-03-27 10:31:07 +00:00
Mario
bee493f628 remove redundant variables and use document.body.clientWidth instead of rounded window.innerWidth 2025-03-26 11:20:11 +00:00
Mario
a4f4a082af fix another js error on small screens and use const instead of let where applicable 2025-03-25 10:38:00 +00:00
Mario
dd9ab07044 restrict access to tool to local channels 2025-03-24 09:11:26 +00:00
Mario
afd811a875 more deprercate jquery 2025-03-23 14:14:19 +00:00
Mario Vavti
122d46b79b use the new version of unparse_url() and fall through to destination if nothing before applied - otherwise remote redirects will fail (e.g. being logged in to a remote server and vewing a linked image with an attached zid at another server) 2025-03-22 18:18:55 +01:00
Mario
36448adad4 minor refactor 2025-03-21 16:58:27 +00:00
Mario
8f93d9aa75 do not check length, it will not be there if the var is null 2025-03-21 11:33:56 +00:00
Mario
76f50d7150 fix some js errors on mobile devices 2025-03-21 11:30:40 +00:00
Mario
80c9880a67 do not include our own activities in unseen forum notifications 2025-03-20 13:39:32 +00:00
Mario
d1f54507f6 Disable browser rotating image based on EXIF metadata. We remove EXIF data for thumbnails but not for the original files. If the preview image has different orientation than the original size it has a strange effect when viewing. 2025-03-20 13:12:45 +00:00
Mario
334852d733 bump version 2025-03-18 08:15:30 +00:00
Mario
362be52be0 version 10.2.1 2025-03-18 08:10:15 +00:00
Mario
20f5e654ad changelog
(cherry picked from commit 34b2bdcf2c)

Co-authored-by: Mario <mario@mariovavti.com>
2025-03-18 08:09:03 +00:00
Mario
34b2bdcf2c changelog 2025-03-18 08:08:14 +00:00
Mario
8c38ee8208 fix sse_bs query 2025-03-18 08:00:37 +00:00
Mario
2c1c12825d we require the HTTP signature to be set in the HTTP_AUTHORIZATION field somewhere down the line (probably in Web/HTTPSig). Make sure it is there.
(cherry picked from commit 5188b9cef5)

Co-authored-by: Mario <mario@mariovavti.com>
2025-03-18 07:58:14 +00:00
Mario
5188b9cef5 we require the HTTP signature to be set in the HTTP_AUTHORIZATION field somewhere down the line (probably in Web/HTTPSig). Make sure it is there. 2025-03-18 07:52:39 +00:00
Mario
8c0b7ce4de Merge branch 'help_davs' into 'dev'
access cloud files under linux using davs

See merge request hubzilla/core!2190
2025-03-17 20:02:25 +00:00
Mario
17d0d6f75d Merge branch 'dedup-head_get_icon' into 'dev'
Remove duped head_get_icon function

See merge request hubzilla/core!2191
2025-03-17 20:00:58 +00:00
Mario
bbcf7e9aa1 Merge branch '10.2RC' 2025-03-17 19:39:51 +00:00
Mario
45a2ebc662 version 10.2 2025-03-17 19:33:32 +00:00
Mario
aece22aee6 Merge branch 'dev' into 10.2RC 2025-03-17 19:32:36 +00:00
Mario
9904eba277 update changelog 2025-03-17 19:32:10 +00:00
Mario
7c0f98a513 Merge branch 'dev' into 10.2RC 2025-03-17 19:30:39 +00:00
Mario
8d25b6eae4 changelog 2025-03-17 19:23:30 +00:00
Mario
9369085835 Merge branch 'dev' into 10.2RC 2025-03-17 19:20:55 +00:00
Harald Eilertsen
059113d2a8 Remove duped head_get_icon function
This function was existing both as a static function in the App class,
and as a standalone global function. While only the standalone function
was used, this patch changes the callsite to use the static function in
the App class instead, and removed the global variant.

Note: While unlikely, this _could_ break some addons or custom themes
_if_ they call the global head_get_icon function themselves. I have not
found any addons or themes that do so.

This patch also fixes an issue where an incorrect url would be produced
if the URL set by App::head_set_icon would start with '://' for some
reason.

Also added doc comments for both App::head_set_icon and
App::head_get_icon.
2025-03-17 20:17:54 +01:00
OJ Random
f60dff788e access cloud files under linux using davs 2025-03-17 19:03:19 +01:00
Mario
9c20b4809a an attempt to fix no notifications for likes on our comments - beause it came up in the support forum. also some minor cleanup 2025-03-17 08:57:15 +00:00
Mario
00b3039b6e Merge branch 'dev' into 10.2RC 2025-03-16 11:16:31 +00:00
Mario
2695094d16 fix fullscreen view 2025-03-16 11:16:04 +00:00
Mario
bcfdb73001 Merge branch 'dev' into 10.2RC 2025-03-14 10:52:17 +00:00
Mario
1650809cd8 update changelog 2025-03-14 10:51:40 +00:00
Mario
991815469f Merge branch 'dev' into 10.2RC 2025-03-14 10:49:50 +00:00
Mario
c5fb8eafac allow to send signed requests from mod zot_probe 2025-03-12 19:15:28 +00:00
Mario
a0c98e070e Merge branch 'dev' into 10.2RC 2025-03-09 16:14:46 +00:00
Mario
7d6202be13 wrong logic 2025-03-09 16:13:47 +00:00
Mario
4ba470318c Merge branch 'dev' into 10.2RC 2025-03-09 10:09:47 +00:00
Mario
e948aaf751 changelog 2025-03-09 10:06:53 +00:00
Mario
3789017ca0 print an ugly error message and the destination if OWA failed for some reason 2025-03-09 10:03:07 +00:00
Mario
48f5acced3 remove leading @ 2025-03-09 10:00:53 +00:00
Mario
13e2d2f654 css fix
(cherry picked from commit 8d45fd36a1)

Co-authored-by: Mario <mario@mariovavti.com>
2025-03-07 09:02:29 +00:00
Mario
8d45fd36a1 css fix 2025-03-07 09:01:48 +00:00
Mario
6ed2301a94 bump version 2025-03-07 08:54:59 +00:00
Mario
a0eb701503 Merge branch 'dev' into 10.2RC 2025-03-07 08:54:06 +00:00
Mario
39f9a38b23 css fix 2025-03-07 08:51:26 +00:00
Mario
590c0ea778 add pdl file for mod rmagic 2025-03-07 08:43:17 +00:00
Mario
f36d8e4bd2 fix fatal error if variable is an empty string 2025-03-07 08:38:33 +00:00
Mario
4e3bec8a35 streamline login pages layout - fix issue #1892 2025-03-07 08:30:43 +00:00
Mario
eec918bf4a escape tags on xchan name and cleanup baseurl/site_url variables which should be the same 2025-03-06 11:42:25 +00:00
Mario
13002af4c3 version 10.2RC1 2025-03-06 10:00:21 +00:00
Mario
40c63a7f12 changelog 2025-03-06 09:57:49 +00:00
Mario
3d0621eb8c remove superfluous file 2025-03-06 09:17:55 +00:00
Mario
030c02dfdc boxy alignment 2025-03-05 17:03:31 +00:00
Mario
00c1509549 update string to match with the autotime string 2025-03-05 16:42:25 +00:00
Mario
8122c40252 bump dev version 2025-03-05 10:22:46 +00:00
Mario
787c63b7ae version 10.2RC and strings 2025-03-05 10:17:39 +00:00
Mario
ee988edc83 make sure attachment is an array
(cherry picked from commit 2b4b409c01)

Co-authored-by: Mario <mario@mariovavti.com>
2025-03-03 08:56:30 +00:00
Mario
a71f5e123a Debianinstall
(cherry picked from commit cf408c3fac)

34e867cf provide a simplified automated installation as we had years ago
266df96c a) php version for max uplaod sizes b) hubzilla is the only option
c4d340d1 fixed installation of addons
b80a8a01 added composer
f1961884 composer: do not download again but install in any case
96710d83 help: default database name and user
ecf35537 fix composer
2d2bf751 main differences to homeinstall script
dcca3cab changed disclaimer
6c65c17f removed set path to convert because it does not have to be changed
ed77bfb5 email verification
93f85913 environments
00dd3bdd Debian 12 again
10223ef7 extra headings
f528a959 wording
18565bb2 sury instead of Debian repo
bc07f0c4 Merge remote-tracking branch 'origin/dev' into dev
38743496 fixed php install and db creation
d08bb5e6 fixed variable for creating db
b1cc4f4f do not care about more then one single webserver installed
8b0ec26a Merge branch core:master into dev
88e3522d Merge branch 'debianinstall' into dev

Co-authored-by: OJ Random <ojrandom@protonmail.com>
2025-03-03 08:41:11 +00:00
Mario
7579749adc Merge branch 'debianinstall' into 'master'
Debianinstall

See merge request hubzilla/core!2179
2025-03-03 08:40:29 +00:00
OJ Random
cf408c3fac Debianinstall 2025-03-03 08:40:29 +00:00
Mario
0c97792ca7 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-02-28 20:29:08 +00:00
Mario
84d63b3b67 fix $owner_hash not set correctly when editing and some whitespace fixes 2025-02-28 20:28:49 +00:00
Mario Vavti
63aa50eb8d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-02-26 16:37:38 +01:00
Mario Vavti
7fb13f23fe fix docu 2025-02-26 16:37:22 +01:00
Mario
65156a0e4d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-02-26 15:33:05 +00:00
Mario
e3eebcd95d calculate observer.baseurl from xchan_url since xchan_connurl is only set for zot xchans 2025-02-26 15:32:36 +00:00
Mario Vavti
9eff1a08d4 refactor unparse_url() to allow to return a custom field set only and add tests 2025-02-26 16:26:40 +01:00
Mario
cfcac590c3 refine text 2025-02-26 12:57:38 +00:00
Mario
872415bffe fix an issue where some participants could not post to forums 2025-02-26 12:52:27 +00:00
Mario
a46b781664 slightly improve event object rendering 2025-02-22 14:43:25 +00:00
Mario
b77fac43c8 feedutils: fix php warnings and style 2025-02-21 09:51:59 +00:00
Mario
2b4b409c01 make sure attachment is an array 2025-02-20 11:27:46 +00:00
Mario
67aa547c48 bump version 2025-02-20 11:09:57 +00:00
Mario Vavti
e288f33776 looks like we now require vendor/symfony for production 2025-02-20 12:05:50 +01:00
Mario Vavti
a5aab4c30e Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-02-20 11:44:54 +01:00
Mario Vavti
cf7613b3e0 composer --no-dev 2025-02-20 11:44:00 +01:00
Mario
fa01a2b348 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-02-20 10:36:58 +00:00
Mario Vavti
65c8de3410 update to smarty v5 2025-02-20 11:35:33 +01:00
Mario Vavti
d9b262348f update composer libs 2025-02-20 11:29:06 +01:00
Mario
ea9d2a0acf prefer contextHistory over context 2025-02-19 09:46:52 +00:00
Mario
5d55006be8 Merge branch 'replace-epub-thumbnail-code' into 'dev'
Replace Epub thumbnail generation with our own code

See merge request hubzilla/core!2186
2025-02-14 15:06:25 +00:00
Mario
d9ced0c6bf Merge branch 'update-gitignore' into 'dev'
Exclude test results and PHPStan from git

See merge request hubzilla/core!2188
2025-02-14 14:58:26 +00:00
Mario
8d4d1b17c7 Merge branch 'cherry-pick-10e2fbb2' into 'dev'
Update Spanish strings

See merge request hubzilla/core!2187
2025-02-14 14:58:07 +00:00
Mario
453f6a08a3 Merge branch 'highlight_mark_button3' into 'dev'
Highlight_mark_button3

See merge request hubzilla/core!2185
2025-02-14 14:56:17 +00:00
Rocky
b6560e5456 Highlight_mark_button3 2025-02-14 14:56:17 +00:00
Mario
b805f48c32 revert adding of additional sort field which was added for testingg 2025-02-13 18:57:43 +00:00
Harald Eilertsen
33b78a4943 Exclude test results and PHPStan from git 2025-02-13 16:02:35 +01:00
Manuel Jiménez Friaza
48b187ccd8 Update Spanish strings
(cherry picked from commit 10e2fbb22c6369c9ef6cbc6f943ff6878206e9fb)

Co-authored-by: mjfriaza:4GF~eYj,-iAv <mjfriaza@disroot.org>
2025-02-13 14:11:13 +00:00
Mario
f680bba3e6 select navbar by id to avoid conflict with possible additional navbars 2025-02-13 10:18:12 +00:00
Harald Eilertsen
09aabc6b41 Remove dependency on PHP EpubMeta library. 2025-02-12 20:05:42 +01:00
Harald Eilertsen
0dd456c653 Replace the the code to extract epub thumbnails
The PHP Epub Meta library has a dependency that prevents deployment on
32bit architectures. We also don't need all the functionality in that
library, so this patch replaces it with our own simplified code for
fetching the cover embedded in Epub archives.

We also expand the test suite and clean up some minor issues in the
Epubthumbnail class.
2025-02-12 20:05:42 +01:00
Harald Eilertsen
97ba14cbe0 Configue gd for jpeg support in CI
For some reason the gd build did not find libjpeg, even though it was
installed in the image. We will need jpeg support for testing the
thumbnail generation, so this patch adds the required configuration.
2025-02-12 20:01:45 +01:00
Mario Vavti
ee6367a549 bump version 2025-02-11 19:15:15 +01:00
Mario Vavti
fc52d1b44f exclude uplinked items from those queries since they are unlikely to be the originals (sourced items from a channel at the same hub) 2025-02-11 19:14:11 +01:00
Mario Vavti
bfce562a46 start sending contextHistory along with context 2025-02-11 17:52:26 +01:00
Mario Vavti
8d8a7f44e1 bump version 2025-02-01 12:36:54 +01:00
Mario Vavti
6c8da6ce36 version 10.0.8 2025-02-01 12:30:15 +01:00
Mario
e19a050b92 changelog
(cherry picked from commit a13bf6a3fe)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-02-01 11:28:04 +00:00
Mario Vavti
a13bf6a3fe changelog 2025-02-01 12:26:49 +01:00
Mario
0edf761499 Merge branch 'owa-error-messages' into 'dev'
Add error message on missing owa auth headers

See merge request hubzilla/core!2183
2025-02-01 10:53:12 +00:00
Mario
bf76d5981f Merge branch 'testing-add-psr4-namespace' into 'dev'
Add Zotlabs\Tests namespace to autloader in dev

See merge request hubzilla/core!2182
2025-02-01 10:50:44 +00:00
Mario
33fcb43173 Merge branch 'dba_pdo-insert-and-update' into 'dev'
Add an insert and update methods to dba_pdo

See merge request hubzilla/core!2181
2025-02-01 10:49:47 +00:00
Mario
ffae47f523 Merge branch 'highlight_button' into 'dev'
add highlight/mark button

See merge request hubzilla/core!2180
2025-02-01 10:35:03 +00:00
Rocky
c07cdb30fa add highlight/mark button 2025-02-01 10:35:03 +00:00
Mario
546c4fcad2 calling fetch_post_tags() will add duplicate items here
(cherry picked from commit 0a17b83578)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-02-01 00:03:50 +00:00
Mario Vavti
0a17b83578 calling fetch_post_tags() will add duplicate items here 2025-02-01 01:02:06 +01:00
Mario
2782b6d724 possible sql performance improvements
(cherry picked from commit dc076a4c00)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-30 12:10:45 +00:00
Mario Vavti
dc076a4c00 possible sql performance improvements 2025-01-30 13:09:04 +01:00
Harald Eilertsen
a550c7c853 Add error message on missing owa auth headers
If the /owa endpoint received a request with a missing or invalid
Authorization header, it would return an error to the requester, but
without any message describing why it failes.

This patch adds a message to the error response, so that it will be a
bit easier to debug these issues in the future.

The owa spec includes a 'message' field in the error response, but makes
it optional. Any conforming implementations should accept a response
that includes the 'message' field.
2025-01-29 18:41:40 +01:00
Harald Eilertsen
7a3d59bff3 Add Zotlabs\Tests namespace to autloader in dev
This is technically not needed, as we load the required classes in the
bootstrap file (`tests/unit/bootstrap.php`), but it helps editors that
integrate with language servers etc to find the classes so it does not
flag errors everywhere.
2025-01-29 15:56:17 +01:00
Harald Eilertsen
82a3b71a51 Fix broken DbaPdo test on postgresql 2025-01-29 13:24:12 +01:00
Harald Eilertsen
e39b2eb7b9 Add an dba_pdo::update method
This is a convenience funcition to make it easier to update an existing
row in a database table.
2025-01-29 12:42:44 +01:00
Harald Eilertsen
9f8248cc9c Use returning clause on dba_pdo::insert where supported
By using the returning clause when inserting a new record, we get back
the inserted record right away; thus saving us an extra roundtrip to the
database.

Both PostgreSQL and MariaDB supports this clause, but MySQL don't. In
that case we fall back to manually fetching the last inserted row.
2025-01-29 12:42:44 +01:00
Harald Eilertsen
71e4326606 Fetch the server version on dba_pdo::connect.
The server version string is useful to among other things check whether
we are running on a real MySQL system, or MariaDB. Instead of fetching
it every time we need it, cache it in the dba_pdo object when we connect
to the db.
2025-01-29 12:42:44 +01:00
Harald Eilertsen
7eb6f9b11d Only skip DbaPdo returning test on actual MySQL
MySQL does not support the INSERT...RETURNING clause, while MariaDB
does. This patch ensures that the test is not skipped on MariaDB, but
only on an actual MySQL system.
2025-01-29 12:42:44 +01:00
Harald Eilertsen
4625ffa6b4 Fix return value from dba_pdo::q()
According to the documentation, this function should never return null.
Still that's what it did if a non-select query raised a PDOException.
This patch fixes this, so that it so that the function conforms to the
docs.
2025-01-29 12:42:44 +01:00
Harald Eilertsen
3e6a646603 Add an insert method to dba_pdo
A common use case is to insert a record into a database table, but also
instantiate an object from the inserted data. This requires that we know
the value of any default or calculated columns that is filled in by the
database when the row is inserter.

This patch adds a `insert` method to pda_dbo that will insert a row, and
immediately fetch the row back from the database – including the default
and calculated values not specified by the insert itself.
2025-01-29 12:42:36 +01:00
Mario
324b281813 fix php warniing in case tgt_type is not set
(cherry picked from commit 03d1f3383e)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-24 12:16:33 +00:00
Mario Vavti
03d1f3383e fix php warniing in case tgt_type is not set 2025-01-24 13:10:46 +01:00
Mario
69a23c604d return if $furl is empty for some reason
(cherry picked from commit 174469970a)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-24 11:44:34 +00:00
Mario Vavti
174469970a return if $furl is empty for some reason 2025-01-24 12:43:12 +01:00
Mario Vavti
89b254dc1c add target and tgt_type tou sourced rss items if we rewrite them to our own 2025-01-24 00:11:26 +01:00
Mario Vavti
8e51988e96 unescape_tags() on URLs before we start messing with them 2025-01-23 21:24:06 +01:00
Mario Vavti
52e279f443 fix auto save draft not set correctly and use round instead of ceil for cover height calculation 2025-01-23 19:08:58 +01:00
Mario Vavti
4efa853690 tagsinput still requires jquery 2025-01-23 13:08:13 +01:00
Mario Vavti
9b13055dfe version 10.0.7 2025-01-22 13:08:42 +01:00
Mario
06afd8a375 changelog
(cherry picked from commit 27efb887d2)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-22 11:24:32 +00:00
Mario
6f027544d6 make sure to provide uid to drop_item() where applicable and check ownership when imporing feed items
(cherry picked from commit ccd52584a4)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-22 11:22:15 +00:00
Mario Vavti
2d2c9fa519 bump version 2025-01-22 11:50:46 +01:00
Mario Vavti
27efb887d2 changelog 2025-01-22 11:48:51 +01:00
Mario Vavti
ccd52584a4 make sure to provide uid to drop_item() where applicable and check ownership when imporing feed items 2025-01-22 10:43:33 +01:00
Mario Vavti
ab0fdb13d4 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2025-01-17 12:38:22 +01:00
Mario Vavti
2bca44ed25 bump version 2025-01-17 12:38:08 +01:00
Mario Vavti
eab08d0bcb rewrite redbasic javascript without jquery 2025-01-17 12:37:21 +01:00
Mario
d3f00704bd Merge branch 'add-security-policy' into 'dev'
Proposing a security policy.

See merge request hubzilla/core!2164
2025-01-16 12:29:57 +00:00
Harald Eilertsen
1e1a7109a9 Proposing a security policy. 2025-01-16 12:29:57 +00:00
Mario
ebab5ff281 use bin2hex() instead of btoa() to create an id for the toast. btoa() will not work with nonascii chars.
(cherry picked from commit 0165f44063)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-15 12:00:01 +00:00
Mario Vavti
0165f44063 use bin2hex() instead of btoa() to create an id for the toast. btoa() will not work with nonascii chars. 2025-01-15 12:50:45 +01:00
Mario
5fb6e5d6f7 fix regression in notifications filter
(cherry picked from commit 8fc0e41beb)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-06 09:15:59 +00:00
Mario Vavti
8fc0e41beb fix regression in notifications filter 2025-01-06 10:14:54 +01:00
Mario Vavti
3ad63a6e82 bump version 2025-01-05 13:40:29 +01:00
Mario Vavti
5a84ffdcda version 10.0.6 2025-01-05 13:31:28 +01:00
Mario
ad993645be changelog
(cherry picked from commit 392cb020aa)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-05 12:30:32 +00:00
Mario Vavti
392cb020aa changelog 2025-01-05 13:29:21 +01:00
Mario
0701cde239 dismiss entries where primary location data is not complete for some reason
(cherry picked from commit 884b612ffc)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-05 11:56:51 +00:00
Mario
a136c288d5 cleanup outdated doc entries just once after the docs were imported to the db
(cherry picked from commit ae0d138d2a)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-05 11:56:09 +00:00
Mario Vavti
884b612ffc dismiss entries where primary location data is not complete for some reason 2025-01-05 12:40:56 +01:00
Mario Vavti
ae0d138d2a cleanup outdated doc entries just once after the docs were imported to the db 2025-01-05 11:00:48 +01:00
Mario
1624a2620a remove redundant arguments
(cherry picked from commit 48ef4744ac)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2025-01-04 10:20:40 +00:00
Mario Vavti
48ef4744ac remove redundant arguments 2025-01-04 11:19:03 +01:00
Mario Vavti
a17cb75baf bump version 2024-12-29 17:42:53 +01:00
Mario Vavti
f4769d0f04 version 10.0.5 2024-12-29 17:36:28 +01:00
Mario Vavti
c8e30a00e2 Merge branch 'dev' 2024-12-29 17:35:44 +01:00
Mario Vavti
169c971cb1 changelog 2024-12-29 17:35:10 +01:00
Mario Vavti
51745d3652 Merge branch 'dev' 2024-12-29 17:18:04 +01:00
Mario Vavti
3ebbb91ae9 pass uid to drop_item() to ensure we will have permission to actually drop the item 2024-12-29 17:17:22 +01:00
Mario
762d402dea Merge branch 'dev' 2024-12-26 09:00:33 +00:00
Mario
051cef79fc changelog 2024-12-26 09:00:02 +00:00
Mario
b05a440f03 version 10.0.4 2024-12-26 08:58:46 +00:00
Mario
9bb4988eda Merge branch 'dev' 2024-12-26 08:55:36 +00:00
Mario
f66f0e398b missing argument name 2024-12-26 08:54:58 +00:00
Mario
49cb73c8c7 version 10.0.3 2024-12-26 08:04:05 +00:00
Mario
2a00bd9a28 Merge branch 'dev' 2024-12-26 08:03:26 +00:00
Mario
553b3f6faa changelog and bump version 2024-12-26 08:02:29 +00:00
Mario
2980827925 fix another possible loop 2024-12-26 07:55:08 +00:00
Mario
45a78dcbc0 this should fix the infinite loop caused by a regression in Daemon/Expire 2024-12-25 20:53:32 +00:00
Mario
5813b65aed hotfix release version 10.0.2 2024-12-25 12:03:43 +00:00
Mario
f8acd1d3a5 Merge branch 'dev' 2024-12-25 12:02:32 +00:00
Mario
c9ebb23b69 hotfix for loop caused in Daemon/Expire 2024-12-25 12:00:27 +00:00
Mario
bc998eacd0 bump version 2024-12-22 17:40:41 +00:00
Mario
648979467a do not allow a new zid to override an existing remote login - otherwise a prfactored request with an added zid can log us out 2024-12-22 17:39:58 +00:00
Mario
5c0ff6f584 once more improved imagesLoaded() 2024-12-22 17:35:25 +00:00
Mario
632721da4e version 10.0.1 2024-12-22 08:51:48 +00:00
Mario
f3a702e927 Merge branch 'dev' 2024-12-22 08:51:15 +00:00
Mario
58985f2200 update changelog 2024-12-22 08:51:04 +00:00
Mario
c55662510d fetch missing commit from dev 2024-12-22 08:31:04 +00:00
Mario
f01e917fff Merge branch 'dev' 2024-12-22 08:26:26 +00:00
Mario
3940187d19 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-12-22 08:20:24 +00:00
Mario
1215e8a030 Revert "Drop obsolete library LightOpenID"
This reverts commit e516c1352f
2024-12-22 08:19:55 +00:00
Mario
5b6e27233a fix sql error 2024-12-22 08:15:16 +00:00
Mario
b80cba4e68 Merge branch '10.0RC' 2024-12-21 18:49:06 +00:00
Mario
f2b28f5bbb version 10.0 2024-12-21 18:46:40 +00:00
Mario
4aeb4963a4 Merge branch 'dev' into 10.0RC 2024-12-21 18:44:04 +00:00
Mario
de9b10e850 more changelog 2024-12-21 18:43:41 +00:00
Mario
36a1d98c52 changelog 2024-12-21 18:09:56 +00:00
Mario
cf66f245b4 RC2 2024-12-21 12:34:05 +00:00
Mario
b1f2f67a04 better pubs notofication fiy and also fix a javascript error and remove last bit of jquery from notifications 2024-12-21 12:07:31 +00:00
Mario
bd10c1e40a fix anomaly in pubs notification 2024-12-21 11:55:19 +00:00
Mario
e146eaa8f8 bump version 2024-12-21 10:28:07 +00:00
Mario
92e21c4f3d deduplicate the images array by src 2024-12-21 10:27:28 +00:00
Mario
55265c8a3e track processed images 2024-12-20 20:53:47 +00:00
Mario
c3cc624621 bump version 2024-12-20 19:13:21 +00:00
Mario
b466932e37 improved imagesLoaded() and formatting 2024-12-20 19:12:09 +00:00
Mario
a3248e8b3b version 2024-12-20 12:36:00 +00:00
Mario
9ec2db7c97 port scrollToItem() to vanilla js and more fixes 2024-12-20 12:35:29 +00:00
Mario
9bd94287dd improved imagesLoaded() and notifications fixes 2024-12-20 11:47:38 +00:00
Mario
faca95b21c bump version 2024-12-19 23:18:59 +00:00
Mario
79f8b06ede various fixes for the last commit 2024-12-19 23:17:56 +00:00
Mario
a2dde34b1b refactor notifications widget and updateConvItems() to not require jquery 2024-12-19 18:49:07 +00:00
Mario
fb5824417e Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-12-19 10:37:44 +00:00
Mario
804b4effa2 changelog 2024-12-19 10:37:19 +00:00
Mario Vavti
4c8e1de4c6 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-12-13 10:09:07 +01:00
Mario
d9c69b747d bump dev version 2024-12-13 09:07:55 +00:00
Mario Vavti
0e4be679e4 composer dump autoload 2024-12-13 09:59:31 +01:00
Mario
14360c4735 version 10.0RC and strings 2024-12-13 08:49:18 +00:00
Mario
2da55d3bd8 remove jquery.timeago.js in favor of a native js implementation 2024-12-12 14:18:55 +00:00
Mario Vavti
e9222d0d9a add test for item_forwardable() 2024-12-10 22:45:56 +01:00
Mario
93f72a53f5 introduce item_forwardable() and check it before we call the notifier to possibly safe some processes - test will follow, also add some other possibly blocking flags to the add item 2024-12-10 10:27:48 +00:00
Mario
93c4bd4692 pubcrawl: support for inbound add/remove activities and minor cleanup 2024-12-10 09:22:17 +00:00
Mario
486c21b519 hq: improved file filtering 2024-12-09 08:42:01 +00:00
Mario
7785487d77 fix delayed post handling in cron, always set item_delayed if we select a create date 2024-12-08 22:46:21 +00:00
Mario
9756023e39 fix expiration 2024-12-07 23:25:59 +00:00
Mario Vavti
bb0a22ee58 add test for relative_time() 2024-12-07 23:49:17 +01:00
Mario
e88ae54bef add more indicators and a new function to return relative time in the past and the future 2024-12-07 20:41:13 +00:00
Mario
d37d181d94 Libzot: remove commented code which duplicates code in Activity::decode_note() 2024-12-07 19:43:17 +00:00
Mario
d59d808883 more cleanup 2024-12-07 19:38:18 +00:00
Mario
b59fe77906 provide a comments disabled indicator and some cleanup 2024-12-07 19:34:30 +00:00
Mario
1941b4f026 only allow disable_comments on thread top 2024-12-07 18:40:56 +00:00
Mario
5c82229e34 Ãfix issue where poll updates were dismissed due to missing edited update, fix wrong array key when retaining item, update dreport push to also push the related item 2024-12-06 23:31:49 +00:00
Mario
66d502d8e1 an attempt to fix some comments on/off anomalies 2024-12-06 19:24:14 +00:00
Mario
66acfc66ce set item_type so that notifier can do the right thing 2024-12-06 11:41:01 +00:00
Mario
2e13640ab4 wrong class 2024-12-05 13:14:07 +00:00
Mario
277b4f7d10 even more fa2bi 2024-12-05 13:08:48 +00:00
Mario
edf2a6db1b we use the chat-quote icon for forums throughout the app. basically because the forum posts a quote of the original post 2024-12-05 13:02:18 +00:00
Mario
8ad000ec70 more fa2bi issues 2024-12-05 12:42:37 +00:00
Mario
563628fef8 another fa2bi issue 2024-12-05 12:33:55 +00:00
Mario
15b6353c1c filtering censored xchans in mod pubstream queries has possible performance issues. we will filter them in process_delivery() instead 2024-12-05 11:27:56 +00:00
Mario
1a86348a6c Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-12-02 09:23:16 +00:00
Mario
a80ab5887c also copy the item_restrict field to the add activity and check for this field in the notifier 2024-12-02 09:17:15 +00:00
Mario
475ae7ba13 Merge branch 'fix/chat-icon-fix' into 'dev'
Fixed notification icons in chat

See merge request hubzilla/core!2177
2024-12-02 09:15:32 +00:00
SK
e107298125 Fixed notification icons in chat 2024-12-02 04:32:48 +05:30
Mario
428ffa5e35 save a loop by ordering results by item_wall and more uuid only lookup 2024-11-28 15:34:16 +00:00
Mario
0bffe6e019 sql lookup by uuid should be sufficient by now, remove superfluous require_once() 2024-11-28 15:12:57 +00:00
Mario Vavti
9e2f3dc05f fix more issues reported by phpstan 2024-11-27 10:25:37 +01:00
Mario
9fa18a5557 Merge branch 'phpstan-ignore-some-warnings' into 'dev'
phpstan: Ignore warnings on missing return statement.

See merge request hubzilla/core!2175
2024-11-27 08:18:58 +00:00
Mario
9608ab27c4 Merge branch 'dev' into 'dev'
updated fork-awesome icons to bootstrap

See merge request hubzilla/core!2174
2024-11-27 08:18:09 +00:00
Mario
464b331deb Merge branch 'module-admin-accounts-enhancements' into 'dev'
Fix and refactor module Admin\Accounts part I

See merge request hubzilla/core!2173
2024-11-27 08:15:59 +00:00
Harald Eilertsen
0189d04614 Fix and refactor module Admin\Accounts part I 2024-11-27 08:15:59 +00:00
Mario
cbb3ad1620 make sure to toggle aside if a notification or message is clicked and some whitespace cleanup 2024-11-26 09:57:55 +00:00
Harald Eilertsen
c0f9d55cfb phpstan: Ignore warnings on missing return statement.
While some of these may be fixable without too much hassle, quite a few
of them will possibly require architectural restructuring. We should
revisit these, but let's silence them for now.
2024-11-25 13:11:58 +01:00
Mario
0da51e0f71 fix superfluous slash in some cases 2024-11-25 08:11:33 +00:00
SK
9014a288b0 updated fork-awesome icons to bootstrap 2024-11-22 18:49:13 +05:30
Mario
dcef9f61b5 remove logging 2024-11-22 10:28:21 +00:00
Mario
3d80db0cdc Merge branch 'add-mailer-class' into 'dev'
Add Zotlabs\Lib\Mailer class to replace z_mail function.

See merge request hubzilla/core!2172
2024-11-22 09:59:14 +00:00
Harald Eilertsen
3a2f787f96 Add Zotlabs\Lib\Mailer class to replace z_mail function. 2024-11-22 09:59:14 +00:00
Mario
f7a9b84943 mod cal: if a day is provided default to week view except the date has a ! prepended 2024-11-21 09:36:31 +00:00
Mario
46e6600169 mod cal: provide a possibility to link to a specific month or day by passing a fragment 2024-11-21 09:04:55 +00:00
Mario
243a2a9bdf Update chat.tpl to correct expand and contract icons from forkawesome to bootstrap icons.
(cherry picked from commit c626985448)

Co-authored-by: Saiwal K <sk@utsukta.org>
2024-11-19 21:08:55 +00:00
Mario
91baa52b8b Merge branch 'saiwal-master-patch-76831' into 'master'
Update chat.tpl to correct expand and contract icons from forkawesome to bootstrap icons.

See merge request hubzilla/core!2171
2024-11-19 21:08:32 +00:00
Harald Eilertsen
5338793883 Ubreak tests: update MagicTest for new behaviour of Magic module. 2024-11-19 11:10:49 +01:00
Mario Vavti
9acc73b273 some cleanup for mod magic 2024-11-18 23:15:29 +01:00
Saiwal K
c626985448 Update chat.tpl to correct expand and contract icons from forkawesome to bootstrap icons. 2024-11-17 19:59:31 +00:00
Mario Vavti
5cfb3842f1 more phpstan errors 2024-11-17 20:52:13 +01:00
Mario Vavti
25b089c1a9 fix some errors detected by phpstan 2024-11-17 16:17:05 +01:00
Mario
67a9292aaa Merge branch 'issue-1879-emails-with-plus-addressing-rejected' into 'dev'
Fix #1879: Emails with + in local part was rejected.

See merge request hubzilla/core!2170
2024-11-17 10:26:25 +00:00
Mario
81dda15669 fix undefined variables 2024-11-17 07:58:11 +00:00
Harald Eilertsen
5b7f8d986c Fix #1879: Emails with + in local part was rejected. 2024-11-16 13:45:36 +01:00
Mario
5dee600735 Merge branch 'add-dev-dependecy-phpstan' into 'dev'
Add PHPStan as a developer dependency.

See merge request hubzilla/core!2169
2024-11-14 18:45:29 +00:00
Mario
01da60b385 Merge branch 'various-phpstan-issues' into 'dev'
Several issues discovered by PHPStan

See merge request hubzilla/core!2168
2024-11-14 18:40:15 +00:00
Harald Eilertsen
951800eca6 Several issues discovered by PHPStan 2024-11-14 18:40:15 +00:00
Mario
72c47cd8db version 9.5.2 - merge containers 2024-11-14 17:14:15 +00:00
Mario
e3a8668c32 Merge branch 'dev' into containers 2024-11-14 17:09:22 +00:00
Mario
fd9977eada css fixes 2024-11-14 14:22:18 +00:00
Mario
bd3304ff94 Merge branch 'oops-fix-db-update' into 'dev'
Fix invocation of DB_Update::run.

See merge request hubzilla/core!2167
2024-11-14 13:32:48 +00:00
Mario
586cda5155 fix some conent import issues
(cherry picked from commit c9a8914b07)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-11-14 13:30:07 +00:00
Mario Vavti
c9a8914b07 fix some conent import issues 2024-11-14 12:47:40 +01:00
Mario
b21b9260d9 fix race condition when updating multiple choice polls 2024-11-13 14:01:14 +00:00
Mario
b5c07e4c01 this is not true anymore - check owner perms 2024-11-13 11:08:18 +00:00
Harald Eilertsen
28b5b0cab5 Add PHPStan as a developer dependency.
PHPStan is a static PHP code analyzer that's aimed at finding actual
bugs in the code. Where PHP Code Sniffer is about codeing standards,
PHPStan is about correctness of code.

The provided configuration file (`phpstan.neon.dist`) is configured to
use the _lowest_ level of checks that PHPStan will report on. See
https://phpstan.org/user-guide/rule-levels for information about the
various rule levels.

Run an analysis of the code base like this:

    % ./vendor/bin/phpstan

It will output any found issues to stdout.

You can also run it like this:

    % ./vendor/bin/phpstan --error-format=raw > phpstan.log

This will give you an output file in a format that's suitable for use
with typical editors for mapping errors to source locations.
2024-11-12 09:42:11 +01:00
Mario
39d0a3f1f6 containers: poll testing 2024-11-11 22:25:53 +00:00
Mario
513cd3b99a fix click area in dropdown add/remove reaction
(cherry picked from commit 8268ed1ba7)

Co-authored-by: Mario <mario@mariovavti.com>

(cherry picked from commit ce9d67f7b1)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-11 20:00:36 +00:00
Mario
ce9d67f7b1 fix click area in dropdown add/remove reaction
(cherry picked from commit 8268ed1ba7)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-11 20:00:25 +00:00
Mario
8268ed1ba7 fix click area in dropdown add/remove reaction 2024-11-11 19:53:20 +00:00
Harald Eilertsen
6c1d0851d7 Fix invocation of DB_Update::run.
Thought this should have been part of the change set that turned the
DB_Update routine to a static function instead of a constructor to an
object that is not used.
2024-11-11 17:05:13 +01:00
Mario
3bc0fd5db4 fix undefined var warning 2024-11-11 09:18:56 +00:00
Mario Vavti
4c3f3d1477 Merge branch 'dev' into containers 2024-11-10 23:38:30 +01:00
Mario Vavti
17411a501c containers: testing sourced items 2024-11-10 23:37:45 +01:00
Mario
d446f171c5 Revert "Module\Item: Make $item_id an object property."
This reverts commit 2c17d0b031
2024-11-10 22:36:35 +00:00
Mario Vavti
b24b409a01 Merge branch 'dev' into containers 2024-11-10 19:01:40 +01:00
Mario
3791dfab3a Merge branch 'begin-refactoring-module-item' into 'dev'
Begin refactoring Module\Item

See merge request hubzilla/core!2166
2024-11-10 18:01:06 +00:00
Mario
31a146b23a Merge branch 'oops-ref-to-nonexisting-class' into 'dev'
Remove import of non-existing class in test.

See merge request hubzilla/core!2165
2024-11-10 17:55:27 +00:00
Mario Vavti
e52714ed16 make sure to notify the drop if necessary 2024-11-10 18:53:46 +01:00
Harald Eilertsen
2c17d0b031 Module\Item: Make $item_id an object property.
This also allows us to deduplicate initialization and validation.
2024-11-10 16:43:48 +01:00
Harald Eilertsen
57e69372d3 Module\Item: Move processing of zot and as requests to functions.
These seem to be entirely independent, so moving the body of the if
statements to separate functions should be fine.
2024-11-10 16:43:48 +01:00
Mario Vavti
43acb86aab fix encoding and attribution 2024-11-10 11:49:09 +01:00
Mario Vavti
e339fbcc46 container fixes for photo and file upload 2024-11-10 11:40:56 +01:00
Mario
f05b8bd87d Do not filter deleted hublocs in xchan_query because it will result in empty profile info in conversations if the hubloc was deleted. Deleting a hublocation does not neccesarily delete its content and the author could appear again from another location.
(cherry picked from commit 4e6696b049)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-11-09 20:12:21 +00:00
Mario Vavti
4e6696b049 Do not filter deleted hublocs in xchan_query because it will result in empty profile info in conversations if the hubloc was deleted. Deleting a hublocation does not neccesarily delete its content and the author could appear again from another location. 2024-11-09 21:11:33 +01:00
Harald Eilertsen
fbc79e36e0 Remove import of non-existing class in test.
This one snuck in by mistake. No harm done, as the actual class was
never referenced, but it should still not be there.
2024-11-09 14:38:27 +01:00
Mario Vavti
c9d4b068c2 remove extensiv logging to syslog 2024-11-09 12:49:10 +01:00
Mario Vavti
b6dbbbc82f fix regression propagating deletes 2024-11-09 12:39:24 +01:00
Mario Vavti
954d92c354 Merge branch 'dev' into containers 2024-11-09 11:27:53 +01:00
Mario Vavti
8dbebc2b42 update border color 2024-11-09 11:27:13 +01:00
Mario
14207c68ca Merge branch 'fix-incorrect-module-imports' into 'dev'
Fix incorrect module imports.

See merge request hubzilla/core!2163
2024-11-09 10:26:23 +00:00
Mario
0ed08274f1 Merge branch 'clean-up-some-dependencies' into 'dev'
Clean up deps and upgrade EpubMeta

See merge request hubzilla/core!2162
2024-11-09 10:24:26 +00:00
Mario
2a152e0803 Merge branch 'more-deprecations-in-tests' into 'dev'
Fix some more deprecation warnings in the tests.

See merge request hubzilla/core!2161
2024-11-09 10:18:27 +00:00
Mario Vavti
a0c54c5f04 make sure to store target information when decoding and indicate contained conversations with a colored border for now 2024-11-09 10:55:10 +01:00
Harald Eilertsen
ac8c80ddbe Fix incorrect module imports.
When importing modules with use statements, they always require the
fully qualified module name. Iow, there's no need to prefix them with an
extra backslash.

Ref: https://www.php.net/manual/en/language.namespaces.importing.php
2024-11-09 08:45:45 +01:00
Mario Vavti
ebad9d56c9 port to containers item_store() continued 2024-11-08 22:24:33 +01:00
Mario Vavti
0481901b59 refactor drop_item[s]() for containers 2024-11-08 20:18:20 +01:00
Harald Eilertsen
0534fe6886 Thumbs\Epubthumb: Adapt to new version of EPub meta lib.
Also fixes a few issues and refactor the code a bit.
2024-11-08 16:48:23 +01:00
Harald Eilertsen
6e51571309 Remove epub-meta from library 2024-11-08 16:48:23 +01:00
Harald Eilertsen
fe30b54975 Update php-epub-meta and use composer for dep handling.
Note that we upgrade to the 2.x branch of the dependency, as the 3.x
branch requires PHP version 8.2 or later. There's no reason for us to
move our minimum supported version of PHP just yet.
2024-11-08 16:43:29 +01:00
Harald Eilertsen
b00ae997a5 Remove obsolete and unused symfony/options-resover and process
These actually look like they could be useful, but since unused, let's
drop them for now. They can always be re-added via composer if needed
later.
2024-11-08 16:39:26 +01:00
Harald Eilertsen
b5b7d0cda9 Remove obsolete and unused sticky-kit 2024-11-08 16:39:26 +01:00
Harald Eilertsen
300d461a1a Remove obsolete and unused tiptip library 2024-11-08 16:39:26 +01:00
Harald Eilertsen
e516c1352f Drop obsolete library LightOpenID
We're not using it anyways.
2024-11-08 16:39:26 +01:00
Mario Vavti
4b4cac63fd Merge branch 'dev' into containers 2024-11-08 11:19:42 +01:00
Harald Eilertsen
47f109451d Fix some more deprecation warnings in the tests. 2024-11-07 17:29:54 +01:00
Mario
e466c73407 fix allday not set if a rsource is provided
(cherry picked from commit 17183cc5dc)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-07 14:31:18 +00:00
Mario
17183cc5dc fix allday not set if a rsource is provided 2024-11-07 14:29:52 +00:00
Mario
e5aae2af0f fix allday variable not set when clicking an event
(cherry picked from commit 939e5d9ca5)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-06 16:17:18 +00:00
Mario
939e5d9ca5 fix allday variable not set when clicking an event 2024-11-06 16:16:23 +00:00
Mario
600209e21e bump dev version 2024-11-06 15:48:18 +00:00
Mario
173c4d242d version 9.4.4 2024-11-06 13:06:05 +00:00
Mario
76b8c36f7c changelog
(cherry picked from commit 12c88c06d8)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-06 13:05:18 +00:00
Mario
12c88c06d8 changelog 2024-11-06 13:04:03 +00:00
Mario
f35352090e Update translations for Norwegian Bokmål
(cherry picked from commit 35a05073f2)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-06 12:30:37 +00:00
Mario
e5db47e0d5 Module\Thing: Don't try to escape field that's not present
The `profile_assign` field is only present if the multiple profiles
feature is enabled.


(cherry picked from commit 472484dde0)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-06 12:30:16 +00:00
Mario
6a52e502aa Module\Thing: Don't use $_REQUEST superglobal.
Replaces all occurences with $_POST or $_GET instead.


(cherry picked from commit 5c3bdbd1e0)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-06 12:29:46 +00:00
Mario
6a866fe904 Move Norwegian translations from nb-no to nb
(cherry picked from commit ec02453d37)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-06 12:28:51 +00:00
Mario
229efddbf1 Merge branch 'fix-mariadb-support-for-test-setup' into 'dev'
tests: Update test db setup script for mariadb

See merge request hubzilla/core!2160
2024-11-06 11:50:40 +00:00
Mario
abb67a4565 Merge branch 'make-phpcs-a-bit-more-lax' into 'dev'
Make phpcs a bit more lax...

See merge request hubzilla/core!2159
2024-11-06 11:49:25 +00:00
Mario
2e324d4cef Merge branch 'move-norwegian-locale' into 'dev'
Move and update norwegian locale

See merge request hubzilla/core!2158
2024-11-06 11:48:54 +00:00
Mario
d4d1a7523d Merge branch 'fix-module-thing' into 'dev'
Fix error adding Things when multiple profiles not enabled

See merge request hubzilla/core!2157
2024-11-06 11:47:57 +00:00
Mario
d9d239bf3a only zot6 hublocs have a sitekey so only query such hublocs. This will safe alternative network hublocs from being marked deleted allthough they are intact
(cherry picked from commit 7a3f2c1ba9)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-06 11:16:46 +00:00
Mario
429d15f009 correctly hide modals and remove unneeded toString() conversion since we are not dealing with string objects here
(cherry picked from commit 9f473fc204)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-06 11:16:20 +00:00
Mario
7a3f2c1ba9 only zot6 hublocs have a sitekey so only query such hublocs. This will safe alternative network hublocs from being marked deleted allthough they are intact 2024-11-06 11:12:42 +00:00
Mario
9f473fc204 correctly hide modals and remove unneeded toString() conversion since we are not dealing with string objects here 2024-11-06 09:44:07 +00:00
Harald Eilertsen
35a05073f2 Update translations for Norwegian Bokmål 2024-11-04 10:22:13 +01:00
Harald Eilertsen
472484dde0 Module\Thing: Don't try to escape field that's not present
The `profile_assign` field is only present if the multiple profiles
feature is enabled.
2024-11-03 20:42:59 +01:00
Harald Eilertsen
5c3bdbd1e0 Module\Thing: Don't use $_REQUEST superglobal.
Replaces all occurences with $_POST or $_GET instead.
2024-11-03 20:42:59 +01:00
Harald Eilertsen
ec02453d37 Move Norwegian translations from nb-no to nb 2024-11-03 18:06:42 +01:00
Mario
2b44be58c3 explicit check for channel_address
(cherry picked from commit e20327d267)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-03 11:02:35 +00:00
Mario
c44db397ff Zotlabs\Module\Setup: Fix deprecation.
Using `self` in callables has been deprecated, so change to proper fully
qualified class name.


(cherry picked from commit 8ab3ad6531)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-03 11:02:04 +00:00
Mario
a385fdff37 Zotlabs\Web\HttpMeta: Declare and init properties.
The $ogproperty was not declared, which triggered a warning in PHP 8.2.

Also fixed the initialization of the properties, and removed the now
superfluous constructor.


(cherry picked from commit bf008465ad)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-03 11:01:50 +00:00
Mario
20aacb82c6 tests: Declare private property $output.
Uncovered by PHP 8.2 because dynamic properties are deprecated.


(cherry picked from commit a29a1c768d)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-03 11:01:38 +00:00
Mario
0d17d8dad9 tests: Fix typo in UnitTestCase.
Uncovered by PHP 8.2 because dynamic properties are deprecated.


(cherry picked from commit 90bc987ea7)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-03 11:01:21 +00:00
Mario
2ab0118c13 Fix missing CSRF checks in admin/account_edit
(cherry picked from commit 38c947590e)

342d94c3 tpl: Fix warnings in templates.
bccaeb1e tests: Update Module\TestCase to support POST requests
f627e55b tests: Update account fixtures with fixed account_level.
ee62aff4 Module\Admin\Account_edit: Add missing CSRF checks.

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-03 10:59:41 +00:00
Mario
30419bdbf6 add ocap tokens to all media files and attachments
(cherry picked from commit 2f0a47e583)

Co-authored-by: Mario <mario@mariovavti.com>
2024-11-03 10:59:16 +00:00
Mario Vavti
21b60bf119 Merge branch 'dev' into containers 2024-11-03 11:57:45 +01:00
Mario
5db3f93be9 Merge branch 'php8.2-deprecations' into 'dev'
Fix deprecations uncovered by running tests on PHP 8.2

See merge request hubzilla/core!2156
2024-11-03 10:57:03 +00:00
Mario Vavti
d25314c75b Merge branch 'dev' into containers 2024-11-03 11:45:08 +01:00
Mario
e20327d267 explicit check for channel_address 2024-11-03 10:43:17 +00:00
Harald Eilertsen
8ab3ad6531 Zotlabs\Module\Setup: Fix deprecation.
Using `self` in callables has been deprecated, so change to proper fully
qualified class name.
2024-11-03 08:48:53 +01:00
Harald Eilertsen
bf008465ad Zotlabs\Web\HttpMeta: Declare and init properties.
The $ogproperty was not declared, which triggered a warning in PHP 8.2.

Also fixed the initialization of the properties, and removed the now
superfluous constructor.
2024-11-03 08:42:11 +01:00
Harald Eilertsen
a29a1c768d tests: Declare private property $output.
Uncovered by PHP 8.2 because dynamic properties are deprecated.
2024-11-03 08:39:21 +01:00
Harald Eilertsen
90bc987ea7 tests: Fix typo in UnitTestCase.
Uncovered by PHP 8.2 because dynamic properties are deprecated.
2024-11-03 08:32:01 +01:00
Mario
46fdce4402 Merge branch 'admin-account-edit-csrf-check' into 'dev'
Fix missing CSRF checks in admin/account_edit

See merge request hubzilla/core!2155
2024-11-02 14:42:01 +00:00
Harald Eilertsen
38c947590e Fix missing CSRF checks in admin/account_edit 2024-11-02 14:42:00 +00:00
Mario
c5faa012b5 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-11-02 14:35:42 +00:00
Mario
2f0a47e583 add ocap tokens to all media files and attachments 2024-11-02 14:35:04 +00:00
Mario
c958cc6f90 URL escape zid param in head.tpl
This should fix issue #1877 fully.


(cherry picked from commit 065f85bab1)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-11-01 09:03:21 +00:00
Mario
541a0f6476 Merge branch 'issue-1877-more-fixes' into 'dev'
URL escape zid param in head.tpl

See merge request hubzilla/core!2154
2024-11-01 09:02:37 +00:00
Harald Eilertsen
065f85bab1 URL escape zid param in head.tpl
This should fix issue #1877 fully.
2024-10-31 19:15:52 +01:00
Mario
38ac60e618 make sure the objects published date has the correct time format
(cherry picked from commit 160c40b580)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-31 11:12:54 +00:00
Mario
160c40b580 make sure the objects published date has the correct time format 2024-10-31 11:07:42 +00:00
Mario Vavti
005d4ad351 Merge branch 'dev' into containers 2024-10-30 12:50:08 +01:00
Mario
90a1dad02c Merge branch 'make-db-upgrade-static-method' into 'dev'
Change DB_Upgrade to a static function instead.

See merge request hubzilla/core!2151
2024-10-30 11:47:52 +00:00
Harald Eilertsen
4daba84223 Make phpcs a bit more lax...
Allow spaces for indent, and newlines before braces.
2024-10-30 12:35:08 +01:00
Harald Eilertsen
fc182f1b07 tests: Update test db setup script for mariadb
Mariadb now issues warnings when using the deprecated `mysql` binary. So
we make sure to use the proper name for the binary depending on the
actual DB engine installed.
2024-10-30 12:13:21 +01:00
Mario
23a19ecf1f escape the zid parameter - issue #1877
(cherry picked from commit 0207c02420)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-30 09:18:23 +00:00
Mario
0207c02420 escape the zid parameter - issue #1877 2024-10-30 09:12:26 +00:00
Mario Vavti
68135c28da Merge branch 'dev' into containers 2024-10-30 09:50:17 +01:00
Mario
274bfa9024 Merge branch 'add-missing-test-for-bbcode-cleanup-fix' into 'dev'
tests: Tests for BBCode cleanup fix

See merge request hubzilla/core!2152
2024-10-30 08:27:44 +00:00
Mario Vavti
4bb28a21c4 Merge branch 'dev' into containers 2024-10-27 14:05:25 +01:00
Mario
8b75f50f23 fix en tos page
(cherry picked from commit 0e50b1d10c)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-10-27 12:57:02 +00:00
Mario Vavti
0e50b1d10c fix en tos page 2024-10-27 13:53:31 +01:00
Harald Eilertsen
8f4c3a2f88 Merge branch 'dev' into make-db-upgrade-static-method 2024-10-23 14:56:41 +02:00
Harald Eilertsen
73006ccdf5 tests: Tests for BBCode cleanup fix
Somehow I forgot to include this in the patch that fixed the issue.
2024-10-23 14:31:21 +02:00
Mario Vavti
1006ebbf61 Merge branch 'dev' into containers 2024-10-23 14:19:45 +02:00
Mario
436b1673cf make sure we select only sys channel items and remove dupes checking (this will be checked in item_store() anyway)
(cherry picked from commit e530476e6c)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-23 12:08:03 +00:00
Mario
e530476e6c make sure we select only sys channel items and remove dupes checking (this will be checked in item_store() anyway) 2024-10-23 12:06:32 +00:00
Mario
e0a91bed7a allow to file items from the public stream 2024-10-23 12:04:15 +00:00
Mario Vavti
168ec53686 Merge branch 'dev' into containers 2024-10-19 20:50:48 +02:00
Mario
4d1be3aea5 bring filed items to mod hq 2024-10-19 18:49:47 +00:00
Mario Vavti
e8f816a981 Merge branch 'dev' into containers 2024-10-18 21:36:48 +02:00
Mario
e649ba5b13 remove attach_upgrade() after 7 years it should not be required anymore 2024-10-18 19:32:41 +00:00
Mario
92ce66e766 i guess a couple of weeks have passed by now 2024-10-18 19:20:20 +00:00
Mario
96210f5ecc fix edit button not clickable if below right aside
(cherry picked from commit 1411eafa9b)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-18 19:14:04 +00:00
Mario
1411eafa9b fix edit button not clickable if below right aside 2024-10-18 19:06:35 +00:00
Mario Vavti
20db45c815 Merge branch 'dev' into containers 2024-10-18 20:19:36 +02:00
Mario Vavti
4acdb8fb10 containers: port events 2024-10-18 20:18:55 +02:00
Mario
9e9e8efb2d fix tags rendering in the editor
(cherry picked from commit f4495fd441)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-17 09:04:25 +00:00
Mario
f4495fd441 fix tags rendering in the editor 2024-10-17 09:03:32 +00:00
Harald Eilertsen
e2ae8f0c4d Zotlabs\Lib\DB_Upgrade: Add API documentation. 2024-10-14 23:07:42 +02:00
Harald Eilertsen
074dc440cc Change DB_Upgrade to a static function instead.
No need for this to be an object, since it's never referenced or even
kept after construction. Further all the functionality was in the
constructor anyways.

Also removed some unused properties.
2024-10-14 22:52:13 +02:00
Mario
e9dc4b553b Fix regex to detect URLs in cleanup_bbcode.
This fixes the issue where the text after the URL would be included in
the link if it was immediately followed by a newline.

Example:

    https://example.com
	this is a test.

Would become:

	#^[url=https://example.com_this]https://example.com_this[/url]
	is a test


(cherry picked from commit 687cda3673)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-12 17:08:15 +00:00
Mario Vavti
d7fa6f6709 Merge branch 'dev' into containers 2024-10-12 19:06:35 +02:00
Mario
40a9989be2 Merge branch 'fix-cleanup-bbcode-url-regex' into 'dev'
Fix naked URLs immediately followed by a newline

See merge request hubzilla/core!2150
2024-10-12 17:05:19 +00:00
Harald Eilertsen
d1648927b5 Fix some whitespace issues in zid.php.
No functional change.
2024-10-12 18:23:30 +02:00
Harald Eilertsen
ecde4a3ded Change config used by Markdown tests to reflect actual use.
This makes the configuration used align better with how it is being used
in the mdpost addon. This also reveals some issues that are less than
ideal for Markdown posts. The relevant test cases have been adjusted to
pass with the new config, but have been commented.
2024-10-12 18:19:43 +02:00
Harald Eilertsen
687cda3673 Fix regex to detect URLs in cleanup_bbcode.
This fixes the issue where the text after the URL would be included in
the link if it was immediately followed by a newline.

Example:

    https://example.com
	this is a test.

Would become:

	#^[url=https://example.com_this]https://example.com_this[/url]
	is a test
2024-10-12 18:15:54 +02:00
Mario Vavti
47cdef390a Merge branch 'dev' into containers 2024-10-12 17:17:11 +02:00
Mario
05a5b644bf Merge branch 'remove-repo-handling-from-admin-addons' into 'dev'
Remove addon repo management from admin/addons.

See merge request hubzilla/core!2149
2024-10-12 15:15:40 +00:00
Mario
84556854e8 Merge branch 'drop-unused-html5-library' into 'dev'
Remove HTML5 parser lib deprecated in Hubzilla 5.0

See merge request hubzilla/core!2148
2024-10-12 15:10:02 +00:00
Mario
314443d41e Merge branch 'first-tests-for-module-magic' into 'dev'
tests: Add some tests for the Zotlabs\Magic module.

See merge request hubzilla/core!2147
2024-10-12 15:08:29 +00:00
Mario Vavti
c23a71c936 code consistency 2024-10-12 17:05:35 +02:00
Mario Vavti
12b33a23de containers: port start_delivery_chain() 2024-10-12 16:31:00 +02:00
Mario Vavti
a305c20e08 Merge branch 'dev' into containers 2024-10-12 16:24:58 +02:00
Mario
c70bd08c10 Fix duplicate posts from forum clones
(cherry picked from commit e2cfe245b7)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-10-12 13:59:12 +00:00
Mario Vavti
e2cfe245b7 Fix duplicate posts from forum clones 2024-10-12 15:58:00 +02:00
Mario Vavti
12b24e0e5e containers: port mod impel 2024-10-11 17:16:44 +02:00
Mario Vavti
d5291e9b07 containers: port core modules and attach_store_item() 2024-10-11 17:10:56 +02:00
Mario Vavti
a1818b1a29 document some special handling 2024-10-10 15:10:51 +02:00
Mario Vavti
e8eb283fd8 fix c/p typo 2024-10-10 14:18:23 +02:00
Mario Vavti
96d5370122 update item entity for hubzilla 2024-10-10 14:17:13 +02:00
Mario Vavti
2bcb6a4fed merge dev and resolve conflicts 2024-10-10 13:13:17 +02:00
Mario Vavti
aee396421a revert 2024-10-10 13:09:04 +02:00
Mario Vavti
897568a087 resolve merge conflict 2024-10-10 13:07:48 +02:00
Mario Vavti
69109a558b version 9.4.3 2024-10-10 12:16:33 +02:00
Mario
4aff6d19d6 changelog
(cherry picked from commit a5c1b669b4)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-10-10 10:11:31 +00:00
Mario Vavti
a5c1b669b4 changelog 2024-10-10 12:09:39 +02:00
Mario
3cb5d14037 also discard Add/Remove at the AP side
(cherry picked from commit 2aee659cbd)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-10-10 10:04:17 +00:00
Mario
5f685bcf63 also dismiss add/remove collection activities in fetch_conversation()
(cherry picked from commit 44232677c8)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-10 10:03:51 +00:00
Mario
cb44f7e360 dismiss add/remove collection activities until we support themÃ
(cherry picked from commit 16603ca854)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-10 10:03:32 +00:00
Mario Vavti
2aee659cbd also discard Add/Remove at the AP side 2024-10-10 12:01:46 +02:00
Harald Eilertsen
b117cf9dc7 emove another PHPGit related file. 2024-10-09 23:38:01 +02:00
Mario Vavti
c2ce1d9881 containers: send add in mod like, send remove on delete 2024-10-09 22:43:01 +02:00
Harald Eilertsen
2ed8908127 Remove now unused PHPGit from library. 2024-10-09 21:02:08 +02:00
Harald Eilertsen
6588e272db Remove addon repo management from admin/addons.
This functionality was broken anyways, and needs to be rethought. Addon
reporitories can still be managed from the terminal using the tools in
util/.
2024-10-09 21:00:12 +02:00
Harald Eilertsen
c13645f136 Remove HTML5 parser lib deprecated in Hubzilla 5.0 2024-10-09 18:47:35 +02:00
Mario Vavti
8cee16be1b enable the hooks again 2024-10-09 18:26:15 +02:00
Mario Vavti
45c0091d3d more work on porting containers from streams 2024-10-09 18:17:37 +02:00
Mario
44232677c8 also dismiss add/remove collection activities in fetch_conversation() 2024-10-09 15:41:40 +00:00
Mario
16603ca854 dismiss add/remove collection activities until we support themà 2024-10-09 07:39:13 +00:00
Mario
75184355d0 whitespace and use empty for check 2024-10-06 16:47:15 +00:00
Mario
1988d21e6c start containers 2024-10-06 15:53:39 +00:00
Harald Eilertsen
bccac55cf9 tests: Add some tests for the Zotlabs\Magic module.
Only tests the delegate functionality at the moment.

This patch also includes some minor fixes to the Magic module, triggered
by the tests with empty destination URL's.
2024-10-06 11:47:45 +02:00
Mario
19eeadfe5b port some libs from streams repo 2024-10-06 08:59:36 +00:00
Mario
8f74ee67e3 css fixes
(cherry picked from commit 2693e9e990)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 11:27:56 +00:00
Mario
b0a11537de remove bogus icon id
(cherry picked from commit 04741c761a)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 11:27:40 +00:00
Mario
2693e9e990 css fixes 2024-10-04 11:26:48 +00:00
Mario
04741c761a remove bogus icon id 2024-10-04 11:14:41 +00:00
Mario
4de9cb1142 more fa2bi fixes
(cherry picked from commit 8f890fb6fa)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 11:07:50 +00:00
Mario
8f890fb6fa more fa2bi fixes 2024-10-04 11:06:35 +00:00
Mario
158ddfb009 changelog
(cherry picked from commit 1afb2a4ce8)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 07:09:21 +00:00
Mario
2b4f344181 Version 9.4.2 2024-10-04 07:07:31 +00:00
Mario
1afb2a4ce8 changelog 2024-10-04 07:06:24 +00:00
Mario
2e5f922561 due to popular demand: indicate reacted state via icon color
(cherry picked from commit afbeb58c16)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 06:59:50 +00:00
Mario
a6498a0cfc Reflect change to btn-link in js template
(cherry picked from commit 8ffab25f5d)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 06:59:16 +00:00
Mario
8ffab25f5d Reflect change to btn-link in js template 2024-10-04 06:57:46 +00:00
Mario
1073392398 Fix modal backdrop not removed when like/unlike from the modal
(cherry picked from commit 7d41deebce)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 06:51:15 +00:00
Mario
7d41deebce Fix modal backdrop not removed when like/unlike from the modal 2024-10-04 06:50:06 +00:00
Mario
76064dbb33 Fix missing handle icon in mod pdledit_gui
(cherry picked from commit 7e48caae6b)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-04 06:27:37 +00:00
Mario
7e48caae6b Fix missing handle icon in mod pdledit_gui 2024-10-04 06:26:34 +00:00
Mario
afbeb58c16 due to popular demand: indicate reacted state via icon color 2024-10-03 08:18:59 +00:00
Mario
1ab4f36a1b Merge branch 'master' of https://framagit.org/hubzilla/core 2024-10-03 04:52:40 +00:00
Mario
cea9c88b9e version 9.4.1 2024-10-03 04:52:18 +00:00
Mario
babe118383 Tests: Unbreak help test.
(cherry picked from commit 5b93aa1148)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:27:26 +00:00
Mario
2b140e53cc changelog
(cherry picked from commit 9008760aa6)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-02 20:21:51 +00:00
Mario
9008760aa6 changelog 2024-10-02 20:20:56 +00:00
Mario
fb1514a782 Help: Drop language specifier in URL when redirecting
This finally fixes the help for languages other than english.


(cherry picked from commit 4daa03f025)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:09:36 +00:00
Mario
7679894684 Replace drop shadow in help toc with brighter color.
The drop shadow looked terrible in dark mode. While that could be fixed,
I think it looks better with just using the link hover color and making
the selected item bold.


(cherry picked from commit 8ae9df3bb7)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:08:55 +00:00
Mario
520cf1015c Move some help related styling from redbasic to module css.
(cherry picked from commit 25d9d3ba1b)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:08:33 +00:00
Mario
64bd8eef4b Use html details element for toc on top of help pages.
This allows us to get rid of some more unneccessary JavaScript that just
implements stuff that web browsers now do anyways.


(cherry picked from commit 26ce231951)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:08:04 +00:00
Mario
aa42f6a6b2 Remove link to "Contents" from the help table of contect sidebar.
Changes the element where the jQuery.toc plugin looks for headings to
only include the actual help contents, not the toc itself.


(cherry picked from commit fb9464437e)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:07:31 +00:00
Mario
13345d3cbe deps: Upgrade smarty/smarty to version 4.5.4
This eliminates a potential vulnerability where an template author could
inject arbitrary PHP files to be run via the 'extends' tag.

See:
  - https://github.com/smarty-php/smarty/security/advisories/GHSA-4rmg-292m-wg3w
  - 0be92bc8a6

Impact assessment:

In our case I would consider this a low severity issue as we don't
allow users to dynamically add or edit smarty templates. Templates has
to be updated via merge requests, or by installing a theme. In both
cases a malicious attacker already has easier ways to inject whatever
code they want.

Further, the extend tag is not in use in any of our core templates.


(cherry picked from commit 4dff1a1e5b)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:06:10 +00:00
Mario
888ee16d52 fix german about page title
(cherry picked from commit 1c45030c58)

Co-authored-by: Mario <mario@mariovavti.com>
2024-10-02 20:05:06 +00:00
Mario
0f3e01f343 markdown: Don't link URLs in code blocks.
When passing a content throught the `markdown_to_bb` function
to convert any markdown in the content, any recognized URLs in the
content would be converted to BBCode links as a post processing step
after the main conversion.

After commit a1ccacb825 this did no longer
consider content within code blocks, and would thus convert them as
to BBCode links.

Example: The following content

	[code]
	example url: https://example.com
	[/code]

Would be converted to

	[code]
	example url: [url=https://example.com]https://example.com[/url]
	[/code]

Prior to commit a1ccacb825, code blocks
would be protected, so this would not happen.

This patch removes the post processing step for converting plain URLs to
links completely from this routine. This functionality is in any case
covered in the actual BBCode parser where it belongs.

This will have some other side effects as well, such as images and links
created using Markdown, will not be converted to [zmg] or [zrl] tags
where that would be done automatically before. If you intend to use a
[zrl] or [zmg] tag, you now need to do so explicitly.


(cherry picked from commit 803cd74b48)

Co-authored-by: Harald Eilertsen <haraldei@anduin.net>
2024-10-02 20:04:30 +00:00
Mario
79220ede66 rewrite sql logic to rename photos - there are more DB queries involved now but the previous logic was throwing error in postgresql (while the result was correct anyway)
(cherry picked from commit a5f0253aef)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-10-02 20:03:54 +00:00
Mario
6b98b799c8 Merge branch 'tests-for-activitystreams' into 'dev'
tests: Add a basic test for ActivityStreams

See merge request hubzilla/core!2146
2024-10-02 13:13:42 +00:00
Mario
9f49d313f5 Merge branch 'markdown/dont-link-urls-in-code-blocks' into 'dev'
markdown: Don't link URLs in code blocks.

See merge request hubzilla/core!2145
2024-10-02 13:10:05 +00:00
Mario Vavti
a5f0253aef rewrite sql logic to rename photos - there are more DB queries involved now but the previous logic was throwing error in postgresql (while the result was correct anyway) 2024-10-02 14:45:10 +02:00
Harald Eilertsen
4e6f871bc4 tests: Add a basic test for ActivityStreams
This is just a basic test that parses a specific object, and tests that
all the referenced objects are fetched from the originating servers.
2024-10-02 09:51:22 +02:00
Harald Eilertsen
803cd74b48 markdown: Don't link URLs in code blocks.
When passing a content throught the `markdown_to_bb` function
to convert any markdown in the content, any recognized URLs in the
content would be converted to BBCode links as a post processing step
after the main conversion.

After commit a1ccacb825 this did no longer
consider content within code blocks, and would thus convert them as
to BBCode links.

Example: The following content

	[code]
	example url: https://example.com
	[/code]

Would be converted to

	[code]
	example url: [url=https://example.com]https://example.com[/url]
	[/code]

Prior to commit a1ccacb825, code blocks
would be protected, so this would not happen.

This patch removes the post processing step for converting plain URLs to
links completely from this routine. This functionality is in any case
covered in the actual BBCode parser where it belongs.

This will have some other side effects as well, such as images and links
created using Markdown, will not be converted to [zmg] or [zrl] tags
where that would be done automatically before. If you intend to use a
[zrl] or [zmg] tag, you now need to do so explicitly.
2024-09-30 13:54:50 +02:00
Mario
0bfdb958f5 update symfony/polyfill-php81 2024-09-30 07:13:55 +00:00
Mario
becd4c6ffd update sabre/vobject 2024-09-30 07:12:30 +00:00
Mario
3f411787c1 update spomky-labs/otphp 2024-09-30 07:11:05 +00:00
Mario
5782a674b0 update ramsey/uuid 2024-09-30 07:09:20 +00:00
Mario
fc79e47d88 update scssphp 2024-09-30 07:07:30 +00:00
Mario
1c45030c58 fix german about page title 2024-09-30 06:29:37 +00:00
Mario
18f3887050 Merge branch 'more-help-improvements' into 'dev'
Fix help for other languages than english

See merge request hubzilla/core!2144
2024-09-30 06:22:28 +00:00
Mario
2cc962e53a Merge branch 'security/update/smarty' into 'dev'
deps: Upgrade smarty/smarty to version 4.5.4

See merge request hubzilla/core!2143
2024-09-30 06:20:48 +00:00
Harald Eilertsen
5b93aa1148 Tests: Unbreak help test. 2024-09-29 14:28:17 +02:00
Harald Eilertsen
4daa03f025 Help: Drop language specifier in URL when redirecting
This finally fixes the help for languages other than english.
2024-09-29 14:09:41 +02:00
Harald Eilertsen
8ae9df3bb7 Replace drop shadow in help toc with brighter color.
The drop shadow looked terrible in dark mode. While that could be fixed,
I think it looks better with just using the link hover color and making
the selected item bold.
2024-09-29 14:00:53 +02:00
Harald Eilertsen
25d9d3ba1b Move some help related styling from redbasic to module css. 2024-09-29 14:00:53 +02:00
Harald Eilertsen
26ce231951 Use html details element for toc on top of help pages.
This allows us to get rid of some more unneccessary JavaScript that just
implements stuff that web browsers now do anyways.
2024-09-29 14:00:45 +02:00
Harald Eilertsen
fb9464437e Remove link to "Contents" from the help table of contect sidebar.
Changes the element where the jQuery.toc plugin looks for headings to
only include the actual help contents, not the toc itself.
2024-09-29 13:58:41 +02:00
Harald Eilertsen
4dff1a1e5b deps: Upgrade smarty/smarty to version 4.5.4
This eliminates a potential vulnerability where an template author could
inject arbitrary PHP files to be run via the 'extends' tag.

See:
  - https://github.com/smarty-php/smarty/security/advisories/GHSA-4rmg-292m-wg3w
  - 0be92bc8a6

Impact assessment:

In our case I would consider this a low severity issue as we don't
allow users to dynamically add or edit smarty templates. Templates has
to be updated via merge requests, or by installing a theme. In both
cases a malicious attacker already has easier ways to inject whatever
code they want.

Further, the extend tag is not in use in any of our core templates.
2024-09-28 15:07:23 +02:00
Mario
b498e50f74 adjust post app icon and remove obsolete arguments
(cherry picked from commit 5cbd42bbc4)

Co-authored-by: Mario <mario@mariovavti.com>
2024-09-27 16:51:57 +00:00
Mario
2c05638776 Merge branch 'cherry-pick-d1811ea1' into 'dev'
Update Spanish strings

See merge request hubzilla/core!2142
2024-09-27 16:39:24 +00:00
Mario
5cbd42bbc4 adjust post app icon and remove obsolete arguments 2024-09-27 16:36:25 +00:00
Manuel Jiménez Friaza
ac6720e118 Update Spanish strings
(cherry picked from commit d1811ea1f3f7249023c51104154d680f09df8572)

Co-authored-by: mjfriaza:4GF~eYj,-iAv <mjfriaza@disroot.org>
2024-09-27 15:36:32 +00:00
Mario
8c87b06caa Merge branch '9.4RC' 2024-09-25 19:39:51 +00:00
Mario
339e702beb version 9.4 2024-09-25 19:38:12 +00:00
Mario
8750c5f7bc update changelog
(cherry picked from commit 5281f4dd9b)

Co-authored-by: Mario <mario@mariovavti.com>
2024-09-25 19:36:46 +00:00
Mario
5281f4dd9b update changelog 2024-09-25 19:35:01 +00:00
Mario
c3b4397ea3 update changelog
(cherry picked from commit 424b31b7f0)

Co-authored-by: Mario <mario@mariovavti.com>
2024-09-25 09:48:57 +00:00
Mario
c12ef4fbf4 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-09-25 09:47:21 +00:00
Mario
424b31b7f0 update changelog 2024-09-25 09:46:57 +00:00
Mario
20ee1a5b5b Merge branch 'remove-tests-from-autoload' into 'dev'
Don't autoload test cases using composer.

See merge request hubzilla/core!2141
2024-09-25 08:40:45 +00:00
Harald Eilertsen
2cd779cbe9 Don't autoload test cases using composer.
Introduces a bootstrap file that ensures that the base test case classes
are loaded and available instead.

This reduces the number of warnings when running composer install.
2024-09-24 13:54:42 +02:00
Mario
a3f1189df7 Merge branch 'dev' into 9.4RC 2024-09-24 09:26:12 +00:00
Mario
2bc088e555 mod help: only abort requests without topic if we have not got a search request 2024-09-24 09:24:56 +00:00
Mario
67d8b977b6 version 9.4RC1 2024-09-24 08:59:26 +00:00
Mario
5b1e532791 Merge branch 'dev' into 9.4RC 2024-09-24 08:58:33 +00:00
Mario
0e1bf2cef0 update changelog 2024-09-24 08:58:06 +00:00
Mario
4f129e05e5 notes: make sure we set App::$profile_uid in the module - issue #1865 and minor code cleanup
(cherry picked from commit 3733a80c1d)

Co-authored-by: Mario Vavti <mario@mariovavti.com>
2024-09-22 15:26:52 +00:00
Mario Vavti
3733a80c1d notes: make sure we set App::$profile_uid in the module - issue #1865 and minor code cleanup 2024-09-22 17:24:28 +02:00
Mario Vavti
220571d2a9 bump dev version 2024-09-20 13:04:50 +02:00
Mario Vavti
f6b9a1dd3c version 9.4RC, strings, autoload dump 2024-09-20 12:59:36 +02:00
Mario
393d5020f8 changelog 2024-09-20 11:21:51 +02:00
Mario
06ac41c005 whitespace 2024-09-19 06:59:55 +00:00
Mario
39ee872f49 prefer token if available 2024-09-19 06:59:27 +00:00
Mario
a7c51f5d65 display title only for toplevel items 2024-09-18 19:59:33 +00:00
Mario
5309c032db Adjust fix_attached_permissions() so that if we got a token, we will just add the token to the original ACL instead of rewriting the ACL to theitem ACL - it probably makes much more sense that way 2024-09-18 19:53:07 +00:00
Mario
176298ffeb remove garbage 2024-09-18 15:09:56 +00:00
Mario
fdf19e659e not yet ready for primetime 2024-09-18 15:09:10 +00:00
Mario
e799589781 allow uploading to comments if ocap tokens are enabled 2024-09-18 09:34:10 +00:00
Mario
10acf90d06 refactor get_security_ids() to remove some legacy code from the zot/zot6 transition and re-add scope sql to item_permissions_sql() 2024-09-18 08:48:25 +00:00
Mario
b184533115 fa2bi fixes 2024-09-05 13:26:13 +00:00
Mario
b50e06a9d9 fa2bi fixes 2024-08-28 08:44:32 +00:00
Mario
66901dbe3e fa2bi fixes 2024-08-09 09:55:18 +00:00
Mario
4a7879aad2 fa2bi fixes 2024-08-09 09:08:33 +00:00
Mario
30aa0e3822 fa2bi fixes 2024-08-09 08:56:52 +00:00
Mario
cadc7ee29e bump version 2024-08-08 20:43:51 +00:00
Mario
5a44b8c40c remove fork awesome 2024-08-08 20:42:51 +00:00
Mario
487e68ebd1 fa2bi fix 2024-08-08 20:40:17 +00:00
Mario
6cdbc28d79 missing class 2024-08-08 16:14:08 +00:00
Mario
4113bea104 fa2bi fixes 2024-08-05 10:03:09 +00:00
Mario
294359d7f5 improved content and comment collapse/expand rendering 2024-08-04 13:40:22 +00:00
Mario
8ff870482f add support for inbound locations 2024-08-02 16:56:59 +00:00
Mario
56cb6f1034 streamline location rendering 2024-08-02 16:02:29 +00:00
Mario
7eb23aa8b8 fa2bi fixes 2024-08-02 15:08:27 +00:00
Mario
c793cea2f0 fa2bi: catch some remains 2024-08-02 08:50:50 +00:00
Mario
4e19f1c8be fa2bi: fix directory sort icon 2024-08-02 08:19:08 +00:00
Mario
3d3fcd7334 fa2bi: some sed woodoo on templates and manual fixes in js and php files 2024-08-02 08:06:15 +00:00
Mario
61c03e4b4e fix html2bbcode table and add test 2024-08-02 07:17:54 +00:00
Mario
dd0be272d0 fa2bi continued 2024-07-31 19:24:36 +00:00
Mario
b781739949 fa2bi continued 2024-07-31 13:53:09 +00:00
Mario
2221d8dd12 fa2bi continued 2024-07-30 15:11:08 +00:00
Mario
d67a0b14e3 fa2bi continued 2024-07-30 15:10:47 +00:00
Mario
b838632318 fa2bi continued 2024-07-30 15:10:32 +00:00
Mario
8c38466b75 fa2bi continued 2024-07-30 14:40:33 +00:00
Mario
2919b36e91 streamline calendar icon 2024-07-30 11:39:58 +00:00
Mario
52f7b508af Merge branch 'improve-help-locale-handling' into 'dev'
Improve handling of locale in Help module

See merge request hubzilla/core!2140
2024-07-29 09:59:04 +00:00
Mario
15f6bc93cf minor line height fix 2024-07-29 09:56:15 +00:00
Mario
8c4269d037 fa2bi continued 2024-07-29 09:38:51 +00:00
Mario
7394c97f23 simplified syntax 2024-07-29 07:57:47 +00:00
Mario
33e45d98a3 fa2bi adjustions 2024-07-28 18:49:04 +00:00
Mario
241cc1ad63 storing info and notice messages in the session has some disadvantages if the functions are called via ajax. revert to storing them in xconfig. 2024-07-28 18:44:07 +00:00
Mario
b26db5bde6 fa2bi more fix notifications 2024-07-24 21:04:22 +00:00
Mario
9be799de15 fa2bi fix notifications 2024-07-24 20:09:07 +00:00
Mario
014737fe21 fa2bi fixes 2024-07-24 18:26:50 +00:00
Harald Eilertsen
d3093dce1b Improve translation message for help pages.
Display the target language instead of "your preferred language". Makes
it a bit more explicit.
2024-07-24 11:57:41 +02:00
Harald Eilertsen
61f9ad8274 Add a notice to help pages when defaulting to english. 2024-07-24 11:46:18 +02:00
Harald Eilertsen
7067a0adc2 Move language member to HelpHelperTrait.
Should have been there from the start, was just a miss.
2024-07-24 10:59:03 +02:00
Mario
eb8cab37f3 bi adjustments 2024-07-24 08:01:38 +00:00
Mario
467e0b32b4 fa2bi and a php error in mod appman 2024-07-23 22:08:42 +00:00
Mario
204d91c3c3 this will be a longer journey - we will start to use bootstrap icons now since forkawesome is dead 2024-07-23 18:07:30 +00:00
Harald Eilertsen
1bd52867fb Fallback to english help topic if localized topic is not found. 2024-07-23 18:52:12 +02:00
Harald Eilertsen
898fb4f800 Refactor HelpTest.php.
Move default stubs to a function to make them reusable.
2024-07-23 18:51:22 +02:00
Harald Eilertsen
63a01c0214 Replace $Projectname in help index/toc file. 2024-07-23 18:47:39 +02:00
Mario
39933052a9 do not run set_linkified_perms() if editing an existing post 2024-07-23 14:40:36 +00:00
Mario
719dbf091a some cleanup 2024-07-23 14:17:06 +00:00
Mario
2dad3a8fe5 the tag_deliver permission is not used anymore 2024-07-23 14:00:07 +00:00
Mario
d99ba64206 make sure to failà the tgroup_check() for group posts if they do not have the post_wall permission. 2024-07-23 13:11:24 +00:00
Harald Eilertsen
202b797fe6 Remove language selector from help pages.
It is not in sync with the languages available for the rest of the
Hubzilla UI, so it was confusing and in the way of just supporting
localized help using the same mechanism as the rest of the code.

Also allowed deleting a good chunck of javascript from the help logic.
2024-07-23 13:26:44 +02:00
Harald Eilertsen
9df96fa03b Don't modify address bar when loading help topic.
Modifying the current URL like this causes several problems, and is imo
bad practice.

When requesting a help topic without specifying the language in the URL
(like `help/member/member_guide`) the locale for the current channel is
used to fetch the topic.

On the other hand, if fetching a topic with the language in the URL, the
detected language will be used. Since the channel locale may not match
the locale supported by the help system, weird situations may arise.
I.e. fetching the topic without language in the URL works, but as the
URL has now been rewritten, reloading the page will fail with a 404
status.

Being a bit less clever solves this issue, and leaves the web browser to
behave more as expected by the user.
2024-07-23 12:56:48 +02:00
Harald Eilertsen
7afb01e488 Redirect help to about page when locale but no topic specified in URL 2024-07-23 12:24:42 +02:00
Mario
ae140465d7 only allow repeats if we are the profile owner and minor code simplification 2024-07-23 08:44:18 +00:00
Mario
475cbf6510 more fix logic 2024-07-22 21:32:24 +00:00
Mario
39e5e29ce5 fix logic and add translateable strings 2024-07-22 21:19:28 +00:00
Mario
f4ffef967a undo announce is not yet supported - hide it in the UI until it is 2024-07-22 20:26:14 +00:00
Mario
77a6a21ea2 bump version 2024-07-22 19:25:26 +00:00
Mario
4e35d34226 item buttons redesign - initial checkin 2024-07-22 19:07:19 +00:00
Mario
3708896a65 Merge branch 'dev' into 'dev'
Added util/update_db

See merge request hubzilla/core!2139
2024-07-22 07:03:51 +00:00
Dale Hitchenor
7c3f28f9d2 Added util/update_db 2024-07-22 07:03:51 +00:00
Mario
afc8b88933 Merge branch 'dev' into 'dev'
Added util/update_db

See merge request hubzilla/core!2139
2024-07-22 06:56:17 +00:00
Dale Hitchenor
4668178dee Added util/update_db 2024-07-22 06:56:16 +00:00
Mario
bfec7b6901 Merge branch 'dev' into 'dev'
Added util/update_db

See merge request hubzilla/core!2139
2024-07-22 06:55:43 +00:00
Dale Hitchenor
f026afe11c Added util/update_db 2024-07-22 06:55:43 +00:00
Mario
f388fcaf08 Merge branch 'dev' into 'dev'
Added util/update_db

See merge request hubzilla/core!2139
2024-07-22 06:53:27 +00:00
Dale Hitchenor
9bd2b3ab17 Added util/update_db 2024-07-22 06:53:25 +00:00
Mario
2d0b216a2c version 2024-07-20 18:01:17 +00:00
Mario
c5bca0279c Revert "Revert "sse: reset session after connection aborted""
This reverts commit c71eb401c0
2024-07-20 13:09:05 +00:00
Mario
3fca63a15f Revert "Revert "more work on sse sys messages""
This reverts commit c22f633ae0
2024-07-20 13:08:52 +00:00
Mario
c47900f366 Revert "sse: more work on notifications"
This reverts commit 82f69018a6
2024-07-20 13:08:31 +00:00
Mario
84f64214c3 Revert "sse: add pdl files"
This reverts commit 1055718935
2024-07-20 13:08:04 +00:00
Mario
9cd01e2e13 Revert "sse: add pdl files"
This reverts commit 2461e709d2
2024-07-20 13:07:49 +00:00
Mario
841b4f7d81 Revert "sse: add pdl files"
This reverts commit 6276f36b90
2024-07-20 13:07:32 +00:00
Mario
70212cdb59 Revert "version"
This reverts commit 5f77e9f4ce
2024-07-20 13:07:07 +00:00
Mario
5f77e9f4ce version 2024-07-20 10:17:12 +00:00
Mario
6276f36b90 sse: add pdl files 2024-07-20 10:16:32 +00:00
Mario
2461e709d2 sse: add pdl files 2024-07-20 10:16:24 +00:00
Mario
1055718935 sse: add pdl files 2024-07-20 10:16:13 +00:00
Mario
82f69018a6 sse: more work on notifications 2024-07-20 10:15:44 +00:00
Mario
c22f633ae0 Revert "more work on sse sys messages"
This reverts commit 983fc84f28
2024-07-20 10:00:47 +00:00
Mario
c71eb401c0 Revert "sse: reset session after connection aborted"
This reverts commit 3d03c24f06
2024-07-20 10:00:14 +00:00
Mario
5a1079750e bump version 2024-07-20 07:09:27 +00:00
Mario
3d03c24f06 sse: reset session after connection aborted 2024-07-19 23:14:47 +00:00
Mario
983fc84f28 more work on sse sys messages 2024-07-19 19:35:21 +00:00
Mario
1861eeeb0a more f arg removal 2024-07-19 11:55:21 +00:00
Mario Vavti
663aeca2a7 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-07-19 13:54:16 +02:00
Mario Vavti
526730672a use the same url for attachment and body. otherwise we can not deduplicate at the receiving side. 2024-07-19 13:53:58 +02:00
Mario
7f292d4765 remove unused functions and start removing the ominous f argument 2024-07-19 09:12:50 +00:00
Mario
99bff67168 version 9.2.1 2024-07-18 08:55:07 +00:00
Mario
bb3caeb629 Merge branch 'dev' 2024-07-18 08:54:21 +00:00
Mario
65185a70d5 changelog 2024-07-18 08:52:28 +00:00
Mario
6d1f34284b bump version 2024-07-17 14:58:49 +00:00
Mario
2cfdbbd956 sse: revert removing of reset after 30 seconds and save a db lookup if we have just reset 2024-07-17 14:34:46 +00:00
Mario
5f66ad5bc5 fix php warning 2024-07-17 13:22:17 +00:00
Mario
aff11443b4 gd: check if function exists - obviously this can change after the initial install where we check this 2024-07-17 13:17:30 +00:00
Mario
6ced7ecf89 missing pdl for mod import 2024-07-15 10:34:43 +00:00
Mario
2d467a15ba dbesc the workinfo json 2024-07-15 10:29:12 +00:00
Mario
28c8229218 always use ob_end_flush() and reduce code duplication 2024-07-15 10:16:54 +00:00
Mario
0bcecc4baa make sure we always have an object which was not the case when repeating one of our own items 2024-07-15 10:12:02 +00:00
Mario
78e68519e8 do not handle non sys notifications if we are in sys only mode 2024-07-10 08:52:23 +00:00
Mario
d2b06995c7 more work on making sure system notifications appear on page reload 2024-07-10 08:40:51 +00:00
Mario
5cbae0fb81 improve handling of sse especially in relation with page reloads 2024-07-08 20:35:08 +00:00
Mario
2ddc087512 notifications: provide possibility to only display system notofications 2024-07-07 13:24:26 +00:00
Mario
b0fe94b4b3 adjust release date 2024-07-06 11:29:36 +00:00
Mario
45275910e6 Merge branch '9.2RC' 2024-07-06 11:05:22 +00:00
Mario
c04e781926 version 9.2 2024-07-06 11:04:43 +00:00
Mario
09a609ef6b Merge branch 'dev' into 9.2RC 2024-07-06 11:02:56 +00:00
Mario
213ee83a92 update changelog 2024-07-06 10:29:13 +00:00
Mario
db5e524e3c Merge branch 'dev' into 9.2RC 2024-07-04 10:13:28 +00:00
Mario
f882c44fb3 fix wrong logic after last commit 2024-07-04 10:13:08 +00:00
Mario
8f9e9116df revert the strlen check 2024-07-04 09:43:20 +00:00
Mario
04a35dac9a revert the strlen check 2024-07-04 09:41:21 +00:00
Mario
ed03befa02 fix possible php error 2024-07-04 09:31:13 +00:00
Mario
f944f46744 fix possible php error 2024-07-04 09:30:21 +00:00
Mario
3f5c45a567 Merge branch 'dev' into 9.2RC 2024-06-28 18:19:34 +00:00
Mario
464149e22d fail to import more gracefully if a channel has already been imported at some point but was deleted again 2024-06-28 18:18:35 +00:00
Mario
b51ed67efb Merge branch 'dev' into 9.2RC 2024-06-27 20:02:54 +00:00
Mario
30ba0661aa fix php error 2024-06-27 20:01:52 +00:00
Mario
afdc3d6d18 Merge branch 'dev' into 9.2RC 2024-06-27 19:23:20 +00:00
Mario
26cb32612d fix display issue for doubleleft template 2024-06-27 19:23:00 +00:00
Mario
6a710c3cc3 fix version 2024-06-27 08:29:01 +00:00
Mario
7028e07535 adjust right margin of profile images 2024-06-27 08:27:54 +00:00
Mario
6666bdfda9 version 9.3 2024-06-27 07:47:39 +00:00
Mario
3e57f150bc version 9.2RC1, strings and dump composer autoload files 2024-06-27 07:44:05 +00:00
Mario
a50b3181ad make sure we get a scrollbar if everything else breaks and remove some unused css 2024-06-26 10:27:13 +00:00
Mario
de992452ee use the doubleleft template by default for admin pages to work around some display issues. Also notifications, etc. are not really useful there 2024-06-26 10:12:22 +00:00
Mario
4cddc3d0df fix php error 2024-06-26 09:35:53 +00:00
Mario
241d96e9fa bump version 2024-06-25 09:29:08 +00:00
Mario
8ae6e785f3 reflect the censored state in the local xchan and exclude toplevel posts by censored channels in the public stream 2024-06-25 09:27:59 +00:00
Mario
1c34c354cf fix issue where event items were parsed multiple times 2024-06-21 10:18:40 +00:00
Mario
0f02553d12 move template to wiki addon 2024-06-18 09:07:05 +00:00
Mario
3f5cfc8fa2 fix return to blank page after editing post under some circumstances 2024-06-18 07:18:09 +00:00
Mario
0097840e32 Merge branch 'misc-fixes' into 'dev'
Add module test helper expectRedirectTo + api docs

See merge request hubzilla/core!2138
2024-06-17 08:52:01 +00:00
Mario
082b615e50 Merge branch 'add-tests-for-create-identity' into 'dev'
Add tests for create_identity + fixes

See merge request hubzilla/core!2137
2024-06-17 08:48:27 +00:00
Harald Eilertsen
62cbd87e71 Update API docs for Module test case base class. 2024-06-16 08:57:09 +02:00
Harald Eilertsen
72453c49f8 tests: Add helper expectRedirectTo to module test class.
Just a shorthand for manually stubbing `goaway` and setting the
expectations on the test case.
2024-06-16 08:56:43 +02:00
Harald Eilertsen
66ea277045 Refactor is_local_url() and add api doc. 2024-06-16 08:56:20 +02:00
Harald Eilertsen
40a93d92c8 Missing include in QueueWorker. 2024-06-15 13:01:17 +02:00
Harald Eilertsen
7df701b434 Use empty() to check if array entry exist in create_identity. 2024-06-14 20:24:52 +02:00
Harald Eilertsen
d760790643 Add basic test for create_identity function.
Not an exhaustive test for now, but does at least excercise some of the
code.
2024-06-14 16:43:38 +02:00
Harald Eilertsen
1ed8383c33 Allow passing callable as array to hooks. 2024-06-14 16:43:38 +02:00
Harald Eilertsen
d139f2fe87 QueueWorker: Use DbaTransaction class for db transactions.
This makes sure that the system knows whether a transaction is active or
not, and ensures automatic cleanup if the transaction is not closed
before the methods return.

It also allows us to run this code in tests. When run within a test, the
transaction will be ignored, as the entire test is run within an
already existing transaction. Also as each test has their own db
connection, this should not have any ill effects, as there should not be
any way in which different simultaneous connections can interfere with
the db updates.
2024-06-14 12:10:35 +02:00
Harald Eilertsen
20a8da0683 tests: Remove obsolete stubs from Permissions tests
These stubs are no longer needed, as the tests have a db now.
2024-06-14 12:10:35 +02:00
Mario
ff018b975b Merge branch 'fix-rpost-module' into 'dev'
Refactoring and fixed for Module\Rpost

See merge request hubzilla/core!2136
2024-06-13 19:07:05 +00:00
Harald Eilertsen
fcd657040e Module\Rpost: Just a little bit of doc. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
605f982520 Module\Rpost: Redirect to submitted post on success.
This eliminates a open redirect issue where it was possible to craft a
link that when clicked would take the victim to an external site
controlled by an attacker.
2024-06-13 13:34:20 +02:00
Harald Eilertsen
fb1c66fbc9 Fix warnings exposed by tests.
Mainly missing variables for templates, and channel entries.
2024-06-13 13:34:20 +02:00
Harald Eilertsen
d02fa7c268 Module\Rpost: Add return type and visibilty for get. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
5abe14982a tests: More tests for Module\Rpost.
Also refactor the tests a bit to avoid duplicatng code.
2024-06-13 13:34:20 +02:00
Harald Eilertsen
8be9b109fd Module\Rpost: Refactor handling of attachments.
Move to private function for now.
2024-06-13 13:34:20 +02:00
Harald Eilertsen
91147d5c5b Module\Rpost: Reuse value of local_chanel.
We don't need to call it twice (actually trice in the original code).
2024-06-13 13:34:20 +02:00
Harald Eilertsen
08d4bd94fa Module\Rpost: Refactor redirect or login logic. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
76a92ac2e1 tests: Module\Rpost shows login form if not authenticated. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
7c688de9cd tests: Add comment to Tests\Unit\Module\RpostTest. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
93a45be181 tests: Set query string in Module\TestCase::get method. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
d187c0025a tests: Configure system.baseurl for tests. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
4e9432263a Module\Rpost: Remove obsolete local variable $o. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
0d4c3fd215 Module\Rpost: Remove unused local variables. 2024-06-13 13:34:20 +02:00
Harald Eilertsen
62aefadc27 Module\Rpost: Add basic test and fix session access.
Just a basic test to ensure that the module `get()` method behaves
somewhat reasonable when no query params are given.

Had to make a small change to the Rpost module itself. Since the
`$_SESSION` superglobal may not always be set (and is not in the test),
use `isset` instead of `array_key_exists` to check if we have saved
query params in the session.

In general, isset is safer than array_key_exists if there's a chance
that the array itself may not exist.
2024-06-13 13:34:20 +02:00
Mario
6e0d0e3832 docu and remove superfluous break statement after return statement 2024-06-13 10:17:13 +00:00
Mario
798e870e71 Merge branch 'add-config-for-phpcs' into 'dev'
Add config file and rules for PHP Code Sniffer.

See merge request hubzilla/core!2135
2024-06-13 09:38:35 +00:00
Mario
6a63a38e8d Merge branch 'fix-test-warnings' into 'dev'
Fix test warnings

See merge request hubzilla/core!2134
2024-06-13 09:37:21 +00:00
Harald Eilertsen
9199a1ba81 Add config file and rules for PHP Code Sniffer.
The rules are based on the "Generic" ruleset included by PHP Code
Sniffer, with a significant portion of the rules disabled. This is a
tradeoff between getting some useful feedback, and not being overloaded
by noise.

I've tried to encode a coe style that resembles the existing code as
much as possible, but have included some sniffs that requires code
changes to satisfy the style. This is meant as a starting point, and we
can disable or enable more sniffs as we see fit.

PHPCS also has ready rule sets for other common coding standards we may
want to gravitate towards, e.g. PSR-12. Others are available from the
community.

The best way to run PHPCS is to integrate it with your editor, so that
it will display diacnostics inline when saving or modifying the code. It
can also be run from the command line like this:

    ./vendor/bin/phpcs -n [<path-to-file-to-check>]

If no file is specified it will try to check the entire project.

The `-n` means don't bother with warnings (I recommend that to begin
with. Enable the warnings when the errors are taken care of.)
2024-06-12 23:53:20 +02:00
Harald Eilertsen
ac1e20b188 Module\Setup: Don't access static variable as non static. 2024-06-12 15:13:48 +02:00
Harald Eilertsen
ad9fb4d530 Module\Help: Only variables can be passed by reference.
Introduce an intermediate variable when extracting the file type from
the file name. Otherwise we would try to pass a returned value as a
reference.
2024-06-12 15:13:24 +02:00
Harald Eilertsen
ffc2455bea Module\Rbmark: Pass all fields to input field templates. 2024-06-12 15:12:54 +02:00
Harald Eilertsen
0a818191c1 boot/login: Pass all expected args to sub templates. 2024-06-12 15:12:24 +02:00
Harald Eilertsen
c7ec3159ea Module\Rbmark: Specify all fields in the template.
The `field_select` sub template wants five elements in the `field`
array.
2024-06-12 15:12:09 +02:00
Harald Eilertsen
4d5a7ec39f includes/menu: Fix timestamp handling in menu_create.
Referencing undefined array keys are not allowed anymore, so we need to
check whether they exist first.
2024-06-12 15:12:00 +02:00
Harald Eilertsen
13c074f8b8 Module\Setup: Pass all required params for the template.
Non-existing keys in the array passed to the template causes a warning.
Also make optional parts of the template actually optional by skipping
them if the value is empty.
2024-06-12 15:11:27 +02:00
Mario
088a87914f remove not needed namespace 2024-06-11 09:00:43 +00:00
Mario
5110dcb912 remove not required includes and include security.php in boot.php 2024-06-11 08:58:35 +00:00
Mario
64748cf1f1 cleanup unused code 2024-06-11 08:52:10 +00:00
Mario
4ba4b2976e pass the force argument to the xchan_photo daemon 2024-06-11 07:42:43 +00:00
Mario
06183ba01a duplicate array key 2024-06-10 10:00:25 +00:00
Mario
539ae37553 too many args 2024-06-10 09:50:06 +00:00
Mario
8f41d170a5 fix wrong variable 2024-06-10 09:45:33 +00:00
Mario
d9e97a7c1f remove superfluous backslash 2024-06-10 09:35:13 +00:00
Mario
51fe071c5e Ãfix undefined variable 2024-06-10 09:16:21 +00:00
Mario
c5cab3004f remove duplicate array key 2024-06-10 09:09:36 +00:00
Mario
9c62514c1b docu 2024-06-10 08:58:32 +00:00
Mario
0428a97e00 docu 2024-06-10 08:56:59 +00:00
Mario
43a2c21d87 fix updated not supported in wrapper function 2024-06-10 08:40:39 +00:00
Mario
69862bc6df docu and declare return type for t() 2024-06-10 08:26:06 +00:00
Mario
388e7c88df remove superfluous param, fix wrong var and declare types for unparse_url() 2024-06-10 08:22:43 +00:00
Mario
9348bd6ea5 remove unused variable and superfluous backslash 2024-06-10 08:02:32 +00:00
Mario
0c1d0f7498 version 9.0.2 2024-06-07 09:25:15 +00:00
Mario
81ba070e1a update changelog
(cherry picked from commit bd5f77dbeb)

Co-authored-by: Mario <mario@mariovavti.com>
2024-06-07 09:23:32 +00:00
Mario
a7812657f1 update changelog
(cherry picked from commit d862a6f075)

Co-authored-by: Mario <mario@mariovavti.com>
2024-06-07 09:23:02 +00:00
Mario
bd5f77dbeb update changelog 2024-06-07 09:21:43 +00:00
Mario
d862a6f075 update changelog 2024-06-07 09:19:50 +00:00
Mario
18725c47a0 move button class to the right dom
(cherry picked from commit 59b8c8ad48)

Co-authored-by: Mario <mario@mariovavti.com>
2024-06-07 09:12:32 +00:00
Mario
59b8c8ad48 move button class to the right dom 2024-06-07 09:11:09 +00:00
Mario
494ff44a69 adjusting to the wrong direction when exporting ical and do not use Z because timezone is attached 2024-06-05 10:04:16 +00:00
Mario
5efc6bdd2f bump version 2024-06-05 08:09:26 +00:00
Mario
4835758293 Merge branch 'correct-type-annotation-for-config-get' into 'dev'
Correct type annotation in comment for Config::Get.

See merge request hubzilla/core!2127
2024-06-05 08:01:04 +00:00
Harald Eilertsen
d0bb3a7354 Correct type annotation in comment for Config::Get. 2024-06-05 08:01:04 +00:00
Mario
14df925aa6 Merge branch 'disable-mfa-for-dav-and-cdav' into 'dev'
Skip checking MFA status for WebDAV and CardDAV requests.

See merge request hubzilla/core!2131
2024-06-05 07:59:42 +00:00
Harald Eilertsen
350f84913a Skip checking MFA status for WebDAV and CardDAV requests. 2024-06-05 07:59:42 +00:00
Mario
78ab2e33ef Merge branch 'fetch-url-default-timeout' into 'dev'
Fix default timeouts for z_(fetch|post)_url.

See merge request hubzilla/core!2132
2024-06-05 07:55:53 +00:00
Mario
75e1b70584 php warnings/errors
(cherry picked from commit 10d1cbd3ce)

Co-authored-by: Mario <mario@mariovavti.com>
2024-06-04 09:09:41 +00:00
Mario
1dc73935d9 deal with inReplyTo array
(cherry picked from commit 2145207ad2)

Co-authored-by: Mario <mario@mariovavti.com>
2024-06-04 09:08:32 +00:00
Mario
7d7b43c5b9 hotfix to mitigate queueworker crash
(cherry picked from commit a4d63ab9a3)

Co-authored-by: Mario <mario@mariovavti.com>
2024-06-04 09:06:50 +00:00
Mario
a4d63ab9a3 hotfix to mitigate queueworker crash 2024-06-04 09:05:34 +00:00
Harald Eilertsen
c009c5f43a Fix default timeouts for z_(fetch|post)_url.
When fetching the default timouts from config, the result is converted
to an int via `intval()`, the result of that again is compared strictly
to `false`. Since 0 !== false, the default values will never be used,
and 0 (no timeout) is passed to curl.

This cause requests to hang indefinitely (or until they are killed) when
receiving actions that require a lookup or fetch to another site as part
of the request processing. (E.g webfinger, or fetching objects that we
received an announce action for.) This again cause the request never to
return a useful status to the site sending the action, and could cause
them to think the Hubzilla site is dead.

This patch fixes this by comparing the fetched value from config to 0
instead of false, making the defaults work again if the config is not
set (or set to 0).
2024-05-29 22:50:02 +02:00
Mario
9d56bb952e Merge branch 'doc/update-member-tag-and-mention-docs' into 'dev'
Member docs: Update docs on tags and mentions.

See merge request hubzilla/core!2130
2024-05-27 06:25:43 +00:00
Mario
84abf28cec Merge branch 'update-phpunit-10x' into 'dev'
Upgrade test framework to PHPUnit 10.5

See merge request hubzilla/core!2128
2024-05-27 06:17:05 +00:00
Harald Eilertsen
cad82d12d2 Upgrade test framework to PHPUnit 10.5 2024-05-27 06:17:05 +00:00
Harald Eilertsen
1846ed75bf Minor style update for the .abook-self CSS class.
It was hardcoded to a blindingly white, which did not work too well with
the white text in dark mode. Use a proper bootstrap var, so it follows
the prefered color scheme instead.
2024-05-25 12:25:13 +02:00
Harald Eilertsen
0a6bb06f86 Member docs: Update dogs on tags and mentions.
Rewrote it and corrected some outdated information about how to tag
forums etc. Also cleaned up the markup a bit.

Added information and links about which apps and admin addons are
required for given functionality.

Also added some images to help illustrate some subjects.

Uncertain about whether the information on how the autocomplete popup is
populated is correct anymore. Underlined it and added a question mark to
make sure it annoys someone (possibly me) to figure it out.
2024-05-25 12:20:14 +02:00
Mario
a10402a788 Merge branch 'refactor-module-rbmark' into 'dev'
Refactor and cleanup Rbmark module + add tests

See merge request hubzilla/core!2126
2024-05-15 08:28:19 +00:00
Harald Eilertsen
5da0cc138f Refactor and cleanup Rbmark module + add tests 2024-05-15 08:28:19 +00:00
Mario
2145207ad2 deal with inReplyTo array 2024-05-15 07:38:07 +00:00
Mario
f086dfd8ca missing semicolon and code readability 2024-05-14 09:05:02 +00:00
Mario
26cfc29303 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-05-14 09:01:19 +00:00
Mario
10d1cbd3ce php warnings/errors 2024-05-14 09:00:43 +00:00
Mario
1299fdb7be Merge branch 'remove-unused-modules' into 'dev'
Remove unused Toggle_(safesearch|mobile) modules.

See merge request hubzilla/core!2125
2024-05-13 07:42:18 +00:00
Harald Eilertsen
430347a295 Remove unused Toggle_(safesearch|mobile) modules. 2024-05-13 07:42:17 +00:00
Mario
960354b16c make mod regate return to system.workflow_channel_next and show register message field only if registration is set to register_approve 2024-05-08 19:27:48 +00:00
Mario
481e08b904 remove p tags from li. otherwise we will get unwanted new lines in the list. add test. 2024-05-08 15:41:54 +00:00
Mario
76ce4705e2 more fixes for issue #1843 2024-05-08 14:34:44 +00:00
Mario Vavti
7a5bb99d87 make sure the hcard addon markup will be available even if other profile entries are missing 2024-05-08 12:18:00 +02:00
Mario
11d7a4c9f7 Merge branch 'rename-help-helper-trait' into 'dev'
Rename HelpHelper to HelpHelperTrait.

See merge request hubzilla/core!2124
2024-05-07 09:04:45 +00:00
Mario
9dd63db736 add tests 2024-05-07 08:56:25 +00:00
Mario
f74922db39 add bbcode support for the HTML5 del tag 2024-05-07 08:52:05 +00:00
Mario
605aa37ad3 apply li fixes to html2plain 2024-05-03 11:50:29 +00:00
Mario
262cebb568 make parsing of li slightly more robust 2024-05-03 13:38:45 +02:00
Harald Eilertsen
bfa81490c1 Rename HelpHelper to HelpHelperTrait.
PHPCS prefers traits to be suffixed with "Trait", and I think I agree.
2024-05-03 13:00:14 +02:00
Mario
219f0dfeca also deal with ol and ul tags earlier and add test for double nested lists 2024-05-03 12:04:19 +02:00
Mario
3a50a0b715 deal with li tags earlier seems to be more straight forward also add test for li without closing tag 2024-05-03 10:23:36 +02:00
Mario
b25662e183 fix nested lists by parsing li before ul or ol and add a test 2024-05-03 09:39:58 +02:00
Mario
47a86f8771 make sure to always move the recent notification to the top 2024-05-03 06:52:05 +00:00
Mario
07696d4bd1 fix the test - we do not use a title anymore since it does not make much sense in combination of the sub titles 2024-05-02 19:24:13 +00:00
Mario
52e97fe115 some css voodoo for the help menu 2024-05-02 18:36:16 +00:00
Mario
58033f3255 bump version 2024-05-02 17:52:08 +00:00
Mario
ba4773a61e add some deduplication 2024-05-02 17:51:39 +00:00
Mario
977e6a02f4 another css fix 2024-05-02 17:21:53 +00:00
Mario
6a53ddef21 css fix and bump version 2024-05-02 14:50:57 +00:00
Mario
2fb9c0ec0d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-05-02 14:45:26 +00:00
Mario
98c3e2f93f remove jgrowl 2024-05-02 14:44:16 +00:00
Mario
fb4568001d Merge branch 'fix-broken-get_rpost_path' into 'dev'
Libzot: get_rpost_path was broken for URL's with no port.

See merge request hubzilla/core!2123
2024-05-02 14:43:22 +00:00
Mario
5eab32a65b Merge branch 'improve-unit-test-docs' into 'dev'
Improve docs for UnitTestCase class.

See merge request hubzilla/core!2122
2024-05-02 14:16:16 +00:00
Mario
483221e2a8 remove redundant comma 2024-05-02 14:15:31 +00:00
Mario
2e575dee52 css fix 2024-05-02 14:09:09 +00:00
Mario
058c7d6c13 start removing jgrowl 2024-05-02 13:00:45 +00:00
Harald Eilertsen
630cecd740 Libzot: get_rpost_path was broken for URL's with no port. 2024-05-01 20:57:56 +02:00
Harald Eilertsen
4d29cffde5 Improve docs for UnitTestCase class. 2024-05-01 17:03:03 +02:00
Mario
c6116e367a Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-04-30 07:01:19 +00:00
Mario
b6e6cecf70 Merge branch 'cherry-pick-60cd7cc8' into 'dev'
Fix some errors in Spanish strings

See merge request hubzilla/core!2121
2024-04-30 07:00:03 +00:00
Mario
ce15852b9a Merge branch 'rework-help-module' into 'dev'
Rework Help module + begin tests for Setup module

See merge request hubzilla/core!2120
2024-04-30 06:59:20 +00:00
Harald Eilertsen
7c34a3676d Rework Help module + begin tests for Setup module 2024-04-30 06:59:19 +00:00
mjfriaza:4GF~eYj,-iAv
1c92c7476b Fix some errors in Spanish strings
(cherry picked from commit 60cd7cc8d09240e1a3f7f7b3bde75115a61ce4de)
2024-04-28 14:26:41 +00:00
Mario
80e124f53e remove logging 2024-04-20 18:57:37 +00:00
Mario
48cec94505 Merge branch 'global-state-and-some-docs' into 'dev'
Reduce some global state and add some docs

See merge request hubzilla/core!2119
2024-04-18 09:55:43 +00:00
Harald Eilertsen
26c1fa07c9 Reduce some global state and add some docs 2024-04-18 09:55:42 +00:00
Mario
78a6774206 Merge branch 'cherry-pick-4e5c6f9b' into 'dev'
Update Spanish

See merge request hubzilla/core!2118
2024-04-18 08:31:52 +00:00
Mario
3b812f2570 comment out deprecated way to find forum items and do not count announce activities 2024-04-17 10:00:40 +00:00
Mario
2e15207d0b fix spacing issues in mod wall_attach and make save_chunk() deal with userfile and file array keys 2024-04-17 07:45:20 +00:00
Mario
716013633e passing an empty filter to deliverable_abook_xchans() will return all deliverable abook xchans - we do not want this in this place. also add some docu 2024-04-17 07:39:22 +00:00
Mario
1ca91c49aa add some docu 2024-04-17 07:36:49 +00:00
Mario
7de629a8c3 update siteinfo 2024-04-05 12:56:51 +00:00
Mario
592359ef49 minor refactor and store import host for possible later use 2024-04-05 11:09:15 +00:00
Mario
a56d727c26 allow to kick off sync process in case it did not start at all. requires import host to be set manually in pconfig for now. 2024-04-05 10:40:16 +00:00
mjfriaza:4GF~eYj,-iAv
0b2781f42e Update Spanish
(cherry picked from commit 4e5c6f9bbaa702d9ccd5606a166c8e65224b8d8f)
2024-03-30 11:39:12 +00:00
Mario
b5223a4efb add pdl for mod home
(cherry picked from commit fe43e0994f)
2024-03-27 10:01:33 +00:00
Mario
fe43e0994f add pdl for mod home 2024-03-27 10:00:18 +00:00
Mario
d71c2c245f reduce default directory result set
(cherry picked from commit f85d2d3423)
2024-03-26 14:59:45 +00:00
Mario
f85d2d3423 reduce default directory result set 2024-03-26 14:48:16 +00:00
Mario
3859c010f0 bump version 2024-03-26 10:06:49 +00:00
Mario
526729c0f1 changelog
(cherry picked from commit 418b1eaf78)
2024-03-26 10:06:05 +00:00
Mario
1cd3369f6a version 9.0.1 2024-03-26 09:53:38 +00:00
Mario
418b1eaf78 changelog 2024-03-26 09:51:09 +00:00
Mario
c26ae553e6 if the updated item contains an open modal, the modal we be replaced with the new data but the backdrop will stay because it is attached to the end of the page -> remove it
(cherry picked from commit e0ac7b7f9f)
2024-03-26 09:28:25 +00:00
Mario
e0ac7b7f9f if the updated item contains an open modal, the modal we be replaced with the new data but the backdrop will stay because it is attached to the end of the page -> remove it 2024-03-26 09:26:18 +00:00
Mario
8d78698d00 deprecated bootstrap namespace in list mode
(cherry picked from commit 80d1e07908)
2024-03-25 21:53:25 +00:00
Mario
d5c189753a wrong dreport link in blog mode
(cherry picked from commit f72f5c7321)
2024-03-25 21:53:06 +00:00
Mario
9861e7a0c4 more bootstrap override
(cherry picked from commit a5d483fb5d)
2024-03-25 21:52:42 +00:00
Mario
6d5fa9205c more remove additional linebreaks after block element plus test
(cherry picked from commit 53354a1930)
2024-03-25 21:52:14 +00:00
Mario
0fee7804fb allow to run additional site specific commands at the end of util/udall
(cherry picked from commit c052b7fa99)
2024-03-25 21:51:49 +00:00
Mario
80d1e07908 deprecated bootstrap namespace in list mode 2024-03-25 21:48:25 +00:00
Mario
f72f5c7321 wrong dreport link in blog mode 2024-03-25 21:42:32 +00:00
Mario
a5d483fb5d more bootstrap override 2024-03-25 20:44:22 +00:00
Mario
26a7cef0d8 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-03-25 21:43:15 +01:00
Mario
53354a1930 more remove additional linebreaks after block element plus test 2024-03-25 21:42:50 +01:00
Mario
c052b7fa99 allow to run additional site specific commands at the end of util/udall 2024-03-25 19:47:17 +00:00
Mario
9ecd38911e add observer to the permissions query. this should not be necessary but it makes it clear why it should be included in the cache key
(cherry picked from commit 57e32a7912)
2024-03-25 17:32:52 +00:00
Mario
4002dbaa8b Merge branch 'master' of https://framagit.org/hubzilla/core 2024-03-25 17:32:11 +00:00
Mario
57e32a7912 add observer to the permissions query. this should not be necessary but it makes it clear why it should be included in the cache key 2024-03-25 17:31:53 +00:00
Mario
b6a72d6e4e tilt the piin
(cherry picked from commit 637f39f282)
2024-03-25 17:19:32 +00:00
Mario
6e592ed200 add the observer hash to the cache key in categories_widget() 2024-03-25 17:18:26 +00:00
Mario
637f39f282 tilt the piin 2024-03-25 17:15:05 +00:00
Mario
842df8a799 add the observer hash to the cache key in categories_widget() 2024-03-25 16:09:53 +00:00
Mario
6c033fc776 Merge branch 'fix-category-widget-template' into 'dev'
Fix smarty deprecation warning in category widget.

See merge request hubzilla/core!2116

(cherry picked from commit 2ff84ab25a)

b139e5bb Fix smarty deprecation warning in category widget.
2024-03-25 14:21:39 +00:00
Mario
2ff84ab25a Merge branch 'fix-category-widget-template' into 'dev'
Fix smarty deprecation warning in category widget.

See merge request hubzilla/core!2116
2024-03-25 14:21:07 +00:00
Mario
01c6fd03b7 fix typo after get_config -> Confi::Get conversion 2024-03-25 14:15:28 +00:00
Harald Eilertsen
b139e5bb00 Fix smarty deprecation warning in category widget. 2024-03-25 12:26:06 +01:00
Mario
7c4362db53 make sure we preserve linefeeds in the actual content of lists and tables also add tests
(cherry picked from commit 3c0d6339bb)
2024-03-24 17:00:56 +00:00
Mario
3c0d6339bb make sure we preserve linefeeds in the actual content of lists and tables also add tests 2024-03-24 17:50:27 +01:00
Mario
a0cfe22501 Merge branch 'deprecate-include-config-in-core' into 'dev'
Deprecate *_config() functions in core.

See merge request hubzilla/core!2114
2024-03-24 09:58:21 +00:00
Harald Eilertsen
0dc959d9fe Deprecate *_config() functions in core. 2024-03-24 09:58:21 +00:00
Mario
f7bf9ede72 revert default to activity type Article until we have a more stable solution to override it for platforms which do not support it
(cherry picked from commit ecdd9a4d6e)
2024-03-23 11:20:44 +00:00
Mario
ecdd9a4d6e revert default to activity type Article until we have a more stable solution to override it for platforms which do not support it 2024-03-23 11:19:24 +00:00
Mario
1aeb05628b Merge branch '9.0RC' 2024-03-22 08:37:29 +00:00
Mario
b464fae3bf version 9.0 2024-03-22 08:36:38 +00:00
Mario
a34ce0732d Merge branch 'dev' into 9.0RC 2024-03-22 08:36:07 +00:00
Mario
f457b6623d changelog 2024-03-22 08:35:55 +00:00
Mario
01ebd51fb2 Merge branch 'dev' into 9.0RC 2024-03-22 08:27:18 +00:00
Mario
cb25fc031b use the correct tag for ordered lists 2024-03-22 08:23:44 +00:00
Mario
6c6fc82f43 Merge branch 'dev' into 9.0RC 2024-03-22 08:15:20 +00:00
Mario
990017b588 remove some unused variables 2024-03-22 08:14:41 +00:00
Mario
192ab22cda Merge branch 'dev' into 9.0RC 2024-03-21 20:48:33 +00:00
Mario
5e5a0d7c91 remove friendica specific hack that is not needed anymore 2024-03-21 20:48:10 +00:00
Mario
2dc1adf091 Merge branch 'dev' into 9.0RC 2024-03-21 11:37:55 +00:00
Mario
371b8440c3 adjust tests after recent commit 2024-03-21 11:04:03 +00:00
Mario
49509e7347 more whitespace fixes and some docu 2024-03-21 09:47:34 +00:00
Mario
66f5b34c07 possible fix for issue #1843 2024-03-20 21:08:23 +00:00
Mario
6a3d372050 RC3 2024-03-20 19:41:28 +00:00
Mario
c95359024c Merge branch 'dev' into 9.0RC 2024-03-20 19:39:00 +00:00
Mario
edf898d7b7 it appears the smallest size for pt videos is now 720 2024-03-20 19:33:50 +00:00
Mario
ee0060619d css fix 2024-03-20 15:25:38 +00:00
Mario
4f8ede35bd Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-03-20 13:37:11 +00:00
Mario
9d9c102da8 no extra margin under lists 2024-03-20 13:36:55 +00:00
Mario
3de8f5e7de deal with wihitespace issues in tables and lists and add tests 2024-03-20 14:35:43 +01:00
Mario
a18e873d08 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-03-20 09:31:58 +01:00
Mario
b3c260a145 fix reshares from streams loosing image 2024-03-20 09:31:17 +01:00
Mario
1097bcdaf9 Merge branch 'dev' into 9.0RC 2024-03-19 09:53:33 +00:00
Mario
cfde1be097 Merge branch 'dev' into 'dev'
Recreated hmessage.po for pt-br

See merge request hubzilla/core!2115
2024-03-19 09:51:15 +00:00
Pascal Deklerck
6df4da5313 Recreated hmessage.po for pt-br 2024-03-19 09:51:14 +00:00
Mario
f910de849f Merge branch 'dev' into 9.0RC 2024-03-19 09:46:21 +00:00
Mario
d6eaeba239 changelog
(cherry picked from commit 5c2e10c01e)
2024-03-19 09:45:36 +00:00
Mario
5c2e10c01e changelog 2024-03-19 09:44:18 +00:00
Mario
8754f72e63 fix cover photos not uploaded into folder due to missing source option 2024-03-19 10:39:59 +01:00
Mario
569f243ebd Merge branch 'dev' into 9.0RC 2024-03-18 22:10:16 +00:00
Mario
651a3f8380 docu 2024-03-18 22:09:05 +00:00
Mario
40714ecdd0 changelog 2024-03-18 22:02:09 +00:00
Mario
d4b1bcd641 Merge branch 'dev' into 9.0RC 2024-03-18 09:12:58 +00:00
Mario
acc1834b0d make theme compatible with rc version 2024-03-18 09:12:35 +00:00
Mario
e237cf226a Merge branch 'dev' into 9.0RC 2024-03-18 09:10:34 +00:00
Mario
7c5a0887cc css fix 2024-03-18 09:10:07 +00:00
Mario
0745d0616a Merge branch 'dev' into 9.0RC 2024-03-17 21:34:06 +00:00
Mario
9cbb9a4874 theme min/max version and minor css fix 2024-03-17 21:30:50 +00:00
Mario
14f3b72c82 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-03-17 22:22:33 +01:00
Mario
b05845f495 cleanup some ancient code and fix check for $path so that it will not pass if theme_include() will not return anything. also add an empty zen.css file for the zen template 2024-03-17 22:21:55 +01:00
Mario
2114779037 Merge branch 'dev' into 9.0RC 2024-03-17 11:01:27 +00:00
Mario
937b6d360e fix hardcoded color attr 2024-03-17 11:00:50 +00:00
Mario
0d30eed4a7 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-03-17 10:53:32 +00:00
Mario
39d4f67417 add Emoji to the AP schema 2024-03-17 10:53:09 +00:00
Mario
68d989c79e slightly adjust text sizing
(cherry picked from commit 9600789d6b)
2024-03-16 19:40:57 +00:00
Mario
9600789d6b slightly adjust text sizing 2024-03-16 19:39:48 +00:00
Mario
ea7559c158 RC2 2024-03-16 16:24:27 +00:00
Mario
baa12b7497 Merge branch 'dev' into 9.0RC 2024-03-16 16:23:32 +00:00
Mario
ac4aa6a9ea css fixes 2024-03-16 16:22:39 +00:00
Mario
732dbfd6f5 maybe git can be removed again now after the streams lib got removed?
(cherry picked from commit 5860abf46f)
2024-03-16 16:01:36 +00:00
Mario
5860abf46f maybe git can be removed again now after the streams lib got removed? 2024-03-16 15:50:58 +00:00
Mario
2874d3e1e1 Merge branch 'dev' into 9.0RC 2024-03-16 15:47:55 +00:00
Mario
42b0205ad0 apply the streams fixes manually until the addition of the streams library is sorted 2024-03-16 15:47:25 +00:00
Mario
36778850ee Merge branch 'dev' into 9.0RC 2024-03-16 12:18:46 +00:00
Mario
19c0e97658 add git again allthough it is not clear why it is required 2024-03-16 12:18:24 +00:00
Mario
fe018d646a more composer weirdness 2024-03-16 12:09:49 +00:00
Mario
24132e56d9 Merge branch 'dev' into 9.0RC 2024-03-16 11:56:44 +00:00
Mario
8fc0210428 Revert "another attmpt to install streams/php-jcs via composer"
This reverts commit 5af3c35778
2024-03-16 11:54:45 +00:00
Mario
64560cbca9 Revert "try installing git"
This reverts commit 0b4e086376
2024-03-16 11:54:07 +00:00
Mario
6e97c97920 Revert "remove streams folder"
This reverts commit 216f3755fc
2024-03-16 11:53:39 +00:00
Mario
916edcb45e Revert "really add streams folder"
This reverts commit f402baffd3
2024-03-16 11:53:16 +00:00
Mario
8873c10364 Merge branch '9.0RC' of https://framagit.org/hubzilla/core into 9.0RC 2024-03-16 11:50:42 +00:00
Mario
77e1220cf9 fix version 2024-03-16 11:50:16 +00:00
Mario
f402baffd3 really add streams folder 2024-03-16 11:48:27 +00:00
Mario
216f3755fc remove streams folder 2024-03-16 11:45:49 +00:00
Mario
d846cefade adjust encrypted content representation and also add it to bb_to_markdown
(cherry picked from commit f3efdbf230)
2024-03-15 22:36:44 +00:00
Mario
f3efdbf230 adjust encrypted content representation and also add it to bb_to_markdown 2024-03-15 22:34:27 +00:00
Mario
826ef11247 bump dev version 2024-03-15 19:05:55 +00:00
Mario
b68ddc4cd3 version, strings and dump composer autoload 2024-03-15 18:58:01 +00:00
Mario
41f909c415 update redbasic screenshot 2024-03-15 17:36:44 +00:00
Mario
0b4e086376 try installing git 2024-03-15 18:25:53 +01:00
Mario
5af3c35778 another attmpt to install streams/php-jcs via composer 2024-03-15 17:14:31 +01:00
Mario
dddcddc453 refactor sodium b2b encryption 2024-03-15 11:30:28 +00:00
Mario
754d90a676 fix overlay z-index 2024-03-14 19:21:01 +00:00
Mario
8b0dce56ad remove some now redundant css 2024-03-14 19:11:25 +00:00
Mario
42696606e3 wrong logic 2024-03-14 16:03:02 +00:00
Mario
b645ede168 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-03-14 13:35:39 +00:00
Mario
6e12b5ec08 fix shortnames replaced in html tags 2024-03-14 13:35:21 +00:00
Mario
fbf36992be Merge branch 'add-testing-doc' into 'dev'
Add some developer docs for the test system.

See merge request hubzilla/core!2113
2024-03-14 12:42:36 +00:00
Mario
e0de813700 Merge branch 'fix-test-setup-on-mariadb' into 'dev'
Fix test db setup on MySQL/Mariadb + changed default

See merge request hubzilla/core!2112
2024-03-14 12:42:04 +00:00
Harald Eilertsen
39448a0871 Fix test db setup on MySQL/Mariadb + changed default 2024-03-14 12:42:03 +00:00
Mario
4fb37ef6f3 revert adding of zip and bump composer php version to 8.1 2024-03-14 12:40:07 +00:00
Mario
a9d4adaf23 Revert "next try to use the streams php-jcs library until the floats issue will be fixed upstream. see here for reference https://codeberg.org/streams/streams/issues/151"
This reverts commit 70dfce356b.
2024-03-14 12:30:05 +00:00
Mario
70dfce356b next try to use the streams php-jcs library until the floats issue will be fixed upstream. see here for reference https://codeberg.org/streams/streams/issues/151 2024-03-14 11:15:20 +00:00
Mario
10fbfa06e9 add fix again after escaping composer hell 2024-03-14 11:06:32 +00:00
Mario
6315757967 Revert "use the streams php-jcs library until the floats issue will be fixed upstream. see here for reference https://codeberg.org/streams/streams/issues/151"
This reverts commit 81ce67df94.
2024-03-14 11:02:31 +00:00
Mario
9ddd840897 evert "fix deprecation warning"
This reverts commit 898762dd95.
2024-03-14 11:02:10 +00:00
Mario
6c5627ac0e Revert "update lock file"
This reverts commit a93fed5ae2.
2024-03-14 11:01:36 +00:00
Mario
c2d6d376a4 Revert "revert addition of zip"
This reverts commit 55532c7cb1.
2024-03-14 11:01:20 +00:00
Mario
55532c7cb1 revert addition of zip 2024-03-14 10:58:20 +00:00
Mario
a93fed5ae2 update lock file 2024-03-14 10:49:41 +00:00
Mario
ba1b48f177 lets try this 2024-03-14 10:45:09 +00:00
Mario
898762dd95 fix deprecation warning 2024-03-14 10:29:07 +00:00
Mario
81ce67df94 use the streams php-jcs library until the floats issue will be fixed upstream. see here for reference https://codeberg.org/streams/streams/issues/151 2024-03-14 10:18:51 +00:00
Mario
55097c47c5 Revert "composer update and use the fixed streams php-jcs library until the floats issue will be fixed upstream. see here for reference https://codeberg.org/streams/streams/issues/151"
This reverts commit 6bf61dfa6b.
2024-03-14 10:13:22 +00:00
Mario
97b82fc77b fix dreport links after recent changes 2024-03-14 09:53:40 +00:00
Mario
b7bda0b87d return false if we have nothing to look at 2024-03-14 09:47:08 +00:00
Mario
6bf61dfa6b composer update and use the fixed streams php-jcs library until the floats issue will be fixed upstream. see here for reference https://codeberg.org/streams/streams/issues/151 2024-03-14 09:35:09 +00:00
Mario
0e59cfb839 fix code comment 2024-03-13 14:08:56 +01:00
Mario
328ce0a837 fix another regression from last Lib/Config refactor which returned the default falue in case the value was an array. also add a testcase for this situation 2024-03-13 14:05:58 +01:00
Mario
34e24ea5e9 fix modal headerà 2024-03-12 09:11:53 +00:00
Mario
907426af5e deprecated function 2024-03-11 20:42:21 +00:00
Mario
360713c689 add sodium-plus js crypto library 2024-03-10 22:38:21 +00:00
Mario
ee8aba3221 implement sodium-plus library to replace unmaintained sjcl 2024-03-10 22:35:59 +00:00
Harald Eilertsen
ae657754b0 doc: Add some developer docs for the test system.
Not sure if this is too long, or if it would be better to split it into
multiple files. Also, still missing the "How to write your own tests"
section.
2024-03-10 21:41:11 +01:00
Mario
0a730935f5 remove superfluous () 2024-03-10 13:14:10 +01:00
Mario
d285da09fe add the file 2024-03-10 13:12:51 +01:00
Mario
b291f1bad3 move escape_tags() to Lib/Text.php and add test 2024-03-10 13:10:42 +01:00
Mario
e1b660bfa3 we usually use ENT_COMPAT for content, so stick to this 2024-03-10 10:06:15 +00:00
Mario
0036c0cde9 remove logging 2024-03-09 21:00:13 +00:00
Mario
49c1833a46 bump version 2024-03-09 20:58:53 +00:00
Mario
46fa26502b more work on emojis 2024-03-09 20:53:18 +00:00
Mario
ba1e705c61 passing null to mb_strlen() is deprecated 2024-03-08 10:28:48 +00:00
Mario
043e2ff58b check if term is set before processing it 2024-03-08 09:23:31 +00:00
Mario
deba1863f5 fix php warnings 2024-03-08 09:16:27 +00:00
Mario
0e27f010f9 start sending articles instead of notes by default 2024-03-08 08:44:16 +00:00
Mario
45b1be8962 inbound support for custom emojis 2024-03-08 08:42:50 +00:00
Mario
fe9ca30c5e list attachments in the original order 2024-03-07 10:38:08 +00:00
Mario
9e8ba5f6e2 add at the top to maintain original order 2024-03-07 10:16:35 +00:00
Mario
5207e1e774 remove unused include 2024-03-07 09:06:20 +00:00
Mario
c1228d6b6d whitespace 2024-03-07 10:01:46 +01:00
Mario
6262d351b7 fix deprecation warning and add test 2024-03-07 10:00:02 +01:00
Mario
27e57ff7aa fix another php warning 2024-03-06 20:52:36 +00:00
Mario
74fc7508f3 fix php warning 2024-03-06 20:49:01 +00:00
Mario
3eea4f475c Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-03-06 21:10:24 +01:00
Mario
37b22fe542 fix unterminated entity reference error when dealing with domxpath and add a test 2024-03-06 21:08:46 +01:00
Mario
b5b8106e7a minor refactor 2024-03-06 16:08:53 +00:00
Mario
b77100ff6d update fullcalendar 2024-03-06 14:20:21 +00:00
Mario
5eb6572277 update composer libs 2024-03-06 13:57:07 +00:00
Mario
69bed9c889 minor mod thing fixes 2024-03-06 13:04:06 +00:00
Mario
3c88c5e66a cleanup context and introduce schema:identifier for future use 2024-03-06 13:02:22 +00:00
Mario
d40d62ac4f bump version 2024-03-05 10:10:23 +00:00
Mario
d23ed6b11f improve things display a little 2024-03-05 09:45:49 +00:00
Mario
1e2a4a57b6 Merge branch 'fix-admin-site-page' into 'dev'
Remove obsolete field for system lang from site admin page.

See merge request hubzilla/core!2111
2024-03-04 21:37:37 +00:00
Mario
7892eeb2d2 Thing > Page 2024-03-04 21:27:53 +00:00
Mario
d7ceb977da basic AS2 support for things 2024-03-04 21:24:21 +00:00
Harald Eilertsen
36d0594b8e Remove obsolete field for system lang from site admin page.
The field was commented out in the module, but still remained in the
template. This patch also removes some processing to discover available
languages whose result were not used.

This should fix https://framagit.org/hubzilla/core/-/issues/1840
2024-03-03 12:30:27 +01:00
Mario
3f32a5239d we are checking for null|array union type later - false would throw an error 2024-03-01 19:17:57 +00:00
Mario
15a7d2d4de Merge branch 'some-bbcode-cleanup' into 'dev'
Add some beginning tests for bbcode, and a bit of refactoring

See merge request hubzilla/core!2110
2024-03-01 16:18:07 +00:00
Harald Eilertsen
80ed2ff89a Add some beginning tests for bbcode, and a bit of refactoring 2024-03-01 16:18:07 +00:00
Mario
37a0343163 Merge branch 'update-doxygen-config' into 'dev'
Update Doxygen config for generating online API docs

See merge request hubzilla/core!2109
2024-03-01 16:14:00 +00:00
Mario
8529e2f14e Merge branch 'dba-transactions' into 'dev'
include/dba: Make Dba driver transaction aware.

See merge request hubzilla/core!2108
2024-03-01 16:11:24 +00:00
Mario
b73401bd7f handle imagick readImageBlob() exception 2024-03-01 16:01:53 +00:00
Mario
af839a0589 AS2 Follow/Ignore 2024-03-01 15:47:40 +00:00
Mario
4bbeb224f6 more cleanup 2024-02-29 21:11:39 +00:00
Mario
8435d9eb13 some cleanup 2024-02-29 17:35:05 +00:00
Mario
d97df1859f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-02-29 17:06:18 +00:00
Mario
46f67eaa1e AS2 Update and implement a first draft of AS2 Profile activities 2024-02-29 17:05:48 +00:00
System user; root
54451851bb changelog
(cherry picked from commit 5d64a9c90f)
2024-02-29 10:19:46 +00:00
System user; root
5b7387459c version 8.8.8 2024-02-29 11:05:01 +01:00
System user; root
5d64a9c90f changelog 2024-02-29 11:03:28 +01:00
System user; root
ffaa985339 streams compatibility 2024-02-29 11:01:30 +01:00
Mario
291e12574a more cleanup 2024-02-28 13:16:47 +00:00
Mario
fc5b5ba021 if we rename a folder in dav we should also move its content 2024-02-28 12:04:46 +00:00
Mario
056c55a963 bump version 2024-02-28 10:20:34 +00:00
Mario
02a0af3eef remove poke and mood from apps 2024-02-28 10:19:57 +00:00
Mario
96e8316633 some cloeanup after last commit 2024-02-28 10:04:22 +00:00
Mario
37878bf0a3 do away with deprecated activity types 2024-02-28 09:18:31 +00:00
Mario
b4f079c4b5 For now we will use standard Create verb for emoji reactions 2024-02-27 10:31:27 +00:00
Harald Eilertsen
18abfb11ef Update Doxygen config for generating online API docs
Enabled implicit brief descriptions (`JAVADOC_AUTOBRIEF`), and markdown
support (`MARKDOWN_SUPPORT`) for doc blocks. This means that we no
longer need to explicitly inclufe a `@brief` tag in the doc block, the
first full sentence will be regarded as the brief documentation if it's
not explicitly given. Also we can use Markdown formatting in the
comments, which is a bit nicer than the native Doxygen tags.

I also disabled the Doxygen_phpvarfilter, but leave it commented out. It
should not be needed anymore unless somebody is using an ancient version
of doxygen. (Don't do that!)

I also changed the heading a bit, removed "The" from "The Hubzilla", and
added a tagline. Feel free to revise to whatever conforms to the project
norms.
2024-02-27 11:08:18 +01:00
Harald Eilertsen
25dbc8a9f6 include/dba: Make Dba driver transaction aware.
This patch introduced database transaction support to the Dba driver via
the DbaTransaction class.

The goal of this is to allow the driver control over the creation and
finalization of database transactions.

Until now code that has needed transaction support has done so directly
by issuing "BEGIN", "ROLLBACK" and "COMMIT" commands to the underlying
database directly.

This has several disadvantages:

  - We do have no control or knowledge of whether any transactions being
	active.

  - Since transactions can not be nested, we run the risk of unrelated
	code trying to create a transaction when one is already active.

  - Code using transactions are not testable, as the test runner wraps
	all tests within a transaction to begin with.

This patch should eliminate all these problems.

A transaction is started by instantiating the DbaTransaction class:

    $my_transaction = new \DbaTransaction();

The transaction will automatically be _rolled back_ if it has not been
committed before the instance is destroyed. (When the variable holding
it goes out of scope, i.e when the containing function returns.)

A transaction is committed like this:

    $my_transaction->commit();

This will immediately commit the changes in the transaction, and the
transaction will be marked as committed, so it will not be attempted to
be rolled back on destruction.

I have chosen to "ignore" the problem of nested transactions by having
the DbaTransaction class _not_ initiate a new transaction if one is
already active. This also makes the rollback and commit actions of the
DbaTransaction class into no-ops.

An alternative would be to simulate nested transactions by using save
points if a transaction is already active. However, I'm unsure about
wether there's any safe way to avoid all potential pitfalls when doing
that.

In any case, nested transactions should preferably be avoided, and
afaict we don't rely on that in any of the existing code. The reason we
need to support it in some way is that it's needed for testing where the
code under test is creating a transaction on it's own. (Since each test
is run within a db transaction to begin with.)

Also, I have taken the liberty to assume a PDO based db driver for this
stuff. I don't think that's going to be a problem, as that's the only
thing supported by the rest of the code in any case.
2024-02-26 15:11:39 +01:00
Mario
c639704f3c more streams compatibility 2024-02-25 21:36:34 +00:00
Mario
3dd7394247 AS2 2024-02-25 19:29:50 +00:00
Mario
b860b730a9 simplify pleroma custom emoji stuff and some cleanup 2024-02-22 10:23:38 +00:00
Mario
17e2877c91 make sure to decode html special chars before sending over the wire and 2024-02-21 10:44:56 +00:00
Mario
b7bc28c333 update test 2024-02-20 15:09:11 +00:00
Mario
fb5a52cbde Merge branch 'bootstrap-new2-v5' into 'dev'
update to Bootstrap 5

See merge request hubzilla/core!2107
2024-02-20 15:08:44 +00:00
Mario
6d125d02d8 introduce get_actor() force flag to omit cache, rework contact refresh, special handling for announce by group, and revert change regarding friendica addressing anomality 2024-02-15 14:27:50 +00:00
Mario
0b18b35f5f require the intl extension for 2024-02-14 21:28:20 +00:00
Mario
9859008271 deal with inReplyTo array + some docu and style 2024-02-14 20:23:02 +00:00
Mario
423c36f67b improved checks in HTTPSig::find_headers() 2024-02-14 18:07:29 +00:00
Rocky
1e0195e439 update to Bootstrap 5 2024-02-14 15:02:31 +01:00
Mario
30271bb32f minor css adjustment 2024-02-14 11:33:31 +00:00
Mario
e2b1670d6c fix round buttons not being round 2024-02-13 21:14:03 +00:00
Mario
2bfdfbe3cc do not feed null to TimeZoneUtil::getTimeZone() 2024-02-13 15:00:41 +00:00
Mario
9a85421a0e we are now using the item uuid for the notification hash if available. since we can have more than one notification per item (e.g. tag and comment) also look for the notification type to make sure we get the right one 2024-02-13 14:05:30 +00:00
Mario
1fa59df6f3 Add test for a paragraph with a mention and some text 2024-02-13 13:01:09 +00:00
Mario
2c93294eea scss: show current color and add some help text 2024-02-13 12:28:11 +00:00
Mario
316829269a bump version 2024-02-13 11:57:55 +00:00
Mario
55236f86e0 move the empty recips check to store(). otherwise it might interfere with zot6 native addressing which is always empty 2024-02-13 11:19:28 +00:00
Mario
060210e930 consider a message arriving to our inbox with no recipients (as seen from friendica) a direct message 2024-02-13 11:00:49 +00:00
Mario
9291622885 fix logic so that direct messages will be allowed in case the send_mail permission is granted even if the send_stream permission is not granted 2024-02-13 10:48:06 +00:00
Mario
07978a061e mb_strlen() will return 2 for some emojis - possibly grapheme_strlen() will be better for this job 2024-02-13 09:22:12 +00:00
Mario
08b2356ed1 add sample scss file 2024-02-12 22:09:07 +00:00
Mario
d17934ed80 scss: more options and some fixes 2024-02-12 22:07:54 +00:00
Mario
94f17f0dae use primary color 2024-02-10 22:22:03 +00:00
Mario
7ccb2a2615 custom sass bootstrap builds for channels and site 2024-02-10 22:04:24 +00:00
Mario
067a66b927 fix some whitespace issues after recent changes 2024-02-09 11:20:46 +00:00
Mario
096fad5e8c another try 2024-02-09 08:02:58 +00:00
Mario
e21e4c7127 let's try this 2024-02-09 07:33:13 +00:00
Mario
5754ea828d move parsing of a tags upà to fix an issue where mentions arriving from masto did not parse correctly, fix typo when restoring temporary linebreaks and remove redundant codeline when converting span tags 2024-02-08 20:22:26 +00:00
Mario
5fbc203367 mark items verified in zot delivery also if either LDSignature or EddsaSignature verified 2024-02-08 19:32:40 +00:00
Mario
08884c44fb whitespace 2024-02-08 19:15:00 +00:00
Mario
bd04ca21a4 Merge branch 'minor-markdown-fixes' into 'dev'
Minor markdown fixes

See merge request hubzilla/core!2098
2024-02-08 19:14:29 +00:00
Harald Eilertsen
19ae8cfdfc Support code blocks with language in markdown and html. 2024-02-08 10:00:12 +01:00
Harald Eilertsen
86e953f495 Fix: Preserve hard linebreaks from markdown and html 2024-02-07 22:34:13 +01:00
Mario
4bc4f5b2a6 update docu and remove redundant pernission check after vonv fetch fixes 2024-02-07 15:56:54 +00:00
Mario
5f2e808497 add uuid to dreport for internal use and and fix issues with conversation fetches 2024-02-07 15:37:20 +00:00
Harald Eilertsen
4f69e02768 Don't concert html nodes with no bbcode equivalent. 2024-02-07 16:02:53 +01:00
Harald Eilertsen
e6ce2885c0 Fix: Keep indentation in html and md code blocks.
Moves the logic for unwrapping broken lines in html (and Markdown) to
the node processing, instead of doing it over the full html content.
This allows us to skip if for code blocks (aka `<code>` elements within
`<pre>` elements).
2024-02-07 15:54:40 +01:00
Harald Eilertsen
ec19ee9d82 Fix convert code blocs from markdown/html to bbcode 2024-02-06 18:39:51 +01:00
Harald Eilertsen
983f063d33 Fix image with alt text for html/md to bbcode 2024-02-06 16:23:39 +01:00
Harald Eilertsen
eb6a143fff Add some tests for markdown to bbcode conversion. 2024-02-06 16:19:30 +01:00
Harald Eilertsen
1881029040 Clean up markdowntest and fix bb to markdown test. 2024-02-06 11:43:32 +01:00
Mario
209651705d fix custom emoji reactions arriving from pleroma 2024-02-04 19:50:31 +00:00
Mario
fab3c92a7c streams collection branch compatibility 2024-02-02 20:23:06 +00:00
Mario
8ad7376865 more fix conv_list template 2024-02-01 17:12:43 +00:00
Mario
c41831aff9 fix conv_list template 2024-02-01 17:05:00 +00:00
Mario
8515aa6966 fix issues related to b64mid to uuid conversion 2024-02-01 16:29:23 +00:00
Mario
691de5bf2e Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-02-01 16:00:36 +00:00
Mario
2e155892fe testing JcsEddsa2022 sigs 2024-02-01 16:00:17 +00:00
Mario
6680c2faf3 Merge branch 'add-ci-job-for-mariadb' into 'dev'
CI: Add job for MariaDB 10.6

See merge request hubzilla/core!2097
2024-02-01 14:22:48 +00:00
Mario
decc8f2162 strip a possible fragment 2024-02-01 14:14:53 +00:00
Mario
7d7a0c160f bump version 2024-02-01 13:27:09 +00:00
Mario
e89563eb4c fix edgecase for notices and make mod hq backwards compatible 2024-02-01 13:25:40 +00:00
Mario
dd204ec34f start using uuid for internal reference instead of base64 encoded mid 2024-02-01 11:42:55 +00:00
Mario
b3a5dd8aa8 store seen mids in session instead of cache and increase sess_data column to medium text 2024-01-31 13:29:56 +00:00
Mario
26ee56f39c remove logging 2024-01-29 10:39:15 +00:00
Mario
300b0e27bd bump version 2024-01-29 10:35:48 +00:00
Mario
29489f62cf introduce Activity::init_background_fetch() and refactor zotconvo to implement it 2024-01-29 10:33:13 +00:00
Mario
09465619e5 enable object cash by default, introduce system.cache_expire_days and default to 7, default system.default_expire_days to 30 and system.active_expire_days to 7 2024-01-28 17:03:05 +00:00
Mario
390af7722d fix last commit 2024-01-28 15:03:40 +00:00
Mario
e18157f818 make sure we return an array if there is no cache entry 2024-01-28 11:35:15 +00:00
Mario
5435d2881c Merge branch 'dev' into 'dev'
Added Circle Person Avatar

See merge request hubzilla/core!2096
2024-01-27 20:26:29 +00:00
Mario
2e8f3d1869 Merge branch 'upgrade-ci-to-mysql-8.0' into 'dev'
CI: Upgrade to use MySQL version 8.0

See merge request hubzilla/core!2093
2024-01-27 20:21:13 +00:00
Mario
3ad1cab006 Merge branch 'doc-updates' into 'dev'
Doc updates

See merge request hubzilla/core!2092
2024-01-27 20:20:18 +00:00
Mario
b806a3ccc2 use std functions 2024-01-27 20:18:28 +00:00
Mario
5e780ba089 implement short time object cache to reduce network calls and some cleanup 2024-01-27 16:36:26 +00:00
Mario
c0a7dfe2f6 refactor fetch_and_store_parents() and inroduce the fetchparents daemon 2024-01-25 10:13:10 +00:00
Mario
fe50d78a0f missing hook 2024-01-24 19:34:41 +00:00
Mario
e513950cb5 restructure Libzot::process_delivery() 2024-01-24 16:44:42 +00:00
Mario Vavti
adc6390a22 bump version 2024-01-24 16:41:03 +01:00
Mario Vavti
9449e8bd61 fix issue where if an item is created and deleted again before the notifier has completed the queueworker will dismiss the delete because it looks like a duplicate entry 2024-01-24 16:40:05 +01:00
Mario
f13af0f60b process source xchan in xchan_query() 2024-01-23 08:46:18 +00:00
Harald Eilertsen
acdb773f89 CI: Add job for MariaDB 10.6
Reuse job definition for mysql job, and alias the mariadb service to
mysql so that the job will find it.
2024-01-22 12:44:36 +01:00
Mario
651a288148 set item_uplink to 0 just to be sure (this should not be necessary) 2024-01-22 09:17:55 +00:00
Mario
b0664f7349 store the original announce actor (the one that pushed the item into our stream first) in source_xchan instead of owner_xchan. this way we will preserve the real owner for the thread and not have conflicts when dealing with deletes of comments or likes 2024-01-22 09:09:41 +00:00
Scott M. Stolz
51586037e1 Added Circle Person Avatar
Added an additional avatar to choose from.
2024-01-21 16:11:35 -06:00
Harald Eilertsen
f573c1772a CI: Slight refactoring. 2024-01-21 22:51:42 +01:00
Harald Eilertsen
f08e91e19d CI: Upgrade to use MySQL version 8.0
This is the oldest version we support now.
2024-01-21 17:50:06 +01:00
Harald Eilertsen
8cd9fff26a Add some developer doc for check_account_password hook 2024-01-21 17:43:35 +01:00
Harald Eilertsen
d489a2854e Update admin guide with min supported db versions 2024-01-21 17:42:42 +01:00
Mario Vavti
9cfd1c2318 missing include 2024-01-21 09:52:13 +01:00
Mario
2dd0677d23 Merge branch 'dont-include-db-updates-in-test-coverage' into 'dev'
Don't include db updates in test coverage.

See merge request hubzilla/core!2090
2024-01-19 20:36:04 +00:00
Mario
00d403e729 Merge branch 'improve-validate-email' into 'dev'
Improve validate_email function

See merge request hubzilla/core!2088
2024-01-19 20:35:43 +00:00
Mario
d83e2daf36 Merge branch 'fix-postgres-ci' into 'dev'
tests: Remove id from db fixtures.

See merge request hubzilla/core!2087
2024-01-19 20:33:36 +00:00
Mario
8fe6aede03 bump version 2024-01-19 20:11:35 +00:00
Mario
fa4ab45692 native repeats continued 2024-01-19 20:10:50 +00:00
Mario Vavti
f57fbaa5dd version 8.8.7 2024-01-19 11:07:23 +01:00
Mario Vavti
aba8002170 Fix regression in Activity::actor_store()
(cherry picked from commit 9cc85adf47)
2024-01-19 10:03:58 +00:00
Mario Vavti
9cc85adf47 Fix regression in Activity::actor_store() 2024-01-19 11:02:13 +01:00
Harald Eilertsen
01ed001041 Don't include db updates in test coverage.
We're not likely to add tests for these in any case.
2024-01-16 10:13:24 +01:00
Harald Eilertsen
403539919a Improve the validate_email function
The validate_email function relied on doing an actual domain lookup (on
supported platforms) to validate the domain of the email address. This
does not work too well in testing environments where we may not want to
spam the DNS system, if it at all is available.

Apart from the the function did very little to actually verify that it
was a valid email address.

This patch tries to change that by usng a somewhat stricted regex based
validation. While this may not be perfect, it should be good enough in
the vast majority of cases. For platforms where no validation was
performed with the old version, it will at least be an improvement.

Also, it allows testing without having an external network connection.

Also clarify the doc comment, that it does not actually try to resolve
the email address, just the domain.
2024-01-15 19:52:31 +01:00
Harald Eilertsen
52ea2fa33e Update CI run to archive dbfail.out if test run fails 2024-01-15 19:32:19 +01:00
Harald Eilertsen
ecd4754f6d tests: Enable debug logging during tests
The debug log will be stored in the test/results directory, and archived
as part of the artifacts of the CI run. This should make it easier to
get some debugging info out from the CI runs if they fail.
2024-01-15 19:25:09 +01:00
Harald Eilertsen
f71033b30d tests: Remove id from db fixtures.
It seems that PostgreSQL will not update the autoincrement index of the
table when inserting rows with an id set. Later inserts without an id
set will then fail, because they get assigned an id that already exists.

MySQL seems to handle this just fine.

Why the id column was added in the first place, one may wonder, but
that's how it were.

In any case, this broke the PostgreSQL tests in the gitlab CI
environment. (While it mysteriously worked in my local ddev
environment.) Anyways, the id column is not needed, and things work
better without them.
2024-01-15 19:11:25 +01:00
Mario
885068834f fix more php deprecations 2024-01-14 19:58:36 +00:00
Mario
c4c4ab2f3d fix regression in commit b05b7561 2024-01-14 19:52:05 +00:00
Mario
aec3247952 fix more php deprecations 2024-01-14 19:40:59 +00:00
Mario
b05b756148 Handling HTML entities via mbstring is deprecated 2024-01-14 17:23:57 +00:00
Mario
03819abb22 remove acct from webfinger 2024-01-14 17:23:19 +00:00
Mario
d074e2aba0 fix more php deprecations 2024-01-14 17:22:33 +00:00
Mario
2bbecfe8dd only attempt fetch if zotfinger actually returned something 2024-01-14 10:11:20 +00:00
Mario
e078e13325 make sure we are dealing with an array 2024-01-14 09:40:18 +00:00
Mario
9d3b852d38 fix wrong array key 2024-01-14 08:10:27 +00:00
Mario
fadb0a5bf2 check for assertionMethod 2024-01-13 20:45:32 +00:00
Mario
fa7aa6cedb start checking integrity proofs, remove signature prior to verify, iterate trough the array to find the desired ekey in actor_store() 2024-01-13 20:38:34 +00:00
Mario
6df98f2fad private -> public 2024-01-13 19:10:44 +00:00
Mario
c597017402 fix some deprecation warnings 2024-01-13 17:38:31 +00:00
Mario
9cb95f6065 store epubkey in actor_store 2024-01-13 16:19:53 +00:00
Mario
477b1535a2 start storing epubkeys in libzot 2024-01-13 15:28:20 +00:00
Mario
1d652cfcbd expose epubkey in zotinfo 2024-01-13 15:09:39 +00:00
Mario
28b604c7c7 typo 2024-01-13 13:46:40 +00:00
Mario
8c11be07cd Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-01-13 08:51:19 +00:00
Mario
e8dd2c28ff make our jsonld parser happy 2024-01-13 08:50:57 +00:00
Mario Vavti
0bdffc4a2d make our jsonld parser happy 2024-01-13 08:49:14 +01:00
Mario
94b1fe4a8b Merge branch 'cherry-pick-96ae46c5' into 'dev'
Update lostpass_eml.tpl

See merge request hubzilla/core!2086
2024-01-11 17:15:38 +00:00
Mario
11ed445319 Merge branch 'cherry-pick-ddfa613e' into 'dev'
Update Spanish strings

See merge request hubzilla/core!2085
2024-01-11 17:15:21 +00:00
Mario Vavti
400dfb4e6b version 8.8.6 2024-01-11 17:57:51 +01:00
Mario
6b951734ce changelog
(cherry picked from commit 000fcfd1ac)
2024-01-11 16:56:13 +00:00
Mario
000fcfd1ac changelog 2024-01-11 16:55:44 +00:00
Mario
051e2ed6cd provide some more jsonld builtins
(cherry picked from commit aac406a245)
2024-01-11 16:40:16 +00:00
Mario
aac406a245 provide some more jsonld builtins 2024-01-11 16:27:57 +00:00
Mario Vavti
ef2952b5fd libsync: dev branch compatibility 2024-01-11 17:00:47 +01:00
Mario
ffdf54b097 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-01-10 13:34:23 +00:00
Mario
58593d7da6 prepare outbound fep-8b32 (object integrity) but do not enable yet since the additional context seems to break ldsig for some reason, introduce Activity::build_packet() and Activity::ap_context() to reduce code duplication, implement fep-2c59 (webfinger) and some cleanup 2024-01-10 13:33:57 +00:00
mjfriaza:4GF~eYj,-iAv
3d13f36ce2 Update lostpass_eml.tpl
(cherry picked from commit 96ae46c5a4aa614b9aed7b640d69e8cd8210595f)
2024-01-09 12:52:48 +00:00
mjfriaza:4GF~eYj,-iAv
8c843ec6d0 Update Spanish strings
(cherry picked from commit ddfa613e828e8f0a569a2d938d3839f5608bc9c3)
2024-01-09 12:49:55 +00:00
Mario
232c7f5301 Merge branch 'tests/includes/account' into 'dev'
Some test cleanup and tests for check_account_email

See merge request hubzilla/core!2083
2024-01-09 08:05:28 +00:00
Harald Eilertsen
16cd8caef3 tests: Add tests for check_account_email 2024-01-08 14:09:13 +01:00
Harald Eilertsen
43dabee53d tests: Set app config in a known state for each test 2024-01-08 14:09:13 +01:00
Harald Eilertsen
f016760851 tests: Add config fixtures.
Adds fixtures for the config table:
- Disables dns checking globally for the tests.
- Adds a few disallowed email domains and addresses.
2024-01-08 14:09:13 +01:00
Harald Eilertsen
99b5166f21 tests: Clean up unused debug stuff from UnitTestCase 2024-01-08 14:01:02 +01:00
Mario
4aa29db7aa reflect new fields in low level functions 2024-01-07 21:27:12 +00:00
Mario
f5b8b18c8e Merge branch 'tests/remove-behat' into 'dev'
Remove unused acceptance tests and dependencies

See merge request hubzilla/core!2082
2024-01-07 21:00:40 +00:00
Mario
6e5566f9c8 bump version 2024-01-07 20:38:40 +00:00
Mario
ca216ae819 set default value for postgres only 2024-01-07 20:34:47 +00:00
Mario Vavti
4713241444 set a default value 2024-01-07 21:18:20 +01:00
Mario
4917170a0d remove logging 2024-01-07 20:00:29 +00:00
Mario
87775ae37a ekey and xchan_updated updates 2024-01-07 19:58:09 +00:00
Harald Eilertsen
eaa244a2a3 CI: Install pecl extensions after system packages.
The php yaml extension requires libyaml, which has to be installed
first.
2024-01-07 20:39:06 +01:00
Harald Eilertsen
db91d66d1a CI: Install yaml extension from PECL. 2024-01-07 20:35:08 +01:00
Harald Eilertsen
4d64481564 Remove unused acceptance test stuff from source tree. 2024-01-07 20:26:14 +01:00
Harald Eilertsen
0a31fc176c Remove behat as dev dependency.
As the Symphony\Yaml stuff disappeared with behat, we need another way
to load read the yaml files with database fixtures for the integration
tests.

As the php yaml extension is not distributed with PHP by default, this
creates it as another dev dependency!
2024-01-07 20:24:52 +01:00
Harald Eilertsen
659a8c967c Exclude dev dependencies from version control.
This will ignore dependencies only installed as part of the dev setup.
2024-01-07 19:39:49 +01:00
Harald Eilertsen
626887a792 Exclude phpunit cache from version control 2024-01-07 19:25:01 +01:00
Mario
256b66de41 Revert "DB update 1260 - REQUIRES SODIUM PHP EXTENSION!!!"
This reverts commit 5ee4f37b8d
2024-01-07 15:50:50 +00:00
Mario
5ee4f37b8d DB update 1260 - REQUIRES SODIUM PHP EXTENSION!!! 2024-01-07 15:34:25 +00:00
Mario
3dc122db84 fix regression collapsing non conv item content 2024-01-07 10:43:43 +00:00
Mario
99c5a4e2f8 we do not use named params yet 2024-01-06 16:44:17 +00:00
Mario
f922a92ffa install bcmath 2024-01-06 16:37:11 +00:00
Mario
a36de8ba1a Merge branch 'tests/fix-db-and-ci-integration' into 'dev'
tests: Integrate the DB in "unit" tests.

See merge request hubzilla/core!2081
2024-01-06 16:34:39 +00:00
Harald Eilertsen
e3d30763da tests: Integrate the DB in "unit" tests. 2024-01-06 16:34:38 +00:00
Mario
c73518d8ec dump composer autoload 2024-01-06 16:31:42 +00:00
Mario
ed0d2fed66 require bcmath or gmp extension 2024-01-06 16:23:26 +00:00
Mario
960bcb6b53 port test for JcsEddsa2022 from streams 2024-01-06 16:12:25 +00:00
Mario
6252340804 add Bookmark and Category to ap schema and bump ap schema version 2024-01-06 10:03:44 +00:00
Mario
517d67b2e0 add check for sodium on setup 2024-01-05 20:16:13 +00:00
Mario
e95b7ca3a0 require ext-sodium, dump composer autoload and a minor js fix 2024-01-05 19:30:37 +00:00
Mario
c771d7c31a Ãdisplay selected mid in an open state - issue #1425 2024-01-05 12:53:00 +00:00
Mario
ce0e8d7497 update apache rewite rule to fix issue with recent apache versions - issue #1822 2024-01-05 11:06:08 +00:00
Mario
852678e238 port multibase and jcsedssa2022 libs from streams 2024-01-03 19:20:28 +00:00
Mario
16e6eec3fb composer add mmccook/php-json-canonicalization-scheme 2024-01-03 11:09:22 +00:00
Mario
afe8552be6 comÃposer add tephenhill/base58 2024-01-03 11:07:03 +00:00
Mario
cd0e50da24 update symfony/polyfill-php81 2024-01-03 11:00:20 +00:00
Mario
85001c034b update sabre/vobject 2024-01-03 10:58:31 +00:00
Mario
a56f6576e2 update ramsey/uuid 2024-01-03 10:57:15 +00:00
Mario
d3e5d05026 update ezyang/htmlpurifier 2024-01-03 10:56:03 +00:00
Mario
322b619a71 update sabre/dav 2024-01-03 10:53:37 +00:00
Mario
dff906ca69 bump version 2024-01-02 20:50:50 +00:00
Mario
515d1d5e63 postgres does not like binaries to be string while mariadb/mysql does not seem to care - let's see 2024-01-02 20:49:57 +00:00
Mario
bb6ed22594 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-01-01 20:35:28 +00:00
Mario Vavti
d655e1d765 version 8.8.5 2024-01-01 21:30:45 +01:00
Mario Vavti
db70ed006d Merge branch 'dev' 2024-01-01 21:29:53 +01:00
Mario Vavti
ce1dd5c632 changelog 2024-01-01 21:29:15 +01:00
Mario Vavti
9e2a253dda Merge branch 'dev' 2024-01-01 21:21:04 +01:00
Mario
95c645865d Merge branch 'doc-fixes' into 'dev'
docs: Update admin guide requirements

See merge request hubzilla/core!2080
2024-01-01 20:17:52 +00:00
Mario
ceb510bbf5 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2024-01-01 20:04:44 +00:00
Mario
2590e3c99b reveal repeat 2024-01-01 20:04:24 +00:00
Mario Vavti
f2f9cfaf28 Work around possible loop and use Lib/Config in init 2024-01-01 21:01:47 +01:00
Mario Vavti
62db8c3969 fix php errors and deprecation warnings 2023-12-31 09:55:27 +01:00
Mario Vavti
ae3db366e5 deprecate simplepie idna_convert 2023-12-31 09:54:54 +01:00
Harald Eilertsen
57570c144a doc/admin-guide: Update min php version and reqd extensions. 2023-12-26 15:34:50 +01:00
Mario
c3a235242e do not double process quoted strings 2023-12-21 10:19:26 +00:00
Mario
b629eb5657 fix merge conflict 2023-12-20 12:32:15 +00:00
Mario
2e674cd0b3 version 8.8.4 2023-12-20 12:26:28 +00:00
Mario
3330e9a19a Merge branch 'dev' 2023-12-20 12:25:43 +00:00
Mario
c5f6208396 changelog 2023-12-20 12:25:27 +00:00
Mario
c0d93bbcf4 Merge branch 'dev' 2023-12-20 12:20:04 +00:00
Mario
db941e7007 changelog 2023-12-20 12:17:35 +00:00
Mario
4761857157 Revert "changelog"
This reverts commit 3aefe23184.
2023-12-20 12:15:42 +00:00
Mario
3aefe23184 changelog 2023-12-20 12:15:24 +00:00
Mario
6f852814fd move App::$install check to Config::Load() as suggested by Harald 2023-12-20 11:58:33 +01:00
Mario
b15e521b0e Merge branch 'fix-config-deserialization' into 'dev'
Fix deserialization of config values broken by 69266cd6.

See merge request hubzilla/core!2077
2023-12-20 10:27:56 +00:00
Mario
63c401e6d6 Merge branch 'extend-siteinfo' into 'dev'
Add active addons and blocked sites to siteinfo (html)

See merge request hubzilla/core!2079
2023-12-20 10:16:44 +00:00
Harald Eilertsen
e59750e8de Add active addons and blocked sites to siteinfo (html)
This adds information about addons activated on the hub, as well as
which other sites this hub won't federate with in the HTML version of
siteinfo.

Based on suggestions by @rockyiii@huby.infozoo.de.
2023-12-18 15:05:23 +01:00
Harald Eilertsen
9c184ddfd0 Fix deserialization of config values broken by 69266cd6.
This should fix issue #1828.

This patch makes it explicit that we store arrays in the config as json
encoded arrays, while we allow both json encoded and PHP serialized
arrays to be deserialized correctly. Unless it's a brand new install,
the existing data in the database will be PHP serialized.

I've also added a hardening measure in case we fall back to PHP
unserialize, making sure we're not vulnerable to a PHP Object Injection
attack. This means that deserializing arrays containing PHP objects will
no longer work, but afaict we never do that anyways, so I don't think
that should break anything.
2023-12-17 19:30:05 +01:00
Mario
9df6e821d8 use reqiure_once() - second part of issue #1827 2023-12-17 16:47:19 +00:00
Mario
9551dc5ecd fix loop as described in issue #1827 2023-12-17 16:36:13 +00:00
Mario
d372daff60 Revert "check return from Config::Load() and retry on failure plus cleanup"
This reverts commit 69266cd6c6
2023-12-17 11:16:58 +00:00
Mario
f742e6e394 Merge branch 'dev' 2023-12-17 08:53:32 +00:00
Mario
414b2b0e4c changelog 2023-12-17 08:53:14 +00:00
Mario
603c5692ae Merge branch 'dev' 2023-12-17 08:50:39 +00:00
Mario
b35e994d1b Merge branch 'translations-nb_no' into 'dev'
More translations for Norwegian Bokmål (nb_NO)

See merge request hubzilla/core!2075
2023-12-17 08:50:13 +00:00
Mario
abe2ab229a version 8.8.3 2023-12-17 08:43:08 +00:00
Mario
5ad9939bcf Merge branch 'dev' 2023-12-17 08:41:48 +00:00
Mario
ce451128ba changelog 2023-12-17 08:41:21 +00:00
Mario
70470016cc Merge branch 'dev' 2023-12-17 08:35:33 +00:00
Harald Eilertsen
2122ea77e1 More translations for Norwegian Bokmål (nb_NO) 2023-12-16 14:57:01 +01:00
Mario Vavti
69266cd6c6 check return from Config::Load() and retry on failure plus cleanup 2023-12-14 12:32:34 +01:00
Mario Vavti
062d61567e return if we could not fetch the author 2023-12-14 12:06:50 +01:00
Mario Vavti
d6120fc908 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-12-14 12:06:21 +01:00
Mario
91f8e7a07b typo 2023-12-13 14:34:34 +00:00
Mario Vavti
f57d89245c add the app terms before syncing - otherwise the terms will be reset at the other end 2023-12-08 21:44:32 +01:00
Mario Vavti
c307a71f53 Merge branch 'dev' 2023-12-08 18:08:03 +01:00
Mario Vavti
1e4e59bb57 if it is not an array do not attempt count() 2023-12-08 18:02:54 +01:00
Mario
f62d16d274 Merge branch 'dev' 2023-12-06 11:27:54 +00:00
Mario
f175712d4b typo 2023-12-06 11:27:35 +00:00
Mario
5f942d78e6 Merge branch 'dev' 2023-12-06 11:23:21 +00:00
Mario
538c8885ad changelog 2023-12-06 11:23:02 +00:00
Mario
c8158c3d62 vesrion 8.8.2 2023-12-06 11:14:00 +00:00
Mario
1f4762060f Merge branch 'dev' 2023-12-06 11:12:25 +00:00
Mario
81c3682781 more issue #1820 2023-12-06 09:47:13 +00:00
Mario
2e6e1fdd55 css fixes 2023-12-04 09:28:16 +00:00
Mario
1a09cd560b require acl_selectors.php - fix issue #1820 2023-11-30 08:02:33 +00:00
Mario
8c9d2bc6f6 Merge branch 'dev' 2023-11-27 08:48:47 +00:00
Mario
78ad5ca713 changelog 2023-11-27 08:48:23 +00:00
Mario
43c2e71b25 Merge branch 'dev' 2023-11-27 08:45:19 +00:00
Mario
5b9f32fade Merge branch 'dev' into 'dev'
Update doubleleft.css and doubleright.css according to v.8.8 default.css

See merge request hubzilla/core!2074
2023-11-27 08:44:25 +00:00
Mario
76a1a6da34 version 8.8.1 2023-11-27 08:42:09 +00:00
zlaxy
a2b0abc90d Update doubleleft.css and doubleright.css according to v.8.8 default.css 2023-11-27 10:50:31 +03:00
Mario
0fd8e02a88 Merge branch '8.8RC' 2023-11-25 17:12:28 +01:00
Mario
55c4bfb670 version 8.8 2023-11-25 17:11:07 +01:00
Mario
ea1030f8bf Merge branch 'dev' into 8.8RC 2023-11-25 17:06:55 +01:00
Mario
6dd285811a changelog 2023-11-25 17:06:25 +01:00
Mario
ee149ed1eb Merge branch 'dev' into 8.8RC 2023-11-25 17:05:08 +01:00
Mario
c3aa96d423 update changelog 2023-11-24 14:40:58 +01:00
Mario
6e59d95da5 Merge branch 'dev' into 8.8RC 2023-11-23 20:25:13 +00:00
Mario
a396e74a79 like in get_cached_actor() also remove fragment in get_actor() 2023-11-23 13:21:56 +00:00
Mario
80bdb39ae3 case insensitive digest algo 2023-11-22 16:41:44 +00:00
Mario
5cb1a9dcc6 Merge branch 'dev' into 8.8RC 2023-11-22 16:21:58 +00:00
Mario
1cfa81450c remove follow (does not make any sense to add follow link of the logged in channel), add startpage 2023-11-21 08:07:40 +00:00
Mario
1f18fed3a2 add additional observer and channel info to nav if applicable 2023-11-21 08:01:03 +00:00
Mario
33cb429e15 remove unused variable 2023-11-20 21:56:31 +00:00
Mario
cfdbf02e6b the additional parameter has been deprecated there is no need to check the version anymore 2023-11-20 21:52:40 +00:00
Mario
f8c631a3f0 Merge branch 'dev' into 8.8RC 2023-11-20 20:32:46 +00:00
Mario
74911e9f6d revert dreport changes - too chatty 2023-11-20 20:32:14 +00:00
Mario
0f453ae4cf version 8.8RC2 2023-11-20 20:27:35 +00:00
Mario
febebc8d3d more do not provide channel info for templates and code cleanup 2023-11-20 20:21:03 +00:00
Mario
166c45f97f do not provide channel info for templates 2023-11-20 19:22:06 +00:00
Mario
af58364fef only check for privacy mismatch if observer != owner 2023-11-17 07:50:10 +00:00
Mario
eadf83d61b work around a possible privacy mismatch when processing zot requests 2023-11-16 15:57:03 +00:00
Mario
3c20231aad add backlink to profile to profile vcard and adjust switch colors for better visibility 2023-11-15 22:11:20 +00:00
Mario
402bf395d1 bump dev version 2023-11-10 08:25:10 +00:00
Mario
9a45938fe6 run composer dump-auotoload 2023-11-10 08:20:57 +00:00
Mario
d963e4a2c4 version and strings 2023-11-10 08:15:57 +00:00
Mario
1063a67ae2 a possible fix for issue #1816 2023-11-09 21:37:28 +00:00
Mario
602ef883bb version 2023-11-09 21:00:52 +00:00
Mario
aad6042d42 DB Update 1259 2023-11-09 20:09:49 +00:00
Mario
85d8c1a97e some low level work on native repeats 2023-11-09 19:32:29 +00:00
Mario
547e6542ba move color_mode related code to theme_init.php 2023-11-07 10:09:31 +00:00
Mario
f74044f9b0 Merge branch 'owa_improvement' into 'dev'
work with Mastodon-style keyId

See merge request hubzilla/core!2060
2023-11-07 08:46:15 +00:00
Mario
42651707f8 check if required keys are set 2023-11-07 08:40:34 +00:00
Mario
95c13eaf5a remove logging 2023-11-07 08:34:13 +00:00
Mario
c74068ae4d libzot: correctly attribute streams repeats 2023-11-07 08:33:22 +00:00
Mario
ca92dd0299 bbcode: do not overrule default list style 2023-11-07 08:30:27 +00:00
Mario
798f791b6b simplepie: fix fatal error with php 8.2 - issue is filed upstream but probably will not be fixed any time soon 2023-11-07 08:28:42 +00:00
Mario
331622309f if channel is not defined we need to provide an empty array 2023-11-01 15:47:16 +00:00
Mario
4f334525c2 only show tools to creators if they still have perms 2023-11-01 15:38:53 +00:00
Mario Vavti
82e704ec5b remove the directory updates entry if the channel was removed
(cherry picked from commit 67aaa97904)
2023-10-26 14:08:33 +00:00
Mario Vavti
67aaa97904 remove the directory updates entry if the channel was removed 2023-10-26 16:06:15 +02:00
Mario
4f55248a6c Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-10-25 13:06:24 +00:00
Mario
61b46f1a3e add stats logging to zotfinger 2023-10-25 13:05:56 +00:00
Mario Vavti
286104a988 slightly less noise when logging normal 2023-10-25 14:45:26 +02:00
Mario Vavti
8ea6ead08a use Activity::get_actor() which will check for the cache record in xconfig before fetching 2023-10-21 21:42:14 +02:00
Mario
bd9cc23681 update logger statements 2023-10-20 09:30:52 +00:00
Mario
f2d7298cf4 check if we have the record in the short time cache before actually fetching it 2023-10-20 09:30:29 +00:00
Mario
da636ca881 css fix 2023-10-20 09:27:53 +00:00
Mario
39bfa30185 css fix 2023-10-19 11:27:50 +00:00
Mario
d7c005a2f1 refactor actor_store() 2023-10-19 06:59:13 +00:00
Mario
763b69bf5b enable reset button in mod rpost 2023-10-12 08:39:18 +00:00
Mario
2f2e353ece use new lang detect library which supports much more languages 2023-10-07 16:00:34 +00:00
Mario Vavti
0092b7c0a4 should be tinyint instead of numeric for mysql 2023-10-06 14:28:59 +02:00
Mario Vavti
9f48109640 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-10-06 14:24:51 +02:00
Mario Vavti
b976adb8aa add missing columns in install script 2023-10-06 14:24:33 +02:00
Mario
fe38c81e07 use the correct variable 2023-10-06 08:50:11 +00:00
Mario
fed9bc7072 use encode_person() instead of plain xchan_url since the function makes some special effort to determine the real actor id 2023-10-06 08:49:36 +00:00
Mario
044e252d19 composer update html to markdown 2023-10-05 11:35:02 +00:00
Mario
6920fb2793 composer update oauth2 server 2023-10-05 11:33:28 +00:00
Mario
3d1171de8d composer update smarty 2023-10-05 10:24:46 +00:00
Mario
6e09754d06 rever iconv in gitlab ci 2023-10-05 10:20:03 +00:00
Mario
32f2de17d4 composer update bootstrap 2023-10-05 10:17:07 +00:00
Mario
600e8081a8 fix regression 2023-10-05 09:29:53 +00:00
Mario
59fd7c3c9a css fix 2023-10-04 19:15:53 +00:00
Mario Vavti
7e70fe1126 bump version 2023-10-04 21:01:30 +02:00
Mario Vavti
5265c774ae move right aside into bottom of left aside if screen width is < 1200px 2023-10-04 21:00:00 +02:00
Mario Vavti
d1421d720c parse the event object in first place and use the body bbcode as backup 2023-10-04 20:11:05 +02:00
Pascal
2bd09d3b30 work with Mastodon-style keyId 2023-10-04 17:00:19 +02:00
Mario
56e54ac820 if the item is sourced and provides an event add it to the calendar 2023-09-28 16:55:49 +00:00
Mario
08d85798ed since the activity filter widget requires the network module we can link to the module directly so that it will work as quicklink widget in other modules 2023-09-27 13:27:35 +00:00
Mario
38c2b36606 ÅÅfix narrow navbar 2023-09-25 20:00:33 +00:00
Mario
01b747287a fix php warnings 2023-09-22 09:24:04 +00:00
Mario
c925e13e5a cleanup and warnings 2023-09-21 14:47:56 +00:00
Mario
1ced89a869 fix javascript error 2023-09-21 09:14:15 +00:00
Mario
a5e32dc3de more deprecate $a 2023-09-21 08:34:02 +00:00
Mario
150174c3bb jsonld: return object instead of json string 2023-09-21 08:33:17 +00:00
Mario
601ee0b40b only show theme switch icon if switching is supported by the theme 2023-09-21 08:31:53 +00:00
Mario
9627c3e7c8 store the actor cache date so we can easily invalidate it after a period of time 2023-09-21 06:14:24 +00:00
Mario
d88c67eba3 deprecate the ancient $a variable 2023-09-20 10:45:33 +00:00
Mario
bb38a90dda use small profile images instead of medium 2023-09-17 13:35:55 +00:00
Mario
c36743f7ee css fixes 2023-09-16 19:17:02 +00:00
Mario
860275f888 typo 2023-09-16 18:37:34 +00:00
Mario
670228ff63 more changelog
(cherry picked from commit 4338e4ef86)
2023-09-16 20:16:59 +02:00
Mario
4338e4ef86 more changelog 2023-09-16 18:16:13 +00:00
Mario
dbc712c53c version 8.6.3 2023-09-16 18:02:22 +00:00
Mario
bb6011ea73 Revert "version 8.6.3"
This reverts commit 1915f34de8
2023-09-16 18:00:42 +00:00
Mario
1915f34de8 version 8.6.3 2023-09-16 17:59:31 +00:00
Mario
675f26fe90 changelog
(cherry picked from commit 491e309911)
2023-09-16 19:58:52 +02:00
Mario
491e309911 changelog 2023-09-16 17:55:59 +00:00
Mario
283d27c5b1 css fix 2023-09-16 11:35:41 +00:00
Mario
24d862c1bc fix regression in jsonld_document_loader()
(cherry picked from commit 3708c1ac8c)
2023-09-16 13:26:38 +02:00
Mario
3708c1ac8c fix regression in jsonld_document_loader() 2023-09-16 10:51:28 +00:00
Mario
df60be423a redbasic: add functions for reference 2023-09-15 13:50:19 +00:00
Mario
a1e583129f more type checking
(cherry picked from commit a06b28b693)
2023-09-15 15:46:15 +02:00
Mario
a06b28b693 more type checking 2023-09-15 13:45:24 +00:00
System user; apache
198070700c only select the required fields to prevent memory exhaustion on big result sets
(cherry picked from commit 3a01aa40d8)
2023-09-15 15:32:38 +02:00
System user; apache
3a01aa40d8 only select the required fields to prevent memory exhaustion on big result sets 2023-09-15 15:28:13 +02:00
Mario
b628af2258 allow themes to manipulate app icons (photos) via a hook 2023-09-15 06:55:27 +00:00
Mario
0cb5d0d63e also look for widgets in view/theme/themename/widget 2023-09-14 12:30:14 +00:00
Mario
526c85e2ca fix minor regression after recent changes 2023-09-14 10:00:24 +00:00
Mario
8a21c8e618 more theme fixes 2023-09-13 20:56:27 +00:00
Mario
8d3d5747d2 more theme fixes 2023-09-13 16:31:38 +00:00
Mario
f1f1406596 revert extra padding 2023-09-13 15:53:40 +00:00
Mario
9e42be9884 theme fixes 2023-09-13 15:51:10 +00:00
Mario
75e75b93cf an attempt to cache seen item mids for the purpose that we can hide seen pubstream items from the notifications - might revert if it turns out that it does not scale 2023-09-10 19:09:55 +00:00
Mario
0e8ecbc9fc theme fixes to make a barebones theme work slightly better 2023-09-10 08:00:18 +00:00
Mario
a88236b36f possible fix for item widget not respecting ACL if added by title - issue #1799 2023-09-09 18:52:30 +00:00
Mario
df06c54bd2 Merge branch 'translations/update-norwegian-bokmål-strings' into 'dev'
Update translations for Norwegian Bokmål.

See merge request hubzilla/core!2059
2023-09-09 18:02:52 +00:00
Mario
f2d88387c9 Merge branch 'redbasic/fix-darktheme-colorbox' into 'dev'
redbasic: Use body background color for colorboxes.

See merge request hubzilla/core!2058
2023-09-09 18:01:00 +00:00
Mario
db4c6bbd3b Merge branch 'cherry-pick-847732bd-2' into 'dev'
Update Spanish strings

See merge request hubzilla/core!2057
2023-09-09 17:59:48 +00:00
Harald Eilertsen
c8e7f79f50 Update translations for Norwegian Bokmål. 2023-09-09 15:41:18 +02:00
Mario
1157dc7dc8 make sure to set the other relevant dates aswell to omit discrepancies if they would be set a splitsecond later when we store the item 2023-09-07 19:55:15 +00:00
Harald Eilertsen
c12833521f Transparent background for colorbox controls icons.
This makes it blend in better when using dark style. I've kept the
actual button/control colours unchanged though.
2023-09-07 20:34:40 +02:00
Harald Eilertsen
5d9346999e redbasic: Use body background color for colorboxes.
Typically (only?) used by the "view source" function.
2023-09-07 13:30:58 +02:00
mjfriaza:4GF~eYj,-iAv
52c0631833 Update Spanish strings
(cherry picked from commit 847732bd8ac4b79f206981af7d90f183ee8ea58a)
2023-09-02 16:37:25 +02:00
Mario
e16aefec2c call init allthough it does not contain anything atm. it will set up things we need later e.g. App::$page["htmlhead"] and php will raise a warning if it does not exist. Also minor cleanup 2023-08-30 08:44:18 +00:00
Mario
053a247cc8 work around sabre caldav php warnings 2023-08-28 08:11:32 +00:00
Mario
1426b7a6dc order by hubloc_id like everywhere else for this reason and do not include deleted hublocs 2023-08-27 20:29:30 +00:00
Mario
ec66949b35 version 8.6.2 2023-08-27 19:06:14 +00:00
Mario
bc9d8d1136 changelog 2023-08-27 19:03:21 +00:00
Mario
542a527d0d changelog 2023-08-27 19:02:55 +00:00
Mario Vavti
5e0c392287 test refactor the previous commit
(cherry picked from commit 0a3094fc9a)
2023-08-27 20:01:01 +02:00
Mario Vavti
05ff94941c allow public stream comments/reactions if item_fetched is set, when fetching parent of a reaction fetch the thr_parent
(cherry picked from commit 816bbad28a)
2023-08-27 20:00:30 +02:00
Mario
a27d75d610 fix notification text for likes in cases where obj.actor is not set
(cherry picked from commit ce4150cd06)
2023-08-27 19:59:24 +02:00
Mario
446e842904 make sure that we allow "0" as pathname
(cherry picked from commit be19b75031)
2023-08-27 19:58:55 +02:00
Mario
ba153e2c18 mising pdl file
(cherry picked from commit 2d5c99f459)
2023-08-27 19:58:07 +02:00
Mario
3342ea6891 fix unable to create folders with name 0
(cherry picked from commit c4af4e3297)
2023-08-27 19:57:01 +02:00
Mario
8c3d5fd295 fix index name mixup
(cherry picked from commit 1acfc05e2d)
2023-08-27 19:56:26 +02:00
Mario
5fc58fb10a missing semicolon
(cherry picked from commit b40c38f58c)
2023-08-27 19:56:10 +02:00
Mario
4e2ae9cd4e remove unused variable
(cherry picked from commit 0ec715d7c9)
2023-08-27 19:55:49 +02:00
DM42.Net Hubzilla Development
4167ca2e5c Fix Typo
(cherry picked from commit 3bd2a91992)
2023-08-27 19:55:23 +02:00
Mario
9b3e9dcf02 fix cached jsonld files fetched via network 2023-08-27 17:53:40 +00:00
Mario
f203fcc92e more performance improvements
(cherry picked from commit 4b1384be83)
2023-08-27 19:50:39 +02:00
Mario
0b20069c20 move trigger out of the loop for better performance and some var -> let 2023-08-27 17:49:52 +00:00
Mario
bad7b778b3 fix php warning 2023-08-27 17:48:10 +00:00
Mario
f89ce93940 ignore internal follow activity
(cherry picked from commit 7200c71673)
2023-08-27 19:45:51 +02:00
Mario
1ddbc8a26d fix admin table highlight by adding the correct classes
(cherry picked from commit c412c01a65)
2023-08-27 19:43:09 +02:00
Mario Vavti
0a3094fc9a test refactor the previous commit 2023-08-21 10:45:12 +02:00
Mario Vavti
816bbad28a allow public stream comments/reactions if item_fetched is set, when fetching parent of a reaction fetch the thr_parent 2023-08-21 10:07:51 +02:00
Mario
ce4150cd06 fix notification text for likes in cases where obj.actor is not set 2023-08-19 08:55:17 +00:00
Mario
be19b75031 make sure that we allow "0" as pathname 2023-08-15 12:05:50 +00:00
Mario
3ddab5966b only try to fetch the icon if we actually got one 2023-08-14 18:13:58 +00:00
Mario
2d5c99f459 mising pdl file 2023-08-14 09:40:51 +00:00
Mario
a5a1bbf5d7 move profile photo fetching to background 2023-08-14 09:21:45 +00:00
Mario
c4af4e3297 fix unable to create folders with name 0 2023-08-14 08:17:47 +00:00
Mario
1acfc05e2d fix index name mixup 2023-08-14 07:58:44 +00:00
Mario
b40c38f58c missing semicolon 2023-08-14 07:38:36 +00:00
Mario
87c41cb9ac Merge branch 'DM42-Manifest-Typo-20230725' into 'dev'
Fix Typo

See merge request hubzilla/core!2055
2023-08-11 09:03:29 +00:00
Mario
0ec715d7c9 remove unused variable 2023-08-09 08:18:27 +00:00
Mario
e6a261a789 now all acl fields are checked. if they are not complete the check will fail 2023-08-09 08:01:18 +00:00
DM42.Net Hubzilla Development
3bd2a91992 Fix Typo 2023-07-25 09:07:32 -04:00
Mario
c721bc672c Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-07-21 12:07:57 +00:00
Mario
931b876b44 fix cached jsonld files fetched via network 2023-07-21 12:07:17 +00:00
Mario
87b91e5023 Merge branch 'DM42-20230718-fixjsonldrawfile' into 'dev'
add .jsonld to the list of allowed file suffixes for direct download.  Fixes...

See merge request hubzilla/core!2053
2023-07-21 10:02:41 +00:00
Mario
4b1384be83 more performance improvements 2023-07-21 08:17:45 +00:00
Mario
8da6e6a096 move trigger out of the loop for better performance and some var -> let 2023-07-20 19:20:56 +00:00
Mario
5181e575b4 fix accesslist in two cases 2023-07-20 11:46:40 +00:00
Mario
ca994735be Merge branch 'zotlabs/improve-access-list-type-safety' into 'dev'
Zotlabs: Improve type safety for AccessList class.

See merge request hubzilla/core!2052
2023-07-20 09:05:42 +00:00
Harald Eilertsen
718c303086 Zotlabs: More type safety for AccessList class.
Add more type declarations to class attributes and functions.

This should ensure that only strings and null values can be assigned to
the various access list members. This is still a bit loose, as we should
probably aim for lists of channel or group id's instead of a generic
type like a string.

I'll leave that for later, though.
2023-07-19 20:19:00 +02:00
Mario
7200c71673 ignore internal follow activity 2023-07-19 12:52:41 +00:00
DM42.Net Hubzilla Development
14c97799c6 add .jsonld to the list of allowed file suffixes for direct download. Fixes 404 error when trying to get /library/w3org/security-v1.jsonld and /library/w3org/activitystreams.jsonld 2023-07-18 14:34:10 -04:00
Harald Eilertsen
a06e8bfaee Zotlabs: Improve type safety for AccessList class.
Add type annotations for constructor and set* methods, and throw an
exception if the passed in arrays are missing required keys. This means
that both invalid input types and missing keys will throw and exception
rather than just die with a runtime error.

There's not checks to verify that the contents of the required array
keys are valid or make sense, though. They are just assigned, and
returned as is by the get method when requested.

Also, the set_from_array method is not well tested at the moment.
2023-07-18 20:18:42 +02:00
Mario
7dad60bbd5 version 8.6.1 2023-07-18 13:09:56 +00:00
Mario
a66b4626fb changelog
(cherry picked from commit 330add963d)
2023-07-18 15:08:07 +02:00
Mario
330add963d changelog 2023-07-18 13:04:34 +00:00
Mario
da1ccc620b Merge branch 'DM42-20230717-fixfatalerron304' into 'dev'
Skip logging when DB functions are not yet loaded (logging requires db lookup).

See merge request hubzilla/core!2051
2023-07-18 11:12:11 +00:00
Mario
c412c01a65 fix admin table highlight by adding the correct classes 2023-07-18 11:00:21 +00:00
Mario
74d7fa61d9 fix hcard addon regression
(cherry picked from commit ef6ea4484e)
2023-07-18 12:11:50 +02:00
Mario
ef6ea4484e fix hcard addon regression 2023-07-18 09:57:38 +00:00
DM42.Net Hubzilla Development
ba2d775215 Skip logging when DB functions are not yet loaded (logging requires db lookup). 2023-07-17 20:34:16 -04:00
Mario
f866771854 Merge branch 'tests/cleanup-unit-tests' into 'dev'
Cleanup unit tests

See merge request hubzilla/core!2049
2023-07-17 08:43:08 +00:00
Mario
70b8c57d22 basic per item rtl language support - issue ##1780 2023-07-13 09:47:50 +00:00
Harald Eilertsen
b04e0d0fd4 tests: AccessListTest expand is_private test. 2023-07-12 21:57:27 +02:00
Harald Eilertsen
3f9d5e11d1 tests: AccessListTest move type annotation to code
This cleans up the doc comment. Should probably try to do this
everywhere.
2023-07-12 21:56:09 +02:00
Harald Eilertsen
09fe271b25 tests: AccessListTests nitpicking on doc comment. 2023-07-12 21:39:37 +02:00
Harald Eilertsen
d5c1a49984 tests: AccessListTest collect defaults in one testcase.
Just no need to have them spread around in various other tests cases.
2023-07-12 21:38:10 +02:00
Harald Eilertsen
e80d3653c9 test: Enable and cleanup GetTagsTest.
These tests actually tests both the get_tags() function, and the
handle_tags() function. The latter don't work, and should probably be
split into it's own test cases.

There's also some stubs here that we may want to deal with in another
way.

Also removed meaningless "test" of intval() builtin function. It behaves
as documented, no need for us to test it.
2023-07-12 20:42:37 +02:00
Harald Eilertsen
30b0d0a5cc tests: Cleanup ContainsAttribute test.
Mostly cosmetic to satisfy phpcs + remove explicit require.
2023-07-12 20:42:37 +02:00
Harald Eilertsen
9beceb9b02 tests: Cleanup Autoname test.
Not sure if this test is actually useful, but leave it for now.
2023-07-12 20:42:37 +02:00
Harald Eilertsen
6f13cabfba tests: Don't explicitly require CUT in AntiXSSTest.
Rely on PHPUnit config to load the app and the code under test.
2023-07-12 20:42:37 +02:00
Harald Eilertsen
7bd2de9967 unit-tests: There's no need to test builtin func hex2bin 2023-07-12 20:42:37 +02:00
Harald Eilertsen
b0b0973e2d unit tests: Cosmetic fixes in AntiXSSTest.php
- Start comments with capital letter
- Fix indentation
- Add missing doc comments
2023-07-12 20:42:36 +02:00
Mario
3d866e8975 update date 2023-07-11 19:55:08 +00:00
Mario
63fb8d0392 Merge branch '8.6RC' 2023-07-11 18:57:18 +00:00
Mario
384de0925e version 8.6 2023-07-11 18:56:21 +00:00
Mario
5b5c569c82 RC2 2023-07-05 10:06:57 +00:00
Mario
6f2371ee74 changelog 2023-07-05 10:05:38 +00:00
Mario
d6e7d90197 fix regression after recent changes 2023-07-05 09:29:33 +00:00
Mario
aa73db0fe6 bump dev version 2023-07-04 18:05:37 +00:00
Mario
d85088fc3d version and strings 2023-07-04 18:00:33 +00:00
Mario
7e21aeedcd css fix 2023-07-04 17:51:16 +00:00
Mario
342460fa17 css fixes 2023-07-04 11:19:04 +00:00
Mario
e57211fbd1 also filter deleted hublocs 2023-07-04 09:07:39 +00:00
Mario
d31eb4c89c update fullcalendar 2023-07-04 08:47:22 +00:00
Mario
6753d260e4 do not linkify in nobb and noparse tags - issue #1776 2023-07-04 08:05:00 +00:00
Mario
a3092204a1 fix issue #1771 2023-07-03 18:35:10 +00:00
Mario
10b49af776 fix php warning 2023-07-03 12:42:46 +00:00
Mario
3497ced9f9 Ãfix php warning 2023-07-03 10:49:34 +00:00
Mario
7a0f22b0a7 make sure to return infos from current hub where applicable - fix issue #1770 2023-07-03 10:37:32 +00:00
Mario
4f03272a5f unify code for selecting deliverable abook xchans 2023-07-01 11:03:26 +00:00
Mario
7755936a2e remove unused pseudo abook code 2023-06-29 12:31:32 +00:00
Mario
9f6844ec30 pass $escape to stringify_array_elms() 2023-06-29 11:43:02 +00:00
Mario
c2952aa803 make sure to not allow moderation of poll answers 2023-06-29 11:29:48 +00:00
Mario
8f7383f5c2 text 2023-06-28 12:05:55 +00:00
Mario
750641ef19 implement inline moderation of reactions 2023-06-27 14:53:23 +00:00
Mario
fb48dfc082 bump version 2023-06-24 21:30:39 +00:00
Mario
1de5bce1c1 remove logging 2023-06-24 21:00:24 +00:00
Mario
676603239d Merge branch 'cherry-pick-1baa3489' into 'dev'
Update Spanish translation-2

See merge request hubzilla/core!2048
2023-06-23 12:39:19 +00:00
Mario
4c87f36a8c bump version 2023-06-23 12:37:07 +00:00
Mario
12b2137a04 fix relaying and syncing in Activity::drop(), change wording for moderation request notices and redirect moderation request for reactions to mod moderate 2023-06-23 12:35:41 +00:00
mjfriaza
762e1c9c2b Update Spanish translation-2
(cherry picked from commit 1baa34894f6799cac3d973db8c1205239ad6179b)
2023-06-23 13:44:18 +02:00
Mario
cd26ead043 implement optional moderation of unsolicited comments, minor css fixes and some more work on ocap 2023-06-23 09:13:51 +00:00
Mario
6a560cfec4 always check pageflags otherwise site specific flags will be overwritten when a sync package arrives from a clone that has no flags for this channel - fix issue #1769 2023-06-21 09:20:25 +00:00
Mario
489ba72d5c fix issues in mod oep 2023-06-19 19:47:01 +00:00
Mario Vavti
5df9779669 make sure to use the correct url 2023-06-18 22:27:33 +02:00
Mario
e49d2f6b8f remove deprecated templates 2023-06-18 09:20:57 +00:00
Mario
9550a7a954 more html fix 2023-06-18 09:02:10 +00:00
Mario
d9f855b97e fix bogus html 2023-06-18 09:00:54 +00:00
Mario
e275dae6e3 use function to get actor hublocs 2023-06-18 08:43:05 +00:00
Mario
88ccc2a3b9 bump version 2023-06-17 07:59:16 +00:00
Mario
84487edc05 undefined variable and return null in fetch_local if we did not find anything (we also return null in fetch) 2023-06-16 12:27:08 +00:00
Mario
7177649969 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-06-16 12:16:47 +00:00
Mario
18b7b3f125 deprecate ActivityStreams::fetch() and provide the possibility to fetch local items directly 2023-06-16 12:16:22 +00:00
Mario
89c7e1a8ee Merge branch 'help' into 'dev'
typo in hooklist.bb

See merge request hubzilla/core!2042
2023-06-15 20:41:06 +00:00
Mario
774a9b118e Merge branch 'make-unit-tests-pass' into 'dev'
Make unit tests pass

See merge request hubzilla/core!2041
2023-06-15 20:40:28 +00:00
Mario
327841280b Merge branch 'dev' into 'dev'
Simplified version auf automated install script

See merge request hubzilla/core!2040
2023-06-15 20:36:22 +00:00
OJ Random
1e0a686561 Simplified version auf automated install script 2023-06-15 20:36:20 +00:00
OJ Random
96883100b4 typo in hooklist.bb 2023-06-15 19:19:08 +02:00
Harald Eilertsen
1fcb05ed8c Unit tests: Update Markdown tests to reflect that it works. 2023-06-14 23:02:13 +02:00
Harald Eilertsen
8c85516c57 Unit tests: Book Hubzilla to make app env available in tests.
Not quite unit test clean, but a somewhat pragmatic approach to make the
tests pass as is.
2023-06-14 23:00:44 +02:00
Mario
6989a3eaad fix string replacement if a match is available more than once 2023-06-12 19:05:37 +00:00
Mario
57796a2f96 only remove the owner from delivery if its their post and minor cleanup
(cherry picked from commit 59b217f7ea)
2023-06-12 10:17:17 +02:00
Mario
59b217f7ea only remove the owner from delivery if its their post and minor cleanup 2023-06-12 08:13:42 +00:00
Mario
fb9a193c44 do not add deleted xchans for poco 2023-06-08 16:24:02 +00:00
Mario
2739f1f3f0 remove logging 2023-06-08 15:34:00 +00:00
Mario
0c2cb18578 shuffle queue deliveries for more randomness 2023-06-08 15:33:02 +00:00
Mario
db2c5aae84 bump version 2023-06-02 19:56:50 +00:00
Mario
aa2cec103b Merge branch 'dev' into 'dev'
Update 'full' and 'minimal' layouts to use color_mode functionality

See merge request hubzilla/core!2039
2023-06-02 19:54:59 +00:00
ivan zlax
a532a70ac0 Update 'full' and 'minimal' layouts to use color_mode functionality 2023-06-02 19:54:59 +00:00
Mario
ec6cec8854 even more changelog
(cherry picked from commit 3fb22d27ab)
2023-06-02 21:47:41 +02:00
Mario
3fb22d27ab even more changelog 2023-06-02 19:46:49 +00:00
Mario
1cbaab5889 more changelog
(cherry picked from commit fef19b47c2)
2023-06-02 21:39:27 +02:00
Mario
fef19b47c2 more changelog 2023-06-02 19:38:46 +00:00
Mario
5126613825 update bootstrap to version 5.3 2023-06-02 19:35:23 +00:00
Mario
07097d2fa3 version 8.4.2 2023-06-02 19:27:36 +00:00
Mario
8c9fb32ca0 changelog
(cherry picked from commit 68d921e918)
2023-06-02 21:26:22 +02:00
Mario
68d921e918 changelog 2023-06-02 19:25:49 +00:00
Mario
330b36159d work around hubloc confusion in mod rmagic
(cherry picked from commit 02089f15c4)
2023-06-02 21:18:52 +02:00
Mario
046152e798 improved unseen forums notification
(cherry picked from commit 6a27afa6ac)
2023-06-02 21:18:30 +02:00
Mario
11ca5bb7d5 owa: workaround for friendica when using nginx until this will be fixed at their side and check prrofile uid for features instead of local channel
(cherry picked from commit 423fdc0a96)
2023-06-02 21:16:56 +02:00
Mario
e0838ff8ab fix wrong array key
(cherry picked from commit 11a2419c22)
2023-06-02 21:13:31 +02:00
Mario
11a2419c22 fix wrong array key 2023-06-02 19:10:53 +00:00
Mario
f3420c0adb bump version 2023-06-02 18:30:04 +00:00
Mario
bd84ff4838 update bootstrap to version 5.3 2023-06-02 16:36:57 +00:00
Mario
87689df062 even more adjust text 2023-06-02 15:59:26 +00:00
Mario
1bfbd57ee4 more adjust text 2023-06-02 15:34:06 +00:00
Mario
64d7585282 adjust text 2023-06-02 15:29:24 +00:00
Mario
0ee03a565f remove custom acl from rpost 2023-06-02 12:02:50 +00:00
Mario Vavti
1b0e268416 fix theme_attachments()
(cherry picked from commit 65a472c113)
2023-06-02 13:35:39 +02:00
Mario
0e8d1afcaf Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-06-02 11:34:08 +00:00
Mario
48a33f08e2 ocap initial checkin 2023-06-02 11:33:44 +00:00
Mario Vavti
f9ca956510 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-06-02 13:30:36 +02:00
Mario Vavti
65a472c113 fix theme_attachments() 2023-06-02 13:30:21 +02:00
Mario
4b17ea04a7 add owner and author to item_permissions_sql() 2023-06-01 10:15:35 +00:00
Mario
423fdc0a96 owa: workaround for friendica when using nginx until this will be fixed at their side and check prrofile uid for features instead of local channel 2023-06-01 08:15:33 +00:00
Mario
396b124e84 do not parse x-multicode as bbcode 2023-05-30 09:11:30 +00:00
Mario
6a27afa6ac improved unseen forums notification 2023-05-30 08:59:29 +00:00
Mario
b9812ba06a update composer libs 2023-05-30 08:36:17 +00:00
Mario
bc6aded074 fix a possible privacy mismatch 2023-05-29 18:16:38 +00:00
Mario
904401617a mod magic make a get request instead of post and remove digest header 2023-05-26 10:17:53 +00:00
Mario
02089f15c4 work around hubloc confusion in mod rmagic 2023-05-26 08:19:34 +00:00
Mario
43a18a2569 update description 2023-05-25 09:01:29 +00:00
Mario
4c2dc2bf16 Merge branch 'dev' into 'dev'
double columns templates

See merge request hubzilla/core!2035
2023-05-25 08:53:03 +00:00
ivan zlax
e6eb2a8476 double columns templates 2023-05-25 08:53:03 +00:00
Mario
af5ae163f3 more fixes for where keyId = acct:xxx@yyy.zz 2023-05-25 08:18:16 +00:00
Mario
d00860430f owa fixes for where keyId = acct:xxx@yyy.zz 2023-05-25 08:03:10 +00:00
Mario
af0b4a0fca return hubloc_hash instead of hubloc_id_url for AP and improved check for location 2023-05-24 09:08:32 +00:00
Mario
404189f88c backgound url must be between quotation marks 2023-05-20 17:38:37 +00:00
Mario
1a27fad9b9 backgound url must be between quotation marks 2023-05-20 12:40:28 +00:00
Mario
c2cfe481df version 8.4.1 2023-05-20 09:28:32 +00:00
Mario
3a56fb6ec6 Merge branch 'dev' 2023-05-20 09:27:45 +00:00
Mario
61950decb3 changelog 2023-05-20 09:27:31 +00:00
Mario
1a614ea023 instead of setting the value to 0 just continue so that already existing values will not be overwritten 2023-05-19 13:17:45 +00:00
Mario
a83b6a5e63 instead of setting the value to 0 just continue so that already existing values will not be overwritten 2023-05-19 13:16:53 +00:00
Mario
65d98af24c Merge branch '8.4RC' 2023-05-17 13:28:23 +00:00
Mario
62d35627f3 version 8.4 2023-05-17 13:28:05 +00:00
Mario
84f1ed1587 Merge branch 'dev' into 8.4RC 2023-05-17 13:26:01 +00:00
Mario
31b4fb343d changelog 2023-05-17 13:25:33 +00:00
Mario
3c3f5c60da changelog 2023-05-16 09:26:45 +00:00
Mario
18914f2081 Merge branch 'dev' into 8.4RC 2023-05-15 08:04:02 +00:00
Mario
b50da2d8b7 fix parent_mid and thr_parent not set correctly for response activities 2023-05-15 08:03:27 +00:00
Mario
5bdd699c9d Merge branch 'dev' into 8.4RC 2023-05-13 19:52:52 +00:00
Mario
29e8e6d95c fix parent and parent_mid for likes 2023-05-13 19:51:25 +00:00
Mario Vavti
049fc91615 Merge branch 'dev' into 8.4RC 2023-05-13 21:38:08 +02:00
Mario Vavti
b7c96f2cbd Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-05-13 21:37:45 +02:00
Mario Vavti
1e6408df13 fix regression decoding the uuid for responses 2023-05-13 21:37:33 +02:00
Mario
7b90548c1d save a query 2023-05-12 17:45:30 +00:00
Mario
5d330e18ff save a query 2023-05-12 16:29:42 +00:00
Mario
07662ff076 Merge branch 'dev' into 8.4RC 2023-05-12 08:02:19 +00:00
Mario
9252ae1596 css fixes 2023-05-12 08:01:25 +00:00
Mario
0155e9131d remove outdated comments 2023-05-11 12:51:25 +00:00
Mario
247cf40ace bump version 2023-05-10 20:45:33 +00:00
Mario
4a6b450c55 Merge branch 'dev' into 8.4RC 2023-05-10 20:44:43 +00:00
Mario
5b80d57a54 php warning 2023-05-10 20:40:10 +00:00
Mario
8ac4547e73 php warnings 2023-05-10 20:33:38 +00:00
Mario
3658975b69 typo 2023-05-10 20:22:18 +00:00
Mario
abc3545ef9 use act->objprop() in decode_note() 2023-05-10 20:11:54 +00:00
Mario
01f8cb698d check if we have a type and a href 2023-05-10 18:38:43 +00:00
Mario
5e4d0f45fc check if var is set and escape $ sign in ru translation 2023-05-10 16:43:00 +00:00
Mario
efd2f78274 check if var is set and escape $ sign in ru translation 2023-05-10 16:42:12 +00:00
Mario
690ff955fa Merge branch 'dev' into 8.4RC 2023-05-10 16:09:36 +00:00
Mario Vavti
3fb27bdc55 fix query for postgres 2023-05-10 18:04:19 +02:00
Mario
d8306fca6f Merge branch 'dev' into 8.4RC 2023-05-10 12:05:15 +00:00
Mario Vavti
380775540d missing function 2023-05-10 14:03:37 +02:00
Mario Vavti
65e3b0dafd deal with arrays and json 2023-05-10 13:53:03 +02:00
Mario
4ae81d753c Merge branch 'dev' into 8.4RC 2023-05-10 08:16:09 +00:00
Mario
0f01aac823 wording 2023-05-10 08:15:21 +00:00
Mario
ce0a96351e make sure we have a xchan and a hubloc - otherwise re-discover 2023-05-10 08:14:51 +00:00
Mario
93dda6f1fd Merge branch 'dev' into 8.4RC 2023-05-09 09:20:48 +00:00
Mario
5e83db959e more changelog 2023-05-09 09:20:21 +00:00
Mario
74436eb03e Merge branch 'dev' into 8.4RC 2023-05-09 09:08:06 +00:00
Mario
993178fc49 changelog 2023-05-09 09:07:32 +00:00
Mario
1c217cf446 es translation as per manuel 2023-05-09 07:58:41 +00:00
Mario
0bf2be1f9d Merge branch 'owa-compat-friendica' into 'dev'
Owa compatibility for Friendica

See merge request hubzilla/core!2036
2023-05-09 07:50:30 +00:00
Pascal Deklerck
548589be4d Owa compatibility for Friendica 2023-05-09 07:48:52 +00:00
Max Kostikov
697a1b1ed1 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!2037
2023-05-08 12:44:18 +00:00
Max Kostikov
d893c7eb33 Update Russian hstrings.php 2023-05-08 12:42:17 +00:00
Max Kostikov
8957d24752 Update Russian hmessages.po 2023-05-08 12:41:46 +00:00
Mario
677e730235 Merge branch 'dev' into 8.4RC 2023-05-07 14:25:17 +00:00
Mario
4227d973b9 missing class 2023-05-07 14:24:59 +00:00
Mario
06c0af50c3 Merge branch 'dev' into 8.4RC 2023-05-07 12:48:14 +00:00
Mario
4d3a48d1c1 cropper fixup 2023-05-07 12:47:13 +00:00
Mario
f6b66f4cad Merge branch 'dev' into 8.4RC 2023-05-07 12:17:09 +00:00
Mario
a56f9ab4e6 more css and whitespace 2023-05-07 12:16:52 +00:00
Mario
ca913e5077 Merge branch 'dev' into 8.4RC 2023-05-07 12:04:54 +00:00
Mario
b25ebe12c5 more css 2023-05-07 12:03:42 +00:00
Mario
984980b170 version 2023-05-07 11:31:50 +00:00
Mario
be45005dbb css fixes 2023-05-07 11:29:45 +00:00
Mario
b8c9f04989 bump version 2023-05-07 09:04:10 +00:00
Mario
bf2d41eb14 composer autoload 2023-05-07 08:46:28 +00:00
Mario Vavti
158f9afb37 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-05-07 10:42:10 +02:00
Mario Vavti
f884e31d21 composer autoload 2023-05-07 10:41:57 +02:00
Mario
d3a5ff9d68 version and strings 2023-05-07 08:39:59 +00:00
Mario Vavti
7185780d4e h3 adds bottom margin - remove it 2023-05-07 10:30:34 +02:00
Mario Vavti
f995b2822f exclude deleted hublocs 2023-05-07 10:03:27 +02:00
Mario Vavti
d7490ac738 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-05-07 09:52:38 +02:00
Mario Vavti
383d0e17f2 fix directory search 2023-05-07 09:52:27 +02:00
Mario
7c1a3ab36e css fix 2023-05-07 07:11:54 +00:00
Mario
edc8d17031 slightly change online status display 2023-05-06 20:42:04 +00:00
Mario
f3f861234d minor css fix 2023-05-06 20:28:29 +00:00
Mario
93278c00b7 update profile vcard to implement the cover image 2023-05-06 19:41:02 +00:00
Mario
5bbe93d49f minor de strings update 2023-05-05 17:49:08 +00:00
Mario
21cd8d31d7 css fix 2023-05-05 17:46:53 +00:00
Mario
d649b4df28 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-05-05 16:10:12 +00:00
Mario
2bb9550343 slightly more robust get_quote_bbcode() 2023-05-05 16:09:53 +00:00
Mario Vavti
ef0feff4a5 Hidden > Spam 2023-05-05 12:33:39 +02:00
Mario
dfa43b4856 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-05-04 09:28:05 +00:00
Mario
a24a1ca6d7 update 1258 to remove traces of channelreputation 2023-05-04 09:27:31 +00:00
Mario Vavti
2d4b35fbc9 provide possibility to flag via ajax calls to prevent pageloads 2023-05-03 22:42:52 +02:00
Mario Vavti
57e2910477 flag new xtags with the xchan flag 2023-05-03 18:13:47 +02:00
Mario Vavti
ffbaa7e4dc when flagging an entry also flag its xtags and improved keywords query in dirsearch 2023-05-03 15:25:47 +02:00
Mario
df42036100 make sure config.system.trusted_directory_servers is an array 2023-05-03 08:47:21 +00:00
Mario Vavti
ca9491d343 move trusted directory servers to security and implement in backend 2023-04-29 22:43:49 +02:00
Mario
96ae569eaf trusted dir servers frontend 2023-04-29 19:38:34 +00:00
Mario Vavti
fb295d53f1 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-04-29 20:17:19 +02:00
Mario Vavti
95d07974f4 fix php warning 2023-04-29 20:13:52 +02:00
Mario
39d78064da Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-04-28 21:50:01 +00:00
Mario
a2bcbb90ed fix regression decoding obj type 2023-04-28 21:44:12 +00:00
Mario
c31b37f570 bootstrap files 2023-04-28 19:23:28 +00:00
Mario
2a1341b910 update bootstrap 2023-04-28 19:02:23 +00:00
Mario Vavti
354e341d69 mastodon says hashtag is a subset of link - issue #1750 2023-04-28 12:50:57 +02:00
Mario Vavti
13946b2b76 fix and document edge case 2023-04-28 10:03:05 +02:00
Mario Vavti
29aa52df6a fix poller after refactor 2023-04-28 09:29:15 +02:00
Mario Vavti
c3267a27d3 fix column name 2023-04-28 09:04:02 +02:00
Mario Vavti
3543e6dd32 slightly refactor dir sync 2023-04-28 08:57:21 +02:00
Mario Vavti
5412ba617d more dir sync testing 2023-04-28 00:58:46 +02:00
Mario Vavti
1f81a2cb1b remove updates entry if a xchan_hash mismatch is encountered 2023-04-27 22:54:45 +02:00
Mario Vavti
5da58d42f6 adjust args in libzotdir update and some dir sync fixes 2023-04-27 22:26:53 +02:00
Mario Vavti
299b6037c9 remove logging 2023-04-27 11:24:26 +02:00
Mario Vavti
1ed8b9dd14 fix php error 2023-04-27 11:17:53 +02:00
Mario Vavti
cf4912cb3d use shorter strings 2023-04-27 11:08:21 +02:00
Mario Vavti
e6ec87f910 update doco and fix safemode 2023-04-27 11:00:43 +02:00
Mario Vavti
f72fb974a9 for flag updates also match site directory and ud host 2023-04-27 07:07:38 +02:00
Mario Vavti
bdb25315b6 initial commit for directory flags federation 2023-04-26 23:01:56 +02:00
Mario
60f0739c3e update 1257 ud_guid > ud_host 2023-04-26 16:28:20 +00:00
Mario
0faab9277f fix update 2023-04-26 16:09:14 +00:00
Mario Vavti
51fce12cd7 update 1256 2023-04-26 17:59:20 +02:00
Mario Vavti
d79290df75 dirsync update column 2023-04-26 17:58:35 +02:00
Mario Vavti
0bf65bcad5 remove rate entry and move ignore button to the right 2023-04-26 13:46:25 +02:00
Mario Vavti
44dbf19e89 wrong variable 2023-04-26 12:59:04 +02:00
Mario Vavti
469a76f1f6 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-04-26 12:50:56 +02:00
Mario Vavti
f851c272fa enable dir admins to flag or hide entries 2023-04-26 12:50:37 +02:00
Mario
027a9fec61 fix potential security issue as per friendica 2023-04-26 06:28:24 +00:00
Mario
09fde2f839 correctly set some perms when our follow request was accepted 2023-04-25 08:36:20 +00:00
Mario
8a14e4261d check for uuid so that will be also catch items that were posted from alternate locations 2023-04-23 18:44:39 +00:00
Mario
6c9f1de265 remove logging 2023-04-23 18:05:17 +00:00
Mario
3ad0179b62 fix regression when rendering event items 2023-04-23 16:07:57 +00:00
Mario Vavti
81f33da499 improved fetch_conversation() 2023-04-23 13:02:38 +02:00
Mario
80d70e64f5 bump version 2023-04-23 09:26:30 +00:00
Mario
eec4845cd0 add the conversation endpoint and implement paginated fetch for zot requests in mod item 2023-04-23 09:23:39 +00:00
Mario
b99a4ade1a bump version 2023-04-21 10:39:17 +00:00
Mario
84e25e8fd2 Fetch conversations in the background. Otherwise it might sgnificantly delay delivery 2023-04-21 10:34:55 +00:00
Mario
39e14eb95c hotfix: make sure to not pass an empty path to fopen() 2023-04-21 10:33:05 +00:00
Mario
f277d08244 queue and poller testing 2023-04-21 07:45:32 +00:00
Mario
d7c479fa6d % values in format_poll() should be rounded 2023-04-19 11:01:49 +00:00
Mario Vavti
44e5dc7d97 bump version 2023-04-19 11:14:46 +02:00
Mario Vavti
fdd54057a8 also return deleted channels info in webfinger and document why 2023-04-19 11:12:35 +02:00
Mario Vavti
d43485141f use empty for check 2023-04-16 20:12:04 +02:00
Mario Vavti
2350561903 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-04-16 17:13:00 +02:00
Mario Vavti
5674badccd improved update_directory_entry(), update ud_last even if webfinger failed 2023-04-16 17:12:49 +02:00
Mario
a793f4414d fix php warning 2023-04-16 13:47:48 +00:00
Mario
e99957f99f fix php warning 2023-04-16 11:20:02 +00:00
Mario
ad5bbc463b fix wrong variable 2023-04-16 10:59:26 +00:00
Mario
81993cf2a3 cleanup 2023-04-15 15:15:55 +00:00
Mario
5d40742ee6 fix wrong variable 2023-04-15 07:53:30 +00:00
Mario
1ce050d911 update es strings as per Manuel 2023-04-14 19:02:37 +00:00
Mario
8e7393fc26 update it string as per Giaco 2023-04-14 18:55:45 +00:00
Mario Vavti
ad45205ddf this has been moved to cron for now 2023-04-14 10:45:01 +02:00
Mario Vavti
409e9208ee Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-04-14 09:21:46 +02:00
Mario Vavti
d8811b499d improved item_expire() 2023-04-14 09:21:33 +02:00
Mario
dd1f9494f1 css fix 2023-04-14 06:04:44 +00:00
Mario Vavti
20f4538db4 update remove_all_xchan_resources() and remove deletion of deprecated conv table 2023-04-13 22:28:08 +02:00
Mario Vavti
d08c8e6edc Revert "zot_info(): improved check for deleted"
This reverts commit f1667dbbe6.
2023-04-13 21:50:13 +02:00
Mario Vavti
f1667dbbe6 zot_info(): improved check for deleted 2023-04-13 21:25:03 +02:00
Mario Vavti
2bab7e2693 prevent duplicate definitions 2023-04-13 18:51:13 +02:00
Mario Vavti
824497b97a fix wrong array key, check for xchan_deleted with empty() which will also catch a possibly already removed xchan (which will be null) and bump version 2023-04-13 11:37:01 +02:00
Mario Vavti
0b7bece8e3 remove pre zot6 compatibility tweaks 2023-04-13 11:01:57 +02:00
Mario Vavti
6ddf1a5786 update zotinfo to use as much info as possible from channel since in some cases the xchan might be history already 2023-04-13 10:45:36 +02:00
Mario Vavti
b9827dfe02 move colon to the variable 2023-04-12 23:11:02 +02:00
Mario Vavti
64f30831ac rename update_modtime() to update() and only bump ud_date if something actually changed 2023-04-12 23:07:19 +02:00
Mario Vavti
bf5722cd25 always call update_modtime() foer now; 2023-04-12 19:07:28 +02:00
Mario Vavti
ae074153c8 remouve updates stuff from import_directory_profile() 2023-04-12 18:40:51 +02:00
Mario Vavti
63d46dbdfb more logging 2023-04-12 18:27:04 +02:00
Mario Vavti
bdf1b23198 reset ud_last if we had contact and some cleanup 2023-04-12 18:24:44 +02:00
Mario Vavti
6f1c261f6b deprecate ud_flags and ud_arr in import_xchan() 2023-04-12 18:01:35 +02:00
Mario Vavti
3233d5485f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-04-12 17:51:09 +02:00
Mario Vavti
aa06400a50 deprecate flags and transaction_id and only return results which are currently updated 2023-04-12 17:50:39 +02:00
Mario
30724bd7c4 update updates if anything changed 2023-04-12 15:35:21 +00:00
Mario Vavti
0d3b389538 fix php warning 2023-04-12 13:35:41 +02:00
Mario Vavti
9f7dbe16fd adjust check 2023-04-12 13:21:26 +02:00
Mario Vavti
432024123a update updates if we are provided an ud_arr or we imported a new xchan 2023-04-12 13:17:23 +02:00
Mario Vavti
261762448e use url instead of addr for updates and clean up local_dir_update() and update_modtime() 2023-04-12 11:36:34 +02:00
Mario Vavti
7ce4175876 initial commit directory sync rewrite - should work but still requires lots of cleanup 2023-04-12 09:29:51 +02:00
Mario
a57739c462 Merge branch 'dev' 2023-04-09 20:01:22 +00:00
Mario
03bdbfa705 set ud_last after successfully probing a channel 2023-04-09 20:00:54 +00:00
Mario
92246ce3a8 Merge branch 'dev' 2023-04-09 19:53:27 +00:00
Mario
cdf74c2e41 Revert "make sure to update ud_last timestamp if we successfully fingered a channel"
This reverts commit f76d9b7908.
2023-04-09 19:52:54 +00:00
Mario
4a72ea6666 Merge branch 'dev' 2023-04-09 19:45:04 +00:00
Mario
f76d9b7908 make sure to update ud_last timestamp if we successfully fingered a channel 2023-04-09 19:44:35 +00:00
Mario
dcfdf3a5d7 Merge branch 'dev' 2023-04-09 19:02:36 +00:00
Mario
4873f61d6c disable thread listener interface by default and minor fixes 2023-04-09 18:51:55 +00:00
Mario
1538107ae4 minor queueworker fixes 2023-04-08 20:25:31 +00:00
Mario
9b93dc5137 split up a potentially long running sql query 2023-04-08 20:18:17 +00:00
Mario Vavti
5ec721b978 likes not synced between clones 2023-03-31 09:31:28 +02:00
Mario
24568c0e2f add some explanation and remove logging 2023-03-30 13:23:16 +00:00
Mario
92a89ca258 version 8.3.1 2023-03-30 13:10:47 +00:00
Mario
ba71c53bc6 ignore deliveries by our own channel which do not origin from the local hub. instead rely on the sync delivery. 2023-03-30 12:08:43 +00:00
Mario Vavti
b3cfeb573a do not add not_here, anon, token and rss contacts to receivers 2023-03-29 21:46:28 +02:00
Mario
9083e99d2a in fact this can be removed
(cherry picked from commit 70ca247c88)
2023-03-24 10:29:09 +01:00
Mario
70ca247c88 in fact this can be removed 2023-03-24 09:22:10 +00:00
Mario
14fc0c735b encode object after we have dealt with deleted items and work around a php error
(cherry picked from commit 70b3c8080e)
2023-03-24 10:05:37 +01:00
Mario
70b3c8080e encode object after we have dealt with deleted items and work around a php error 2023-03-24 09:01:06 +00:00
Mario
2c483c460a initial check in to allow all mentions option 2023-03-23 20:11:18 +00:00
Mario
79405cf1d3 Merge branch 'dev' 2023-03-21 09:20:57 +00:00
Mario
5c755fdd1c PHP 8.1 is the required minimum version 2023-03-21 09:20:22 +00:00
Mario
89285f1408 Merge branch '8.2RC' 2023-03-19 13:55:18 +00:00
Mario
17c0bb2069 version 8.2 2023-03-19 13:54:15 +00:00
Mario
192736f6d7 Merge branch 'dev' into 8.2RC 2023-03-19 13:53:12 +00:00
Mario
ae928b9aff changelog 2023-03-19 13:52:43 +00:00
Mario
4eee8ce770 Merge branch 'dev' into 8.2RC 2023-03-19 13:50:39 +00:00
Mario
723eb6597a simplify 2023-03-19 13:29:35 +00:00
Mario
3dcfdba74b simplify 2023-03-19 13:28:43 +00:00
Mario
5428053663 Merge branch 'dev' into 8.2RC 2023-03-19 09:43:34 +00:00
Mario
d0b41d0b07 more changelog 2023-03-19 09:41:17 +00:00
Mario
a82d861d2c update changelog 2023-03-19 09:25:56 +00:00
Mario
1e184b781b Merge branch 'dev' into 8.2RC 2023-03-19 08:22:29 +00:00
Mario
54b684fdb8 css fixes 2023-03-19 08:22:08 +00:00
Mario
c1ddb89990 Merge branch 'dev' into 8.2RC 2023-03-18 15:47:09 +00:00
Mario
2f5fa4df75 add the download attribute to prevent onbeforeunload 2023-03-18 15:46:30 +00:00
Mario
20735083b3 update bb_parse_b64_crypt() 2023-03-18 14:52:25 +00:00
Mario
7ac7cb129f Merge branch 'dev' into 8.2RC 2023-03-17 09:44:17 +00:00
Mario
f8b2f738bb remove redundant untranslated htconfig templates and add the db_skip_locked_supported config option 2023-03-17 09:30:17 +00:00
Mario
11b9e546a9 Merge branch 'dev' into 8.2RC 2023-03-14 10:43:03 +00:00
Mario
7e4721e4c7 work around friendica img attachment has different href than body which results in duplicate images 2023-03-14 10:35:01 +00:00
Mario
3a3fd38e3a Merge branch 'dev' into 8.2RC 2023-03-12 22:04:37 +00:00
Mario
63a8611579 fix issue #1728 2023-03-12 22:03:47 +00:00
Mario
38a1b79174 fix max_oembed_size check if content length header is an array (e.g. after a redirect with code 301) - fix issue #1727 2023-03-12 20:59:36 +00:00
Mario
0a679e503e make sure to only transform channel wall posts for group actors
(cherry picked from commit 95cbcf30d7)
2023-03-12 19:56:34 +01:00
Mario
e7c529f2c3 Merge branch 'dev' into 8.2RC 2023-03-12 18:44:28 +00:00
Mario
95cbcf30d7 make sure to only transform channel wall posts for group actors 2023-03-12 18:43:50 +00:00
Mario
dfc70021e3 fix version after merge 2023-03-12 09:38:31 +00:00
Mario
9daecca0ad make an format exception for repeated forum posts 2023-03-12 09:34:35 +00:00
Mario
c9d8a4dc1d bump dev version 2023-03-11 20:43:21 +00:00
Mario
5fada6a497 more strings and provide mfa feedback via jgrowl 2023-03-11 20:40:32 +00:00
Mario
ac9c33fb3b check form security token and require password to enable/diable mfa 2023-03-11 20:24:56 +00:00
Mario
641b1c2e1b fix php error 2023-03-11 19:38:37 +00:00
Mario
f031707563 strings and version 2023-03-11 19:37:34 +00:00
Mario
7f0518f693 merge es translations as per manuel 2023-03-11 19:28:17 +00:00
Mario
634d2f02b5 translateable strings 2023-03-11 19:25:27 +00:00
Mario
d7aee292d3 mark items as fetched in other places 2023-03-11 14:47:10 +00:00
Mario
1987517836 only set owner to observer if the item is not fetched otherwise the comment author could end up as owner 2023-03-09 18:31:43 +00:00
Mario
203d9d651f mfa strings update 2023-03-09 15:48:03 +00:00
Mario
8af5788fc1 more mfa cleanup, set the value in session if mfa is enabled and only allow enabling mfa after a test passed 2023-03-08 17:29:56 +00:00
Mario
3de81877c6 more mfa cleanup 2023-03-08 13:15:33 +00:00
Mario
2665b34962 whitespace 2023-03-08 10:21:05 +00:00
Mario
2ffef2be8f minor cleanup 2023-03-08 10:18:32 +00:00
Mario
c2e5610455 tests 2023-03-08 10:11:59 +00:00
Mario
234bb64250 port totp mfa from streams with some adjustions 2023-03-08 10:04:29 +00:00
Mario
d43a56614c position should be fixed 2023-03-04 21:33:50 +00:00
Mario
9f10e7e356 simplify pageloader animation 2023-03-04 17:03:37 +00:00
Mario
dc6075aa3f do not use zrl tag for non zot profiles and remove redundant foreach which was a leftover from zot to zot6 transition days 2023-03-03 19:33:39 +00:00
Mario
972d6917ac add fixme 2023-03-03 14:59:48 +00:00
Mario
ec3ba87f3a Revert "some work on bringing bang tags back for forums"
This reverts commit da034045cc.
2023-03-03 08:49:18 +00:00
Mario
da034045cc some work on bringing bang tags back for forums 2023-03-02 21:15:19 +00:00
Mario
65f001b4b7 provide a fake progress bar for pwa standalone mode 2023-03-02 16:45:10 +00:00
Mario
d81473487f minor cleanup and docu 2023-03-02 12:39:21 +00:00
Mario
06a8d5a4fa bump version 2023-03-02 11:48:52 +00:00
Mario
3653a86ad3 message filter entries are stored encoded - make sure to decode the word before we use it 2023-03-02 11:00:03 +00:00
Mario
c8d913fba7 wrong variable 2023-03-02 10:24:18 +00:00
Mario
b70acd0079 wrong variable 2023-03-02 10:20:43 +00:00
Mario
f167648115 improve mod hq to save some db lookups 2023-03-02 10:14:49 +00:00
Mario
b457c66bf9 do not include deleted hublocs when looking for author 2023-03-02 10:13:54 +00:00
Mario
ca0bd3ed32 fix some php warnings 2023-02-28 09:29:39 +00:00
Mario
7dacc7c268 Revert "fix second part of issue #1731"
This reverts commit 0db2e6b62c.
2023-02-27 20:38:42 +00:00
Mario
0db2e6b62c fix second part of issue #1731 2023-02-27 20:31:16 +00:00
Mario
e412bdbdbe bump version 2023-02-27 09:07:26 +00:00
Mario
f032bcc5f2 Default owner_xchan to $observer (sender) in Activity::store() - this is because in case where an announce holds a relayed activity we drop the announce and process the relayed activity only. In that case actor.id as set in Activity::decode_note() will not be the correct owner. In other cases actor.id and sender should be identical. 2023-02-27 08:42:13 +00:00
Mario
9ab9ac0e2e possible fix for issue #1731 2023-02-27 08:22:35 +00:00
Mario
fd3adf4d11 slightly improve contact search 2023-02-24 21:35:22 +00:00
Mario
c42911bd8d css fixes 2023-02-23 16:19:02 +00:00
Mario
828087ee8c fix syntax for get_compund_property() 2023-02-23 14:54:04 +00:00
Mario
efcda1d37d port some functions from streams 2023-02-23 09:51:37 +00:00
Mario
656400b418 look for owner instead of author - this way we will also catch the via posts 2023-02-22 17:07:53 +00:00
Mario
ca7bd49964 Activity: do not force new thread if the announce is from a group actor 2023-02-22 11:20:32 +00:00
Mario
3527137264 Activity: set xchan_pubforum if we deal with a group actor 2023-02-22 10:47:11 +00:00
Mario
e045a36559 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-02-17 10:18:30 +00:00
Mario
ee8fc701a6 do not try to oembed in notes 2023-02-17 10:18:01 +00:00
Mario Vavti
777fdeb462 realy make sure we will deduplicate even if there is a bogus second primary entry 2023-02-16 16:56:57 +01:00
Mario Vavti
1078b774ae make sure we will deduplicate even if there is a bogus second primary entry 2023-02-16 16:52:29 +01:00
Mario
62a363debc queue fixes 2023-02-16 14:17:05 +00:00
Mario Vavti
7839b931f1 make sure we provide a created timestamp for likes and remove the workaround which returned the wrong date format 2023-02-16 13:12:22 +01:00
Mario
cbf8c4bdb2 more queue updates from streams and remove a hz_syslog 2023-02-16 11:16:44 +00:00
Mario
321cd9f2e0 more restructure for better responsive behaviour 2023-02-15 18:06:16 +00:00
Mario
09a60774d7 we can sign messages which are not from the primary location 2023-02-15 13:33:23 +00:00
Mario
1ca988b177 revisit author_id and fix issue with pinned content 2023-02-15 09:41:48 +00:00
Mario
07fd8cf6cd restructure wall-item-head 2023-02-15 08:51:23 +00:00
Mario
e7fb56447a bump version 2023-02-14 07:35:41 +00:00
Mario
de3e83f0a2 fix mod cal after fullcalendar update 2023-02-14 07:33:05 +00:00
Mario
6c78f7b769 css fixes 2023-02-12 15:05:06 +00:00
Mario
2c459fefce remove deprecated functions 2023-02-12 14:13:59 +00:00
Mario
a1eb39872b implement hq widget author image and notifications updates 2023-02-12 10:43:31 +00:00
Mario
724b8cc6a5 port queue improvements from streams 2023-02-12 10:41:23 +00:00
Mario Vavti
2bfd18e6cd css fixes 2023-02-10 21:08:49 +01:00
Mario
20658f3b4a do not blur 2023-02-09 12:46:23 +00:00
Mario
c945698eb4 work around wierd textcomplete behaviour 2023-02-09 12:37:08 +00:00
Mario
5f89bd75a4 bump version 2023-02-09 01:53:46 +00:00
Mario
09c9b47265 fix more hubloc confusion, implement hq widget author filter and some autocomplete fixes 2023-02-09 01:52:48 +00:00
Mario
ea2b653b9b queueworker: do not wait for locked rows, use skip locked if configured via system.db_skip_locked_supported 2023-02-08 11:03:29 +00:00
Mario
9c3660e2f6 remove superfluous semicolon 2023-02-01 10:02:35 +00:00
Mario
4bcacf858b do not deduplicate notifications because the dupes could be valid and var -> let 2023-01-29 10:06:58 +00:00
Mario
7faa3359f0 fix undefined varable warning 2023-01-28 20:19:51 +00:00
Mario
71f1814477 remove redundant argument 2023-01-28 20:04:18 +00:00
Mario
a3913c5ca4 fix ics import 2023-01-28 16:57:32 +00:00
Mario
ae1cc65b23 do not use transparency for navbar togglers in dark mode 2023-01-28 15:00:11 +00:00
Mario
9a16bf65bd update simplepie 2023-01-27 07:28:21 +00:00
Mario
c3d3dc9d92 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-01-27 07:26:35 +00:00
Mario
e54eb21b71 update smarty 2023-01-27 07:24:50 +00:00
Harald Eilertsen
0140f9fe56 translations: Misc updates for nb_NO.
(cherry picked from commit ec6832687b)
2023-01-27 08:00:26 +01:00
Harald Eilertsen
03243df16a translations: Fix timeago for nb_NO.
(cherry picked from commit 9065a90ac0)
2023-01-27 08:00:07 +01:00
Mario
28dc8443a8 Merge branch 'translations/update-nb-no' into 'dev'
Translations/update nb no

See merge request hubzilla/core!2034
2023-01-27 06:58:45 +00:00
Harald Eilertsen
ec6832687b translations: Misc updates for nb_NO. 2023-01-26 20:07:59 +01:00
Harald Eilertsen
9065a90ac0 translations: Fix timeago for nb_NO. 2023-01-26 20:07:02 +01:00
Mario
94b26e1e66 redbasic: fix regression 2023-01-26 18:35:49 +00:00
Mario
a2fc2e776a bump version 2023-01-26 18:29:21 +00:00
Mario
79b40179b4 redbasic: implement setting for always light navbar icons and some minor fixes 2023-01-26 18:28:40 +00:00
Mario
60c968222f bump version 2023-01-26 10:26:55 +00:00
Mario
e99dc2193f remove unsused variables 2023-01-26 10:23:33 +00:00
Mario
cf1838f76e minor cleanup and prevent duplicate recipients in some places 2023-01-26 10:10:06 +00:00
Mario
0db5016666 remove redundant code 2023-01-26 09:15:46 +00:00
Mario
c4b37ba462 theme fixes 2023-01-26 07:22:21 +00:00
Mario
c3b908dcfc : fixes 2023-01-25 16:35:18 +00:00
Mario
23f93044c1 update forkawesome lib 2023-01-25 15:22:15 +00:00
Mario
32dcc28414 calendar: fixes 2023-01-25 14:05:20 +00:00
Mario
ddae3eaf84 calendar: remove deprecated options 2023-01-25 13:39:50 +00:00
Mario
a9ae17036d update fullcalendar 2023-01-25 13:09:00 +00:00
Mario
08e925758e update fullcalendar library 2023-01-25 13:08:05 +00:00
Mario
213c8a6eec according to spec this should be id instead of href 2023-01-25 13:06:50 +00:00
Mario
ca4ad836a3 revert theme color 2023-01-25 11:00:01 +00:00
Mario
56361fa2fc theme fixes 2023-01-25 10:59:17 +00:00
Mario
fedce4cd74 cleanup 2023-01-24 09:36:27 +00:00
Mario
cac48fc4bf use light colored navbar for light mode - this makes the focus light schema redundant 2023-01-24 09:29:00 +00:00
Mario
1cad844d2d theme fixes 2023-01-22 15:35:55 +00:00
Mario
2d5e09f930 theme fixes 2023-01-20 20:07:37 +00:00
Mario
fbda34935d remove dark schema quirks 2023-01-20 11:19:39 +00:00
Mario
c5ca7f236f bump version 2023-01-20 11:06:05 +00:00
Mario
9dc949b62c native dark theme initial checkin 2023-01-20 11:05:15 +00:00
Mario
40394b94d7 typo :\ 2023-01-17 10:33:31 +00:00
Mario
bae446973f reflect pubstream disable/enable logic change in can_view_public_stream() 2023-01-17 10:29:12 +00:00
Mario
2805520d1b Merge remote-tracking branch 'origin/8.0RC' 2023-01-13 20:01:05 +00:00
Mario
fb7ca18820 version 8.0 2023-01-13 19:56:11 +00:00
Mario
1b00d5657f Merge branch 'dev' into 8.0RC 2023-01-13 19:55:44 +00:00
Mario
cd9f35e78a update changelog 2023-01-13 19:55:18 +00:00
Mario
f9cedab964 update changelog 2023-01-13 09:42:57 +00:00
Mario
9ec516e5a4 Merge branch 'dev' into 8.0RC 2023-01-12 16:12:26 +00:00
Mario
550b6d90a4 missing semicolon 2023-01-12 16:11:42 +00:00
Mario
5cb92b6e21 Merge branch 'dev' into 8.0RC 2023-01-12 11:55:13 +00:00
Mario
8a7b221412 mark old hubloc entries from re-installed hubs deleted if we discover any 2023-01-12 11:28:48 +00:00
Mario
d092e79ebc remove fragment in notifier - it should not be required, when processing multiple choice polls sleep some time before calling the notifier 2023-01-12 11:04:03 +00:00
Mario
2ddb88a34d RC2 2023-01-11 19:57:35 +00:00
Mario
71761c9039 Merge branch 'dev' into 8.0RC 2023-01-11 16:35:21 +00:00
Mario
16555b93bb fix race conditions when processing multiple choice polls 2023-01-11 16:34:23 +00:00
Mario
bd5e834b42 Merge branch 'dev' into 8.0RC 2023-01-08 08:20:05 +00:00
Mario
2eb4f093be update theme requirements 2023-01-08 08:19:37 +00:00
Max Kostikov
d4bf587103 Merge branch 'dev' into 'dev'
Fix Russian translation escaping

See merge request hubzilla/core!2033
2023-01-07 14:06:54 +00:00
Max Kostikov
ae7bd8b644 Fix translation escaping 2023-01-07 14:05:52 +00:00
Max Kostikov
f89cede020 Merge branch 'dev' into 'dev'
Update Russian translations

See merge request hubzilla/core!2032
2023-01-07 13:58:39 +00:00
Max Kostikov
59facf6f00 Update hstrings.php 2023-01-06 11:29:49 +00:00
Max Kostikov
01d93733ae Update hmessages.po 2023-01-06 11:24:03 +00:00
Mario
4c434129a6 Merge branch 'dev' into 8.0RC 2023-01-05 18:25:45 +01:00
Mario
b40499b4c1 revert accidental change in session 2023-01-05 18:25:08 +01:00
Mario
66333aedb7 fix version 2023-01-05 18:23:00 +01:00
Mario
47071c58aa fix affinity slider updates - issue #1714 2023-01-05 18:21:49 +01:00
Mario
79d99688b4 bump version 2023-01-05 11:39:09 +01:00
Mario
edcb0631aa composer dump autoload 2023-01-05 11:35:15 +01:00
Mario
bc361e6469 strings and version 2023-01-05 11:33:50 +01:00
Mario
c95ef1a5c0 pdledit_gui: only show installed modules and widgets 2023-01-05 11:06:19 +01:00
Mario
0c0891f64f bump version 2023-01-05 10:37:40 +01:00
Mario
23828f53bc pubstream: when going to conv from unthreaded mode stay in the module 2023-01-05 10:29:42 +01:00
Mario
f909e129ab Merge branch 'nb-no/update-translations' into 'dev'
Update translations for nb-no (Norsk Bokmål)

See merge request hubzilla/core!2031
2023-01-04 20:34:57 +00:00
Mario
7d4bcc2e8b translateable strings 2023-01-04 20:20:14 +00:00
Mario
2eb4d87621 fix issue #1717 2023-01-04 20:14:11 +00:00
Mario
435888c1a3 bump version 2023-01-04 19:39:11 +00:00
Mario
e69fabcd71 pdledi_gui: sort widgets 2023-01-04 19:33:18 +00:00
Mario
1a283301cf Revert "pdledit_gui: minor cleanup"
This reverts commit 031df70cf8.
2023-01-04 19:29:42 +00:00
Mario
031df70cf8 pdledit_gui: minor cleanup 2023-01-04 19:29:11 +00:00
Mario
3ad36db7dd pdledit_gui: minor cleanup 2023-01-04 19:27:44 +00:00
Mario
e16ea1ae05 pdl editor for addon iitial commit 2023-01-04 14:25:46 +00:00
Mario
941135a0a6 we should look for owner_xchan just like in mod pubstream 2023-01-04 09:01:44 +00:00
Mario
29776ecea2 queueworker: implement auto_queue_worker_sleep setting in frontend 2023-01-03 13:50:22 +00:00
Mario
d2edef5c5a go away if method is not implemented 2023-01-03 13:30:53 +00:00
Mario
da9349ea62 provide inline error messages for mod cloud 2023-01-03 10:59:38 +00:00
Mario
de0d2afc15 fix issues with pubstream tagcloud 2023-01-02 21:56:20 +00:00
Mario Vavti
d8c94c2003 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2023-01-02 20:39:15 +01:00
Mario Vavti
0e71bfe222 add sys channel to receiveres for public items 2023-01-02 20:38:56 +01:00
Mario
0ae402e624 bump version 2023-01-02 18:38:44 +00:00
Mario
b96dc11ddd improve sse loop 2023-01-02 18:37:36 +00:00
Mario Vavti
37b539eaa5 fix wrong variable - issue #1720 2023-01-01 21:25:15 +01:00
Mario Vavti
0741708086 change the logic of building the site only public stream. we will now fetch sys channel items but restrict them to authors of this site only. this fixes a comment permission issue. 2023-01-01 21:21:13 +01:00
Mario
a30cfd8fec filter approvals 2022-12-27 16:08:08 +00:00
Mario
633cd11c5b move mod queueworker to /admin 2022-12-27 10:44:54 +00:00
Mario
3101c6540a add workerq to the install schemas 2022-12-27 10:33:29 +00:00
Mario
d2d6be73b8 fix subquery in hq widget and order by hubloc_id desc in handle_tag() to make sure we get the most recent entry when using privacy tags 2022-12-26 09:08:54 +00:00
Mario
a46e2c1e6d only display details if there are any 2022-12-22 13:35:46 +00:00
Mario
2b0404fefc queueworker: add some more details 2022-12-22 13:29:34 +00:00
Mario
7ef9462286 bring back item-highlight 2022-12-22 12:22:32 +00:00
Mario Vavti
c6e7a7eaee comment out unused code 2022-12-22 12:42:44 +01:00
Mario
999e142370 minor cleanup 2022-12-22 10:09:35 +00:00
Mario
a7ad117a83 there is no point in wrapping single queries into a transaction 2022-12-22 10:02:31 +00:00
Mario
1ba44fc117 update 2022-12-21 17:15:34 +00:00
Mario
ca5610ebf1 bump version 2022-12-21 17:13:09 +00:00
Mario
e5c70a1304 queueworker: adjust process query to be complient with mariadb < 10.6 and add process timeout exceptions for long running processes 2022-12-21 17:11:33 +00:00
Mario
7dd2308534 pooll fixes 2022-12-20 20:16:06 +00:00
Mario Vavti
62eee07b6e make sure to include only zot6 hublocs in this query. including other networks could lead to unexpected results 2022-12-20 14:06:14 +01:00
Mario
f6d9406063 streamline ap followers only privacy warning with current handling. also fixes possible php error.
(cherry picked from commit 34125177e8)
2022-12-19 10:05:02 +01:00
Mario
34125177e8 streamline ap followers only privacy warning with current handling. also fixes possible php error. 2022-12-19 09:04:24 +00:00
Mario
d977b5d662 bump version 2022-12-18 10:24:44 +00:00
Mario
e36677b757 queueworker: cleanup and implement auto sleep interval (hidden config for now) 2022-12-18 10:19:06 +00:00
Mario
4d54755057 queueworker: fix maxworkers check and cleanup 2022-12-15 16:53:17 +00:00
Mario
91917c98e4 bump version 2022-12-15 09:19:56 +00:00
Mario
2f687de477 queueworker testing and more logging to syslog 2022-12-15 09:18:58 +00:00
Mario Vavti
5446062b95 bump version 2022-12-12 23:28:26 +01:00
Mario Vavti
c9e170dfcc queueworker: introduce new interval config queueworker.queue_interval - defaults to 500000 microseconds. No config UI yet. 2022-12-12 23:26:45 +01:00
Mario
e3a19469eb bring back poll and delivery interval 2022-12-12 09:03:49 +00:00
Mario
45f8e43be4 debug from php log 2022-12-11 20:46:02 +00:00
Mario
7ef0b05ce6 fix typo 2022-12-11 20:24:22 +00:00
Mario
c5a0ec4e93 css fixes 2022-12-11 19:19:47 +00:00
Mario
1c17768dc5 minor fixes 2022-12-11 10:40:02 +00:00
Mario
86e1dd4673 remove debug logging 2022-12-10 17:06:54 +00:00
Mario
0ee41c3341 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-12-10 17:04:18 +00:00
Mario
e1c2835173 add option to set worker sleep based on load average, remove redundand code and add return to some daemons 2022-12-10 17:03:57 +00:00
Max Kostikov
5c6d3753ef Fix Redis session PHP warnings 2022-12-09 15:53:01 +00:00
Mario
6e881bcef2 exclude not tagable xchan networks handle_tag()
(cherry picked from commit 4f9a933108)
2022-12-08 21:41:56 +01:00
Mario
4f9a933108 exclude not tagable xchan networks handle_tag() 2022-12-08 20:40:37 +00:00
Mario
9f8585914c sse_bs: respect the site firehose setting 2022-12-07 14:07:31 +00:00
Mario
3ba27b9752 add mark to html2bbcode parser 2022-12-07 11:01:28 +00:00
Mario
abae5de4d8 when uploading a image file, embed it in the item. otherwise attach it 2022-12-07 10:50:26 +00:00
Mario
6952c5a3f5 $visitor is a string 2022-12-06 11:15:53 +00:00
Mario
0184d2c292 typo 2022-12-04 10:43:57 +00:00
Mario
7a40561aaa wording 2022-12-04 10:36:30 +00:00
Mario
79e6c9590a the logic for public stream has changed - adjust help text and externals, disable lockfile check in cron daemon 2022-12-04 10:27:02 +00:00
Mario
12a963cc40 version 7.8.7 2022-12-03 09:01:18 +00:00
Mario
f89975fd0e changelog 7.8.7
(cherry picked from commit b4dffe5946)
2022-12-03 09:59:06 +01:00
Mario
b4dffe5946 changelog 7.8.7 2022-12-03 08:57:56 +00:00
Mario
539b69d507 look for iconfig at the right place, fix mod sharedwithme, comment out unused configs 2022-12-03 08:53:53 +00:00
Harald Eilertsen
9927363f39 Update translations for nb-no (Norsk Bokmål) 2022-12-03 00:30:16 +01:00
Mario
1a4f59cd70 bump version 2022-12-02 19:32:47 +00:00
Mario
25727a24a5 fix typos 2022-12-02 19:29:46 +00:00
Mario
2fd2dc964b Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-12-02 19:28:52 +00:00
Mario
935b032f15 db update 1254 2022-12-02 19:22:50 +00:00
Mario
2bb58843ab move queueworker to core and bump version 2022-12-02 19:22:19 +00:00
Mario
00512579f3 fix regression when adding feed contacts
(cherry picked from commit 5216c5b232)
2022-12-02 18:47:40 +01:00
Mario
6f09796142 Merge branch 'fix-category-widget-urls' into 'dev'
Fix Category widget URLs

See merge request hubzilla/core!2030
2022-12-02 17:46:42 +00:00
Mario
697a74f37e fix regression: new event not created
(cherry picked from commit d16b6c3838)
2022-12-02 18:06:20 +01:00
Mario
d16b6c3838 fix regression: new event not created 2022-12-02 15:18:01 +00:00
Mario
e4461f2e61 adjust the query to work with postgres 2022-11-30 11:20:10 +00:00
Mario
baf1b8b02d fetch the unseen count in a subquery instead of a separate query and rename array key 2022-11-30 10:36:55 +00:00
Mario
3ce1373ae0 provide a pdl file for mod invite and set the profile 2022-11-30 09:18:57 +00:00
Mario
4002531b92 fix issue where site_firehose setting was always false 2022-11-29 10:00:07 +00:00
Mario
004d0f074d disable context help until its content will be updated - it is not helpful otherwise 2022-11-27 12:20:04 +00:00
Mario
e87887c328 re-install: make sure to fetch the latest hubloc in api_auth otherwise authentication might fail 2022-11-27 09:40:23 +00:00
Harald Eilertsen
2de2c8e207 Fix Category widget URLs
The category widget template expects a URL without any query params, as
it appends `/?cat=<selected category>` to the base URL passed to it.

The Widget code tried to preserve any query param passed to it except
for the `cat` query param. When passed to the template, this caused the
invalid URLs to be generated.

Example input url:

    https://example.com/channel/user?f=&tag=pasta

The URL generated for the "Dinner" category would then be:

    https://example.com/channel/user&tag=pasta&tag=pasta/?cat=Dinner

Which is troublesome in more than one way, and cause at least some
search bots to go wild by sending requests with increasingly long URLs.

This patch will simply discard the existing query params in the URL, so
with the same input url, the generated URL for the "Dinner" category
will now be:

    https://example.com/channel/user/?cat=Dinner

This is comparable to what the Category Cloud and Tag Cloud widgets
already do.
2022-11-26 15:45:37 +01:00
Mario
c76f19f19a bump version 2022-11-26 08:39:59 +00:00
Mario
a050e8c8f5 should compare against abook_updated to make sure we do not always poll broken feeds 2022-11-26 08:37:45 +00:00
Mario
ae1fad5de7 basically every incoming item should have a uuid by now 2022-11-25 18:44:33 +00:00
Mario
68ca8951a8 mark unseen items seen after a certain amount of time (default 90 days) 2022-11-25 18:37:22 +00:00
Mario Vavti
1e4718eae1 do not always trigger a sse event if pubs notification are off or the app is not installed for the channel 2022-11-24 16:42:09 +01:00
Mario Vavti
680cf25f37 de-duplicate by mid. there is no combined index for uid and uuid hence the query could be slow if an uid has a lot of items. the workaround for hubzilla < 4.0 is not required anymore 2022-11-24 16:08:57 +01:00
Mario Vavti
7ec6df495f slight restructure 2022-11-24 16:05:19 +01:00
Mario
aeda31fda7 fix warnings 2022-11-24 09:52:50 +00:00
Mario
5248aa3065 css fix 2022-11-24 09:42:35 +00:00
Mario
67767c5853 Merge branch 'redbasic/dark-theme-fixes' into 'dev'
redbasic: Dark scheme fixes

See merge request hubzilla/core!2029
2022-11-23 18:43:42 +00:00
Mario
6de1aec683 the blue dots were slightly too bold. 2022-11-22 21:10:11 +00:00
Harald Eilertsen
221d3cdf6a redbasic: Dark theme fixes
- Make rows in admin tables readable while hovering over them.
2022-11-22 15:31:54 +01:00
Harald Eilertsen
1ff12c5520 redbasic: Dark scheme fixes
- Changed background of category tags to make them readable.
- Changed background on "view source" dialog to make it readable.
2022-11-22 09:46:41 +01:00
Mario
41376ec2cd fix issue in tag_deliver() and silence some more warnings 2022-11-20 20:31:59 +00:00
Mario
bf335ecaf3 hq widget: use distinct classes for seen and unseen thread items count 2022-11-18 13:32:14 +00:00
Mario
424bc73f58 bump version 2022-11-18 10:45:42 +00:00
Mario
59e6989cbc hq widget: implement thread unseen items count 2022-11-18 10:43:33 +00:00
Mario
0e6b27c9f4 if a feed fails, do not update connected timestamp. attempt to poll feeds only once a day if we could not fetch it last time we tried 2022-11-17 11:50:13 +00:00
Mario
0e157e4e8b remove logging 2022-11-17 09:11:34 +00:00
Mario
805074a0f9 externals: fix warnings 2022-11-17 09:09:02 +00:00
Mario
5216c5b232 fix regression when adding feed contacts 2022-11-17 08:57:09 +00:00
Mario
8633162f0c bump versionà 2022-11-15 21:22:39 +00:00
Mario
c392a77b46 performance: just count the first 99 unseen items and display 99+ if there are more than 99 2022-11-15 21:22:10 +00:00
Mario
08c2c9bc22 possible fix for issue #1698 2022-11-15 19:29:29 +00:00
Mario
f64bd590a8 bump version 2022-11-14 05:51:32 +00:00
Mario
131ffcf582 changelog 7.8.6 2022-11-14 05:49:33 +00:00
Mario
b17a0aef17 fix typo and version 7.8.6 2022-11-14 05:47:16 +00:00
Mario
8a21783fa5 bump version 2022-11-13 19:45:36 +00:00
Mario
53152e2ef5 version 7.8.5 2022-11-13 19:44:08 +00:00
Mario
ca6ba92d82 Merge branch 'dev' 2022-11-13 19:43:12 +00:00
Mario
04516b787a update changelog 2022-11-13 19:42:07 +00:00
Mario
6e124a4d72 changelog 2022-11-13 19:40:03 +00:00
Mario
6da65c7ddc cast the type to update if it is an edit 2022-11-13 17:13:33 +00:00
Mario
9eb332f032 allow to look for pubstream items if we do not own one but make sure the permissons are checked correctly 2022-11-10 17:57:26 +00:00
Mario
30ddee65a4 fix wrong array key and undefined array key 2022-11-10 10:48:24 +00:00
Mario
63dc8d7fc4 fix undefined variable 2022-11-10 10:37:41 +00:00
Mario
a1a287bac7 fix typo in variable name 2022-11-10 10:34:05 +00:00
Mario
e9b786d5e8 Ãwrong array key 2022-11-09 13:05:48 +00:00
Mario
ad9fb411f6 address issue #1705 2022-11-09 11:52:55 +00:00
Mario
1ff982983e items_fetch(): check if set and if there is a value 2022-11-09 11:34:03 +00:00
Mario
8c6c43d762 items_fetch(): check if set and if there is a value 2022-11-09 11:33:10 +00:00
Mario
6baf197842 version 7.8.4 2022-11-09 09:38:09 +00:00
Mario
42e5a50e4f changelog and version 2022-11-09 09:33:18 +00:00
Mario
b713c9a491 fix new uuid created when editing post 2022-11-09 09:27:33 +00:00
Mario
64ade742d9 whitespace 2022-11-07 19:55:30 +00:00
Mario
1870c3c876 whitespace 2022-11-07 19:55:13 +00:00
Mario
23b272aafd merge conflict 2022-11-07 19:53:03 +00:00
Mario
057db41758 bump version 2022-11-07 19:50:55 +00:00
Mario
839c5a8e41 fix regression where automatically created directories were not public and pinned/featured state of apps was not displayed correctly 2022-11-07 19:41:22 +00:00
Mario
36b8b6bf6c Merge branch 'dev' 2022-11-06 08:27:18 +00:00
Mario
40d74fa779 fix case and german translation string 2022-11-06 08:27:00 +00:00
Mario
249bdeb642 Merge branch 'dev' 2022-11-05 10:26:14 +00:00
Mario
b4ee80d1ea changelog 2022-11-05 10:25:40 +00:00
Mario
96bf9d0769 version 7.8.2 2022-11-05 09:52:11 +00:00
Mario
7fc9c83986 Merge branch 'dev' 2022-11-05 09:50:55 +00:00
Mario
5502f1cc63 do not update the guid on xchan/hubloc updates and define some array keys 2022-11-04 10:31:05 +00:00
Mario
b55801323c fix warnings 2022-11-03 15:26:46 +00:00
Mario
818374c8cc wor around shares from streams not rendered correctly 2022-11-03 13:54:40 +00:00
Mario
e80191d4cd fix regression 2022-11-03 13:09:11 +00:00
Mario
c2a796b6ea rename variable and warning fixes 2022-11-03 11:57:35 +00:00
Mario
00694f0dfd css fixes 2022-11-02 19:19:24 +00:00
Mario
134f4c5b52 undefined array key 2022-11-02 18:59:47 +00:00
Mario
0840fc42f9 php warning 2022-11-02 18:49:36 +00:00
Mario
2650a647e9 php warnings 2022-11-02 18:32:52 +00:00
Mario Vavti
3311269162 throw a 404 if we could not determine which channel to load 2022-11-02 17:52:19 +01:00
Mario
b2172d39f6 re-install: if we have a cashed entry, make sure we fetch the latest 2022-11-02 15:54:12 +00:00
Mario Vavti
f4d39bd3c8 fix more php warnings 2022-11-02 16:52:42 +01:00
Mario Vavti
1cf659033b set hubloc_connected in mod fhublocs otherwise the hublocs might be removed by prune_hub_reinstalls() 2022-11-02 10:38:40 +01:00
Mario
3dc5527690 css variables 2022-10-31 14:01:00 +00:00
Mario
81b02d04b5 version 7.8.1 2022-10-26 21:57:53 +00:00
Mario
95f6f9e10a Merge branch 'dev' 2022-10-26 21:56:32 +00:00
Mario
9554f53519 update version and changelog 2022-10-26 21:54:29 +00:00
Mario
5d7081a224 fix php warnings 2022-10-26 21:40:27 +00:00
Mario
9cbdf3f31f wrong argument in documentation 2022-10-26 19:27:15 +00:00
Mario
c8bc1b560b missing field in query 2022-10-26 19:11:13 +00:00
Mario
40ae6b396f fix php warnings 2022-10-26 18:12:56 +00:00
Mario
9c117ffa05 fix php warnings 2022-10-26 15:56:41 +00:00
Mario Vavti
9e95f189ed fix php warnings 2022-10-26 17:56:04 +02:00
Mario Vavti
221b31bcc6 fix php warnings 2022-10-25 19:06:17 +02:00
Mario Vavti
8879776d64 fix php warnings 2022-10-23 14:02:19 +02:00
Mario
5edd13c6bb fix various issues 2022-10-21 11:20:23 +02:00
Mario
7ca289edd0 fix php warnings 2022-10-20 19:25:01 +00:00
Mario
bf434818d7 fix php warnings 2022-10-20 13:16:03 +00:00
Mario
03aeb88832 fix php warnings 2022-10-20 10:25:11 +00:00
Mario Vavti
bb5b33a0d3 fix more php warnings 2022-10-20 11:40:31 +02:00
Mario Vavti
53931017b9 fix php warnings 2022-10-20 11:15:06 +02:00
Mario Vavti
e9ca17cec1 fix php warnings 2022-10-18 12:39:13 +02:00
Mario
f70956964b fix php warning 2022-10-14 15:23:23 +00:00
Mario Vavti
4547a9d9d3 catch decryption failure edgecase 2022-10-14 17:13:23 +02:00
Mario Vavti
71accb6b0a fix php warnings 2022-10-13 16:38:18 +02:00
Mario Vavti
2a95500b65 fix more php warnings 2022-10-13 13:15:08 +02:00
Mario Vavti
2ddad66ce7 mod dirsearch: fix php warnings 2022-10-13 12:48:22 +02:00
Mario
108be24aed remove logging 2022-10-12 19:39:15 +00:00
Mario
71efb05658 fix php warnings 2022-10-12 19:36:24 +00:00
Mario
a9a36894cb fix php warnings 2022-10-12 12:15:30 +00:00
Mario
bc9778e02f poco: remove unused parameters 2022-10-12 10:02:18 +00:00
Mario
a83d2efe84 remove dead code and deal with conv privacy mismatches in Activity::store() 2022-10-12 09:47:47 +00:00
Mario
d3856caf81 composer update michelf/php-markdown 2022-10-12 09:09:55 +00:00
Mario
e1f9b1c47d composer update jbroadway/urlify 2022-10-12 09:01:22 +00:00
Mario
497c953d0e composer update bshaffer/oauth2-server-php 2022-10-12 08:54:51 +00:00
Mario
bec76bd057 composer update ezyang/htmlpurifier 2022-10-12 08:53:14 +00:00
Mario
54f4762e1a composer update symfony 2022-10-12 08:48:27 +00:00
Mario
8bf5c18425 composer update ramsey/uuid 2022-10-12 08:45:01 +00:00
Mario
c36bb17475 composer update sabre 2022-10-12 08:42:41 +00:00
Mario
2291fcdf11 composer update simplepie 2022-10-12 08:28:35 +00:00
Mario
4070c46d15 composer update smarty 2022-10-11 19:20:46 +00:00
Mario
a749db8d0f composer update twbs 2022-10-11 18:45:17 +00:00
Mario
10ba98c4f5 Revert "update composer libs"
This reverts commit 108a3efe0b.
2022-10-11 18:41:34 +00:00
Mario
108a3efe0b update composer libs 2022-10-11 18:34:03 +00:00
Mario
ccd826f63a Revert "update composer libs"
This reverts commit 5e5f0aa955.
2022-10-11 18:29:06 +00:00
Mario
5e5f0aa955 update composer libs 2022-10-11 18:18:57 +00:00
Mario
f9a4c53e3f jQuery.timeago.settings.strings should not be in document.ready 2022-10-11 10:03:05 +00:00
Mario
60b576568e more css fixes 2022-10-11 09:45:12 +00:00
Mario
d0e1b73205 css fixes 2022-10-11 09:18:40 +00:00
Mario
ef2448e17e Merge branch '7.8RC' 2022-10-10 18:05:26 +00:00
Mario
99a5cf1ad4 version 7.8 2022-10-10 18:03:48 +00:00
Mario
bc3113ae16 Merge branch 'dev' into 7.8RC 2022-10-10 16:50:04 +00:00
Mario
fb475da008 update changelog 2022-10-10 16:37:24 +00:00
Mario
d5fc3ad646 Merge branch 'dev' into 7.8RC 2022-10-10 16:29:50 +00:00
Mario
8b7da6e318 spanish translations as per Manuel 2022-10-10 15:06:48 +00:00
Mario
ed208c4bcc update changelog 2022-10-10 15:02:37 +00:00
Mario
6ab65519a0 when updating hubloc_connected also update hubloc_updated
(cherry picked from commit 4549bc89ec)
2022-10-05 10:49:19 +02:00
Mario
4549bc89ec when updating hubloc_connected also update hubloc_updated 2022-10-05 08:41:31 +00:00
Mario
a0430f91bd fix owa in case of hub reinstalls 2022-09-30 10:25:46 +00:00
Mario
624bb1db8d Merge branch 'dev' into 7.8RC 2022-09-30 07:56:24 +00:00
Mario
9f522bbe6c update strings 2022-09-30 07:54:46 +00:00
Mario
931da3b4f7 Merge branch 'dev' into 7.8RC 2022-09-30 07:38:47 +00:00
Mario
5a25fd54a4 fix issue #1694 2022-09-30 07:14:47 +00:00
Mario
9f0f4c50a4 update htconfig.tpl 2022-09-30 06:43:53 +00:00
Mario
0bf3d31578 make it an info 2022-09-29 15:36:02 +00:00
Mario Vavti
8ca293c3e4 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-09-29 16:59:07 +02:00
Mario Vavti
ba0c877ffc fix menu item display issue 2022-09-29 16:56:54 +02:00
Mario
b8e00c2dc9 remove custom navbar override from repo 2022-09-29 14:19:14 +00:00
Mario
2dd48898a8 Merge branch 'dev' into 'dev'
GERMAN TRANSLATION - fix for minutes, hours, years,... by polls in .po file and translation more competed  pdpr1 and SiteTOS added

See merge request hubzilla/core!2027
2022-09-29 14:16:22 +00:00
Rock
66fc807655 GERMAN TRANSLATION - fix for minutes, hours, years,... by polls in .po file and translation more competed pdpr1 and SiteTOS added 2022-09-29 14:16:22 +00:00
Mario
653eb2909b Merge branch 'dev' into 7.8RC 2022-09-29 09:03:29 +00:00
Mario
72520a2dd9 fix hq widget displaying superblocked items 2022-09-29 08:58:36 +00:00
Mario
a7d4666a70 Merge branch 'dev' into 7.8RC 2022-09-28 15:21:34 +00:00
Mario
13476d5003 remove unnecessary check 2022-09-28 15:21:11 +00:00
Mario
879cdedec3 Merge branch 'dev' into 7.8RC 2022-09-28 10:35:36 +00:00
Mario
05bd2a1f9e one more hub reinstall fix 2022-09-28 10:35:09 +00:00
Mario
c49d1547c4 Merge branch 'dev' into 7.8RC 2022-09-28 10:27:58 +00:00
Mario
ad35363c2e hub reinstall issues 2022-09-28 10:27:35 +00:00
Mario
b3f70140e5 Merge branch 'dev' into 7.8RC 2022-09-27 08:59:44 +00:00
Mario
2f21dc50b4 fix mod poke 2022-09-27 08:59:08 +00:00
Mario
cbd8c2483b fix versionà 2022-09-26 08:33:47 +00:00
Mario
03475bfb15 Ãfix regression 2022-09-26 08:31:57 +00:00
Mario
bb9411e7dc update dev version 2022-09-26 07:16:11 +00:00
Mario
bce4e2d022 update version and strings 2022-09-26 07:13:01 +00:00
Mario
7cfc14fef7 emit a notice if an item was deleted - issue #1691 2022-09-22 12:50:11 +00:00
Mario
f220cf3173 fix issue #1687 2022-09-22 12:02:21 +00:00
Mario
725359b1aa fix issue #1690 2022-09-22 10:55:58 +00:00
Mario
937d6cb1ef php8: fix warnings 2022-09-22 06:31:35 +00:00
Mario
118a5edebc fix warnings and regressions 2022-09-15 09:19:55 +00:00
Mario
1b4333e8d9 chek permissions in get_things() - partly fixes issue #1686 a lot more work is requird though 2022-09-14 18:35:36 +00:00
Mario
d66a0b50e9 address issue #1688 2022-09-14 17:43:12 +00:00
Mario
1d56b9a1bb php8: warning fixes 2022-09-14 12:31:19 +00:00
Mario
96535ee4df make actor_store() fetch the actor object if none is provided, remove announce from the is_response array and provide a function to find the attributedTo url 2022-09-13 11:20:35 +00:00
Mario
b55f314d7e php8: fix warnings 2022-09-11 18:26:27 +00:00
Mario
480862d714 php8: fix more warnings 2022-09-11 14:58:40 +00:00
Mario
990a3af2a7 php8: random cleanup and warning fixes 2022-09-08 20:02:22 +00:00
Mario
1f5a23143a remove debug code 2022-09-07 18:07:38 +00:00
Mario
fcfb9e9758 fix random php warnings 2022-09-07 12:50:46 +00:00
Mario
9beee689ce fix display of star and dreport links 2022-09-06 11:32:27 +00:00
Mario
2c388c3833 add missing modal 2022-09-06 10:52:59 +00:00
Mario
1a75066616 revert: do not wrap multi line code blocks into pre tag 2022-09-06 10:27:01 +00:00
Mario
3dfb0bcae9 do not wrap multi line code blocks into pre tag 2022-09-06 09:21:39 +00:00
Mario
9ac0b77e92 fix missing closing div tag if there are no recent channel activities to display 2022-09-05 08:04:37 +00:00
Mario
6421a32520 fix issue where an unkown diaspora author was not imported if the comment arrived via a relayed activity and a minor css fix 2022-08-30 13:51:59 +00:00
Mario
fdcae52740 do not escape tags here since it will destroy additional query params 2022-08-21 18:21:05 +00:00
Mario
a8752844ef Activity: check for other forms of as:Public, Search: make sure to run htmlspecialchars_decode on the AP url so that previously encoded chars will be decoded again 2022-08-21 16:02:51 +00:00
Mario
e04ce5028e more css fixes 2022-08-20 15:53:09 +00:00
Mario
f2c4d80ac0 more css fixes 2022-08-20 15:10:16 +00:00
Mario
d8a6226805 fix syntax error 2022-08-20 11:26:28 +00:00
Mario
fedf60a32c redbasic dark: fixes 2022-08-20 11:23:46 +00:00
Mario
b3548fefc1 bump version 2022-08-20 10:07:57 +00:00
Mario
febd64c527 pdledit_gui: fix offcanvas 2022-08-20 10:06:04 +00:00
Mario
d67a5c5070 redbasic dark schema major cleanup 2022-08-20 09:56:23 +00:00
Mario
aefe7ddd8f redbasic: make use of css variables and implement link_hover_colour 2022-08-20 09:31:30 +00:00
Mario
254dea7558 more css fixes 2022-08-19 15:02:06 +00:00
Mario
b1550f7922 more css fixes 2022-08-19 14:34:09 +00:00
Mario
2d07c3e45d more bs upgrade fixes 2022-08-19 13:39:31 +00:00
Mario
e5f3406cb5 time for a new screenshot 2022-08-19 13:30:38 +00:00
Mario
185ddf1eaf update to bootstrap 5.2 and fixes 2022-08-19 13:15:48 +00:00
Mario Vavti
2734335869 version 2022-08-07 14:16:56 +02:00
Mario Vavti
0132c4e36e Merge branch 'dev' 2022-08-07 14:16:31 +02:00
Mario Vavti
7dee47183d changelog 2022-08-07 14:16:00 +02:00
Mario Vavti
9c4988c297 Merge branch 'dev' 2022-08-07 14:07:10 +02:00
Mario Vavti
3bfbc70587 check against null 2022-08-07 14:06:08 +02:00
Mario Vavti
34858fce1c Merge branch 'dev' 2022-08-07 12:17:56 +02:00
Mario Vavti
b47dab0ee9 update widget description 2022-08-05 12:45:43 +02:00
Mario Vavti
6eeb033b96 only decode attachment and iconfig for nonresponse activities 2022-08-04 12:42:35 +02:00
Mario Vavti
0679cb8e00 fix wrong attribution in unseen like notifications 2022-08-04 12:13:00 +02:00
Mario
3abc9ee387 fix regression in dark schema
(cherry picked from commit 2e9211cf41)
2022-07-27 09:29:22 +02:00
Mario
2e9211cf41 fix regression in dark schema 2022-07-27 07:27:51 +00:00
Mario
40377796ed Merge branch '7.6RC' 2022-07-26 18:00:00 +00:00
Mario
fedad7f31a version 7.6 2022-07-26 17:59:11 +00:00
Mario
d2a34e0107 Merge branch 'dev' into 7.6RC 2022-07-26 17:20:30 +00:00
Vinzenz Vietzke
769c822568 StartSSL is defunct since 2018
https://www.thesslstore.com/blog/startcom-ssl-shutting-down-2018/
2022-07-26 17:19:16 +00:00
Mario
c452a621fe Merge branch 'remove-dead-startssl' into 'master'
StartSSL is defunct since 2018

See merge request hubzilla/core!2022
2022-07-26 17:18:26 +00:00
Mario
231ab95ef6 update changelog 2022-07-26 17:16:13 +00:00
Mario
7c01b59ffb version 2022-07-26 15:38:57 +00:00
Mario
e79668ddf4 fix lang tests if result is ambigous 2022-07-26 15:37:17 +00:00
Mario
dc6b6fc353 add "falsey" test 2022-07-26 15:22:05 +00:00
Vinzenz Vietzke
34ea58cf38 StartSSL is defunct since 2018
https://www.thesslstore.com/blog/startcom-ssl-shutting-down-2018/
2022-07-25 12:14:43 +00:00
Mario
199168c318 bump dev version 2022-07-19 12:44:46 +00:00
Mario
063d4bbd7d composer autoload 2022-07-19 12:41:53 +00:00
Mario
29fd9b9d64 version and strings 2022-07-19 12:40:08 +00:00
Mario
c301baafb5 check if the webpages app is installed 2022-07-18 17:52:00 +00:00
Mario
4282672201 bump version 2022-07-16 14:52:10 +00:00
Mario
ae705dd865 HQ dashboard - missing files 2022-07-16 14:49:56 +00:00
Mario
f0fa2ce171 bump version 2022-07-15 17:51:01 +00:00
Mario
d6a9a9927c HQ dashboard - initial checkin 2022-07-15 17:50:02 +00:00
Mario
40b4636858 fix vcard-card background for dark schema 2022-07-03 09:49:09 +00:00
Mario
97fe499b63 Merge branch 'redbasic/dark-fixes' into 'dev'
redbasic/dark: make category pills readable.

See merge request hubzilla/core!2021
2022-07-03 09:42:06 +00:00
Mario
e0915cffda es: update plural function 2022-06-23 17:10:35 +00:00
Mario
7602de85c3 make sure the document is loaded 2022-06-23 17:01:43 +00:00
Harald Eilertsen
0787817eb8 redbasic/dark: make category pills readable. 2022-06-21 19:24:21 +02:00
Mario
e030648957 Merge branch 'dev' of https://codeberg.org/hubzilla/hubzilla into dev 2022-06-21 08:57:43 +00:00
hubzilla
b815935fd7 Merge pull request 'Fixing some error in Spanish translation' (#12) from mjfriaza/hubzilla:dev into dev
Reviewed-on: https://codeberg.org/hubzilla/hubzilla/pulls/12
2022-06-21 10:57:12 +02:00
Mario
a5000ba311 Merge branch 'dev' into 'dev'
Fix Opengraph images inside zmg opening tag

See merge request hubzilla/core!2020
2022-06-21 08:52:47 +00:00
Max Kostikov
5e2bb874c8 Fix Opengraph images inside zmg opening tag 2022-06-14 23:19:09 +02:00
mjfriaza
fcb5a7f645 Revert "Fixing some error in Spanish translation"
This reverts commit 1d99c3d3f7.
2022-06-12 18:18:55 +02:00
mjfriaza
b8c6520abb Fix two errors in Spanish translation 2022-06-12 17:21:14 +02:00
mjfriaza
1d99c3d3f7 Fixing some error in Spanish translation 2022-06-05 17:29:44 +02:00
Mario
5e112b395d oembed: implement a max oembed size which defaults to 1MB and do not try to oembed text previews 2022-06-03 08:51:54 +00:00
Mario
d1a8e7813a Revert "composer updates"
This reverts commit 47448b11cd.
2022-06-02 08:00:45 +00:00
Mario
a0582fec12 Revert "composer update"
This reverts commit 2cd3a7b3f0.
2022-06-02 08:00:31 +00:00
Mario
2cd3a7b3f0 composer update 2022-06-02 07:56:13 +00:00
Mario
47448b11cd composer updates 2022-06-02 07:43:33 +00:00
Mario
e63f043841 Merge branch '7.4RC' 2022-06-01 07:00:21 +00:00
Mario
33dd0c83e3 version 7.4 2022-06-01 06:59:23 +00:00
Mario
32dad136f8 Merge branch 'dev' into 7.4RC 2022-06-01 06:58:19 +00:00
Mario
073ed52538 update changelog 2022-06-01 06:58:05 +00:00
Mario
eef828cf3e fix version after merge 2022-05-31 09:38:54 +00:00
Mario
d0b5930a3a Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-05-31 08:42:54 +00:00
Mario
c66ad9ccc8 update changelog 2022-05-31 08:42:27 +00:00
Max Kostikov
9959a15c8e Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!2019
2022-05-28 13:31:24 +00:00
Max Kostikov
f0e4b4dc84 Update Russian translation 2022-05-28 15:28:40 +02:00
Mario
f62f808368 bump dev version 2022-05-25 08:45:21 +00:00
Mario
530a521679 version and strings 2022-05-25 08:41:25 +00:00
Mario
50782dfb83 prevent php error and add some doco 2022-05-25 08:34:29 +00:00
Mario
27a142d5c5 cleanup 2022-05-25 08:17:37 +00:00
Mario
6d00b2e63d bump php version requirement 2022-05-25 08:14:59 +00:00
hubzilla
7be1415a3a Merge pull request 'Update Spanish' (#11) from mjfriaza/hubzilla:dev into dev
Reviewed-on: https://codeberg.org/hubzilla/hubzilla/pulls/11
2022-05-25 09:54:22 +02:00
Mario
0a30b12f7d move wiki related templates to addon 2022-05-25 07:02:15 +00:00
Mario
3058cbfbb2 categories widgets cleanup 2022-05-24 09:31:30 +00:00
Mario
ae780c977b move article and card categories widgets to addons 2022-05-24 09:18:41 +00:00
Mario
e146a67f4b fix photo permission if a photo description is available and use the filename as default photo description if uploading via the editor 2022-05-23 18:56:09 +00:00
Mario
162d86983a streamline inbound attachment handling and fix regression from issue #1679 2022-05-23 09:26:29 +00:00
Mario
8534366a31 move photo flag feature entry to core 2022-05-21 08:25:14 +00:00
Mario
d1c6617dc9 missing files after composer updates 2022-05-20 09:21:23 +00:00
Mario
6f994709b9 do not show deprecated warnings by default 2022-05-19 08:27:09 +00:00
Mario
55d833a9c8 update composer libs 2022-05-19 08:18:15 +00:00
Mario
8ba4745097 update to remove core apps (wiki, cards, articles) which have been moved to addons 2022-05-19 08:04:39 +00:00
Mario
940a0c8b10 add a hidden config for the hs2019 http sig algo 2022-05-19 07:36:57 +00:00
Mario
8928b24e23 rendering fixes 2022-05-19 07:22:10 +00:00
Mario
ae9a9191f3 implement starring of pubstream items 2022-05-18 08:47:45 +00:00
mjfriaza
cb553bd016 Update Spanish 2022-05-17 14:01:28 +02:00
mjfriaza
a75c61d71e Merge remote-tracking branch 'upstream/dev' into dev 2022-05-17 13:44:06 +02:00
Mario
c1dc16a89d make sure we use source.content when rendering events to correctly render observer related content. fix wrong media types. 2022-05-16 20:44:53 +00:00
Mario
66436ce4a2 fix php errors 2022-05-14 19:04:05 +00:00
Mario
62b1ff4ba1 add the title in forum post reshares 2022-05-14 18:30:39 +00:00
Mario
304d136437 do not set allowed to true if verb is ACTIVITY_SHARE and slightly changed logic for conv fetches 2022-05-13 19:13:47 +00:00
Mario
1b4268b9b0 do not stringify integer value 2022-05-11 11:52:22 +00:00
Mario
a7968e6525 update queries in mod search - fixes #1677 2022-05-11 11:50:29 +00:00
Mario
e59cc3d404 deal with pleroma reactions 2022-05-10 12:15:29 +00:00
Mario
3a2d126877 use rev instead of _updated and the unix timestamp is less likely to cause issues in the future 2022-05-09 08:27:50 +00:00
Mario
ee3d6fcfee use addr for webfinger and name for the real name in the userinfo array 2022-05-09 08:23:55 +00:00
Mario
09d929bd56 add the update date to the icon url. some platforms will not update if the icon url remains static 2022-05-07 13:42:14 +00:00
Mario
bd55ae15f2 cleanup channel apps 2022-05-07 07:09:31 +00:00
Mario
2ca80118bf more cleanup 2022-05-06 19:10:28 +00:00
Mario
04eb20ac35 some cleanup after moving articles and cards to addons 2022-05-06 14:58:27 +00:00
Mario
f299391aa1 fix core issue #1676 and a liked/disliked/commented confusion 2022-05-06 08:24:17 +00:00
Mario
c334fc9d22 move wiki to addons 2022-05-06 07:29:59 +00:00
Mario
8520088376 move articles to addon - also remove the pdl 2022-05-04 19:26:45 +00:00
Mario
9ada8518dc move articles to addon 2022-05-04 19:26:05 +00:00
Mario
f0c09b374c move cards to addon 2022-05-04 18:46:45 +00:00
Mario Vavti
c5f33baf27 version 7.2.2 2022-04-26 11:12:43 +02:00
Mario Vavti
2efcdd92e0 Merge branch 'dev' 2022-04-26 11:11:53 +02:00
Mario Vavti
38fda98b6d changelog and version 2022-04-26 11:11:17 +02:00
Mario Vavti
f9fd195c24 Merge branch 'dev' 2022-04-26 11:08:10 +02:00
Mario Vavti
01e82090b2 hubloc in AS has been moved from data to meta a while ago 2022-04-26 11:07:23 +02:00
Mario Vavti
39602ede37 version bump 2022-04-25 22:53:04 +02:00
Mario Vavti
98a311ae40 version 7.2.1 2022-04-25 22:23:47 +02:00
Mario Vavti
5c398b3e8f Merge branch 'dev' 2022-04-25 22:21:12 +02:00
Mario Vavti
83e585ee9b more changelog 2022-04-25 22:19:20 +02:00
Mario Vavti
e386499bfa Merge branch 'dev' 2022-04-25 22:16:39 +02:00
Mario Vavti
4552630bf8 changelog 2022-04-25 22:15:31 +02:00
Mario Vavti
2d8065a780 whitespace 2022-04-25 21:34:47 +02:00
Mario Vavti
b94da93c74 if we have not been provided a profile id set the profile id to the default profile - fixes #1671 2022-04-25 21:34:05 +02:00
Mario Vavti
695045f197 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-04-23 20:53:05 +02:00
Mario Vavti
376733bd08 fix regression with incoming poll answers from activitypub 2022-04-23 20:52:45 +02:00
Mario
4c7c5137c5 check if addons have been removed from the filesystem and also remove them from the db if that is the case 2022-04-22 07:42:31 +00:00
Mario
930b9820f2 Revert "move AP addressing to pubcrawl"
This reverts commit 1390e1db39
2022-04-07 07:28:43 +00:00
Mario Vavti
b2fa63f2c8 move AP addressing to pubcrawl
(cherry picked from commit 1390e1db39)
2022-04-07 09:27:12 +02:00
Mario Vavti
1390e1db39 move AP addressing to pubcrawl 2022-04-07 09:20:06 +02:00
Mario
e7768ae954 fixes in regard to hub re-installs: dismiss deleted hublocs, make sure we use the latest hubloc entry for addressing, in Queue::deliver() prefer primaries since their info is probably more accurate
(cherry picked from commit 38d977e546)
2022-04-01 11:56:07 +02:00
Mario
38d977e546 fixes in regard to hub re-installs: dismiss deleted hublocs, make sure we use the latest hubloc entry for addressing, in Queue::deliver() prefer primaries since their info is probably more accurate 2022-04-01 09:50:12 +00:00
Mario
3e38a24f0a fix PHP error 2022-03-31 10:07:15 +00:00
Mario Vavti
0784cd593a Merge branch '7.2RC' 2022-03-29 11:42:53 +02:00
Mario Vavti
9c5d2ee563 version 7.2 2022-03-29 11:41:33 +02:00
Mario Vavti
be5f7c2e67 Merge branch 'dev' into 7.2RC 2022-03-29 11:39:28 +02:00
Mario Vavti
0d0f73fb67 update changelog 2022-03-29 11:38:59 +02:00
Mario
680be6cfec Merge branch 'fix-changelog' into 'dev'
Update changelog with missing fix and cve

See merge request hubzilla/core!2018
2022-03-27 19:51:20 +00:00
Harald Eilertsen
2ab3d072b0 Update changelog with missing fix and cve 2022-03-25 22:14:39 +01:00
Mario
943ecff623 fix version 2022-03-25 09:27:39 +00:00
Mario
03973f5d1d changelog 2022-03-25 09:22:57 +00:00
Mario
c42a0fa9b6 bump dev version 2022-03-23 20:20:44 +00:00
Mario
61522ed31d strings 2022-03-23 20:16:33 +00:00
Mario Vavti
29a527426a make sure to set comments_closed to the created date if nocomment is set 2022-03-23 21:08:54 +01:00
Mario
62ac0ff21e streamline comment policy with downstream 2022-03-23 19:01:42 +00:00
Mario
a41c7caa18 Merge branch 'security-fixes-lfi-xss-open-redirect' into 'dev'
Security fixes

See merge request hubzilla/core!2017
2022-03-23 18:38:03 +00:00
Harald Eilertsen
b3ca31bce7 CVE-2022-27256: Open redirect via rpath query param.
Don't follow urls to external sites when submitting forms from the
settings modules. This mitigates an Open Redirect vulnerability where an
attacker could trick a user to go to an attacker controlled destination.

Fixes part of https://framagit.org/hubzilla/core/-/issues/1666
2022-03-20 15:34:24 +01:00
Harald Eilertsen
b02f6a1dae Add function is_local_url() to check if url is local. 2022-03-20 15:34:24 +01:00
Harald Eilertsen
d35609f33a CVE-2022-27258: XSS via rpath query param.
Escape URLs provided by the rpath query param in settings modules. This
prevents a possible Cross-Site scripting vulnerability, where an
attacker could inject web scripts and html into the settings form via
the rpath query parameter, and have a user execute the script by
tricking them to clicking a link.

Fixes part of https://framagit.org/hubzilla/core/-/issues/1666
2022-03-20 15:34:24 +01:00
Harald Eilertsen
8c19ab8f9f Add helper to escape URLs.
The escaping makes the URL safe for display and for use in HTML element
attributes (such as href="..." etc), but does not guarantee that the URL
itself is valid after conversion. This should be good enough for
mitigating XSS issues caused by injecting html or javascript into a URL.
Also probably good enough for _most_ normal URLs, but there may be
devils hidden in the details somewhere.
2022-03-20 15:34:24 +01:00
Harald Eilertsen
30ae198b89 CVE-2022-27257: LFI in Redbasic theme.
Limit valid chars in schema names, and discard attempts at loading
schemas with invalid names.

This prevents a local file inclusion vulnerability where an
unauthenticated attacker can include arbitrary php files readable by the
server process and potentially obtain remote code execution.

Valid schema names may consist of ascii letters, numbers, hyphens and
underscores. Should be good enough for most cases, I think.

Fixes https://framagit.org/hubzilla/core/-/issues/1665
2022-03-20 15:34:17 +01:00
Mario
bddeab3ac1 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-03-20 08:59:07 +00:00
Mario
591349ee74 add the signing algo to zotinfo, and store it in import_xchan() if present 2022-03-20 08:58:18 +00:00
Mario
9081a25e64 Merge branch 'volse-redbasic-dark' into 'dev'
redbasic/dark: Use bootstrap-nightfall for dark schema.

See merge request hubzilla/core!2016
2022-03-20 08:27:30 +00:00
Mario
1beadfc6e7 Merge branch 'volse-fix-stylesheet-root-path' into 'dev'
Use correct base url for stylesheets and js.

See merge request hubzilla/core!2015
2022-03-17 08:23:02 +00:00
Harald Eilertsen
f4af532c5a Trim trailing & from query_string.
When trying to fetch an image file from the Cloud module, the default
nginx config will add a trailing & if there's no args specified.

Example:

https://example.com/cloud/username/some_image.png

This will be rewritten to:

https://example.com/index.php?q=/cloud/username/some_image.png&

This in turn will cause the Cloud module to try to redirect back to the
original because it does not match the query_string (in which the
ampersand has been converted to a question mark). And this will repeat
until the browser get's tired of it.
2022-03-13 19:37:45 +01:00
Harald Eilertsen
76eb1a9d78 redbasic/dark: Tune button colours a bit.
Makes buttons a bit less bright so they don't stick out quite as much.
2022-03-13 17:08:06 +01:00
Harald Eilertsen
14a2790dcb redbasic/dark: Use schema colour for dropdown item 2022-03-13 17:08:06 +01:00
Harald Eilertsen
46f54db197 redbasic/dark: Use bootstrap-nightfall for dark schema.
This is a color only stylesheet, modifying the original Bootstrap colors
to a dark variant. Insert this as base before the redbasic dark schema
modifications, and any custom modifications to have a nicer base for the
dark schema.
2022-03-13 17:07:45 +01:00
Mario
4ffd7587a9 make sure an announce does not overwrite an item we already have and make sure it will be a toplevel post 2022-03-11 20:29:18 +00:00
Mario
c48c62c7a8 whitespace 2022-03-10 11:41:34 +00:00
Mario
9e7fd20ade support for hs2019 2022-03-10 09:44:37 +00:00
Mario
efa1d381ba move attachments to the top 2022-03-05 13:55:16 +00:00
Mario
740fa058aa remove logging 2022-03-04 18:43:54 +00:00
Mario
37f56e1efd event fixes 2022-03-04 18:43:21 +00:00
Mario
6294be371a bump version 2022-03-04 16:12:44 +00:00
Mario
bee7549a1e fix regression 2022-03-04 16:09:44 +00:00
Mario
db14dbacc9 streamline event activity handling 2022-03-04 15:05:58 +00:00
Mario
27058e6297 bump version 2022-03-04 09:51:21 +00:00
Mario
b41175e0e2 port some ap quirks from the addon 2022-03-04 09:45:11 +00:00
Mario
eeea3251ad more work on enhanced content filters 2022-03-03 20:31:43 +00:00
Harald Eilertsen
34ffff3947 Remove now unused function script_path. 2022-03-03 19:50:07 +01:00
Harald Eilertsen
65ed3818ec Use correct base url for stylesheets and js.
Use z_root instead of script_path when formatting stylesheet and
javascript links for the head section. script_path does not preserve
information about the port if the site uses a nonstandard port.
2022-03-03 19:47:33 +01:00
Mario
c8417df6f1 fix duplicate ids in login form and move login/register buttons into the hamburger menu on small screens 2022-03-03 16:52:04 +00:00
Mario
dc3be7ecf7 collect the accept headers in an array 2022-03-03 11:22:46 +00:00
Mario
cf3c0b593b Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-03-02 19:53:16 +00:00
Mario
34f64148e8 composer updates 2022-03-02 19:52:47 +00:00
Mario
fc5dad1983 port some peertube tweeks from pubcrawl to lib/activity 2022-03-02 19:52:26 +00:00
Mario
c3c40548b9 Merge branch 't0rum-master-patch-68993' into 'master'
Typo in Setup.php prevents users from using Postgres

See merge request hubzilla/core!2014

(cherry picked from commit 0e2e932102)

d384f55d Typo in Setup.php prevents users from using Postgres
2022-03-01 21:21:50 +01:00
Mario
0e2e932102 Merge branch 't0rum-master-patch-68993' into 'master'
Typo in Setup.php prevents users from using Postgres

See merge request hubzilla/core!2014
2022-03-01 20:20:58 +00:00
Mario
6930c4e23b fix feedutils regression 2022-03-01 20:06:10 +00:00
Mario
01b9f2dfcf enhanced content filters 2022-03-01 10:14:05 +00:00
Mario
0cc6f66a26 make gprobe deal with URLs, fix issue in get_actor_protocols and fix missing author issue if wall2wall comment arrives and author is not yet known 2022-02-28 10:16:19 +00:00
t0rum
d384f55dd1 Typo in Setup.php prevents users from using Postgres 2022-02-26 19:15:02 +00:00
Mario
1893368aa5 missing content region for directory 2022-02-23 13:52:49 +00:00
Mario
a520063265 widget descriptions and add content region to all pdl files for convenience 2022-02-23 11:52:11 +00:00
Mario
1e171a72a0 bump version 2022-02-21 10:18:39 +00:00
Mario
5b1a0d93b9 this was required for old style forum posts only and should not be needed anymore 2022-02-21 10:16:21 +00:00
Mario
7e04662a9c do not require network for forums widget 2022-02-21 10:03:43 +00:00
Mario
a804549781 remove deprecated widgets and add some more widget descriptions 2022-02-21 10:02:33 +00:00
Mario
2a60f1cc6e merge branch pdledit_gui into dev - many widgets still miss their description and requirements (this is work in progress) 2022-02-20 20:18:24 +00:00
Mario
2ddff785e5 thr_parent lost across edits 2022-02-18 18:52:38 +00:00
Mario
38882efb5c composer update 2022-02-18 12:43:10 +00:00
Mario
6f7786b068 Merge branch 'undefined' into 'dev'
Replace htconfig.tpl fr

See merge request hubzilla/core!2008
2022-02-15 10:41:36 +00:00
Mario
0819141f03 Merge branch 'dandauge-dev-patch-02109' into 'dev'
Update lostpass_eml.tpl fr

See merge request hubzilla/core!2009
2022-02-15 10:38:43 +00:00
Mario
329ef5049f Merge branch 'dandauge-dev-patch-69038' into 'dev'
Upload New File : invite.material.subject.tpl fr

See merge request hubzilla/core!2010
2022-02-15 10:38:12 +00:00
Mario
34bb8c65d6 Merge branch 'dandauge-dev-patch-34611' into 'dev'
Upload New File : invite.material.tpl fr

See merge request hubzilla/core!2011
2022-02-15 10:37:52 +00:00
Mario
575ccae6f9 Merge branch 'dandauge-dev-patch-30995' into 'dev'
Update passchanged_eml.tpl fr

See merge request hubzilla/core!2012
2022-02-15 10:37:30 +00:00
Mario
486be87e33 Merge branch 'dandauge-dev-patch-92660' into 'dev'
Update update_fail_eml.tpl fr

See merge request hubzilla/core!2013
2022-02-15 10:37:03 +00:00
Mario
c0350861ef php8 warnings 2022-02-13 19:31:51 +00:00
Mario
a7ec1805e3 address deprecation warnings 2022-02-13 18:58:12 +00:00
Mario
4b06bc552f add inbound support for quoteUrl 2022-02-13 16:53:43 +00:00
Dan d'Auge
76ee7b7eea Update update_fail_eml.tpl fr 2022-02-13 06:21:35 +00:00
Dan d'Auge
04b1e7e34f Update passchanged_eml.tpl fr 2022-02-13 06:08:31 +00:00
Dan d'Auge
17dbb156e1 Upload New File : invite.material.tpl fr 2022-02-13 06:03:17 +00:00
Dan d'Auge
135117c637 Upload New File : invite.material.subject.tpl fr 2022-02-13 05:54:55 +00:00
Dan d'Auge
d3348f7855 Update lostpass_eml.tpl fr 2022-02-13 05:51:23 +00:00
Dan d'Auge
39bbcb66c8 Replace htconfig.tpl fr 2022-02-13 05:22:33 +00:00
Mario
d45e8e4d20 make sure we have an array 2022-02-11 12:59:08 +00:00
Mario
d65052c1ac comment out failing tests for now 2022-02-11 12:19:50 +00:00
Mario
2fbc42753f language test 2022-02-11 11:42:33 +00:00
Mario
4195865965 add options 2022-02-11 11:29:08 +00:00
Mario
de3f6fbeba more dependencies 2022-02-11 11:25:24 +00:00
Mario
6a377120bd lets try this 2022-02-11 11:22:03 +00:00
Mario
502226b0a6 more ci testing 2022-02-11 11:16:03 +00:00
Mario
78206b48f4 add php-gd 2022-02-11 11:12:28 +00:00
Mario
dc3cec06ca restructure 2022-02-11 11:08:43 +00:00
Mario
5a7688e099 do phpunit though 2022-02-11 11:05:11 +00:00
Mario
c721f01c76 skip db tests for now 2022-02-11 11:02:50 +00:00
Mario
463806822c more ci testing 2022-02-11 10:56:23 +00:00
Mario
b74c2f001d more ci testing 2022-02-11 10:54:00 +00:00
Mario
9fc7a8b626 more ci testing 2022-02-11 10:47:27 +00:00
Mario
3ffd92a6c3 more ci testing 2022-02-11 10:45:31 +00:00
Mario
29b02e5329 more ci testing 2022-02-11 10:43:42 +00:00
Mario
97584e046f more ci testing 2022-02-11 10:40:04 +00:00
Mario
09d2fce85d run composer updatee 2022-02-11 10:33:54 +00:00
Mario
fc3060cb29 we do not actually require this for the tests 2022-02-11 10:28:22 +00:00
Mario
9804a67165 more version bumps 2022-02-11 10:24:51 +00:00
Mario
21eddefa41 typo 2022-02-11 10:18:10 +00:00
Mario
9b62e7eedb bump php image to 8.0 2022-02-11 10:17:04 +00:00
Mario
bf30cfd8a4 more composer updates 2022-02-11 10:01:39 +00:00
Mario
139ffae367 fix another deprecation warning 2022-02-11 09:51:21 +00:00
Mario
51a48cc264 bump php version 2022-02-11 09:42:54 +00:00
Mario
abbca12565 typo 2022-02-11 09:37:29 +00:00
Mario
9e9d96a2ec minor restructure to omit php 8.1 deprecation warning 2022-02-11 09:36:17 +00:00
Mario
615c9f1cbe composer update smarty to version 4.1 - new files 2022-02-11 09:27:57 +00:00
Mario
7d75d0cfbd composer update smarty to version 4.1 2022-02-11 09:27:35 +00:00
Mario
5468de2c6a composer libs minor version updates add new files 2022-02-11 09:23:29 +00:00
Mario
6d8aabab23 composer libs minor version updates 2022-02-11 09:21:19 +00:00
Mario
e74359fcfe 3rd arg in str_replace() can not be null 2022-02-11 09:10:19 +00:00
Mario
53c842c614 Merge branch 'dev' 2022-02-10 19:50:28 +00:00
Mario
23ececeb34 changelog and version 2022-02-10 19:48:52 +00:00
Mario
521c9eb566 Merge branch 'dev' 2022-02-10 19:45:08 +00:00
Mario
35877b1382 allow to override the DB charset via the $db_charset variable in .htconfig.php 2022-02-10 18:57:44 +00:00
Mario
c531287170 fix php8.1 deprecation warning 2022-02-09 19:25:55 +00:00
Mario
8e79a81b88 Merge branch 'dev' 2022-02-09 12:10:04 +00:00
Mario
b95ceb301f gc() returns bool 2022-02-09 12:09:33 +00:00
Mario
76a94495c4 Merge branch 'dev' 2022-02-09 12:02:00 +00:00
Mario
b6b2299b4e revert: union types are only possible from php version 8 and higher 2022-02-09 12:01:16 +00:00
Mario
34ddea87d3 version 2022-02-09 09:54:02 +00:00
Mario
3d318542cb Merge branch 'dev' 2022-02-09 09:50:08 +00:00
Mario
4a8c3cdc61 changelog 2022-02-09 09:49:46 +00:00
Mario
c0b6f2d95f fix missing asterisk 2022-02-09 09:23:12 +00:00
Mario
9ca7fccab8 Merge branch 'dandauge-dev-patch-55065' into 'dev'
Update register_verify_eml.tpl

See merge request hubzilla/core!1998
2022-02-09 09:15:10 +00:00
Mario
d91fcfc866 Merge branch 'dandauge-dev-patch-45641' into 'dev'
Update register_verify_member.tpl

See merge request hubzilla/core!1999
2022-02-09 09:14:44 +00:00
Mario
29b53f3b9d Merge branch 'dandauge-dev-patch-07376' into 'dev'
Update register_open_eml.tpl

See merge request hubzilla/core!2000
2022-02-09 09:13:58 +00:00
Mario
30987095c7 Merge branch 'dandauge-dev-patch-78369' into 'dev'
Upload New File : cert_bad_eml.tpl fr

See merge request hubzilla/core!2001
2022-02-09 09:13:16 +00:00
Mario
43b93de570 Merge branch 'dandauge-dev-patch-72709' into 'dev'
Upload New File : cron_bad_eml.tpl fr

See merge request hubzilla/core!2002
2022-02-09 09:12:59 +00:00
Mario
5b310cf315 Merge branch 'dandauge-dev-patch-59648' into 'dev'
Upload New File : invite.casual.subject.tpl fr

See merge request hubzilla/core!2004
2022-02-09 09:10:21 +00:00
Mario
a1c2a57ea6 Merge branch 'dandauge-dev-patch-81368' into 'dev'
Upload New File : invite.casual.tpl fr

See merge request hubzilla/core!2005
2022-02-09 09:08:36 +00:00
Mario
34bf8f1133 Merge branch 'dandauge-dev-patch-67694' into 'dev'
Upload New File : invite.formal.subject.tpl fr

See merge request hubzilla/core!2006
2022-02-09 09:06:57 +00:00
Mario
c708ec577e Merge branch 'dandauge-dev-patch-34373' into 'dev'
Upload New File : invite.formal.tpl fr

See merge request hubzilla/core!2007
2022-02-09 09:06:33 +00:00
Mario
c185685f2d pdo: add the charset to the connection string 2022-02-09 08:57:27 +00:00
Mario
daee5b3477 since we do not use feedutils for ostatus anymore, we can now safely use import_author_rss() instead of import_author_unknown() 2022-02-09 08:45:19 +00:00
Mario
5d0346ee30 rename variable 2022-02-08 20:44:30 +00:00
Mario
85ad5355cf revert logging 2022-02-08 20:13:19 +00:00
Mario
4c8b84633a revert deleted flag for webfinger and zotfinger key 2022-02-08 20:12:16 +00:00
Mario
c0dd4d748d HTTPSig: introduce the deleted keytype. this will allow us to not fetch an actor we have never seen before if we received a delete activity for this actor for some reason. this is only implemented in the activitypub inbox so far. 2022-02-08 19:51:10 +00:00
Mario
c94f25570b Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-02-08 15:15:18 +00:00
Mario
ffa5e08832 versionà 2022-02-08 15:15:03 +00:00
Mario Vavti
63243c8e04 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-02-08 15:15:34 +01:00
Mario Vavti
21c4ec2de0 fix php error in externals and streamline actor cache time 2022-02-08 15:14:16 +01:00
Mario
a8d87af418 to reduce overall network fetches cache actors in Activity::fetch() and fetch the ldsig creator with get_actor() instead of get_compound_property() so that it will check the cache before actually fetching 2022-02-08 14:09:54 +00:00
Dan d'Auge
7b084a065e Upload New File : invite.formal.tpl fr 2022-02-06 14:46:09 +00:00
Dan d'Auge
47f6b202e5 Upload New File : invite.formal.subject.tpl fr 2022-02-06 14:30:26 +00:00
Dan d'Auge
f588d8379b Upload New File : invite.casual.tpl fr 2022-02-06 10:20:05 +00:00
Dan d'Auge
58827e130b Upload New File : invite.casual.subject.tpl fr 2022-02-06 10:08:07 +00:00
Dan d'Auge
d702334604 Upload New File 2022-02-06 09:03:40 +00:00
Dan d'Auge
b04aa799e3 Upload New File : cert_bad_eml.tpl fr 2022-02-06 08:54:09 +00:00
Dan d'Auge
e113f6cb9d Update register_open_eml.tpl 2022-02-06 07:52:38 +00:00
Dan d'Auge
bc13b7eb72 Update register_verify_member.tpl 2022-02-06 07:42:00 +00:00
Dan d'Auge
f50b395da6 Update register_verify_eml.tpl 2022-02-06 06:41:23 +00:00
Mario
a0e8e40f1c whitespace 2022-02-04 12:50:25 +00:00
Mario
cb6055c1b8 clean the url from parameters 2022-02-04 12:48:47 +00:00
Mario
25424c16e4 unpack encoded mid and make sure to goaway to the right message 2022-02-03 19:09:15 +00:00
Mario
99dcdee67a move JSalmon stuff from the data to the meta field in Lib ActivityStreams and some more refinement on storing the raw ap and diaspora data in iconfig 2022-02-03 11:57:47 +00:00
Mario
99928f1aea only unset if set 2022-02-02 18:59:14 +00:00
Mario
1740ae2104 more PHP 8.1 deprecated warnings 2022-02-02 17:58:29 +00:00
Mario
d8372f8433 more PHP 8.1 deprecated warnings 2022-02-02 12:44:39 +00:00
Mario
2a15d2c421 more PHP 8.1 deprecated warnings 2022-02-02 12:40:09 +00:00
Mario
bacf19688f a like could be stored as item or activity so check both 2022-02-02 09:59:36 +00:00
Mario
31fbdcf6c5 typo 2022-02-01 10:32:54 +00:00
Mario
c8818cb7b3 formatting 2022-02-01 10:30:26 +00:00
Mario
eb20789821 allow zotfinger to recurse through all known hublocs if the one we got does not exist (404) or got removed (410). add functions for updating tables from array and deleting hublocs. 2022-02-01 10:01:56 +00:00
Mario
c90862217e bump version 2022-01-31 11:03:49 +00:00
Mario
df87d6feeb more work on relaying zap and diaspora, fix mod hcard 2022-01-31 10:18:58 +00:00
Mario Vavti
6c808abcfc PHP 8.1 band-aid 2022-01-31 09:49:00 +01:00
Mario Vavti
f1822bdfab add the signature 2022-01-31 08:46:12 +01:00
Mario
c3428acd80 make sure we never save a zot6 packet as ap raw message 2022-01-30 16:29:04 +00:00
Mario
d619192b22 attach iconfig to the activity and adjust ap raw message retrieval to handle both cases. also add a possibility to manually redeliver single hubs for debuging 2022-01-30 15:33:57 +00:00
Mario
5bdc713afe Merge branch 'dev' 2022-01-28 20:10:11 +00:00
Mario
46eff1c937 changelog 2022-01-28 20:09:29 +00:00
Mario
76e1ea1c02 version 7.0.1 2022-01-28 20:04:43 +00:00
Mario
755076a8e5 Merge branch 'dev' 2022-01-28 20:03:30 +00:00
Mario
b49f7b8b34 fix removing contacts from privacy groups 2022-01-28 19:40:42 +00:00
Mario
c4dd8885e4 $cmd should be a strig and not null 2022-01-28 13:32:28 +00:00
Mario
4c82952b58 formatting and unused variables 2022-01-28 13:29:25 +00:00
Mario
0da69cb9c7 do not use escape_tags() for inbox 2022-01-27 21:56:13 +00:00
Mario
36e244060c escape_tags() will turn & to &amp; and there for mess up the xchan hash 2022-01-27 21:51:56 +00:00
Mario
b13a9f57af fix for #1659 2022-01-27 21:10:13 +00:00
Mario
0aa67ad7f9 typo 2022-01-27 20:34:21 +00:00
Mario
195a3a6827 whitespace 2022-01-27 20:28:34 +00:00
Mario
38ecff1220 some refinement on storing the raw ap message, some comments and make sure the AS->raw is always a json string 2022-01-27 20:27:02 +00:00
Mario
67e64287af missing define of variable, remove deprecated zot-info and ofeed from webfinger 2022-01-26 19:28:04 +00:00
Mario
b022703b0b update to remove the mail app 2022-01-26 18:40:02 +00:00
Mario
e8069c0d93 use item_hidden instead of item_notshown for forum comment announces 2022-01-26 13:58:03 +00:00
Mario
7a1c6b64c2 $act->raw will not always hold the AP raw message. Look for it in iconfig. 2022-01-26 13:02:51 +00:00
Mario
8250cb1e8d always store the raw message 2022-01-26 09:35:08 +00:00
Mario
ffe2c4d42b make sure to escape the author name for the reply_to button 2022-01-24 08:51:14 +00:00
Mario
f06c970628 port z_curl_error() from zap 2022-01-23 20:23:40 +00:00
Mario
99bce46b32 fix doc 2022-01-23 15:08:13 +00:00
Mario
f711913778 fix doc 2022-01-23 15:06:18 +00:00
Mario
a8ac231667 make sure that if an existing contact role changes we will re-assign the permissions to all role members and cleanup 2022-01-23 15:03:26 +00:00
Mario
f7c8791a6d make sure we have an existing default role in any case 2022-01-23 13:43:33 +00:00
Mario
7acc775c91 wrong function name 2022-01-21 07:46:12 +00:00
Mario
c2e21e837f wrong function name 2022-01-21 07:45:42 +00:00
Mario
755d0f54f7 Merge branch '7.0RC' 2022-01-21 07:28:24 +00:00
Mario
f62d66ff25 version 7.0 2022-01-21 07:27:35 +00:00
Mario
406d19f930 Merge branch 'dev' into 7.0RC 2022-01-21 07:27:00 +00:00
Mario
42b13614eb update changelog 2022-01-21 07:26:23 +00:00
Mario
c942bd67fe Merge branch 'dev' into 7.0RC 2022-01-21 07:20:30 +00:00
Mario
b8dc3d74b6 update strings 2022-01-21 07:20:04 +00:00
Mario
38fb263737 string 2022-01-21 07:14:40 +00:00
Mario
b55beed2f9 string update 2022-01-20 14:27:28 +00:00
Mario
e9278c03c1 Merge branch 'dev' into 7.0RC 2022-01-20 10:29:52 +00:00
Mario
ae1fe83784 fix potential issue with ap addressing in mod hq 2022-01-20 10:27:55 +00:00
Mario
717a547c40 Merge branch 'dev' into 7.0RC 2022-01-20 10:03:02 +00:00
Mario
ec491e87ab remove deprecated template 2022-01-20 10:02:39 +00:00
Mario
42e30d0835 fix pgsql profile photo issue 2022-01-20 08:14:03 +00:00
Mario
5b19418e48 fix pgsql profile photo issue 2022-01-20 08:12:14 +00:00
Mario
1bc9a7373f Merge branch 'dev' into 7.0RC 2022-01-19 19:14:54 +00:00
Mario
23e59b5dcc update changelog 2022-01-19 19:14:30 +00:00
Mario
c6b459cf96 drop_item() requires the item id not the item array 2022-01-19 19:11:49 +00:00
Mario
33254b4cac Merge branch 'dev' into 7.0RC 2022-01-19 13:22:23 +00:00
Mario
44da40d18d revert background color 2022-01-19 13:21:32 +00:00
Mario
c742f25801 prevent duplicate ids and adjust spinner color 2022-01-19 13:19:32 +00:00
Mario
b153687bf1 prevent duplicate ids and adjust spinner color 2022-01-19 13:18:47 +00:00
Mario
3318f093da Merge branch 'dev' into 7.0RC 2022-01-19 11:25:06 +00:00
Mario
d98d56c3b5 provide a spinner for edit connection action in threads 2022-01-19 11:24:42 +00:00
Mario
c3f5f6c7ad Merge branch 'dev' into 7.0RC 2022-01-19 10:04:42 +00:00
Mario
5f21edcc53 update changelog 2022-01-19 10:04:20 +00:00
Mario
cd0731cbb0 version RC2 2022-01-19 09:51:32 +00:00
Mario
f392ddec2f Merge branch 'dev' into 7.0RC 2022-01-19 09:41:57 +00:00
Mario
df71168ab7 fix channel app naming and translation and cleanup apps with an db update 2022-01-19 09:41:16 +00:00
Mario
e93b26bf54 Merge branch 'dev' into 'dev'
Fix strings translation

See merge request hubzilla/core!1997
2022-01-19 09:21:55 +00:00
Mario
a73d4a8cbd Merge branch 'dev' into 7.0RC 2022-01-19 08:39:12 +00:00
Mario
20ee57801c we must check if actor.id is empty(). checking for isset() only could still end up in an empty string and produce unexpected results 2022-01-19 08:29:44 +00:00
Max Kostikov
6a270d7f02 Fix strings translation 2022-01-18 22:40:25 +02:00
Mario
68639637c9 RC1 2022-01-18 10:27:37 +00:00
Mario
0d1eabbc33 Merge branch 'dev' into 7.0RC 2022-01-18 10:26:21 +00:00
Mario
dce249f7a9 change name on all associated xchans by matching the url 2022-01-18 10:24:52 +00:00
Mario
1723d4fbd8 fix version 2022-01-18 09:59:54 +00:00
Mario
c4b09f1a4f check for existence of vcard 2022-01-18 10:50:25 +01:00
Mario
788c973c13 vcards are not actually implemented anymore 2022-01-18 10:39:00 +01:00
Mario
465c5c8cfb make sure to use the correct default role 2022-01-18 10:26:13 +01:00
Mario
ee28ba5be1 adjust lock hover text if item_private === 2 2022-01-17 08:23:15 +00:00
Mario
9a22e9cf39 bump dev version 2022-01-16 12:47:26 +00:00
Mario
2513f605b6 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2022-01-16 12:45:58 +00:00
Mario
3b1ffb2028 changelog 2022-01-16 12:45:00 +00:00
Max Kostikov
47c6624e12 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1996
2022-01-14 19:22:43 +00:00
Max Kostikov
b6f1b064d3 Update Russian translation 2022-01-14 21:20:40 +02:00
Mario
17d89467df composer dump autoload 2022-01-14 18:31:38 +00:00
Mario
1282214d48 strings and version 2022-01-14 18:28:33 +00:00
Mario
f4bc6ee615 ux improvements 2022-01-13 13:07:59 +00:00
Mario
f8b8d8c540 make sure to fallback if local_channel and no nav_bg is set 2022-01-13 10:32:36 +00:00
Mario
57ff667438 pwa improvements according to lighthouse 2022-01-13 10:18:53 +00:00
Mario
abe3039926 ux improvements 2022-01-12 21:08:29 +00:00
Mario
82a1117e91 mod profile_photo template cleanup 2022-01-12 13:43:30 +00:00
Mario
b6ff3a4d99 mod profile_photo cleanup 2022-01-12 13:35:51 +00:00
Mario
f4046efcb2 refactor mod profile_photo 2022-01-12 13:09:53 +00:00
Mario
fc1d3831cf revert commit 7e2aecd8 2022-01-11 09:59:07 +00:00
Mario
867deda247 remove legacy mail which has been deprecated since a year 2022-01-11 09:29:18 +00:00
Mario
f8149face5 toc: add headings 2022-01-11 09:17:39 +00:00
Mario
7e2aecd8bb lifetime->expires 2022-01-10 11:37:47 +00:00
Mario
105d121199 set samesite cookie flag to none - some browsers start to default the flag to lax (previous none) 2022-01-10 11:36:20 +00:00
Mario
37d662f2f5 css fixes 2022-01-10 09:29:59 +00:00
Mario
5b50454b4d make toc bbcode find its own container by default 2022-01-09 20:44:30 +00:00
Mario
b5e4c08fc5 fix get_tags() parsing toc bbcodes 2022-01-09 18:25:17 +00:00
Mario
db39cd8b7c fix php error 2022-01-09 16:38:10 +00:00
Mario
a35f741a35 deprecate AccessList::widget() 2022-01-09 15:40:54 +00:00
Mario
fc02e018cb mark group actors as such in items and minor text change 2022-01-08 18:57:59 +00:00
Mario
b14a530efb missing nav_set_selected() 2022-01-08 13:22:15 +00:00
Mario
f70bc571bd css fix 2022-01-08 13:17:19 +00:00
Mario
8cc64176b4 missing files 2022-01-07 20:14:11 +00:00
Mario
7450ac1a31 missing files 2022-01-07 20:07:09 +00:00
Mario
c72e5e3b66 streamline privacy groups 2022-01-07 20:03:40 +00:00
Mario
5e811819e2 add link to create new contact roles 2022-01-07 19:14:14 +00:00
Mario
f1c0034a18 more work on access tokens 2022-01-06 21:09:18 +00:00
Mario
7342cb81a3 bump version 2022-01-04 20:42:43 +00:00
Mario
b40e858556 only display connections widget if there are any connections to show 2022-01-04 20:42:07 +00:00
Mario
95a4ed7d6a do not show blocked or ignored contacts in connections 2022-01-04 20:31:42 +00:00
Mario
2c2d4b6b95 remove suggestions widget from mod directory 2022-01-04 19:57:04 +00:00
Mario
4490eae4fe remove suggestions widget from mod network 2022-01-04 19:55:53 +00:00
Mario
9d59cb0135 minor wording change and fix connections link 2022-01-04 19:48:15 +00:00
Mario
7d348fe69f fix Access^CccessList include and plink in post_activity_item() 2022-01-03 20:20:42 +00:00
Mario
fa8fb9e73f more lockview ui improvements 2022-01-03 11:00:14 +00:00
Mario
f6093872ec minor usability improvement 2022-01-03 09:35:42 +00:00
Mario
e8030e29d9 remove logging 2022-01-02 20:46:44 +00:00
Mario
df8bb0596a port new_token from zap, fixes and more cleanup 2022-01-02 20:45:25 +00:00
Mario
0003e0b8a5 lockview: fix guest links for profile groups and photos, cleanup 2022-01-02 19:33:10 +00:00
Mario
e42703d557 lockview: provide guest links for private resources 2022-01-02 08:49:36 +00:00
Mario
4636e56395 minor theme fixes 2021-12-29 18:45:03 +00:00
Mario
27ebeffad4 update_poll() can be called many times in a row for the same item if a multiple poll is being updated. This could result in the queueworker not processing duplicates. We are now adding the source item mid to the notifier call as the third argument (fragment) so that the queueworker will not think they are duplicates. The fragment is also passed to the deliver_hooks call in the notifier 2021-12-22 09:50:50 +00:00
Mario
07110cee17 add the title to the object 2021-12-21 09:58:07 +00:00
Mario
afa1f1416b string change 2021-12-21 09:20:53 +00:00
Mario
f8dfcab0ca string change 2021-12-21 09:20:21 +00:00
Mario
e14fd920d6 version 2021-12-21 09:19:07 +00:00
Mario
8c10fdae5b missing label 2021-12-21 09:14:48 +00:00
Mario
eee027d9ff Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-12-21 09:09:43 +00:00
Mario
1b1fb5d26a improve pconfig sync at the sending side 2021-12-21 09:08:36 +00:00
Mario Vavti
c36e0805d8 improve pconfig sync at the receiving side 2021-12-21 10:04:51 +01:00
Mario
5c56041185 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-12-18 19:45:42 +00:00
Mario
5aefe0b74f guest token xchan_network = "token" and remove permission checks since the guest tokens are now added to the abook automatically 2021-12-18 19:09:15 +00:00
Max Kostikov
20e0359efd Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1995
2021-12-17 22:42:36 +00:00
Max Kostikov
9c790e5a90 Update Russian translation 2021-12-18 00:39:47 +02:00
Mario
9c79b5be77 version 2021-12-17 21:10:00 +00:00
Mario
2d9a4f4e42 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-12-17 21:08:54 +00:00
Mario
565602538c main.js simplify notify_id checks 2021-12-17 21:08:20 +00:00
Mario Vavti
78972725ae mod tokens cleanup and fixes 2021-12-17 22:05:45 +01:00
Mario
5ab90f7791 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-12-17 20:29:06 +01:00
Mario
b90d98fc2b implement background deleting of items in contact_remove() 2021-12-17 20:26:36 +01:00
Mario
eca3ae393b daemon to delete abbok items in the background 2021-12-17 19:25:28 +00:00
Mario
2bd69495d2 missing file 2021-12-17 19:52:54 +01:00
Mario
bfd3da43ac access token refactor 2021-12-17 19:48:09 +01:00
Mario
32a9eaf3b6 update db schemas 2021-12-17 15:30:26 +01:00
Mario
91cea1f28a add template 2021-12-17 15:01:25 +01:00
Mario
220ed35f58 implement contact role deletion 2021-12-17 14:59:25 +01:00
Mario
b1cf5d4e44 nag channel owners to select achannel role if they have not yet done so yet 2021-12-15 12:58:33 +00:00
Mario
fe330ec1bb bump version 2021-12-15 12:18:07 +00:00
Mario
2968bf8241 merge branch perms_ng into dev 2021-12-15 12:17:19 +00:00
Mario Vavti
a40babbf0d version 6.4.2 2021-12-14 11:12:43 +01:00
Mario Vavti
7822257e1c Merge branch 'dev' 2021-12-14 11:11:57 +01:00
Mario Vavti
b37165c62b changelog 2021-12-14 11:09:27 +01:00
Mario Vavti
5e9d267959 mod sse_bs: when processing returned mids, do not assume they are b64 encoded 2021-12-14 11:04:26 +01:00
Mario Vavti
1a1e6b6810 Announce missing in is_response_activity() 2021-12-11 10:56:50 +01:00
Mario Vavti
88140002e7 Merge branch 'dev' 2021-12-03 16:26:10 +01:00
Mario Vavti
efc203d958 fix blured profile images and pdl files 2021-12-03 16:25:42 +01:00
Mario Vavti
42d4cdcc39 Merge branch 'dev' 2021-12-03 15:13:57 +01:00
Mario Vavti
fd433b3eb6 main_width in rem 2021-12-03 15:10:59 +01:00
Mario Vavti
7483adb8ad Merge branch 'dev' 2021-12-03 14:55:39 +01:00
Mario Vavti
45fd462f80 fix content width for dark schema 2021-12-03 14:54:47 +01:00
Mario Vavti
807003adf7 version 6.4.1 2021-12-03 13:47:58 +01:00
Mario Vavti
1b0a17c7db Merge branch 'dev' 2021-12-03 13:46:41 +01:00
Mario Vavti
60b145833c changelog and version 2021-12-03 13:45:19 +01:00
Mario Vavti
39458b2ba8 fix hubloc_site_id in fix_system_urls() on detected site rename events and during sync_locations() if it changed or was stored incorrectly. 2021-11-30 10:50:31 +01:00
Mario Vavti
5de38b3632 mod channel: lookup zotinfo based on hash instead of address 2021-11-29 11:26:29 +01:00
Mario Vavti
6ced3426cf do not deliver to the same channel multiple times in case duplicate hubloc entries for the channel exist 2021-11-29 11:17:14 +01:00
Mario
43460c9d19 re-add css that was removed by accident 2021-11-26 19:29:43 +00:00
Mario
ca17fb01bc profile cleanup and fixes 2021-11-25 07:54:53 +00:00
Mario
a6f65aa9c5 add source option so that the right makros will be used in attach_store() 2021-11-25 07:44:31 +00:00
Mario
ae9a7727d6 maximum width of content region is now calculated in rem 2021-11-24 20:47:18 +00:00
Mario
3ac5d5257b fix issue where likes notices are emited allthough they are actually disabled 2021-11-24 20:19:35 +00:00
Mario
668d7c73ed address issue #1651 (reload page after comment or like) 2021-11-24 20:01:16 +00:00
Mario
c95f708c91 port httpmeta from zap 2021-11-24 09:08:11 +00:00
Mario
06e214e567 more work on responsive aside 2021-11-23 09:17:04 +00:00
Mario
18f8cafee0 minor vcard fixes 2021-11-21 20:17:14 +00:00
Mario
6bd6afac05 streamline profile vcard with xchan vcard 2021-11-21 19:50:36 +00:00
Mario
fe7ecede70 Merge branch '6.4RC' 2021-11-09 09:10:19 +00:00
Mario
089708ab9f version 6.4 2021-11-09 09:08:52 +00:00
Mario
daa844c038 Merge branch 'dev' into 6.4RC 2021-11-09 09:07:55 +00:00
Mario
4049992228 update changelog 2021-11-09 09:07:37 +00:00
Mario
7c576c91b7 Merge branch 'dev' into 6.4RC 2021-10-30 09:08:32 +00:00
Mario
17bd364614 remove logging 2021-10-30 09:07:56 +00:00
Mario
25ffd39519 Merge branch 'dev' into 6.4RC 2021-10-30 09:05:24 +00:00
Mario
acfa527e3e css fixes 2021-10-30 09:04:50 +00:00
Mario
b512416cb3 fix version 2021-10-28 14:17:53 +00:00
Mario
bd116c53a1 update changelog 2021-10-28 14:14:20 +00:00
Mario
1251fca256 remove mcrypt from the docs 2021-10-27 18:42:25 +00:00
Mario
b2fe21709c update sbom 2021-10-27 12:13:47 +00:00
Mario
c082d12b59 bump dev version 2021-10-27 08:11:09 +00:00
Mario
9a4ca44255 version and strings 2021-10-27 08:05:57 +00:00
Mario
6fce9a41b0 remove logging 2021-10-25 08:12:17 +00:00
Mario
65acdd7b15 mod regate: auto-connect the invitee with the inviter if auto channel create is enabled (default). fix issue where the default group was not set in the return array of create_identity() 2021-10-25 08:03:12 +00:00
Mario
a209374cbd invite: fix variable name in template and do not substitute the Â@ in the webfinger address with @+ 2021-10-22 09:52:30 +00:00
Mario
c1bb87db98 mod item: cleanup and remove some unused variables 2021-10-22 08:16:19 +00:00
Mario
8bae40449f remove library/urlify and use vendor/jbroadway/urlify instead 2021-10-22 08:07:19 +00:00
Mario
bc3bb4694a mod import: formating 2021-10-22 07:50:35 +00:00
Mario
22588e58f3 install urlify via composer 2021-10-22 07:46:30 +00:00
Mario
69ba4eb055 whitespace 2021-10-22 07:27:37 +00:00
Mario
687b9fb6a2 comment out warning about db version differences - it is not relevant 2021-10-22 07:26:30 +00:00
Mario
9b9ca9695c import_items: cleanup 2021-10-21 10:36:31 +00:00
Mario
6357c69868 import_items: provide a possibility to import exported zip files by year 2021-10-21 10:29:44 +00:00
Mario
15cb7ab7a1 nativeWikiPage: more whitespace and cleanup 2021-10-20 19:54:59 +00:00
Mario Vavti
2c741bd24d fix for issue #1640 - use item_store() instead of post_activity_item() which is checking for post_comment permission which we might not have in this case. item_store() requires slightly more data but basically does the same. Also some minor improvements and whitespace changes. 2021-10-20 21:35:42 +02:00
Mario
3f72a3beb6 fix xchan vcard rendering 2021-10-20 09:57:45 +00:00
Mario
42de18d96d fix dutch registration email verification email template
(cherry picked from commit c7515b8687)
2021-10-20 10:09:19 +02:00
Mario
4bdbdab399 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-20 08:08:09 +00:00
Mario
c7515b8687 fix dutch registration email verification email template 2021-10-20 08:07:06 +00:00
Mario
c79e39a488 improve code comments 2021-10-20 08:06:29 +00:00
Mario
d639104b71 invite: use the actual set language and check if we have a template for it
(cherry picked from commit c66a5ba732)
2021-10-18 21:44:06 +02:00
Mario
c66a5ba732 invite: use the actual set language and check if we have a template for it 2021-10-18 21:41:08 +02:00
Mario
79f9b49dd7 provide tags indicating the supported protocols in the actor object and probe for zot6 if appropiate 2021-10-18 07:53:45 +00:00
Mario
8b542c250a mod invite: skip the pre-check for valid email 2021-10-16 20:07:34 +00:00
Mario
55237683d2 xrd whitespace 2021-10-16 19:24:58 +00:00
Mario
27401794e1 rename functions after heavy lifting and expand custom sections to all possible sections 2021-10-16 18:10:23 +00:00
Mario
862a7c2dba manifest: remove orientation so that os default will be used and add default theme_color 2021-10-16 14:03:35 +00:00
Mario
bb31a4620e notes: provide translateable strings 2021-10-15 19:30:38 +00:00
Mario
7aaade8b23 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-15 19:17:31 +00:00
Mario
a622f533ad some heavylifting on manual item export 2021-10-15 19:17:06 +00:00
Max Kostikov
0dd27dabd6 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1994
2021-10-15 15:08:16 +00:00
Max Kostikov
8ab464acf2 Update Russian translation 2021-10-15 16:55:21 +02:00
Mario
db18438db2 escape_tags only once 2021-10-15 08:15:41 +00:00
Mario
f885f98611 use the proprt syntax 2021-10-14 18:59:41 +00:00
Mario
9b8b85545f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-14 18:16:27 +00:00
Mario
532b479f96 provide local copies of the w3.org jsonld documents - addresses issue #1637 2021-10-14 18:15:38 +00:00
Mario
422dfca6d7 fix cacert missing some certificates after last update 2021-10-14 18:13:02 +00:00
Mario
c3d1474f59 Merge branch 'dev' into 'dev'
Support IDNA URLs embedding

See merge request hubzilla/core!1990
2021-10-14 13:16:18 +00:00
Max Kostikov
99873504e4 Support IDNA URLs embedding 2021-10-14 13:16:16 +00:00
Mario
138a67298d version 2021-10-13 11:36:18 +00:00
Mario
aca1551e86 implement AS representation of photos and albums, cleanup and minor fixes 2021-10-13 09:23:59 +00:00
Mario
ca32850a32 fix image object as per AS2 2021-10-12 20:06:11 +00:00
Mario
ba6f069997 HTTPSig: do not query for hubloc_addr 2021-10-12 19:05:21 +00:00
Mario
c6c6b52ccd notes: minor css fix 2021-10-12 18:59:52 +00:00
Mario
96c334e730 bbcode for notes app 2021-10-12 11:27:36 +00:00
Mario
3e503ec3a3 Revert "httpsig: add parentheses"
This reverts commit e455fae334.
2021-10-12 11:25:44 +00:00
Mario
e455fae334 httpsig: add parentheses 2021-10-12 11:25:24 +00:00
Mario
29f3dc2fa3 notifications_widget: fix regression hiding the #nav- * -sub element when there are no more notifications 2021-10-11 09:12:05 +00:00
Mario
aa41b16757 look for hubloc_id_url or hubloc_hash, otherwise we will always fetch the key from the net on platforms where those are different (e.g. mastodon). 2021-10-11 07:41:12 +00:00
Mario
f4d59abe41 streamline logic 2021-10-10 21:13:30 +00:00
Mario
18de58fd8b HTTPSig: cleanup, add some doco and implement missing force mechanism for fetching keys 2021-10-10 21:00:22 +00:00
Mario
4c2b188f8b if we do not have a display path, we are looking at the root directory 2021-10-10 18:16:13 +00:00
Mario
08f65420f4 messages widget: show user-plus icon for connection requests 2021-10-10 09:49:12 +00:00
Mario
b90228b319 make sure we do not select removed channels as importer in onepoll 2021-10-10 08:37:44 +00:00
Mario
ad2c165f26 bbcode: deal with codeblocks before we escape other tags 2021-10-10 08:10:49 +00:00
Mario
af5218593a update composer libs 2021-10-10 07:59:31 +00:00
Mario
f19acd9f50 remove redundant variable and provide missing phpdoc 2021-10-10 07:56:42 +00:00
Mario
59940e7f05 make sure to not include removed channels in xrd or webfinger queries 2021-10-09 19:46:27 +00:00
Mario Vavti
094536e633 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-09 20:08:23 +02:00
Mario Vavti
4f2a439873 mod import: only run automatic content and files import if api version is compatible 2021-10-09 20:08:11 +02:00
Mario
63bdab2b5f use Libzot::fetch_conversation to fetch conversations from search and add an optional force argument to process_delivery 2021-10-09 15:00:21 +00:00
Mario
14733f8482 more bs5 fixes 2021-10-09 08:58:11 +00:00
Mario
b830bbd084 remove hz_syslog and deal with intro notifications in the messages widget 2021-10-08 17:35:36 +00:00
Mario
c1894c5a39 bump version 2021-10-08 13:01:09 +00:00
Mario
e91e488e1f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-08 12:26:08 +00:00
Mario
e6dac085cb update composer libs 2021-10-08 12:24:19 +00:00
Mario
5023a5b56b Merge branch 'Aksel-dev-patch-31902' into 'dev'
German roles.bb

See merge request hubzilla/core!1992
2021-10-06 15:22:43 +00:00
Aksel K
32d37d1178 Aktualisieren doc/de/roles.bb 2021-10-06 15:12:55 +00:00
Aksel K
848221649e Neue Datei hochladen 2021-10-06 14:56:01 +00:00
Mario
f5f357060b fix alt_pager() 2021-10-06 14:32:49 +00:00
Mario
98eea41865 fix drop_query_params() if no query params are left 2021-10-06 14:32:25 +00:00
Mario
8ac529f5ae simplify 2021-10-06 08:43:40 +00:00
Mario
b5fed08dd4 really de-duplicate entries for dead hubs 2021-10-06 08:33:10 +00:00
Mario
9bfcaf2669 do not show duplicate entries for dead hubs 2021-10-06 08:05:16 +00:00
Mario Vavti
af05ee7e1c Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-06 09:40:15 +02:00
Mario
3918439020 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-06 07:39:34 +00:00
Mario
3b71e115a4 implement sync logic in mod appman 2021-10-06 07:39:10 +00:00
Mario Vavti
c33660a015 move sync logic for apps to mod appman. this way we can re-use the functions without creating sync loops. 2021-10-06 09:36:14 +02:00
Max Kostikov
7963d4cb8f Merge branch 'ab-dev' into 'dev'
Polish translation: fixes and updates

See merge request hubzilla/core!1989
2021-10-05 18:27:42 +00:00
Mario
16281e0e7f disable app sync due to a possible loop 2021-10-04 19:16:38 +00:00
Mario Vavti
72c58e60d7 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-04 20:32:32 +02:00
Mario Vavti
4b48ff2868 also sync the undestroy action 2021-10-04 20:32:19 +02:00
Mario
8e212d30d0 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-04 18:21:08 +00:00
Mario
b9ae396e74 unset id before syncing 2021-10-04 18:20:51 +00:00
Mario Vavti
3a38946f8a more app sync 2021-10-04 20:19:16 +02:00
Andrzej Budziński
d0d3a5454e Polish translation: fixes and updates 2021-10-04 19:24:16 +02:00
Mario Vavti
04c6d77d2c set the sync flag to true 2021-10-04 14:14:30 +02:00
Mario Vavti
c2c5730d00 more app sync fixes 2021-10-04 14:08:39 +02:00
Mario Vavti
21a6dffd5f Revert "more app sync fixes"
This reverts commit 7430989212.
2021-10-04 13:54:45 +02:00
Mario Vavti
7430989212 more app sync fixes 2021-10-04 13:41:54 +02:00
Mario Vavti
2e26a13f81 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-04 13:31:30 +02:00
Mario Vavti
404ebd4d5e app sync fixes - part 2 2021-10-04 13:31:26 +02:00
Mario
11ea7bf0fc app sync fixes - part 1 2021-10-04 11:25:52 +00:00
Mario
6da7fe7d27 provide system app sync 2021-10-04 09:24:13 +00:00
Mario
538e540531 commment out deprecated code 2021-10-04 08:46:56 +00:00
Mario
53138f4b09 fix typo 2021-10-04 08:32:36 +00:00
Mario
3d71367f30 add pem 2021-10-04 08:31:00 +00:00
Mario
bb52ff9b4b fix site lookup and minor cleanup 2021-10-04 08:28:57 +00:00
Mario
ab5b82221c update certs 2021-10-03 18:24:26 +00:00
Mario
5c3b89a68b mod locs: do not show drop icon for local clones and get rid of redundant for loop 2021-10-03 17:48:00 +00:00
Mario
da923d7749 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-03 16:54:04 +00:00
Mario
55d905fdd9 clone channel delete issues - part 2 2021-10-03 16:53:48 +00:00
Mario Vavti
4ba70a3fae clone channel delete issues - part 1 2021-10-03 18:52:14 +02:00
Mario
a5835b0e85 disable pg tests 2021-10-03 12:59:10 +00:00
Mario
ed4e5c9bcf version 6.2.2 2021-10-03 12:40:48 +00:00
Mario
d8793de629 make sure we have a sender here
(cherry picked from commit 0722188ea6)
2021-10-03 14:38:59 +02:00
Mario
f45cb38cd3 make sure to return if we have no xchan here
(cherry picked from commit d6f81e139a)
2021-10-03 14:38:29 +02:00
Mario
0722188ea6 make sure we have a sender here 2021-10-03 12:36:17 +00:00
Mario
d6f81e139a make sure to return if we have no xchan here 2021-10-03 12:22:33 +00:00
Mario
58ee147653 fix typo 2021-10-03 08:20:16 +00:00
Mario
28ad6a6883 remove redundant query and exit with status 410 if channel was removed 2021-10-03 07:18:49 +00:00
Mario
9de8aefa98 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-03 07:11:27 +00:00
Mario
66c273ae8d channel_purge: raise limit by factor of 10 2021-10-03 07:11:12 +00:00
Mario Vavti
b27fbf209e Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-03 09:05:54 +02:00
Mario Vavti
4afd1ac705 add optional $removed argument to channelx_by functions to allow inclusion of removed channels which is required (mod channel, daemon notifier -> refresh_all) if a channel got removed also remove caching to App so we always get a fresh copy. In import_hublocs() add site_id to the array passed to Libzot::gethubs() because it is expected there. 2021-10-03 09:05:32 +02:00
Mario
d556ef59e6 sigh... 2021-10-02 14:09:55 +00:00
Mario
81e972b85c another try on pg test 2021-10-02 14:02:58 +00:00
Mario
3bb04cc323 nope - disable pg test until the issue is resolved 2021-10-02 13:28:35 +00:00
Mario
9ff43f081f another try to fix pg test 2021-10-02 13:23:44 +00:00
Mario
8c014e3b6b see if this fixes pgsql test issue 2021-10-02 13:15:17 +00:00
Mario
d8378a17c9 nav move header outsite of container - fixes app sticking above header when sorting 2021-10-02 13:04:10 +00:00
Mario
574a01727e fix removed channels counted for max id check and disable moving until we decide what to do with it 2021-10-02 12:56:35 +00:00
Mario
b5cea3301d cleanup api_auth and make it fetch the identity if we do not have it cached yet 2021-10-02 12:28:13 +00:00
Mario Vavti
9346a06f35 also check for vnotify 2021-10-01 22:48:09 +02:00
Mario Vavti
250e917c6e only show sse pubs if the app is installed 2021-10-01 22:44:26 +02:00
Mario Vavti
7b1cd37cd6 only bootstrap pubs if the app is installed 2021-10-01 22:30:00 +02:00
Mario Vavti
47e83a15c1 import_progress: deal with the situation where items/files are being imported but there are none to import 2021-10-01 21:52:30 +02:00
Mario
597e847a3b css fixes 2021-10-01 17:17:02 +00:00
Mario Vavti
47f3b41d5e remove redundant notice 2021-10-01 19:15:39 +02:00
Mario Vavti
e7f4c1ffd1 missing template class logic 2021-10-01 18:10:32 +02:00
Mario Vavti
9a87b8bf1b only allow resume if we are not completed yet 2021-10-01 17:24:19 +02:00
Mario Vavti
dac27aab68 remove logging 2021-10-01 17:11:14 +02:00
Mario Vavti
069a5429c9 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-01 17:09:54 +02:00
Mario Vavti
b1eaa810ce improve channel import progress page 2021-10-01 17:09:36 +02:00
Mario
e5e3c268a2 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-10-01 07:14:37 +00:00
Mario
22dff49673 improve file upload performance: start uploading next file only after the previous finished, make sure to not return when uploading via ajax 2021-10-01 07:14:05 +00:00
Max Kostikov
591905c282 Merge branch 'dev' into 'dev'
Fix possible storage conversion stuck on file save error

See merge request hubzilla/core!1988
2021-09-30 20:45:02 +00:00
Mario Vavti
6ed160e4fa wording 2021-09-30 17:50:36 +02:00
Mario Vavti
d462230b82 minor display change 2021-09-30 17:43:29 +02:00
Mario
e48ed9d06d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-09-30 15:38:49 +00:00
Mario Vavti
6236869ebe implement file totals and add mod import_progress 2021-09-30 17:34:30 +02:00
Mario
2c7c9ae2d7 provide files total 2021-09-30 15:33:10 +00:00
Mario Vavti
b9b4e71f7d provide a very simple status page for content import 2021-09-30 12:25:03 +02:00
Mario Vavti
b0bf646d71 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-09-30 12:10:11 +02:00
Mario Vavti
5cb5ecdb54 implement channel purge daemon and send a notifier purge_all message if the xchan was deleted 2021-09-30 12:09:50 +02:00
Mario Vavti
44fa5ac9a1 add channel purge daemon 2021-09-30 12:06:28 +02:00
Max Kostikov
9a19f7eac9 Fix possible storage conversion stuck on file save error 2021-09-29 23:01:27 +02:00
Mario
af0896bb8b a possible fix for the nested list test 2021-09-29 20:57:16 +00:00
Mario
817237ef77 composer update league/html-to-markdown 2021-09-29 20:36:32 +00:00
Mario Vavti
fbefff6eed Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-09-29 21:47:36 +02:00
Mario Vavti
4ba47698d7 revise content import/export part 2 2021-09-29 21:47:12 +02:00
Mario
2688abf25a revise content import/export part 1 2021-09-29 19:43:22 +00:00
Mario
5eb79bd51e importer daemons: do not call with zap_compat flag and use return instead of kill so that queueworker can go on 2021-09-27 21:58:26 +00:00
Mario
d3f5f778a4 cleanup mod import and implement importer daemons ported from zap 2021-09-27 20:49:37 +02:00
Mario
3eeb2b0ee4 add importer daemons ported from zap 2021-09-27 18:37:09 +00:00
Mario
230a1919dd add outbox 2021-09-27 18:36:04 +00:00
Mario
14004fbf7f support un-starring of apps in app bin 2021-09-27 11:13:16 +00:00
Mario
73e8af98f2 fix notification panel collapsed state not saved if closed manually 2021-09-27 07:01:33 +00:00
Mario
0117a0019b make sure to also include ap hublocs here. we will select zot6 later in the function if present 2021-09-26 18:10:34 +00:00
Mario
35ff8781f0 always promote the outbox 2021-09-26 12:15:14 +00:00
Mario
2d17442f28 externals: if dealing with AP profiles also fetch comments. there is no way to fetch conversations later 2021-09-25 10:17:45 +00:00
Mario
5c179522bb bring back externals (slightly different approach), rename zotfeed to outbox for consistency wit AP naming. warning: this commit requires update of addons! 2021-09-25 09:03:16 +00:00
Mario
b35d95da52 dismiss deleted xchans in query 2021-09-25 08:47:39 +00:00
Mario
feca5afaa5 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-09-23 20:43:49 +00:00
Mario
9cb5274d30 add zot6 specific handling to onepoll 2021-09-23 20:43:37 +00:00
Mario Vavti
2870fd46da Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-09-23 21:54:12 +02:00
Mario Vavti
dff8ef91a6 implement the top option in items_fetch 2021-09-23 21:52:27 +02:00
Mario
0588975e37 Ãfix wrong variable name and streamline icon with unseen notifications icon 2021-09-23 14:59:40 +00:00
Mario
e0600b241a make sure we do not mix up likes on direct messages and commments on direct messages in notices 2021-09-23 12:45:55 +00:00
Mario
d19aa8fb3b make sure entries is initialized 2021-09-23 11:17:45 +00:00
Mario
989a4f3d49 add notices tab to HQ widget 2021-09-23 10:42:37 +00:00
Mario
2a2c4d3e9c fix bs regression 2021-09-23 08:50:44 +00:00
Mario
a451449766 Revert "composer update bootstrap to version 5.1.1"
This reverts commit 89e4006b2d.
2021-09-23 08:33:36 +00:00
Mario
3347fab105 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-09-22 16:16:50 +00:00
Mario
33a6c92629 version 2021-09-22 16:16:35 +00:00
Mario
0707d33493 bootstrap update fixes 2021-09-22 16:14:28 +00:00
Mario
89e4006b2d composer update bootstrap to version 5.1.1 2021-09-22 06:38:27 +00:00
Mario Vavti
4eb8921635 improve item_url_replace() - fixes #1507 2021-09-21 11:07:23 +02:00
Mario
26ac452c96 mod manage: do not query info which we do not use in the UI and probably should not due to performance considerations 2021-09-21 07:40:00 +00:00
Mario
7122e1522a perform profile sync after all the fields are updated otherwise we will sync outdated data 2021-09-21 07:33:02 +00:00
Mario
5497adfde6 add option to mark all notices of a thread read if a notice of the thread is clicked (default 1) and fix a php error in find_parent() if $act->obj is not an array 2021-09-18 18:06:32 +00:00
Mario
d4c2e50285 changelog and version 2021-09-16 09:50:08 +00:00
Mario
7ba58208f2 version 6.2.1 and changelog 2021-09-16 08:04:59 +00:00
Mario
cc83677711 Merge branch 'master' of https://framagit.org/hubzilla/core 2021-09-16 07:49:43 +00:00
Mario
c28cce1b54 Merge branch 'dev' 2021-09-16 07:48:13 +00:00
Mario
9052695a13 typo 2021-09-15 11:03:19 +00:00
Mario
46b8db53ab provide a get_cached_actor_provider hook and improve the author/owner handling in Libzot::import() 2021-09-15 10:59:16 +00:00
Mario
0b716b3cc7 fix $desturl set to wrong value (null) 2021-09-13 11:36:41 +00:00
Mario
d115e09abc do not process summary in cleanup_bbcode() fixes issue #1612 2021-09-12 17:54:20 +00:00
Mario
0f803aa3ae when updating the channel name from profiles make sure to lookup the xchan entry by xchan_hash since xchan_url is set to the primary location but we might be updating from a clone
(cherry picked from commit e5dc3c05df)
2021-09-10 14:34:21 +02:00
Mario
e5dc3c05df when updating the channel name from profiles make sure to lookup the xchan entry by xchan_hash since xchan_url is set to the primary location but we might be updating from a clone 2021-09-10 12:29:05 +00:00
Mario
1cfe5c3e16 fix spacing issue for collapsed pinned apps with an image
(cherry picked from commit e2d0269b5c)
2021-09-10 10:12:39 +02:00
Mario
e2d0269b5c fix spacing issue for collapsed pinned apps with an image 2021-09-10 08:11:19 +00:00
Mario
b95c61d2c2 fix language selector reloading the page if not clicking the icon exactly and bs5 modal issues
(cherry picked from commit 7b0f8f2896)
2021-09-08 21:50:25 +02:00
Mario
7b0f8f2896 fix language selector reloading the page if not clicking the icon exactly and bs5 modal issues 2021-09-08 19:48:42 +00:00
Mario
25a81ea500 update release date 2021-09-08 07:50:57 +00:00
Mario
4c5f0a05c7 Merge branch '6.2RC' 2021-09-08 07:43:40 +00:00
Mario
977a55eb84 version 6.2 2021-09-08 07:42:44 +00:00
Mario
8ec001c87b Merge branch 'dev' into 6.2RC 2021-09-07 10:22:07 +00:00
Mario
ddbc55d166 fix mod display regressions 2021-09-07 10:21:02 +00:00
Mario
9a3a0d94ea Merge branch 'dev' into 6.2RC 2021-09-07 09:29:14 +00:00
Mario
1d3a59e0cd resolve some vsprintf issues 2021-09-07 09:26:06 +00:00
Mario
ad7c84eda7 Merge branch 'dev' into 6.2RC 2021-09-07 07:36:53 +00:00
Mario
fe62b245ca update changelog 2021-09-07 07:34:59 +00:00
Mario
6084360588 deprecate the custom highlight [hl] bbcode in favor of [mark] which is a html5 standard 2021-09-07 07:33:36 +00:00
Mario
52995bde12 deprecate the custom highlight [hl] bbcode in favor of [mark] which is a html5 standard 2021-09-07 07:32:49 +00:00
Mario
0f54b26e9d bump version 2021-09-06 19:26:30 +00:00
Mario
2523ebc76a version 6.2RC1 2021-09-06 19:24:45 +00:00
Mario
c1ce211b56 Merge branch 'dev' into 6.2RC 2021-09-06 19:22:39 +00:00
Mario
1aa7826331 strings update 2021-09-06 19:22:04 +00:00
Mario
29a1556541 more changelog 2021-09-06 19:17:24 +00:00
Mario
93f48aa805 update changelog 2021-09-06 19:13:30 +00:00
Mario
95367a8267 if posting from hq return to the message we just posted 2021-09-06 10:19:37 +00:00
Mario
97ef781a0f fix post mail check in Activity::create_note() 2021-09-06 09:38:41 +00:00
Mario
81351d2952 update strings 2021-09-06 09:29:23 +00:00
Mario
8d28649e1b check the post_mail permission for direct messages 2021-09-06 09:10:19 +00:00
Mario
9495fef79b fix anon comments for cards and articles 2021-09-05 11:46:52 +00:00
Mario
de02d4c04b do not save collections in a separate xconfig anymore 2021-09-05 11:16:20 +00:00
Mario
18cd3926d7 omit deleted hublocs in get_actor_hublocs() and use Activity::get_actor_collections() to get collections. Fallback to xconfig->collections if Activity::get_actor_collections() does not return anything yet. 2021-09-05 11:11:51 +00:00
Mario
0e1e1cda7a fix regressions in mod hq 2021-09-04 20:18:59 +00:00
Mario
b3f2374b57 work around some weird regex interference 2021-09-04 19:46:17 +00:00
Mario
793881b9f9 more gen_link_id() 2021-09-04 08:30:04 +00:00
Mario
529824d010 more unpack_link_id() 2021-09-04 08:18:41 +00:00
Mario
c47e21f3a7 refactor actor_store and actor cache part 1 2021-09-04 07:37:49 +00:00
Mario
d83c013bec Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-09-04 07:36:28 +00:00
Mario
17220b2465 implement unpack_link_id() in mod channel 2021-09-04 07:34:09 +00:00
Mario
5dcf053b4c implement strict mode for base64url_decode() and introduce unpack_link_id() 2021-09-04 07:32:01 +00:00
Max Kostikov
a11fe8c6c6 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1987
2021-09-01 20:09:21 +00:00
Max Kostikov
70370407ad Fix index in Russian plurals 2021-09-01 22:05:50 +02:00
Max Kostikov
7973f11cd7 Fix Russian plurals 2021-09-01 22:02:20 +02:00
Max Kostikov
44371c9adf Update Russian translation 2021-09-01 21:36:16 +02:00
Mario
3d40ea7f44 version 2021-09-01 19:33:14 +00:00
Mario
8a3446c021 missing file 2021-09-01 19:31:09 +00:00
Mario
6a8cc313da bump version 2021-09-01 18:33:10 +00:00
Mario
7a1c72d5a4 composer dump autoload 2021-09-01 18:18:57 +00:00
Mario
4e7525c355 version and strings 2021-09-01 18:17:01 +00:00
Mario
e20a2752d6 add an optional force flag to actor_store() 2021-08-30 18:03:54 +00:00
Mario
e25558e24d improve icon lookup 2021-08-30 15:36:12 +00:00
Mario
ada7d4eef5 Merge branch 'owafix' into 'dev'
OWA: very difficult to trace failures due to empty public key record. The...

See merge request hubzilla/core!1986
2021-08-30 11:08:40 +00:00
Mario
3fb4077672 Merge branch 'photodir' into 'dev'
file is stored in wrong directory (/) if uploaded using photo module and it...

See merge request hubzilla/core!1985
2021-08-30 07:56:00 +00:00
Zot
5b73cee0d8 file is stored in wrong directory (/) if uploaded using photo module and it... 2021-08-30 07:56:00 +00:00
nobody
8343f63964 OWA: very difficult to trace failures due to empty public key record. The signature might succeed because an empty key triggers an external key fetch. But the empty key cannot encrypt the token. This has been observed in the wild on a number of sites/projects. 2021-08-29 04:54:50 -07:00
Mario
5532560d07 do not define colors in manifest (system colors are mostly the better fit) and use profile fullname instead of channel_name in nav 2021-08-29 10:51:44 +00:00
Mario
ed277dbda9 more app descriptions and remove some unused images 2021-08-28 17:57:06 +00:00
nobody
2866c0b173 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-08-28 01:09:11 -07:00
Mario
5eaabbdb18 slightly improve push notification handling for HQ and some app descriptions 2021-08-27 18:41:52 +00:00
Mario
d24fbb51fc adjust background color 2021-08-26 18:27:38 +00:00
Mario
6e4c9d684d port latest pwa work from zap 2021-08-26 18:03:17 +00:00
Mario
3ff184f8bb whitespace 2021-08-26 11:57:50 +00:00
Mario
a68b5f9de4 more app descriptions 2021-08-26 10:28:38 +00:00
Mario
d5bf42faf0 Merge branch 'dev' into 'dev'
issue 1599

See merge request hubzilla/core!1984
2021-08-26 08:38:42 +00:00
Zot
88b13658a7 issue 1599 2021-08-26 08:38:41 +00:00
nobody
05152ac8c8 issue 1599 - import_author_zot failing if primary is both dead and unknown 2021-08-25 19:15:46 -07:00
nobody
aa2106f949 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-08-25 19:13:31 -07:00
Mario
6261d0826c db update 1248 to clean up possible bogus entries in xconfig and remove gnusoc from app 2021-08-25 15:54:26 +00:00
Mario
2e7a915ee8 add appstore widget to appman 2021-08-25 10:19:20 +00:00
Mario
0081bafab2 more app descriptions 2021-08-25 08:56:34 +00:00
Mario
64b59b4358 capitalize widget titles 2021-08-25 06:56:45 +00:00
Mario
19f9bbcad4 nav: fix minor display issue and add some code duplication for better readability 2021-08-25 06:37:14 +00:00
Mario
f399528055 more app descriptions and change the image counter to display % of images loaded instead of loaded images count 2021-08-24 18:50:19 +00:00
Mario
fea3980c01 channel manager -> channels 2021-08-24 09:03:09 +00:00
Mario
8804499cb7 channel_menu is not used anymore 2021-08-24 08:41:02 +00:00
Mario
fa1878fda1 nav cleanup 2021-08-24 08:37:51 +00:00
Mario
b129d74a38 affinity needs a version bump to pick up the description 2021-08-23 11:42:53 +00:00
Mario
189da4fdc1 untangle the app template into separate templates and fix bbcode view 2021-08-23 10:32:48 +00:00
Mario
824894baf0 more app descriptions and return to the app if installed from the module itself 2021-08-23 07:59:37 +00:00
Mario
2bd4f7384e more app descriptions 2021-08-22 18:56:04 +00:00
Mario
1c44b37cb0 rename variable 2021-08-22 18:14:16 +00:00
Mario
ab0da7db13 use the slightly altered app_render() function instead of a separate function 2021-08-22 17:55:38 +00:00
Mario
052633d570 improve documentation 2021-08-22 10:13:25 +00:00
Mario
3bb71a6ba8 infrastructure to provide an app install widget for modules and make the bookmark app use it 2021-08-22 09:20:40 +00:00
Mario
7093b66b76 fix typo 2021-08-21 08:30:13 +00:00
Mario
168010a32c remove deprecated forum term type and re-introduce bookmark term type 2021-08-21 08:26:46 +00:00
Mario
6eb84a3d9a restructure apps to make space for app descritions 2021-08-21 08:25:15 +00:00
Mario
69d909596a only redirect to hq if local 2021-08-17 18:37:19 +00:00
Mario
dd296e1aaa more legacy mail cleanup - issue #1595 2021-08-17 18:18:52 +00:00
Mario
c3bbc35e84 more bs5 fixes 2021-08-17 18:07:30 +00:00
Mario
952407363e make sure we have a path before running getimagesize() on it
(cherry picked from commit a2403042c2)
2021-08-17 09:59:03 +02:00
Mario
2deb75de8d remove redundant closing div tag
(cherry picked from commit 87cf2039ad)
2021-08-17 09:58:42 +02:00
Mario
a2403042c2 make sure we have a path before running getimagesize() on it 2021-08-17 07:53:07 +00:00
Mario
87cf2039ad remove redundant closing div tag 2021-08-16 19:36:47 +00:00
Mario
db4109c2a0 streamline default link color 2021-08-15 08:26:11 +00:00
Mario
36564b5aa7 bump version 2021-08-04 14:47:52 +00:00
Mario
101fc33c63 bs5 sets scroll-behavior to smooth which does weird things especially on mobile devices - unset it 2021-08-04 14:46:46 +00:00
Mario
bd2270deb6 app-bin-ng: add a link to the bin for convenience and use the traditional ajax call instead of the post shortcut 2021-08-04 14:13:28 +00:00
Mario
5b72f6f09d fix another bs5 regression 2021-08-04 12:36:20 +00:00
Mario
ee1cec8de2 the default 400px is slightly overkill 2021-08-03 07:35:43 +00:00
Mario
b0a499d8b1 remove logging 2021-08-03 07:17:55 +00:00
Mario
08f70c49f8 Merge branch 'app-bin-ng' into 'dev'
Apps drag and drop feature

See merge request hubzilla/core!1982
2021-08-03 07:12:36 +00:00
Mario
cddc021772 Apps drag and drop feature 2021-08-03 07:12:35 +00:00
Mario
571bae9d1c Merge branch 'ab-dev' into 'dev'
Updated Polish GUI translation

See merge request hubzilla/core!1981
2021-08-03 07:05:45 +00:00
Andrzej Budziński
e01666526e Updated Polish GUI translation according to changes made in version 6.0
/ 6.1 Hubzilla + stylistic fixes and typos.
2021-08-01 03:41:24 +02:00
Mario
562a160a52 remove another possible source for hubloc confusion 2021-07-29 12:29:39 +00:00
Mario
cb57c4ea18 Merge branch 'bs5' into 'dev'
Update to bootstrap 5 and implement next generation app menu (work in progress)

See merge request hubzilla/core!1980
2021-07-29 09:31:47 +00:00
Mario
b7ffec6fbe bs5 border fix 2021-07-29 09:15:18 +00:00
Mario
94be9f115b another badge fix 2021-07-29 09:06:02 +00:00
Mario
693736df7c dropdown-menu-right -> dropdown-menu-end 2021-07-29 09:03:22 +00:00
Mario
943e7dd242 fix notification button class 2021-07-29 08:45:42 +00:00
Mario
c1526b473b bump version 2021-07-29 08:34:33 +00:00
Mario
d459dfac74 update to bootstrap 5.0.2 2021-07-29 08:25:05 +00:00
Mario
cec2f0d894 more work on bs5 2021-07-29 08:19:33 +00:00
Mario
9722d157bf Merge branch 'dev' into bs5 2021-07-29 06:59:13 +00:00
Mario
6bcd24ab90 check if isset before unsetting to omit php errors
(cherry picked from commit c6133d2558)
2021-07-27 21:12:59 +02:00
Mario
c6133d2558 check if isset before unsetting to omit php errors 2021-07-27 19:07:09 +00:00
Mario
ea8d38dec0 version 6.0.1 2021-07-27 07:12:59 +00:00
Mario
0fa41f082d Merge branch 'dev' 2021-07-27 07:11:12 +00:00
Mario
83b1f62e13 more changelog 2021-07-27 07:10:43 +00:00
Mario
b19213b60b Merge branch 'dev' 2021-07-27 07:07:53 +00:00
Mario
3c5b18913f changelog 2021-07-27 07:06:22 +00:00
Mario Vavti
676a65cd61 notifications: move handlers out of jquery ready function otherwise they might not fire on pageload 2021-07-17 14:00:03 +02:00
Mario Vavti
95fb66b433 code style 2021-07-16 13:53:32 +02:00
Mario Vavti
a57529bc54 bump min version 2021-07-16 13:50:38 +02:00
Mario Vavti
4f15c08805 more work on moving notifications handling from main.js to the notifications widget 2021-07-16 13:48:35 +02:00
Mario Vavti
7b2f4b0814 fix a regression in regard to unified session page load times intoduced in 6.0 2021-07-16 12:56:57 +02:00
Mario Vavti
3051e2c268 redirect to the local item instead of the item at the primary location if we deal with a wall item 2021-07-16 12:04:31 +02:00
Mario
d7489e3913 Merge branch 'dev' into 'dev'
Fix link to source on clones

See merge request hubzilla/core!1975
2021-07-16 09:46:08 +00:00
Mario Vavti
62606bf006 photo upload: always show the textarea so that text and tags can be added even if no status post is sent 2021-07-16 11:42:54 +02:00
Max Kostikov
c68f2bc2d1 Fix link to source on clones 2021-07-16 11:12:32 +02:00
Mario Vavti
f5669c9935 chanview: dismiss xchans which are marked deleted 2021-07-15 12:07:54 +02:00
Mario Vavti
9e2bdb012e fix release date 2021-07-09 12:02:50 +02:00
Mario Vavti
d8ac25c35a version 6.0 2021-07-09 11:33:19 +02:00
Mario Vavti
2dd47a9f59 Merge branch '6.0RC' 2021-07-09 11:31:26 +02:00
Mario Vavti
a92ad512bb Merge branch 'dev' into 6.0RC 2021-07-08 13:36:06 +02:00
Mario Vavti
e39b29cc4b set touch_max to 1/10 of the screen width to prevent overlaping with cursor positioning 2021-07-08 13:35:28 +02:00
Mario
76ed9f3915 typo 2021-07-08 13:23:49 +02:00
nobody
73b53675b1 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-07-06 05:02:52 -07:00
Mario Vavti
fd6ec17d4b version rc1 2021-07-05 10:55:10 +02:00
Mario Vavti
8de364c83e Merge branch 'dev' into 6.0RC 2021-07-05 10:54:29 +02:00
Mario Vavti
9b9ac5054f changelog 2021-07-05 10:54:03 +02:00
Mario Vavti
9efea4e188 Merge branch 'dev' into 6.0RC 2021-07-05 10:51:31 +02:00
Mario Vavti
d45df824ed redbasic: close left aside if hq control button is clicked 2021-07-05 10:42:36 +02:00
Mario Vavti
50ead82bc4 remove redundant z-index 2021-07-04 14:05:48 +02:00
Mario Vavti
c43f501716 ux fixes 2021-07-04 13:57:20 +02:00
Mario Vavti
86d471834e do not call stickyScroll() on small screens - it is not functional 2021-07-03 14:52:00 +02:00
Mario Vavti
a1f7f7a966 since position sticky has no effect if overflow is hidden and the workarounds also have issues, we will automatically scroll to top when left aside is brought in 2021-07-03 14:36:27 +02:00
Mario Vavti
081d82218b implement a very simple swipe mechanism for bringing in left aside 2021-07-03 14:27:55 +02:00
Mario Vavti
cca3eb8c56 work around the fact that sticky does not stick if a parent element has set overflow to hidden 2021-07-02 17:49:03 +02:00
Mario Vavti
933c097a52 changelog typos 2021-07-02 16:46:49 +02:00
Mario Vavti
f5912e05ef do not use summary in photo object 2021-07-02 16:37:50 +02:00
Mario Vavti
e94eb1af0c remove mail and conv tables from install SQL schemas 2021-07-02 16:13:48 +02:00
Mario Vavti
0ab7996a2a update changelog 2021-07-02 16:07:31 +02:00
Mario
faeec0b77b revert ebc84eab3f instead be more picky about the xchan in handle_tag() 2021-07-02 07:23:18 +00:00
Mario Vavti
ebc84eab3f update by xchan_url to catch all associated entries 2021-07-01 22:30:29 +02:00
Mario
b560b6fbd3 Merge branch 'dev' into 6.0RC 2021-07-01 09:27:14 +00:00
Mario
c6b3bc5b20 redbasic: bump version limits 2021-07-01 09:26:20 +00:00
Mario
e31cb28b08 Merge branch 'dev' into 6.0RC 2021-07-01 07:44:51 +00:00
Mario
458fa7bfeb port fixes from as_actor_store() 2021-06-30 19:04:42 +00:00
Mario
fab3f0f2de fix RC version after last merge 2021-06-30 12:06:55 +00:00
Mario
c8d9238c58 missing composer file 2021-06-30 09:11:07 +00:00
Mario
5aa79caf84 bump dev version to 6.1 2021-06-30 07:25:23 +00:00
Mario
12cabbde9e update sbom 2021-06-30 07:19:38 +00:00
Mario
ca3ab2014f update composer autoload 2021-06-30 07:19:16 +00:00
Mario
3e6283a262 strings update 2021-06-30 07:11:44 +00:00
Mario
bc0d0a6b39 version 6.0RC 2021-06-30 07:07:58 +00:00
Mario
6a4727e3eb fix variable name 2021-06-29 18:21:12 +00:00
Mario
ff6d1c808d version 2021-06-29 09:54:13 +00:00
Mario
197d15b7de only remove elements after the delete has happened 2021-06-29 09:53:40 +00:00
Mario
bb5f6a1d79 tools -> features 2021-06-29 09:40:34 +00:00
Mario
e8c6121b4e version 2021-06-29 09:24:13 +00:00
Mario
bed81d785c an attempt to improve the query for direct messages on some systems with hopefully no bad side-effect for others 2021-06-29 09:22:38 +00:00
Mario
0503914527 fix deleting and starring in unthreaded view 2021-06-29 08:45:48 +00:00
Mario
cb65ae6848 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-06-29 07:49:34 +00:00
Mario
652d083766 implement removing of notifications/preview-messages of deleted items 2021-06-29 07:49:19 +00:00
Mario
091d9c10fb Merge branch 'clean-up' into 'dev'
mod network clean-up

See merge request hubzilla/core!1974
2021-06-29 07:15:44 +00:00
Xanthor
835fe10bfe mod network clean-up 2021-06-29 07:15:42 +00:00
Mario
5a474f94e0 fix query logic 2021-06-29 05:45:05 +00:00
Mario
d322feeb54 more deprecate legacy zot 2021-06-28 08:37:05 +00:00
Mario
842c7b31fb Merge branch 'fix' into 'dev'
fix call to prepare_body

See merge request hubzilla/core!1973
2021-06-28 06:55:47 +00:00
Michael Johnston
1034f02d4d fix call to prepare_body 2021-06-28 06:55:47 +00:00
Mario
3f6b6dfaf3 fix regression in relation with recent photo changes 2021-06-27 15:20:06 +00:00
Mario
d3d4dee36a version 2021-06-27 13:57:57 +00:00
Mario
7002248325 update 1247 to clean up bogus entries in updates. this only affects directory servers. 2021-06-27 13:57:18 +00:00
Mario
d8d0f01f80 bump version 2021-06-27 13:46:10 +00:00
Mario
b3b842c071 update 1246 to flag legacy zot hublocs and xchans deleted. we will set the deleted flag to 2 so we can distinguish them from real deletes if necessary 2021-06-27 13:45:06 +00:00
Mario
aca8d1b8f9 bump version 2021-06-25 11:00:36 +00:00
Mario
4f328740dc more work on notifications 2021-06-25 10:53:37 +00:00
Mario Vavti
2f1c2f42b1 check if empty 2021-06-25 08:47:05 +02:00
Mario
d42a998e49 strip html tags from notification message 2021-06-25 06:24:46 +00:00
Mario
167db22e15 slightly refactor for desktop notifications and fix minor issues 2021-06-24 19:31:19 +00:00
Mario
108777251e some preperatory work on desktop notifications 2021-06-24 11:27:51 +00:00
Mario
088713a555 Notification.requestPermission() only fires if wraped in click handler 2021-06-24 08:15:44 +00:00
Mario
7582ebc9c8 remove deprecated dir and queue fns 2021-06-24 07:08:12 +00:00
Mario Vavti
97d9764f01 if there are no messages display that there are no messages 2021-06-23 22:14:01 +02:00
Mario Vavti
dfcd8395d5 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-06-23 21:15:26 +02:00
Mario
6e91bee0ba some work on streamlining mod photos 2021-06-23 15:52:04 +00:00
Mario Vavti
cf791a1909 libzotdir: make sure we have the relevant data before string into updates 2021-06-23 17:09:45 +02:00
Mario
c6d872d177 jot: do not collapse the form if in popup mode 2021-06-23 07:39:20 +00:00
Mario
cc4f3a827c streamline jot popup for mod hq 2021-06-21 18:45:33 +00:00
Mario
0489fbb685 theme: slightly more transparency for the backdrop 2021-06-21 18:21:19 +00:00
Mario
7da23603ec fiÃlter children by tt-filter-active class instead of visibility selector to omit reload loop in mobile view where notifications ar not visible while off-canvas 2021-06-21 18:07:19 +00:00
Mario
afb4ae2109 Merge branch 'dev' into 'dev'
Clean up Search.php & Enotify.php code

See merge request hubzilla/core!1972
2021-06-21 17:42:57 +00:00
Xanthor
e024375b15 Clean up Search.php & Enotify.php code 2021-06-21 17:42:56 +00:00
Mario
3632fb359f calendar: emit a warning if the calendar for the created event is disabled 2021-06-21 07:52:47 +00:00
Mario
2a3ba5d5f0 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-06-20 08:25:41 +00:00
Mario
5b9dc764c5 make sure to not calculate timeago before the translations are loaded 2021-06-20 08:25:29 +00:00
Max Kostikov
24a0d4f308 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1970
2021-06-19 18:06:49 +00:00
Max Kostikov
88f5b10b22 Update Russian translation 2021-06-19 20:00:52 +02:00
Mario
cf69859885 one more place to drop media 2021-06-18 10:12:08 +00:00
Mario
af71f7f8cd remove notes from network pdl - it is now located in HQ 2021-06-18 10:06:42 +00:00
Mario
ec22ca7553 css and js fixes 2021-06-18 09:58:00 +00:00
Mario
c42d8a81c7 bbcode: add option to drop media content 2021-06-18 09:51:20 +00:00
Mario
0e7473c3ba more css improvements 2021-06-18 08:59:22 +00:00
Mario
f4f9ccc3b2 css fixes 2021-06-18 08:55:49 +00:00
nobody
efda8aac1d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-06-17 14:57:47 -07:00
Mario
a84cec4acd fix wrong class and bump version 2021-06-17 12:21:39 +00:00
Mario
cf6b7a4236 whitespace 2021-06-17 12:13:40 +00:00
Mario
998f46b45c update hq_controls widget pdl 2021-06-17 12:12:50 +00:00
Mario
5ca352a6c3 allow to add a wrapper class to the hq_controls widget 2021-06-17 12:10:54 +00:00
Mario
a34bd3b013 fix issue where notifications were not loaded if a filter was applied 2021-06-17 11:21:59 +00:00
Mario
c268bc327a fix issues with browser back button and minor cleanup 2021-06-17 10:14:23 +00:00
Mario
e79a27c654 just use ... as preview if we could not wind anything useful 2021-06-17 08:08:14 +00:00
Mario
2f0bac8ddf consolidate notifications strings 2021-06-17 08:06:26 +00:00
Mario
12d7d1c3f0 fix wrong variable 2021-06-17 07:50:16 +00:00
Mario
34ca2cddd4 only show notes if the app is enabled 2021-06-17 07:43:32 +00:00
Mario
fa076efd3b Merge branch 'dm' into 'dev'
New landing page HQ with separate views for direct messages, public/limited messages and starred messages if the feature is enabled

See merge request hubzilla/core!1969
2021-06-17 07:33:46 +00:00
Mario
b55676d089 New landing page HQ with separate views for direct messages, public/limited messages and starred messages if the feature is enabled 2021-06-17 07:33:45 +00:00
Mario
9b71c090c5 Merge branch 'translation-pl' into 'dev'
Translation pl - generated new util/hmessages.po, translated new strings + few fixes

See merge request hubzilla/core!1968
2021-06-17 07:33:15 +00:00
Mario
0f8e4e4eed Merge branch 'dev' into 'dev'
Fix email local part validation

See merge request hubzilla/core!1967
2021-06-17 07:30:57 +00:00
Andrzej Budziński
de1e3d7b17 Polish translation: fixes 2021-06-13 02:30:27 +02:00
Andrzej Budziński
3d077a0bc6 Generated new util/hmesages.po + new Polish translations 2021-06-12 03:16:09 +02:00
Andrzej Budziński
c74d1f4bf7 Polish translation: a little fixes 2021-06-10 23:47:27 +02:00
Andrzej Budziński
776e1211bc fixes in .gitignore file 2021-06-10 23:39:22 +02:00
Max Kostikov
b5a8ca6ef7 Merge branch 'translation-pl' into 'dev'
Polish translation: some fixes

See merge request hubzilla/core!1966
2021-06-10 08:11:20 +00:00
Max Kostikov
2c198ed89a Remove unnecessary parentheses 2021-06-09 12:53:55 +02:00
Max Kostikov
17fdeb9e1f Fix email local part validation 2021-06-09 11:06:12 +02:00
Mario Vavti
e41858f57c remove redundant arg 2021-06-09 09:45:25 +02:00
Mario
219d47f04c bs5: more fixes 2021-06-07 18:38:54 +00:00
Mario
750721c1a0 bs5: minor fix 2021-06-07 14:12:30 +00:00
Mario
b66b43256b bs5: more notifications fixes 2021-06-07 13:21:44 +00:00
Mario
58cacaff06 bs5: more notifications work 2021-06-07 12:37:12 +00:00
Mario
9aebb01d62 bs5: notifications work 2021-06-07 14:10:57 +02:00
Mario
f3b4308cb5 upgrade to bootstrap 5.0.1 and first batch of fixes 2021-06-07 12:56:27 +02:00
Andrzej Budziński
12089e127a Polish Translation: a little fixes 2021-06-05 21:37:29 +02:00
Andrzej Budziński
c75b8711b1 Polish Translation: a little fixes 2021-06-05 20:43:49 +02:00
Mario
67322c1264 more work on directory sync 2021-06-05 18:40:23 +00:00
Mario
607f0346f4 version 2021-06-05 10:14:08 +00:00
Mario
d5bb34f65d composer update symfony/polyfill-ctype 2021-06-05 09:42:45 +00:00
Mario
3e18efd89f composer update psr/log 2021-06-05 09:38:58 +00:00
Mario
bec3cb48e5 composer update commerceguys/intl to version 1.1.0 2021-06-05 09:34:18 +00:00
Mario
e8d2819c42 fix test 2021-06-05 09:17:51 +00:00
Mario
cc85c2f4d7 composer update commerceguys/intl 2021-06-05 09:11:39 +00:00
Mario
bee4fa9937 missing use statement 2021-06-05 09:06:09 +00:00
Mario
14ab5801d2 league/html-to-markdown suports tables now 2021-06-05 08:55:32 +00:00
Mario
fd8a5ff4c4 composer update league/html-to-markdown 2021-06-05 08:47:24 +00:00
Andrzej Budziński
ef9ae0db94 Polish translation: some fixes 2021-06-05 10:45:09 +02:00
Mario
4db384da34 composer update smarty 2021-06-05 08:32:34 +00:00
Mario
0784d2ea4e Merge branch 'dev' into six 2021-06-05 07:52:43 +00:00
Mario
b90db6931d Merge branch 'dev' into 'dev'
Changed behavior in the user interaction of the languages selection. Now works...

See merge request hubzilla/core!1952
2021-06-05 07:51:38 +00:00
Hilmar Runge
25497336bb Changed behavior in the user interaction of the languages selection. Now works... 2021-06-05 07:51:38 +00:00
Mario
a0ee9557f0 Merge branch 'translation-pl' into 'dev'
The Polish translation: ixes and new doc translation

See merge request hubzilla/core!1965
2021-06-05 07:50:50 +00:00
Mario
7b3eb09067 Merge branch 'dev' into six 2021-06-05 07:48:44 +00:00
Andrzej Budziński
1fc3be0c9f Polish translation:
Final fixes in 'view/pl/hmessages.po' + 'docs/pl'.
The Polish translation of Habzill's and Zap's GUI is consistent.
The most important articles of the documentation are also translated
Quality improvements to the documentation remain to be made, including the writing of new articles
(guides).
2021-06-04 23:35:49 +02:00
Mario
6de327402b version 5.6.1 2021-06-04 11:27:09 +02:00
Mario
131ce826c3 Merge branch 'dev' 2021-06-04 11:10:37 +02:00
Mario
a3f4ad9ea0 fix es plural return 2021-06-04 11:10:14 +02:00
Mario
ec3b1131d9 changelog 2021-06-04 11:08:55 +02:00
Mario
74c0345009 Merge branch 'dev' 2021-06-04 10:26:17 +02:00
Mario
628b03da29 fix css issue 2021-06-04 10:25:36 +02:00
Mario
bd59fb0b4e Merge branch 'dev' 2021-06-04 10:09:22 +02:00
mjfriaza
443b436be8 Update Spanish
(cherry picked from commit 993d648011)
2021-06-04 07:52:45 +00:00
mjfriaza
993d648011 Update Spanish 2021-06-04 07:51:53 +00:00
Mario
343f3059e6 fix login name label for the case when system.verify_email is disabled
(cherry picked from commit e44bf42c64)
2021-06-04 07:48:25 +00:00
Mario
10f8fe8973 use uuid for hash 2021-06-04 07:46:36 +00:00
Mario
e44bf42c64 fix login name label for the case when system.verify_email is disabled 2021-06-04 07:45:33 +00:00
Mario
3d1684fa94 Revert "fix login name label for the case when system.verify_email is disabled"
This reverts commit d882bad706.
2021-06-04 07:44:37 +00:00
Mario
d882bad706 fix login name label for the case when system.verify_email is disabled 2021-06-04 07:43:23 +00:00
nobody
686530c187 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-06-03 16:01:16 -07:00
Mario Vavti
e5c8273f72 Merge branch 'six' of https://framagit.org/hubzilla/core into six 2021-06-03 11:00:39 +02:00
Mario Vavti
440f7bacd6 directory improvements 2021-06-03 10:59:12 +02:00
Mario
ba22d3e9b6 fix issue where a deleted channel will return 404 before returning zotinfo
(cherry picked from commit 33463152e8)
2021-06-02 18:13:48 +00:00
Mario
33463152e8 fix issue where a deleted channel will return 404 before returning zotinfo 2021-06-02 17:58:46 +00:00
Mario
657af3024e Merge branch 'dev' into 'dev'
Make pubstream ordering configurable

See merge request hubzilla/core!1964
2021-06-02 08:33:55 +00:00
Max Kostikov
7d82a34538 Make pubstream ordering configurable 2021-06-02 08:33:54 +00:00
Mario
a0b788e96a fix article summary duplicated when editing - issue #1577
(cherry picked from commit 50c14d353b)
2021-06-02 08:32:41 +00:00
Mario
50c14d353b fix article summary duplicated when editing - issue #1577 2021-06-02 08:31:43 +00:00
Mario Vavti
b63aa3079b fix regression where authors from non zot6, activitypub networks got dismissed (e.g. relayed diaspora comments)
(cherry picked from commit b3df15a3c6)
2021-06-02 07:52:40 +00:00
Mario
25be24e6b8 Merge branch 'six' of https://framagit.org/hubzilla/core into six 2021-06-02 07:44:36 +00:00
Mario Vavti
2ec2da5dff Merge branch 'six' of https://framagit.org/hubzilla/core into six 2021-06-02 09:42:27 +02:00
Mario Vavti
b3df15a3c6 fix regression where authors from non zot6, activitypub networks got dismissed (e.g. relayed diaspora comments) 2021-06-02 09:41:57 +02:00
mjfriaza
481ecee9e8 Update Spanish 2021-06-01 11:57:11 +02:00
nobody
462980c70a Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-05-31 14:36:14 -07:00
Max Kostikov
2171686284 Merge branch 'translation-pl' into 'dev'
New traslations: view/pl/invite* files + some fixes

See merge request hubzilla/core!1963
2021-05-31 18:29:38 +00:00
Andrzej Budziński
b382edc61d Fixes to docs/pl/about/about.bb 2021-05-31 18:07:16 +02:00
Andrzej Budziński
5ae21d04b0 New traslations: view/pl/invite* files + some fixes 2021-05-31 13:39:11 +02:00
Mario
b0825ead84 Merge branch 'dev' into six 2021-05-31 11:33:47 +00:00
Mario
2980f852aa fix admin button state not displayed correctly
(cherry picked from commit baabb3a873)
2021-05-31 11:32:09 +00:00
Mario
5e07ebe7fa fix registration bug - issue #1574 2021-05-31 09:07:50 +00:00
Mario
baabb3a873 fix admin button state not displayed correctly 2021-05-31 10:14:26 +02:00
Mario
5ee1c3f2c8 include items.php in boot since it is required almost everywhere 2021-05-31 10:03:34 +02:00
Mario
3fe2a2b181 do not overwrite the original rawmsg iconfig that came with the item 2021-05-31 07:12:36 +00:00
Mario
3d2b923102 notifier fixes 2021-05-29 06:20:28 +00:00
Mario
43c941d370 fix notifier for non-zot hublocs 2021-05-28 20:15:34 +00:00
Mario
e1721b8496 remove masto hack - it does not make sense in threaded view 2021-05-28 20:14:15 +00:00
Mario
ccf3ed185f remove mod ping 2021-05-28 17:18:03 +00:00
Mario
99af27770e Merge branch 'dev' into six 2021-05-28 10:16:34 +00:00
Mario
e9088bd52e notifications: if we have to return early, make sure to set offset to -1 to prevent looping
(cherry picked from commit f72b8ce30f)
2021-05-28 10:13:25 +00:00
Mario
f72b8ce30f notifications: if we have to return early, make sure to set offset to -1 to prevent looping 2021-05-28 10:02:05 +00:00
Mario
19bb96121b move mark notifications read code to mod notifications 2021-05-28 09:58:18 +00:00
Mario
69ef7cf168 remove more mail leftovers 2021-05-28 08:42:08 +00:00
Mario
f1aace5a22 remove unobscure() 2021-05-28 08:28:32 +00:00
Mario
0718ac514d remove deprecated mail code 2021-05-28 08:11:40 +00:00
Mario
d289994da4 missing include 2021-05-28 07:22:49 +00:00
Mario
30f258b3f9 add check for type 2021-05-28 07:19:49 +00:00
Mario
d06d22c7c9 bump version 2021-05-27 20:06:22 +00:00
Mario
57c301d59c composer dump autoload 2021-05-27 19:58:34 +00:00
Mario
4bde2f64bd remove zot 2021-05-27 19:55:06 +00:00
Mario
8ca487115f remove include/msglib 2021-05-27 19:50:53 +00:00
Mario
7ad0a1e557 remove include/message (the file) 2021-05-27 19:50:35 +00:00
Mario
1aa626f0e8 remove include/message 2021-05-27 19:49:44 +00:00
Mario
7e36d17135 remove include/zot 2021-05-27 19:48:19 +00:00
Mario
2f7e875eb4 remove mod post 2021-05-27 19:45:34 +00:00
Mario
3ab8632d3b update mail widgets to not require include message and minor fixes 2021-05-27 19:20:07 +00:00
Mario
190fc4e3c4 fix typo 2021-05-27 17:44:24 +00:00
Mario
3eb1b9d168 remove reply_message_request(), implement force_refresh and minor fixes 2021-05-27 17:42:28 +00:00
Mario
2fb3d6ddf5 remove zot6/finger 2021-05-27 15:40:28 +00:00
Mario
bf74a75303 bump version 2021-05-27 12:25:23 +00:00
Mario
7d1b240954 fix typo 2021-05-27 12:07:29 +00:00
Mario
2db3e4ca48 fix test 2021-05-27 11:49:09 +00:00
Mario
cee2e63278 fix typo 2021-05-27 11:30:27 +00:00
Mario
9d5732400f remove mod message 2021-05-27 11:21:30 +00:00
Mario
3cb0613d04 mising use statement 2021-05-27 11:16:29 +00:00
Mario
d9920fce3a missing include 2021-05-27 11:10:09 +00:00
Mario
2765a0a9fd missing includes 2021-05-27 10:50:53 +00:00
Max Kostikov
92ea7fcfb1 Merge branch 'translation-pl' into 'dev'
Next fixes to Polish translation

See merge request hubzilla/core!1962
2021-05-27 10:05:30 +00:00
Mario
9d96793e1a update fresh 2021-05-27 09:48:50 +00:00
Mario
7776283a47 remove zot includes 2021-05-27 09:45:39 +00:00
Mario
c9d4802bf1 Ãremove queue_fn includes 2021-05-27 09:33:22 +00:00
Mario
37558e24f8 remove dir_fns includes 2021-05-27 09:30:57 +00:00
Mario
67cf9f6caf deprecate find_upstream_directory() 2021-05-27 09:22:38 +00:00
Mario
16146af039 deprecate remove_queue_by_posturl() 2021-05-27 09:18:46 +00:00
Mario
6a7e06f11c deprecate get_rpost_path() 2021-05-27 09:09:52 +00:00
Mario
adba56a5e5 remove mod events 2021-05-27 08:55:52 +00:00
Mario
90c9fc5338 deprecate import_xchan() 2021-05-27 08:39:23 +00:00
Mario
0a09f507fc remove zping 2021-05-27 08:30:00 +00:00
Mario
9ea60ba79f deprecate make_xchan_hash() 2021-05-27 08:27:33 +00:00
Mario
43ef82aaaa remove zfinger 2021-05-27 08:19:22 +00:00
Mario
7171d790f4 import Lib/Queue as LibQueue 2021-05-27 08:02:54 +00:00
Mario
4099549609 remove deprecated rating code 2021-05-27 07:58:56 +00:00
Mario
4e4bffe5c5 deprecate queue_deliver() 2021-05-27 07:52:18 +00:00
Mario
1c8000d026 remove more legacy zot quirks 2021-05-26 19:02:13 +00:00
Mario
ff34a787c3 php8: more id3 parser fixes 2021-05-26 18:02:29 +00:00
Mario
84c5f57d22 php8: more id3 parser fixes 2021-05-26 17:54:07 +00:00
Andrzej Budziński
64181c7cf1 Next fixes. It already looks very nice, but it's not end work yet for
this translation.
2021-05-26 17:15:09 +02:00
Mario
3c5f840cf0 typo 2021-05-26 12:29:15 +00:00
Mario
1fa4bc9ac0 remove most legacy zot quirks 2021-05-26 12:18:59 +00:00
Mario
b742910107 remove legacy zot from supported protocols 2021-05-26 11:28:33 +00:00
Mario
b7f124072f import_author_xchan(): do not import legacy zot 2021-05-26 11:25:36 +00:00
Mario
ec02eda113 handle_tag(): only use xchans with xhchan_deleted = 0 2021-05-26 09:36:13 +00:00
Mario
8d8523684c more id3parser 2021-05-26 08:51:35 +00:00
Max Kostikov
8a0c7b3fe1 Merge branch 'translation-pl' into 'dev'
Updating translatons strings + fixes to Polish translation

See merge request hubzilla/core!1961
2021-05-25 15:01:33 +00:00
Mario
a29dbaba21 disable mod post for now 2021-05-25 12:17:45 +00:00
Mario
51ad4fac01 php8: even even more fix unmaintained id3 parser 2021-05-25 12:08:58 +00:00
Mario
d863ba1b2a syntax error 2021-05-25 12:04:32 +00:00
Mario
175001eccd php8: even more fix unmaintained id3 parser 2021-05-25 11:47:26 +00:00
Mario
846d99cfce php8: more fix unmaintained id3 parser 2021-05-25 11:24:16 +00:00
Mario
2486a9c914 php8: fix un maintained id3 parser 2021-05-25 11:15:22 +00:00
Mario
a47a81db6f more notifier work 2021-05-25 11:13:13 +00:00
Andrzej Budziński
587e790892 Regenerating hstrings.ph file 2021-05-24 18:37:53 +02:00
Andrzej Budziński
f73a83aa55 Next fixes and generating new hstrings.php file 2021-05-24 17:18:13 +02:00
Andrzej Budziński
513cf2b8e2 Updating translation strings (v. 5.7) + fixes to Polish translation 2021-05-23 23:51:27 +02:00
Mario
ea215697ed remove location command from notifier 2021-05-23 20:36:00 +00:00
Mario
d40686e5d0 remove request command from notifier 2021-05-23 20:31:03 +00:00
Mario
0b7d343c7c remove mail and some hubzilla < 5.0 quirks from notifier 2021-05-23 20:10:43 +00:00
Mario
d692ed634a some cleanup 2021-05-23 19:44:37 +00:00
Mario Vavti
7d4e07df79 AccessList::is_private() does not return info about the private state (1 or 2). Use the info from the parent item until this will be sorted out 2021-05-23 19:17:09 +02:00
Mario
8211bc09d4 remove todo since the zot6 xchan should be merely imported in this case. also only return if we already have a result. 2021-05-21 06:54:37 +00:00
Mario
5705005ca3 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-05-21 06:44:21 +00:00
Mario
79b4642b32 introduce the direct flag for direct messages 2021-05-21 06:44:15 +00:00
Mario
c9981ff0e1 Merge branch 'Malend-dev-patch-02229' into 'dev'
Remove useless test

See merge request hubzilla/core!1957
2021-05-21 06:38:40 +00:00
Mario
0948b061fe Merge branch 'Malend-dev-patch-19605' into 'dev'
Fix phpDoc

See merge request hubzilla/core!1958
2021-05-21 06:37:33 +00:00
Mario
a537e78f14 Merge branch 'cherry-pick-a7a47275' into 'master'
Merge branch 'dev' into 'dev'

See merge request hubzilla/core!1960
2021-05-20 13:40:47 +00:00
Max Kostikov
25edeebf2b Merge branch 'dev' into 'dev'
Fix updated variables in member verificaton template

See merge request hubzilla/core!1959

(cherry picked from commit a7a4727591)

bc2afb21 Fix updated variables
2021-05-20 12:40:54 +00:00
Max Kostikov
a7a4727591 Merge branch 'dev' into 'dev'
Fix updated variables in member verificaton template

See merge request hubzilla/core!1959
2021-05-20 12:33:03 +00:00
Max Kostikov
bc2afb21e1 Fix updated variables 2021-05-20 12:29:37 +00:00
Mario
64fe93b9eb Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-05-20 10:15:08 +00:00
Mario
33d2a852c9 make sure to set the correct item_private state 2021-05-20 10:14:49 +00:00
Malendur
300679c053 Fix phpDoc 2021-05-20 08:23:45 +00:00
Malendur
f9c85c52f3 Remove useless test 2021-05-20 08:14:58 +00:00
Max Kostikov
98985b2761 Merge branch 'dev' into 'dev'
Fix security headers switching

See merge request hubzilla/core!1953
2021-05-19 23:30:39 +00:00
Mario
8fe00d428d bring back the channel_protocols hook 2021-05-19 17:47:26 +00:00
Max Kostikov
02229482b8 Fix security headers switching 2021-05-17 22:30:47 +02:00
Mario
9a5c1aa02f there might be errors in cli without this 2021-05-17 09:42:29 +00:00
Mario
a46e340a13 Ãmake sure we do not deal with diaspora hublocs here 2021-05-17 09:09:24 +00:00
Mario
70c3cd99ac Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-05-15 13:21:22 +00:00
Mario
e89bbde575 add zid and delegate parameters to the bdest string so that we will be authenticated when being redirected offsite 2021-05-15 13:21:07 +00:00
Mario Vavti
2ee1e2af72 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-05-15 15:16:05 +02:00
Mario Vavti
c3ad21c548 make sure we do not mess up the query string when removing single parameters 2021-05-15 15:15:48 +02:00
Mario
635a24dff4 Merge branch 'dev' into 'dev'
Random PHP 8 fixes

See merge request hubzilla/core!1951
2021-05-14 08:56:07 +00:00
Max Kostikov
a03423794a Random PHP 8 fixes 2021-05-14 08:56:06 +00:00
Mario
d4e723a8eb fix regression in regard to menu wrapping
(cherry picked from commit ded9f18b8a)
2021-05-12 08:00:59 +00:00
Mario
ded9f18b8a fix regression in regard to menu wrapping 2021-05-12 07:56:30 +00:00
Mario
3a2e5d480c update include/items.php 2021-05-11 12:14:44 +00:00
Mario
26e851ff7f Merge branch '5.6RC' 2021-05-11 11:59:49 +00:00
Mario
89ec043ce1 version 5.6 2021-05-11 11:58:16 +00:00
Mario
98f0272a84 Merge branch '5.6RC' of https://framagit.org/hubzilla/core into 5.6RC 2021-05-11 11:57:22 +00:00
Mario
0933925a2b Merge branch 'dev' into 5.6RC 2021-05-11 11:57:13 +00:00
Mario
e92929fce4 changelog 2021-05-11 11:56:54 +00:00
Mario
f388412c48 id should be intval here
(cherry picked from commit 836de7f1a5)
2021-05-10 09:07:59 +00:00
Mario
836de7f1a5 id should be intval here 2021-05-10 09:05:27 +00:00
Mario
43008aa42b Merge branch '5.6RC' of https://framagit.org/hubzilla/core into 5.6RC 2021-05-08 08:44:29 +00:00
Mario
7618d8301a 5.6RC3 2021-05-08 08:44:13 +00:00
Mario
09cfc979e4 Merge branch 'dev' into 5.6RC 2021-05-08 08:43:00 +00:00
Mario
00fc5541db remove redundant placeholder in query
(cherry picked from commit 954d06bdb7)
2021-05-08 08:29:56 +00:00
Mario
954d06bdb7 remove redundant placeholder in query 2021-05-08 08:29:04 +00:00
Mario
12828ee4d4 update 1245 to fix hubloc_hash index for postgres
(cherry picked from commit c2e007a839)
2021-05-07 18:47:06 +00:00
Mario
c2e007a839 update 1245 to fix hubloc_hash index for postgres 2021-05-07 15:02:55 +00:00
Mario
605bf3b9d3 register: postgres - add default values for timestamps
(cherry picked from commit ebd0333256)
2021-05-07 12:15:56 +00:00
Mario
ebd0333256 register: postgres - add default values for timestamps 2021-05-07 12:15:00 +00:00
Mario
d7dcf192c7 remove logging
(cherry picked from commit 2ad6f6e11f)
2021-05-07 11:09:09 +00:00
Mario
2ad6f6e11f remove logging 2021-05-07 11:08:40 +00:00
Mario
36a814b03e version 5.6RC2 2021-05-07 11:03:59 +00:00
Mario
92bc99a805 strings 2021-05-07 11:02:21 +00:00
Mario
b5ce207344 register: implement remove_expired_registrations() and minor fixes 2021-05-07 10:03:12 +00:00
Mario
d04ff264fa register: fix minor string issue 2021-05-07 08:26:59 +00:00
Mario
9ad2b017e2 register: fix language issue and add additional info to the infobox if email verification is configured 2021-05-07 08:15:06 +00:00
Mario
1fd5f5c893 register: redirect unverified registration emails to the verification form 2021-05-06 19:06:53 +00:00
Mario
43260891b7 register: we have already checked for existing email in check_account_email() 2021-05-06 13:54:02 +00:00
Mario
aef0350346 remove duplicate singletons hublocs once a day 2021-05-05 09:15:02 +00:00
Mario
83fbb0678c use hubloc_hash instead of hubloc_id_url - otherwise it will bite hublocs which use more than one protocol 2021-05-05 08:50:03 +00:00
Mario
df3778c64f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-05-05 08:36:43 +00:00
Mario
0dc09ea238 possible minor performance improvement 2021-05-05 08:36:18 +00:00
Max Kostikov
f085c3c98f Merge branch 'translation-pl' into 'dev'
Fixes related to correction plural expression, plus typos and some other

See merge request hubzilla/core!1950
2021-05-02 12:17:13 +00:00
Mario
8d4b1ba7d4 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-05-02 11:33:45 +00:00
Mario
b3c543265d introduce function to remove duplicate singleton hublocs 2021-05-02 11:33:26 +00:00
Andrzej Budziński
6eee404bb1 Fixes related to correction plural expression, plus typos and some other
fixes
2021-05-01 02:43:17 +02:00
Max Kostikov
ec4226b5de Merge branch 'dev' into 'dev'
Fix Polish plurals expression

See merge request hubzilla/core!1949
2021-04-30 19:28:15 +00:00
Max Kostikov
8266a1490a Fix Polish plurals expression 2021-04-30 21:24:44 +02:00
Max Kostikov
56554710ea Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!2
2021-04-30 19:23:26 +00:00
Max Kostikov
6a101e6260 Merge branch 'translation-pl' into 'dev'
Translation update to v.5.7 plus fixes and typos

See merge request hubzilla/core!1948
2021-04-30 18:34:29 +00:00
Andrzej Budziński
f12038e63e Translation update to v.5.7 plus fixes and typos 2021-04-30 12:54:22 +02:00
Max Kostikov
ad2bf187bb Merge branch 'dev' into 'dev'
Update Russian translation; fix missprint

See merge request hubzilla/core!1947
2021-04-29 10:10:27 +00:00
Max Kostikov
4cbd97e409 Update Russian translation 2021-04-29 12:06:53 +02:00
Max Kostikov
e67c780afd Fix missprint 2021-04-29 11:35:14 +02:00
Max Kostikov
0cbdeb7bf1 Merge branch 'dev' into 'dev'
Dev Sync

See merge request kostikov/core!1
2021-04-29 09:32:02 +00:00
Mario
6be464ef84 bump version 2021-04-29 08:40:47 +00:00
Mario
54845a7627 composer dump autoload 2021-04-29 08:33:58 +00:00
Mario
2f6da0be7e version and strings 2021-04-29 08:30:31 +00:00
Mario
cf87a5af3b fix typos in Activity::follow() 2021-04-29 07:35:22 +00:00
Mario
207057c92d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-04-29 06:47:26 +00:00
Mario
5300f180db really fix manual fetching of non-ascii domains 2021-04-29 06:47:03 +00:00
Mario
ec7166eb00 fix manual fetching of non-ascii domains 2021-04-28 19:38:43 +02:00
Mario
36f041a1ff cleanup 2021-04-28 14:23:53 +02:00
Mario
0dd2e9004d do not attempt to translate twice 2021-04-28 13:21:49 +02:00
Mario
94f1c001f1 register: more testing and fixes 2021-04-28 13:17:45 +02:00
Mario
531a03562d register: new install testing fixes 2021-04-27 15:09:27 +02:00
Mario
3699f78e95 register: remove single quotes in advanced examples - they might be misleading 2021-04-27 08:08:21 +00:00
Mario
ebd2283b38 more strings changes 2021-04-26 20:33:16 +00:00
Mario
a7788570e5 register: remove debug messages from UI and streamline some strings 2021-04-26 20:30:38 +00:00
Mario
2932ac9d86 register: only log to separate file if configured that way. default to standard logging via logger() 2021-04-26 18:31:08 +00:00
Mario
888c211f44 check perms for comments since in AP they can be different from the top level post 2021-04-26 11:53:25 +00:00
Max Kostikov
61cf92ebdd Support new parse_str() syntax 2021-04-24 22:23:50 +00:00
Mario
80ec45e4f9 fix variable mixup 2021-04-22 19:48:59 +00:00
Mario
9e9851681f Merge branch 'dev' into 'dev'
Fix clones sync when wiki or single wiki page deletion

See merge request hubzilla/core!1945
2021-04-22 17:53:47 +00:00
Max Kostikov
8394d4857c Fix clones sync when wiki or single wiki page deletion 2021-04-22 17:53:47 +00:00
Mario
c700a017a0 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-04-22 17:43:26 +00:00
Mario
c19eb94c52 make sure we transform events to UTC on import before storing. Transform from event timezone if available otherwise channel default 2021-04-22 17:42:58 +00:00
Mario Vavti
597f24ca49 invite: fix javascript issue 2021-04-22 10:07:17 +02:00
Mario
eb793b1601 bump version 2021-04-21 19:28:41 +00:00
Mario
07525c5b45 next batch of fixes 2021-04-21 18:51:53 +00:00
Mario
35df50c39d start sending author id, id_sig and key fields along with author/owner and adjust import_author_xchan() accordingly 2021-04-21 07:55:35 +00:00
Mario Vavti
406ca20634 version 5.4.3 2021-04-20 11:13:19 +02:00
Mario
021e7861b8 changelog
(cherry picked from commit 5dfe4ef6f8)
2021-04-20 11:12:13 +02:00
Mario
5dfe4ef6f8 changelog 2021-04-20 09:11:45 +00:00
Mario
60a0fdc76b fix regression in mod notifications
(cherry picked from commit b8a5f5fbf2)
2021-04-20 10:58:56 +02:00
Mario
cd760454a5 floc off google
(cherry picked from commit 7ccd7b439f)
2021-04-20 10:58:38 +02:00
Mario
c7144dbf96 use protect_sprintf() on query strings
(cherry picked from commit f9793e870f)
2021-04-20 10:57:36 +02:00
Miłosz Kłosowicz
c31e203104 Wfinger - check https from http_x_forwarded_proto
(cherry picked from commit aa2450fae1)
2021-04-20 10:57:00 +02:00
Mario
6feefc5ce0 fix regression finding bookmarks
(cherry picked from commit 16cc695115)
2021-04-20 10:56:37 +02:00
Mario
1d7f9e05ed Merge branch 'dev' into 'dev'
more PHP 8 fixes

See merge request hubzilla/core!1943
2021-04-20 08:53:32 +00:00
Mario
6a858b29fd potential export issue when using PHP8
(cherry picked from commit ba412bc6cf)
2021-04-20 10:52:39 +02:00
Mario
3f0e687558 if we use dbescbin on save we should use dbunescbin when retrieving (at least that is true for postgres)
(cherry picked from commit 31abcac4b4)
2021-04-20 10:52:18 +02:00
Mario
ba412bc6cf potential export issue when using PHP8 2021-04-20 08:49:03 +00:00
Mario
31abcac4b4 if we use dbescbin on save we should use dbunescbin when retrieving (at least that is true for postgres) 2021-04-20 08:42:58 +00:00
Mario
d7f04ff6ee when importing a channel, make sure we import the xchan before the hubloc - otherwise we can not verify the hubloc hash
(cherry picked from commit eaf9003ca2)
2021-04-20 10:36:08 +02:00
Mario
76fd81fad1 revert last part of previous commit -> see comment above the change
(cherry picked from commit eded0f6c09)
2021-04-20 10:35:27 +02:00
Mario
1cfcffc510 import_items(): make sure we compare the correct revision and only call item_store_update() if edited timestamp of the received item > stored item timestamp
(cherry picked from commit c95a6fe1e5)
2021-04-20 10:35:11 +02:00
Mario
eaf9003ca2 when importing a channel, make sure we import the xchan before the hubloc - otherwise we can not verify the hubloc hash 2021-04-20 08:09:33 +00:00
Mario
751d6fe8a4 register: minor strings changes and whitespace 2021-04-19 19:29:35 +00:00
Mario
20ca6676d2 registration: reveal possibility to show all registrations in the UI 2021-04-19 19:07:50 +00:00
Mario
eded0f6c09 revert last part of previous commit -> see comment above the change 2021-04-19 10:49:41 +00:00
Mario
b5049651ad Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-04-19 10:41:51 +00:00
Mario
c95a6fe1e5 import_items(): make sure we compare the correct revision and only call item_store_update() if edited timestamp of the received item > stored item timestamp 2021-04-19 10:41:28 +00:00
Max Kostikov
cd97c32444 more PHP 8 fixes 2021-04-18 21:25:32 +02:00
Max Kostikov
70b204cb3f Merge branch 'dev' into 'dev'
PHP 8 fixes

See merge request hubzilla/core!1942
2021-04-18 07:29:41 +00:00
Max Kostikov
d2f1edfad8 PHP 8 fixes 2021-04-18 09:27:25 +02:00
Max Kostikov
2ddfcd5222 PHP 8 fixes 2021-04-18 09:23:14 +02:00
Max Kostikov
787ee411ce PHP 8 fixes 2021-04-17 23:50:19 +02:00
Max Kostikov
200d3577fa Merge branch 'dev' of https://framagit.org/kostikov/core into dev 2021-04-17 23:46:40 +02:00
Max Kostikov
8ab99747f5 Merge branch 'translation-pl' into 'dev'
Next fixes and typos, and new docs translations

See merge request hubzilla/core!1941
2021-04-16 19:31:44 +00:00
Mario
88f7c2041d register: add option to show all register entries 2021-04-16 18:13:20 +00:00
Andrzej Budziński
43cb21329f Next fixes and typos, and new docs translatons 2021-04-16 16:30:03 +02:00
Mario
b8a5f5fbf2 fix regression in mod notifications 2021-04-16 12:41:31 +00:00
nobody
a96345401f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-04-16 04:42:45 -07:00
Mario
7ccd7b439f floc off google 2021-04-16 09:14:40 +00:00
Mario
f0eceb03ed prepare Activity::follow() for pubcrawl 2021-04-16 08:08:15 +00:00
Mario
c2b9fc1a49 register: add help text to the message field 2021-04-15 13:10:20 +00:00
Mario
4d3a555b53 register: minor fixes and template cleanup 2021-04-15 09:26:47 +00:00
Mario
e35ab97b7e register: provide a possibility to leave a message id registration is by approval 2021-04-14 19:40:51 +00:00
Mario
f9793e870f use protect_sprintf() on query strings 2021-04-14 11:01:34 +00:00
Mario
e48fedd526 most AP projects do not handle an array for person object URL - provide a string 2021-04-14 09:30:19 +00:00
Mario
b899ed3d64 register: change some strings and add new template 2021-04-13 13:04:43 +00:00
Mario
e4adb881cb Merge branch 'dev' into 'dev'
Wfinger - check https from http_x_forwarded_proto

See merge request hubzilla/core!1940
2021-04-12 18:52:37 +00:00
Miłosz Kłosowicz
aa2450fae1 Wfinger - check https from http_x_forwarded_proto 2021-04-12 10:33:21 +00:00
Mario
d9245566f5 register: change some strings and some whitespace fixes 2021-04-11 17:46:06 +00:00
Mario
16cc695115 fix regression finding bookmarks 2021-04-11 15:47:42 +00:00
Mario
f0e5ce7fd1 register: more work on ui/ux 2021-04-10 20:44:04 +00:00
Mario
ea721d380b register: move some html out of the code and provide a basic template 2021-04-10 10:53:27 +00:00
Mario
e193b6d870 feature level is deprecated 2021-04-10 08:00:03 +00:00
Mario
766fc92a3b register: we use default role if auto create is configured 2021-04-09 19:25:31 +00:00
Mario
df6f2abfbe register: if auto create is configured do some more tests against the provided name and nick so it will not fail later in create_identity(); 2021-04-09 19:06:36 +00:00
Mario
684245f24d whitespace 2021-04-09 09:57:22 +00:00
Mario
01b081d809 register: only return verified registrations in get_pending_accounts(), more invite handling fixes 2021-04-09 09:49:36 +00:00
Mario
a34d8852b6 minor revert 2021-04-08 20:01:56 +00:00
Mario
18b6d48944 rgister: fixes for registering with invitecode outside of open hours 2021-04-08 19:55:53 +00:00
Mario
f3fa09fc91 register: more ui/ux 2021-04-08 16:06:43 +00:00
Mario
cb2d8b4ba6 register: minor js cleanup 2021-04-08 15:03:05 +00:00
Mario
a9da370c0b register: cleanup template 2021-04-08 14:57:16 +00:00
Max Kostikov
b5620cb794 Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!1
2021-04-08 14:19:29 +00:00
Mario
cf62e07bec register: default to auto-create channel and fix auto create channel if register approval is configured 2021-04-08 12:38:38 +00:00
Mario
ec4526b5f4 cloud: instead of asking for a page reload when expiriencing a not implemnented exception just go there right away - issue #1556 2021-04-08 08:25:35 +00:00
Mario
806f50eee3 register: more ui/ux work 2021-04-07 20:50:34 +02:00
Mario
6956eadaad registrations: minor cleanup 2021-04-07 17:19:29 +02:00
Mario
9542c1d63c Merge branch 'dev' into 'dev'
air: Fix site admin registration block styles

See merge request hubzilla/core!1938
2021-04-07 14:12:01 +00:00
Mario
81bb02afb7 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-04-06 12:13:24 +00:00
Mario
b8abf806ca bbcode: escape img and zmg tags so that it will not be messed with before required (e.g. URL in image description) - issue #1554 2021-04-06 12:12:51 +00:00
Max Kostikov
0d10f5ba65 Fix site admin registration block styles 2021-04-06 13:41:33 +02:00
Max Kostikov
89409d0577 Merge branch 'dev' into 'dev'
Fix quotes Russian translation

See merge request hubzilla/core!1937
2021-04-06 11:21:10 +00:00
Max Kostikov
144283ca1c Fix quotes 2021-04-06 11:16:47 +00:00
Max Kostikov
c56e2953cf Fix quotes 2021-04-06 11:16:25 +00:00
Max Kostikov
e1d40348ce Update hstrings.php 2021-04-06 11:09:48 +00:00
Max Kostikov
4def370980 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1936
2021-04-06 11:00:14 +00:00
Max Kostikov
54df52675b Revert "Fix mistake"
This reverts commit 9ac5504377
2021-04-06 12:30:03 +02:00
Max Kostikov
12ebdf27c0 Fix variables 2021-04-06 10:27:19 +00:00
Max Kostikov
de0f7ea5d4 Update register_verify_member.tpl 2021-04-06 10:26:26 +00:00
Max Kostikov
72151bc123 Add new file 2021-04-06 10:21:32 +00:00
Max Kostikov
8889abd5a4 Add new file 2021-04-06 10:20:50 +00:00
Max Kostikov
7f7dcd2f33 Fix missprint 2021-04-06 10:18:12 +00:00
Max Kostikov
95c3b1696e Add new formal invitation subject 2021-04-06 10:17:46 +00:00
Max Kostikov
87cd1f87f4 Add formal invitation 2021-04-06 10:16:22 +00:00
Max Kostikov
21c4976a3a Add new invitation subject 2021-04-06 09:59:40 +00:00
Max Kostikov
ec91e51142 Add friendly invitation 2021-04-06 09:56:11 +00:00
Max Kostikov
f1c798e9ac Update Russian hstrings.php 2021-04-06 09:50:44 +00:00
Max Kostikov
f6996f4999 Update Russian hmessages.po 2021-04-06 09:50:21 +00:00
Max Kostikov
9ac5504377 Fix mistake 2021-04-06 09:33:17 +00:00
Mario
91f3c722d6 bump version 2021-04-06 07:57:35 +00:00
Mario
31cf2c688c Merge branch 'dev' into air 2021-04-06 07:55:30 +00:00
Mario
81d3ba5151 do not expire page cache - it does not make much sense actually. 2021-04-06 07:48:09 +00:00
nobody
9359fc065c Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-04-05 23:15:01 -07:00
Max Kostikov
19daadbfd7 Merge branch 'translation-pl' into 'dev'
Upgrading POT, additional translations and next fixes

See merge request hubzilla/core!1935
2021-04-05 20:55:14 +00:00
Andrzej Budziński
0acb371f62 Upgrading POT, additional translations and next fixes 2021-04-05 16:34:30 +02:00
Mario
18d990a034 air: more ui/ux and provide a possibility to lookup your registration id in mod regate (raw and unfinished) 2021-03-28 20:40:26 +00:00
Mario
85b6e352d4 air: fixes 2021-03-28 10:17:54 +00:00
Mario
c389aee112 Merge branch 'air' of https://framagit.org/hubzilla/core into air 2021-03-26 21:04:26 +01:00
Mario
725e57a27a air: more work on UX during register 2021-03-26 20:54:48 +01:00
Mario
9aab47de07 fix timezone issue in mod cal
(cherry picked from commit 6e7c7771bd)
2021-03-26 20:24:51 +01:00
Mario
e6a6723d1f Merge branch 'air' of https://framagit.org/hubzilla/core into air 2021-03-26 19:21:41 +00:00
Mario
6e7c7771bd fix timezone issue in mod cal 2021-03-26 19:20:38 +00:00
Max Kostikov
c609fc71bd Merge branch 'translation-pl' into 'dev'
Fixes and new translations

See merge request hubzilla/core!1934
2021-03-25 19:36:18 +00:00
Mario
b50f1657c3 Merge branch 'air' of https://framagit.org/hubzilla/core into air 2021-03-25 14:00:49 +01:00
Mario
bc1cc65ff2 air: currently it is allowed to register with non-unique did2 (should this be allowed?) - anyway, for now sort them by reg_created to make sure we always match the latest attempt 2021-03-25 14:00:25 +01:00
Andrzej S. Budziński
697e59f9a4 Update hstrings.php 2021-03-25 12:59:45 +00:00
Andrzej Budziński
61d6239c68 Fixes and new translations
1) Changed translations of "a hub" and "a post" ("a hub" like "a node of
network" and not like "a web-hub" or "an air hub".) The word "a post"
should be translated as Polish "wpis" and not jargon "post".
2) New translation: doc/pl/Widgets.md
2021-03-24 23:30:42 +01:00
Mario
eba69f85c7 more work on mod display
(cherry picked from commit 2d716b74b9)
2021-03-24 20:48:42 +01:00
Mario
19b96e37fb Merge branch 'dev' into air 2021-03-24 19:46:07 +00:00
Mario
14186f5c18 cdav: fix regression - sync code was messing with caldav/carddav discovery 2021-03-24 19:41:20 +00:00
Mario
44593a3c8d cdav: fix regression - sync code was messing with caldav/carddav discovery 2021-03-24 19:27:44 +00:00
Mario
4964a32c55 Revalidate imported profile photo on each request (patch provided by Max)
(cherry picked from commit 3d4ad94dcc)
2021-03-24 12:18:32 +01:00
Mario
3d4ad94dcc Revalidate imported profile photo on each request (patch provided by Max) 2021-03-24 11:16:03 +00:00
Mario
6d5f98072d php8: fix fatal errors
(cherry picked from commit 1a15c775f8)
2021-03-24 11:39:19 +01:00
Mario
1a15c775f8 php8: fix fatal errors 2021-03-24 09:21:58 +00:00
Mario
2d716b74b9 more work on mod display 2021-03-23 11:38:42 +00:00
Mario
cc9fd4f4a4 fix regression in mod display
(cherry picked from commit 43c5b72317)
2021-03-23 12:05:40 +01:00
Mario
43c5b72317 fix regression in mod display 2021-03-23 10:54:27 +00:00
Mario
2856ea6370 Merge branch 'dev' into air 2021-03-23 09:56:46 +00:00
Max Kostikov
67d65d878d Merge branch 'dev' into 'dev'
Fix DAV calendars and addressbooks sync on remote access

See merge request hubzilla/core!1931
2021-03-22 14:21:38 +00:00
Max Kostikov
e19bb63857 Merge branch 'translation-pl' into 'dev'
Translation pl

See merge request hubzilla/core!1930
2021-03-22 14:20:56 +00:00
Max Kostikov
dbc5e54a92 Fix DAV calendars and addressbooks sync on remote access 2021-03-22 14:16:54 +00:00
Mario
b8913335b1 those are not actually needed by the handler
(cherry picked from commit 872ac8846e)
2021-03-22 13:51:44 +01:00
Mario
872ac8846e those are not actually needed by the handler 2021-03-22 13:51:11 +01:00
Mario
8c16171855 sse: make sure to also bootstrap info and notice
(cherry picked from commit 598c3aa336)
2021-03-22 13:43:00 +01:00
Mario
2e47ef38a9 libsync fix from zap: look for hubloc_updated instead of hubloc_connected which would always be true
(cherry picked from commit ccefb99cbe)
2021-03-22 13:42:01 +01:00
Mario
81b4d919e5 do not treat an URL including an @ like a webbie
(cherry picked from commit 35ce7dbeab)
2021-03-22 13:41:39 +01:00
Mario
f6d88f20f3 Merge branch 'air' of https://framagit.org/hubzilla/core into air 2021-03-22 13:37:31 +01:00
Mario
598c3aa336 sse: make sure to also bootstrap info and notice 2021-03-22 13:37:01 +01:00
Mario
ccefb99cbe libsync fix from zap: look for hubloc_updated instead of hubloc_connected which would always be true 2021-03-22 10:12:57 +00:00
Mario
35ce7dbeab do not treat an URL including an @ like a webbie 2021-03-22 10:01:32 +00:00
Mario
74610aca6f Merge branch 'air' of https://framagit.org/hubzilla/core into air 2021-03-22 10:29:54 +01:00
Mario
02d4c5ac90 Merge branch 'air' of https://framagit.org/hubzilla/core into air 2021-03-22 09:29:23 +00:00
Mario
7f35dda5cc Merge branch 'dev' into air 2021-03-22 10:28:08 +01:00
Mario
13355d42f7 air security: saving the password as hex string is not acceptable 2021-03-22 09:50:12 +01:00
Andrzej Budziński
77e82d7475 Fixes (Translation.md, hstrings.php) 2021-03-21 19:54:22 +01:00
Andrzej Budziński
da2df4eb55 Fixes and next translations (doc/pl/Plugins.md) 2021-03-21 18:17:06 +01:00
Mario
62fbdf3f63 Merge branch 'air' into 'air'
adminUI cfg to switch on (default off) register w/o email, Issue Air #1539

See merge request hubzilla/core!1927
2021-03-20 16:01:21 +00:00
Mario
554745a25a air: do not require to verify emailaddress once more after invite code got verified - fixes #1546 but probably still requires some finetuning. 2021-03-20 16:57:11 +01:00
Hilmar R
e12c0ca3dc adminUI cfg to switch on (default off) register w/o email,
accept delay 0 (no delay) and expire defaults to 99years
2021-03-19 21:10:01 +01:00
Mario
a18e297a26 Merge branch 'dev' into air 2021-03-19 20:07:59 +00:00
Mario
2d82e1bd6b Merge branch 'dev' into 'dev'
Implement custom Redis session backend

See merge request hubzilla/core!1926
2021-03-19 20:07:00 +00:00
Max Kostikov
7476d8dccc Implement custom Redis session backend 2021-03-19 20:06:59 +00:00
Mario
04b96e2cdc air: php8 asort() argument cannot be passed by reference 2021-03-19 12:06:38 +01:00
Mario
7375824ed4 air: missing module 2021-03-19 11:45:40 +01:00
Mario
06d47deef8 air: improved UX by changing the registration workflow so that it is not required to go back to registration and post the DID. If no registration delay is configured proceed directly to verification. fixes #1540 2021-03-19 11:43:48 +01:00
Mario
85d000e792 air: revert min_livetime of the form security token - it has had its issues and air can be configured for delayed registration verification 2021-03-18 19:51:30 +00:00
Mario
3ac27d8004 air: display the verification status in the notifications 2021-03-18 19:41:12 +00:00
Mario
854a6e3787 air: only set registration request to expired if it is not yet verified 2021-03-18 14:56:53 +00:00
Mario
a36dd5a8b9 adjust timezone after the expiration check 2021-03-18 14:47:37 +00:00
Mario
7c620cbe24 air: make sure to display the timezone corrected times in the admin ui 2021-03-18 14:42:30 +00:00
Mario
7472b96c95 Merge branch 'air' of https://framagit.org/hubzilla/core into air 2021-03-18 14:55:28 +01:00
Mario
3ba42d3dcf air: deal with timezones when displaying open/close time - this should finally fix issue #1544 2021-03-18 14:55:01 +01:00
Mario
eb3a40b07a use lib/keyutils rsatopem()
(cherry picked from commit f0cce1c902)
2021-03-18 09:37:55 +01:00
Mario
f0cce1c902 use lib/keyutils rsatopem() 2021-03-18 08:35:09 +00:00
Mario
9f26b7aa9c air: convert utc to local in browser (we do not have a client timezone othervise at this point) - issue #1544 2021-03-17 17:49:13 +01:00
Mario
febf766be0 air: make sure we always save date_time in UTC - issue #1544 2021-03-17 14:37:16 +01:00
Mario
35d9fd4860 air: another string 2021-03-17 12:24:19 +01:00
Mario
4581abb6d1 air: some work on ui/ux 2021-03-17 12:14:55 +01:00
Mario
8d3c5114ba use html2plain for summary
(cherry picked from commit 80b6954c29)
2021-03-17 10:13:55 +01:00
Mario
80b6954c29 use html2plain for summary 2021-03-17 09:13:09 +00:00
Mario
da37548e2e also move code comments to the function 2021-03-16 12:33:41 +01:00
Mario
c658bbca24 simplify get_pending_accounts query so that it will work in postgres. this will introduce a regression in rendering the table background color. 2021-03-16 12:32:20 +01:00
Mario
3b9a9db664 fix cover photo image issues on some mobile devices
(cherry picked from commit 4e921cfdcf)
2021-03-16 10:13:55 +01:00
Mario
4e921cfdcf fix cover photo image issues on some mobile devices 2021-03-16 09:09:13 +00:00
Mario
bd24224b76 air: fix register notifications 2021-03-15 12:45:39 +00:00
Mario
a5ac388889 air: fix calculate_adue() to return false if the value is zero and do not hardcode regexpire - adding the max setting (99 years) should be fine. 2021-03-15 10:31:23 +00:00
Mario
4be123dc84 fix default value displayed if value is set to empty or zero. fix #1536 and #1537 2021-03-15 10:10:08 +00:00
Mario
0ebb1f685f version 5.4.2 2021-03-15 08:55:46 +00:00
Mario
805a25eb62 more changelog
(cherry picked from commit 268464ccde)
2021-03-15 08:54:16 +00:00
Mario
4ca12afc9d changelog
(cherry picked from commit cb74de7472)
2021-03-15 08:54:05 +00:00
Mario
6cfa2572a8 do not parse bbcode in summary - issue #1532 2021-03-15 08:50:53 +00:00
Mario
04ec986bf7 cleanup
(cherry picked from commit 0fbd0ca416)
2021-03-15 08:50:29 +00:00
Max Kostikov
ee453c4acc Fix plurals variable 2021-03-15 08:50:13 +00:00
Mario
4d3524ba9d mod subthread issue continued
(cherry picked from commit b6d30f6734)
2021-03-15 08:49:53 +00:00
Mario
29beea28c2 fix mod subthread for zot6
(cherry picked from commit 22d769ecae)
2021-03-15 08:48:40 +00:00
Mario
e2a289d614 truncate too long text
(cherry picked from commit 1582b8bc96)
2021-03-15 09:43:18 +01:00
Mario
59d3483a06 save the rewritten llink
(cherry picked from commit db0e1c9f31)
2021-03-15 09:43:08 +01:00
Mario
a99161abdf if rewriting the mid also rewrite the llink
(cherry picked from commit 260c518562)
2021-03-15 09:42:56 +01:00
Mario
79d48dc92b fix mod display query
(cherry picked from commit b51049227f)
2021-03-15 09:42:41 +01:00
Mario
becb898a51 more changelog
(cherry picked from commit 268464ccde)
2021-03-15 09:36:37 +01:00
Mario
268464ccde more changelog 2021-03-15 08:36:00 +00:00
Mario
57aa96c412 changelog
(cherry picked from commit cb74de7472)
2021-03-15 09:34:00 +01:00
Mario
cb74de7472 changelog 2021-03-15 08:33:26 +00:00
Mario
d35849c418 Merge branch 'dev' into air 2021-03-14 20:29:29 +00:00
Mario
a9a112e063 php8: fix some undefined variables
(cherry picked from commit ed64eba13a)
2021-03-14 21:25:45 +01:00
Mario
1e87fe6b49 cleanup
(cherry picked from commit 0fbd0ca416)
2021-03-14 21:24:56 +01:00
Mario
ed64eba13a php8: fix some undefined variables 2021-03-14 20:23:33 +00:00
Mario
0fbd0ca416 cleanup 2021-03-14 19:23:02 +00:00
Max Kostikov
0a31267b1b Fix plurals variable 2021-03-14 11:43:47 +00:00
Mario
97c7b010ed mod subthread issue continued
(cherry picked from commit b6d30f6734)
2021-03-14 10:03:03 +01:00
Mario
b6d30f6734 mod subthread issue continued 2021-03-14 09:01:12 +00:00
Mario
b9e1c38773 fix mod subthread for zot6
(cherry picked from commit 22d769ecae)
2021-03-13 23:22:08 +01:00
Mario
22d769ecae fix mod subthread for zot6 2021-03-13 22:13:17 +00:00
Mario
45ecd1b127 revert default profile image 2021-03-12 10:50:25 +00:00
Mario
3f053611bd Merge branch 'dev' into air 2021-03-12 10:07:15 +00:00
Mario
1582b8bc96 truncate too long text 2021-03-12 09:54:01 +00:00
Mario
432e7e9714 revert follow_failover hook - there is a cleaner solution 2021-03-12 09:06:20 +00:00
Mario
31e237729c introduce the follow_failover hook 2021-03-11 21:58:45 +00:00
Mario
d2b03f6a9b more add interactive flag 2021-03-11 20:11:05 +00:00
Mario
51fe5ec982 add interactive flag 2021-03-11 19:33:03 +00:00
Mario
ce9b01ce84 Merge branch 'php8fixes' into 'dev'
Stricter item array checks

See merge request hubzilla/core!1925
2021-03-11 17:51:14 +00:00
Max Kostikov
024b489af9 Stricter item array checks 2021-03-11 17:51:13 +00:00
Mario
f980c2e3de php8: daily warning fixes (deriving from mod network) 2021-03-11 13:03:54 +00:00
Mario
db0e1c9f31 save the rewritten llink 2021-03-11 08:25:26 +00:00
Mario
260c518562 if rewriting the mid also rewrite the llink 2021-03-10 20:44:20 +00:00
Mario
689603de82 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-03-10 20:35:13 +00:00
Mario
b51049227f fix mod display query 2021-03-10 20:34:47 +00:00
Max Kostikov
0a86efc631 Merge branch 'php8fixes' into 'dev'
Check for HTTP port use on URL build

See merge request hubzilla/core!1924
2021-03-10 19:52:05 +00:00
Max Kostikov
f8467845d2 Check for HTTP port use 2021-03-10 19:44:54 +00:00
Max Kostikov
9098bb431c Check for HTTP port use 2021-03-10 19:44:17 +00:00
Max Kostikov
86ed4f4f99 Check for HTTP port use 2021-03-10 19:44:02 +00:00
Max Kostikov
7795224e70 Check for HTTP port use 2021-03-10 19:43:42 +00:00
Max Kostikov
b729cee9e4 Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!1
2021-03-10 19:41:46 +00:00
Mario
15bc5c64f3 php8: isset() returns true if the array key exists but is empty. We need to check with empty() here. 2021-03-10 16:28:05 +00:00
Mario
440a132c6b Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-03-10 13:18:12 +00:00
Mario
f8447521a8 php8: random fixes deriving from mod network 2021-03-10 13:16:08 +00:00
Mario
c8050ea865 Merge branch 'php8fixes' into 'dev'
More PHP 8 fixes

See merge request hubzilla/core!1923
2021-03-10 11:14:03 +00:00
Max Kostikov
11d831e4d7 More PHP 8 fixes 2021-03-10 11:14:02 +00:00
Mario
15faf01ec9 do not parse bbcode in summary - issue #1532 2021-03-10 11:09:49 +00:00
Mario Vavti
82192d1ead a possible fix for issue #1529
(cherry picked from commit 7ee495624e)
2021-03-09 21:40:43 +01:00
Mario Vavti
7ee495624e a possible fix for issue #1529 2021-03-09 21:36:28 +01:00
Mario
64bbbc8053 Version 5.4.1 2021-03-09 19:07:33 +00:00
Mario Vavti
4d3d868d19 changelog
(cherry picked from commit 45cc2d7bd8)
2021-03-09 19:58:40 +01:00
Mario Vavti
45cc2d7bd8 changelog 2021-03-09 19:53:25 +01:00
Max Kostikov
15b45af550 Revert "Check if we have an observer xchan"
This reverts commit 91ebfbc215
2021-03-09 16:59:44 +01:00
Max Kostikov
91ebfbc215 Check if we have an observer xchan 2021-03-09 15:58:26 +00:00
Max Kostikov
011342ac1b Fix undefined page end on non dynamic pages
(cherry picked from commit 182dec3e57)
2021-03-09 12:14:38 +01:00
Max Kostikov
5577383a48 Fix Spanish plural expression
(cherry picked from commit f952d65cfd)
2021-03-09 12:13:22 +01:00
Mario
dc336010db type submit should not be type button
(cherry picked from commit b09cbb72fb)
2021-03-09 12:12:53 +01:00
Mario
88fbeaddb0 fix unexpected trigger of buttons when pressing enter in input field issue #1528
(cherry picked from commit d57f4a9527)
2021-03-09 12:12:20 +01:00
Mario
7612d8246e fix summary not saved in browser autosave draft
(cherry picked from commit 8d26961639)
2021-03-09 12:11:39 +01:00
Mario
53bb16e799 fix summary not reset on cancel
(cherry picked from commit 0932d2a0a6)
2021-03-09 12:11:09 +01:00
Mario
ed04104250 fix profile not found if not logged in
(cherry picked from commit ed981ec8e8)
2021-03-09 12:10:27 +01:00
Mario
ee40cb337a Merge branch 'php8-netstream' into 'dev'
Fix network stream scrolling with PHP 8

See merge request hubzilla/core!1922
2021-03-09 11:05:43 +00:00
Max Kostikov
bdae290ec4 Revert "More checks on note decoding"
This reverts commit 20199f7aee34dbc7a8aebcd459ef6cb84cdb5bd7
2021-03-09 11:05:43 +00:00
Mario
53c3d0d53d Merge branch 'php8' into 'dev'
Stricter parameters checks for PHP 8 support

See merge request hubzilla/core!1921
2021-03-09 11:02:28 +00:00
Mario
ed981ec8e8 fix profile not found if not logged in 2021-03-09 10:47:13 +00:00
Max Kostikov
723d757091 Change set_linkified_perms() arguments order 2021-03-09 09:08:33 +00:00
Max Kostikov
92ada6eb98 Change set_linkified_perms() arguments order 2021-03-09 09:07:47 +00:00
Max Kostikov
975d8ef0c7 Fix deprecated function arguments order 2021-03-09 09:06:16 +00:00
Max Kostikov
65e9ff357b More checks on note decode 2021-03-08 21:16:24 +00:00
Max Kostikov
66495e6838 Check propeties existance on note decode 2021-03-08 21:06:26 +00:00
Max Kostikov
efe65e1ba8 Fix undefined edited and created checks 2021-03-08 20:57:02 +00:00
Max Kostikov
6b500ee3e1 Check if BBcode field exist 2021-03-08 20:52:39 +00:00
Max Kostikov
1ad6308f97 Formatting 2021-03-08 20:43:29 +00:00
Max Kostikov
5d82bf946e Check if properties were provided on taxonomy decode 2021-03-08 20:35:03 +00:00
Max Kostikov
c8fe56e57d Check if oStatus conversation exists 2021-03-08 20:30:14 +00:00
Max Kostikov
88b6353465 More checks on attachments decode 2021-03-08 20:13:08 +00:00
Max Kostikov
4afddabe15 Fix missed tag warning on decode taxonomy 2021-03-08 20:09:49 +00:00
Max Kostikov
360ae9080e Fix actor store warnings on non defined properties 2021-03-08 20:06:36 +00:00
Max Kostikov
956aec1448 Check if item have a mention 2021-03-08 20:00:59 +00:00
Max Kostikov
4bcd093bef Check for attachments in item 2021-03-08 19:50:55 +00:00
Max Kostikov
f62b294a72 Check if terms are defined as array for item 2021-03-08 19:46:27 +00:00
Max Kostikov
c2adf1dcd1 Check if 'attach' and 'iconfig' array are defined 2021-03-08 19:40:40 +00:00
Mario
0932d2a0a6 fix summary not reset on cancel 2021-03-08 19:40:32 +00:00
Max Kostikov
e451284256 Check if port in the site URL provided 2021-03-08 19:35:45 +00:00
Mario
49f12695cf Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-03-08 19:25:12 +00:00
Mario
8d26961639 fix summary not saved in browser autosave draft 2021-03-08 19:25:01 +00:00
Max Kostikov
c9ec5043b9 Check if HTTP port is defined 2021-03-08 19:22:17 +00:00
Max Kostikov
03bfb8a46f Define $sql_extra2 variable before extending 2021-03-08 19:21:38 +00:00
Max Kostikov
0c5a7ab19b Define $sql_extra2 variable before concatenation 2021-03-08 19:16:41 +00:00
Mario
1561e4a89c Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-03-08 19:15:39 +00:00
Mario
b09cbb72fb type submit should not be type button 2021-03-08 19:14:14 +00:00
Mario
d57f4a9527 fix unexpected trigger of buttons when pressing enter in input field issue #1528 2021-03-08 19:12:37 +00:00
Mario
0e015d52a5 Merge branch 'dev' into 'dev'
Fix undefined page end on non dynamic pages

See merge request hubzilla/core!1920
2021-03-08 19:08:50 +00:00
Max Kostikov
7e0416ac97 Remove unusable variable $sql_query 2021-03-08 19:05:03 +00:00
Max Kostikov
98112497ba Fix Spanish plural expression 2021-03-08 15:59:12 +00:00
Max Kostikov
f952d65cfd Fix Spanish plural expression 2021-03-08 15:48:44 +00:00
Max Kostikov
182dec3e57 Fix undefined page end on non dynamic pages 2021-03-08 15:33:26 +00:00
Max Kostikov
8ab6076566 Merge branch 'dev' into 'dev'
# Conflicts:
#   boot.php
2021-03-08 15:20:38 +00:00
mjfriaza
6506cab55b Update Spanish 2021-03-08 10:28:26 +00:00
mjfriaza
97e483d684 Update Spanish 2021-03-08 10:26:38 +00:00
Mario
fe638c88e0 fix dev version 2021-03-08 10:16:00 +00:00
Mario
951e9c8c4f Merge branch '5.4RC' 2021-03-08 09:31:23 +00:00
Mario
89415e1731 release 5.4 2021-03-08 09:26:50 +00:00
Mario
f9ab020d1d Merge branch '5.4RC' of https://framagit.org/hubzilla/core into 5.4RC 2021-03-08 09:23:11 +00:00
Mario
1828ef6b68 changelog 2021-03-08 09:21:22 +00:00
Mario
4903d7b1e9 update sbom
(cherry picked from commit c67fdd9480)
2021-03-06 18:56:53 +01:00
Mario
c67fdd9480 update sbom 2021-03-06 17:55:24 +00:00
Mario
9b5979c83a fix varable name and more changelog
(cherry picked from commit 7460b1eecb)
2021-03-06 09:51:45 +01:00
Mario
7460b1eecb fix varable name and more changelog 2021-03-06 08:50:36 +00:00
Mario
7d03ff2043 sse_bs: if Enotify::format() returns an empty array do not add it to notifications (the item has probably been blocked)
(cherry picked from commit 1da494a2a5)
2021-03-05 09:26:30 +01:00
Mario
1da494a2a5 sse_bs: if Enotify::format() returns an empty array do not add it to notifications (the item has probably been blocked) 2021-03-05 08:15:41 +00:00
Mario
00ccafc90d more changelog
(cherry picked from commit e0c619519f)
2021-03-04 12:21:27 +01:00
Mario
b767e7ddec even more changelog
(cherry picked from commit 31da1362de)
2021-03-04 12:20:56 +01:00
Mario
31da1362de even more changelog 2021-03-04 11:19:23 +00:00
Mario
e0c619519f more changelog 2021-03-04 10:13:48 +00:00
Mario
f1f1e56f87 revert revert isset()
(cherry picked from commit 33e4b6db72)
2021-03-04 10:53:29 +01:00
Mario
33e4b6db72 revert revert isset() 2021-03-04 09:52:54 +00:00
Mario
1eae7b92d1 revert isset() 2021-03-04 09:50:03 +00:00
Mario
5b7a10401f version 5.4RC2 2021-03-04 09:48:19 +00:00
Mario
1b8c5b9727 changelog
(cherry picked from commit 548936c6ca)
2021-03-04 10:46:56 +01:00
Mario
548936c6ca changelog 2021-03-04 09:45:51 +00:00
Max Kostikov
7beb500fb4 Check if custom CSP is set 2021-03-04 08:36:20 +00:00
Mario
9c110e7b9b revert isset 2021-03-04 08:20:16 +00:00
Mario
129f8107d3 merge conflict 2021-03-04 08:17:07 +00:00
Mario
cb01996039 Merge branch 'dev' into 'dev'
Fix frame-src CSP error on video embedding

See merge request hubzilla/core!1918
2021-03-04 08:05:27 +00:00
Max Kostikov
33b738d00b Fix frame-src CSP error on video embedding 2021-03-04 08:05:26 +00:00
Max Kostikov
cf7f380568 Merge branch 'dev' into 'dev'
# Conflicts:
#   boot.php
2021-03-03 20:05:37 +00:00
Max Kostikov
7e36727ce6 Fix frame-src CSP error on video embedding 2021-03-03 20:01:39 +00:00
Mario
c2dc3e8dec set the default collection acl if indicated so by the role permissions but always set the created friends group as channel_default_group when creating a new channel
(cherry picked from commit 9389abdb75)
2021-03-03 14:12:42 +01:00
Mario
7d1599f9b0 group_add(): return hash if success
(cherry picked from commit f8f15f526f)
2021-03-03 14:11:54 +01:00
Mario
3d264f5a55 php8: fix warnings during install procedure
(cherry picked from commit 48bae9d421)
2021-03-03 14:11:29 +01:00
Mario
9389abdb75 set the default collection acl if indicated so by the role permissions but always set the created friends group as channel_default_group when creating a new channel 2021-03-03 14:09:17 +01:00
Mario
f8f15f526f group_add(): return hash if success 2021-03-03 13:44:38 +01:00
Mario
48bae9d421 php8: fix warnings during install procedure 2021-03-03 13:39:41 +01:00
Hilmar R
c29261487c a bit more useability for the admin at the beginning 2021-03-03 12:59:19 +01:00
Hilmar R
c3229643d0 embarrassing :-( 2021-03-02 22:23:58 +01:00
Hilmar R
2b03e51bfc did2 chk num 5...10 2021-03-02 18:45:13 +01:00
Hilmar R
4cc72db463 hope not to hurry too fast when saying 5.4RC2. But today & tomorrow is only for the tests 2021-03-02 16:11:18 +01:00
Hilmar R
d434490bdf melt include/account 2021-03-02 15:54:51 +01:00
Hilmar R
2c15efbf48 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-03-01 20:26:44 +01:00
Hilmar R
c26dede97f get dev 2021-03-01 18:48:11 +01:00
Max Kostikov
1d899d387e Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!2
2021-02-27 19:47:26 +00:00
Hilmar R
ea3390d626 adjust air.5 to be in sync with 5.2.2 2021-02-26 15:10:24 +01:00
Hilmar R
a04ded9cca repair dd tag and set unique vsn 2021-02-26 14:38:41 +01:00
Mario
55b4eb7b22 version 5.4RC1 2021-02-26 10:15:56 +00:00
Mario
fbb1d6aa41 Merge branch 'dev' into 'dev'
Do not overwrite HTTP schema for Youtube on embedding

See merge request hubzilla/core!1917
2021-02-26 09:03:58 +00:00
Max Kostikov
5440a65607 Do not overwrite HTTP schema for Youtube on embedding 2021-02-25 16:35:19 +00:00
Mario
36c9f9abff Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-02-25 15:43:13 +00:00
Mario
8295ccdda7 a possible fix for #1518 2021-02-25 15:43:01 +00:00
Mario
65892ba555 Merge branch 'dev' into 'dev'
small adjustment

See merge request hubzilla/core!1915
2021-02-25 15:10:41 +00:00
Zot
78938df133 small adjustment 2021-02-25 15:10:41 +00:00
Mario
ac6dec91f1 Merge branch 'dev' into 'dev'
Enable multimedia in podcasts

See merge request hubzilla/core!1916
2021-02-25 15:09:31 +00:00
Mario
373612a046 do not poll feeds if feed_contacts are not allowed 2021-02-25 15:05:49 +00:00
Mario
c1afa306c9 fix logic 2021-02-25 14:15:13 +00:00
Mario
65a20a780d bump version 2021-02-25 12:56:57 +00:00
Mario
b29e121113 replace sticky_kit with a simpler homwgrown solution (still a bit raw) and slightly change the way we load new content so that people with a long aside column do not have to scroll all the way to the bottom for loading the next page 2021-02-25 12:55:19 +00:00
Michal Klodner
f45ebfa223 - Enable enclosures in Atom/RSS (podcasts)
- Remove checking of audio/video URLs for pattern at the end
2021-02-24 21:03:05 +00:00
nobody
878be8fff0 small adjustment (effects export output but is correctly handled by import) 2021-02-24 11:48:28 -08:00
nobody
beb418b093 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-02-24 11:38:38 -08:00
Mario
a033c439f3 zap compat export fixes 2021-02-24 10:19:15 +00:00
Mario
66e4bc327f Merge branch 'dev' into 'dev'
export compatibility from hubzilla to zap

See merge request hubzilla/core!1910
2021-02-24 08:35:30 +00:00
Zot
df362e4f81 export compatibility from hubzilla to zap 2021-02-24 08:35:29 +00:00
nobody
0f89d2b8e0 some content fields found in the wild are actually arrays 2021-02-23 15:37:58 -08:00
Max Kostikov
82ee980172 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1912
2021-02-23 12:33:17 +00:00
Max Kostikov
463a8d338e Update hmessages.po 2021-02-23 12:29:02 +00:00
Max Kostikov
d074bb65da Update Russian hstrings.php 2021-02-23 12:26:20 +00:00
Max Kostikov
b7c411470b Update Russian hmessages.po 2021-02-23 12:24:59 +00:00
Max Kostikov
e09e6c5524 Missprint 2021-02-23 12:22:19 +00:00
Mario
fa73c8d15e bump dev version to 5.5 2021-02-23 10:57:37 +00:00
Mario
6060ca127b composer dump-autoload 2021-02-23 10:54:27 +00:00
Mario
ca4e0351cf update strings 2021-02-23 10:52:38 +00:00
Mario
f3be2ecc9d version 5.4RC 2021-02-23 10:48:47 +00:00
Mario
135305d975 Merge branch 'dev' into 'dev'
Rename photo storage type system variable

See merge request hubzilla/core!1911
2021-02-23 10:02:16 +00:00
Max Kostikov
34aa8ba3cc Rename photo storage type system variable 2021-02-23 10:02:15 +00:00
Mario
28fe91dfa7 Merge branch 'dev' of https://codeberg.org/hubzilla/hubzilla into dev 2021-02-23 09:53:12 +00:00
mjfriaza
883b519714 Update Spanish version 2021-02-23 09:52:24 +00:00
hubzilla
9dae590c64 Merge pull request 'Update Spanish version' (#4) from mjfriaza/hubzilla:dev into dev
Reviewed-on: https://codeberg.org/hubzilla/hubzilla/pulls/4
2021-02-23 10:49:21 +01:00
nobody
fc88c306ab some minor issues uncovered during hubzilla->zap export testing 2021-02-22 17:23:08 -08:00
Mario
d4159e8333 streamline iconf names and make sure to save the correct data 2021-02-22 10:32:05 +00:00
Max Kostikov
90d04082a1 Fix missprint 2021-02-21 14:13:46 +01:00
Max Kostikov
a84c7271f2 Formatting 2021-02-20 14:49:31 +01:00
Max Kostikov
f46ddf2273 Bump DB version 2021-02-20 14:47:50 +01:00
Max Kostikov
b401869d30 Rename photo storage type system variable 2021-02-20 14:47:14 +01:00
Max Kostikov
cc55716879 Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!1
2021-02-20 13:39:54 +00:00
Mario
ddad4f604b provide raw base64 encoded crypto 2021-02-19 17:37:53 +00:00
Mario
dc553ab309 summary edit actions 2021-02-19 10:24:20 +00:00
Mario
a2d170385b deprecate summary tag in favour of a separate input field 2021-02-19 10:11:24 +00:00
Mario
a275726988 update site once a day 2021-02-19 09:26:39 +00:00
Mario
863d4d83a1 fix recursive shares 2021-02-19 07:41:29 +00:00
nobody
5664f5e0a2 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-02-18 21:42:15 -08:00
Mario
d50381c9c6 fix summary regex after recent bbcode chane 2021-02-18 20:36:56 +00:00
Mario
c9bbe1a735 adjust error reporting for php8 to not report warnings - they are too many 2021-02-18 20:04:34 +00:00
Mario
18b9d1efd8 this setting is probably not required anymoreà 2021-02-18 20:00:20 +00:00
Mario
85f1845d15 fix usage of null coalescing operator 2021-02-18 19:46:26 +00:00
Mario
c34fc416a2 php8 warnings 2021-02-18 19:32:45 +00:00
Mario
7794ee5a88 php8 warnings 2021-02-18 13:32:02 +00:00
Mario
65068479b9 php8 warnings 2021-02-18 13:29:15 +00:00
mjfriaza
655ae9d1cd Merge branch 'dev' into dev 2021-02-18 13:28:05 +01:00
mjfriaza
76163fc37b Update Spanish version 2021-02-18 13:22:57 +01:00
Mario
92f3c5ae21 backward compatibility with recent crypto changes 2021-02-18 09:36:22 +00:00
nobody
136bc13ff6 forgot these 2021-02-17 21:50:11 -08:00
nobody
62b738da95 migration testing 2021-02-17 19:42:58 -08:00
nobody
e7c7f91a3f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-02-17 16:37:19 -08:00
nobody
8a65fc8a43 more work on hz->zap migration stuff 2021-02-17 16:36:27 -08:00
Mario
c3ec5d4d6a do not try to fetch legacy zot zotfeed - they will not return anything useful 2021-02-17 20:16:20 +00:00
Mario
0aeb4d6fb5 php8: fix mod mail if there are no messages 2021-02-17 19:41:27 +00:00
Mario
edd4ac791f remove logging 2021-02-17 18:15:09 +00:00
Mario
27577824de fix php8 issue in include/oembed and unencapsulate for zot_refresh() 2021-02-17 18:14:29 +00:00
nobody
0b95e061a3 more zap export work 2021-02-17 01:15:07 -08:00
nobody
383917eb0f more zap export compatibility work 2021-02-17 01:05:30 -08:00
nobody
7e3046b85c more work on zap channel export. 2021-02-16 23:38:17 -08:00
Mario Vavti
281b2261af reduce loglevel until the most glaring php8 issues will be resolved 2021-02-16 14:35:01 +01:00
Mario
3eaf0b7f23 php8 another fix 2021-02-16 12:56:34 +00:00
Mario
76ad2c0fa4 php8 fix 2021-02-16 12:41:27 +00:00
Mario
efaadf54d3 make sure we do not try to update columns which do not exist 2021-02-16 09:21:55 +00:00
Mario
6f71c6d950 fix detection of multiline codeblocks after recent change to bbcode() 2021-02-15 19:18:49 +00:00
Mario
ad0b0364b8 missing files 2021-02-15 18:42:21 +00:00
Mario
e8c2e17bc9 compser update twbs/bootstrap 2021-02-15 18:41:44 +00:00
Mario
6fae291cc8 missing file 2021-02-15 18:40:00 +00:00
Mario
1e48be7ab7 compser update symfony/polyfill-ctype 2021-02-15 18:39:11 +00:00
Mario
0cd4c34101 compser update sabre/dav /vobject 2021-02-15 18:35:40 +00:00
Mario
02401ea9fd composer update ramsey/collection 2021-02-15 18:29:24 +00:00
Mario
18c8f1b903 composer update brick/math 2021-02-15 18:27:20 +00:00
Mario
4171a0136a revert debug code 2021-02-15 18:25:04 +00:00
Mario
ba29a6ce4d composer update smarty 2021-02-15 18:23:26 +00:00
Mario
d72a096fa5 fix preview generating duplicate IDs 2021-02-15 10:15:57 +00:00
Mario
ed99392001 move substitution of new lines with <br> to the end of bbcode(). This will fix issue #1512. 2021-02-15 08:20:42 +00:00
Mario
50e9a12ca5 Merge branch 'fix-public-permissions-in-display' into 'dev'
FIX: Display urls won't show to permitted remote observers

See merge request hubzilla/core!1909
2021-02-14 16:16:26 +00:00
M. Dent
d6b259bb27 FIX: Display urls won't show to permitted remote observers 2021-02-14 17:16:25 +01:00
Mario
f94b046333 changelog
(cherry picked from commit 5e8e6dc458)
2021-02-13 21:23:04 +01:00
Mario
5e8e6dc458 changelog 2021-02-13 20:20:46 +00:00
Mario
9751efb709 version 5.2.2 2021-02-13 21:17:13 +01:00
Mario
7b2f53cc69 fix ping_site() issue
(cherry picked from commit 22e0175ab7)
2021-02-13 21:15:49 +01:00
Mario
22e0175ab7 fix ping_site() issue 2021-02-13 19:30:15 +00:00
Mario
0ffb09aa40 onepoll: add date_begin argument to poll url 2021-02-11 21:05:45 +00:00
Mario
8054d7ad66 remove logging 2021-02-11 21:01:16 +00:00
Mario
d3e70acacd make encode_item_collection() deal with extra query args 2021-02-11 21:00:10 +00:00
Mario
6f520cadb7 actor will be stored in the next step decode_note() 2021-02-11 11:13:06 +00:00
Mario
becdd64257 update 1242 2021-02-10 20:59:30 +00:00
Mario
464a0634d6 use (un)obscurify 2021-02-10 20:40:28 +00:00
Mario
391db61629 revert z_(un)obscure() until (un)obscurify() will be implemented and a update will take care of the data in db 2021-02-10 19:27:00 +00:00
Mario
e6450acc03 version 2021-02-09 19:13:32 +00:00
Mario
e75ae17662 whitespace 2021-02-09 14:09:26 +00:00
Mario
3b3c93f9b3 undo accidental revert in last commit 2021-02-09 14:05:00 +00:00
Mario
b4693870ba port Lib/Crypto from zap 2021-02-09 13:50:03 +00:00
Mario
5aee2f172e restructure keyutiÃls tests 2021-02-08 20:05:05 +00:00
Mario
6b8b42fb21 fix line separators 2021-02-08 16:16:56 +00:00
Mario
320e95aaae composer 2021-02-08 16:08:31 +00:00
Mario
1bcf84f275 fix test 2021-02-08 16:04:56 +00:00
Mario
a8e0bd1f12 keyutils tests 2021-02-08 13:37:48 +00:00
Mario
eb05e5a205 revert include/crypto to its previous state for reference - we are now using Lib/Keyutils for key conversion 2021-02-08 10:55:35 +00:00
Mario
d316d9436b mixed up variables 2021-02-08 10:17:05 +00:00
Max Kostikov
b2e4a4b2b1 Merge branch 'dev' into 'dev'
Use datetime interval in public tag cloud query to support queueworker deduplication

See merge request hubzilla/core!1908
2021-02-06 10:41:33 +00:00
Max Kostikov
e1d622c49f Use datetime interval in public tag cloud query to support queueworker deduplication 2021-02-06 11:36:22 +01:00
Max Kostikov
8bb77bcfd6 Fix new Imagemagick object 2021-02-05 15:32:09 +01:00
Andrzej Budziński
f4ecc0dfb9 Fixes:
- view/pl/hmessages.mo
- view/pl/hmessages.po
- view/pl/hstrings.php
2021-02-05 04:11:52 +01:00
Andrzej Budziński
111ae9812c Fixes:
- view/pl/hmessages.mo
- view/pl/hmessages.po
- view/pl/hstrings.php
2021-02-04 23:53:25 +01:00
Mario Vavti
a9070382e7 bump version 2021-02-04 22:26:29 +01:00
Mario Vavti
9e22641425 add Lib/Keyutils 2021-02-04 22:20:55 +01:00
Mario Vavti
19007dd8eb move key conversion to separate lib 2021-02-04 22:16:48 +01:00
Mario Vavti
03e1f5f8a4 remove unused function 2021-02-04 21:49:25 +01:00
Mario Vavti
6bb73e14b6 key conversion functions cleanup 2021-02-04 21:31:37 +01:00
Mario Vavti
41f84dabcc use phpseclib for key transformations 2021-02-04 21:21:22 +01:00
Mario Vavti
cd79d12e5b phpseclib missing files 2021-02-04 21:05:17 +01:00
Mario Vavti
a6162d3134 downgrade phpseclib to version 2 2021-02-04 21:01:25 +01:00
Andrzej Budziński
ba73845bad Merge branch 'dev' into translation-pl 2021-02-03 15:00:24 +01:00
Andrzej Budziński
7ece28b981 Fixes:
- view/pl/hmessages.mo
- view/pl/hmessages.po
- view/pl/hstrings.php
2021-02-03 14:58:06 +01:00
Mario Vavti
34b28cd8d3 fix wrong operand 2021-02-03 10:22:34 +01:00
Mario Vavti
9a170791e4 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-02-03 10:12:02 +01:00
Andrzej Budziński
5799a073fe Fixes:
- doc/pl/admin/administrator_guide.md
- doc/pl/about/project.bb
- doc/pl/TermsOfService.md
2021-02-03 02:19:27 +01:00
Mario
44b559fb1d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-02-02 12:58:01 +00:00
Mario
2167d12b3f composer add phpseclib 2021-02-02 12:57:46 +00:00
Mario Vavti
e312c381d8 import_xchan() $arr photo structure has changed 2021-02-02 11:47:38 +01:00
Mario Vavti
af6f7f244e Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-02-02 10:58:28 +01:00
Mario Vavti
f3f49cf80f fix php8 issues 2021-02-02 10:58:10 +01:00
Andrzej Budziński
85b1bc7929 Fixes:
- doc/pl/feature/additional/overview.md
2021-02-02 03:17:25 +01:00
Andrzej Budziński
de36172af3 Fixes:
- doc/pl/feature/additional/overview.md
2021-02-02 03:09:04 +01:00
Andrzej Budziński
f5fba51f5c Fixes:
- doc/context/pl/settings/features/help.html: fixes
2021-02-02 03:00:19 +01:00
Andrzej Budziński
a2185c7886 Polish translatons - fixes, typos, and new translation
1) view/pl/messages.po: fixes & typos
2) doc/pl/admin/administrator_guide.md: fixes & typs
3) doc/pl/feature/*: new translations (needed work yet)
4) doc/pl/Features.md: fixes
5) doc/context/pl/cards/help.html: fixes
6) doc/context/pl/settings/features/help.html: fixes
7) doc/context/pl/settings/tokens/help.html: fixes
8) view/pl/register_verify_member.tpl: fixes
2021-02-02 02:50:13 +01:00
Mario
08c9152abd fix getting mimetype via getimagesize() and do not default to image/jpeg yet if it could not be found 2021-02-01 22:58:55 +00:00
Mario
70fa7ad8d0 too many arguments 2021-02-01 20:52:35 +00:00
Mario
cd081ac077 remove unused/commented out code 2021-02-01 14:32:28 +00:00
Mario
197338a727 remove logging 2021-02-01 09:30:22 +00:00
Mario
61e7791d31 Merge branch 'dev' into 'dev'
Better profile photo fetch processing

See merge request hubzilla/core!1906
2021-02-01 08:53:10 +00:00
Max Kostikov
de91d2c804 Better profile photo fetch processing 2021-02-01 09:53:09 +01:00
Mario
11f5550512 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-31 20:37:29 +00:00
Mario
d99611e7dd add fetch_provider hook 2021-01-31 20:37:16 +00:00
Max Kostikov
c0933c90e8 Fix copypaste 2021-01-31 15:26:55 +01:00
Max Kostikov
21b3ba38e7 Fix polish plurals function 2021-01-31 12:05:02 +01:00
Max Kostikov
bac87a8aec Fix polish plurals function 2021-01-31 12:04:26 +01:00
Hilmar R
fae5515350 forgotten docs 2021-01-30 23:19:03 +01:00
Hilmar R
68d5969d33 validate,invite 2021-01-30 23:15:13 +01:00
Max Kostikov
a235917d48 Merge branch 'translation-pl' into 'dev'
New fixes & translations

See merge request hubzilla/core!1907
2021-01-30 18:40:37 +00:00
Andrzej Budziński
d2eb10d7ff Fixes (!1905):
- view/pl/hmessages.po
- view/pl/hstrings.php
2021-01-30 18:42:47 +01:00
Andrzej Budziński
89bf71b227 New fixes & translatosns:
- doc/pl/tutorials/*: 100%
- doc/pl/checking_account_guota_usage.bb: 100%
- doc/pl/member/member_guide.bb: fixes
- doc/pl/admin/hub_snapshots.md: fixes
- view/pl/hmessage.po: fixes
- view/pl/hstrings.po: fixes to generated code
2021-01-30 14:03:39 +01:00
Hilmar R
3773bceb46 context help register en,de 2021-01-29 23:25:47 +01:00
Mario
7686b48723 code format only 2021-01-29 07:36:56 +00:00
Hilmar R
4ecb4189b8 Register panel interaction consistence usage 2021-01-28 22:08:38 +01:00
Mario
840dbbe8ba code format only 2021-01-28 15:50:34 +00:00
Mario
ab4863a2e0 AS discovery for mod profile 2021-01-28 15:44:57 +00:00
Mario
8c2442eca5 AS channel discovery with custom access header 2021-01-28 14:57:37 +00:00
Mario Vavti
8b78e18fb8 keep file permissions in util folder at 755 2021-01-27 11:56:58 +01:00
Mario
66640a206e fix issue in view/pl/hstrings.php 2021-01-27 10:35:17 +00:00
Mario
15c90371e0 Merge branch 'customjotheaders' into 'dev'
Custom "headers" in item creation form.

See merge request hubzilla/core!1901
2021-01-27 10:25:26 +00:00
M. Dent
00fe7bb1bb Custom "headers" in item creation form. 2021-01-27 11:25:26 +01:00
Mario
a2728167bc Merge branch 'dev' into 'dev'
Rebuild public tags cloud not often than once per 5 mins.

See merge request hubzilla/core!1900
2021-01-27 10:23:59 +00:00
Max Kostikov
6326605c99 Revert "Fix directory permissions on create"
This reverts commit 85c5e1178a57865ad977c260725da2839ebb4d98
2021-01-27 11:23:59 +01:00
Mario
7cd4f60922 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-27 10:15:37 +00:00
Mario
af719fea40 fix file permissions. 755 for dirs, 644 for files 2021-01-27 10:15:26 +00:00
Max Kostikov
0af458768f Fix wrong redbasic theme permissions 2021-01-27 12:14:30 +02:00
Mario
3ba46873ba Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-27 09:59:40 +00:00
Mario
f4cc91f0f5 Merge branch 'translation-pl' into 'dev'
Translation pl

Polish translations (used on hub.hubzilla.pl)
- view/pl: 100%
- doc/pl: ~40%
- doc/context/pl: 100%
- doc/macros/pl: 100%

See merge request hubzilla/core!1902
2021-01-27 09:57:30 +00:00
Andrzej S. Budziński
f813671b67 Merge branch 'translation-pl' into 'dev'
Translation pl

Polish translations (used on hub.hubzilla.pl)
- view/pl: 100%
- doc/pl: ~40%
- doc/context/pl: 100%
- doc/macros/pl: 100%

See merge request hubzilla/core!1902
2021-01-27 10:57:30 +01:00
Hilmar R
d0d6170a71 login panel, reg limits. 2021-01-27 00:20:18 +01:00
Mario
74f8f2d956 thread listener improvements 2021-01-26 12:11:01 +00:00
Mario
f0ee4c3cef port fix from zap: catch a complex edge case where some public stream comments were not being delivered and should have been 2021-01-26 10:35:24 +00:00
Mario
6878445319 use mail envelope instead of lock icon for direct messages 2021-01-26 10:29:03 +00:00
Mario
de34dac6cc port youtube embed fix from zap 2021-01-26 09:56:28 +00:00
Mario
1c8d298f3f Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-26 09:21:21 +00:00
Mario
777af6e7ad Libzot::fetch_conversation() fixes 2021-01-26 09:21:16 +00:00
Mario Vavti
82dbdf7c70 fix issues in Activity::encode_item_collection() after recent changes 2021-01-26 10:07:41 +01:00
Mario Vavti
4cf05891d7 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-25 21:52:29 +01:00
Mario Vavti
d4198223bc invoke channel discovery by hash instead of address and add thread listeners only if we also send them the post 2021-01-25 21:52:17 +01:00
Mario
1b4bbcc891 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-25 20:28:03 +00:00
Mario
0e9d99c603 expose manual public item import from searchbar, set commen_policy in Activity::store() to what we get if we get something otherwise default to authenticated, comments by the owner have the relay flag set and therefor $perm will be not be set to post_comments - always check if we own the parent in lib/libzot (not only if $perm = send_stream) if otherwise not allowed 2021-01-25 20:27:50 +00:00
Charlie Root
3ed444b4b4 Run storageconv from web server user 2021-01-25 18:35:28 +02:00
Hilmar R
cd98e75a42 Two field positions 2021-01-24 23:53:28 +01:00
Mario
77793e17c0 Merge branch 'dev' into 'dev'
Add support filesystem storage for xchan profile photos

See merge request hubzilla/core!1898
2021-01-24 20:03:35 +00:00
Max Kostikov
552796286e Add support filesystem storage for xchan profile photos 2021-01-24 21:03:34 +01:00
Hilmar R
3f031399cb auto channel create adjustments 2021-01-24 20:59:11 +01:00
Mario
e486442eb1 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-24 19:55:50 +00:00
Mario
2035828042 revert externals/zotfeed functionality due to scaling issues. Save zotfeed consumers that are not our contacts in thread listeners 2021-01-24 19:55:29 +00:00
Hilmar R
0a16674f6e auto channel create adjustments, zar log reg msgs 2021-01-24 16:44:58 +01:00
Mario
4fbedb6750 extra check for item_private in fetch_and_store_parents() 2021-01-24 15:00:01 +00:00
Hilmar R
9365b8691e 2 fields dups removed 2021-01-23 23:58:20 +01:00
Max Kostikov
6b0c61ac6b Merge branch 'dev' into 'dev'
Variable typo

See merge request hubzilla/core!1897
2021-01-23 20:57:47 +00:00
Max Kostikov
0a13c794ab Variable typo 2021-01-23 21:55:50 +01:00
Max Kostikov
a53f286467 Merge branch 'dev' into 'dev'
Don't fetch profile photos from own hub

See merge request hubzilla/core!1896
2021-01-23 20:47:06 +00:00
Max Kostikov
e4ed5ed264 Do not store multiple profile images thumbnails 2021-01-23 21:45:20 +01:00
Max Kostikov
74441f2f00 Don't fetch profile photos from own hub 2021-01-23 21:38:03 +01:00
Max Kostikov
007de17702 Merge branch 'dev' into 'dev'
Bump DB update version

See merge request hubzilla/core!1895
2021-01-23 15:24:44 +00:00
Max Kostikov
ecf2e4e0ee Bump DB update version 2021-01-23 16:22:29 +01:00
Hilmar R
33825ba0b4 typo 2021-01-23 16:08:16 +01:00
Hilmar R
67db1c6e9b melt diff prod fork 4.6.2 air onto 5.2.1 to 5.2.2 DB 1241 2021-01-23 15:24:24 +01:00
Max Kostikov
03910453a9 Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!3
2021-01-23 13:07:09 +00:00
Max Kostikov
30962dadbf Merge branch 'dev' into 'dev'
# Conflicts:
#   Zotlabs/Daemon/Cache_query.php
#   include/contact_widgets.php
#   include/taxonomy.php
2021-01-23 14:04:42 +01:00
Max Kostikov
33951dc1e4 Remove duplicated profile photos 2021-01-23 14:00:38 +01:00
Max Kostikov
893847c649 Fix duplicate profile photos creation for clones 2021-01-23 13:58:05 +01:00
Mario
fbbc53838c fix ramsey/uuid exception 2021-01-23 12:35:02 +00:00
Hilmar R
abdf6f40a2 at end of day, some files probably without conflicts so far 2021-01-23 00:08:25 +01:00
Max Kostikov
7bc0340106 Encode SQL query array 2021-01-22 15:39:48 +01:00
Max Kostikov
bfb9f10234 Encode SQL query array 2021-01-22 15:38:40 +01:00
Max Kostikov
3f34c73f09 Decode SQL query array 2021-01-22 15:37:49 +01:00
Mario
92f420f77c cleanup 2021-01-22 10:42:58 +00:00
Mario Vavti
78716c42d6 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-22 11:16:43 +01:00
Mario Vavti
e6aed4fb8e implement externals via zot6 and zotfeed - part 2 2021-01-22 11:12:39 +01:00
Mario
064effe5fd fix encode_item_collection() 2021-01-22 10:11:27 +00:00
Mario
93ac3c985f implement externals via zot6 and zotfeed - part 1 2021-01-22 10:06:50 +00:00
Hilmar R
523765b968 Merge branch 'master' into air.5 2021-01-22 01:38:43 +01:00
Mario
fe97b63e0b Merge branch 'dev' into 'dev'
Implement SQL query background caching

See merge request hubzilla/core!1894
2021-01-21 09:08:53 +01:00
Max Kostikov
3836e75c89 Implement SQL query background caching 2021-01-21 09:08:53 +01:00
Max Kostikov
28ae78c579 Higher log level 2021-01-21 08:16:15 +01:00
Mario
bdd6d878f1 cleanup lib/libsync 2021-01-21 07:09:19 +00:00
Max Kostikov
8134e9cae0 Process channel categories list in background 2021-01-20 22:28:38 +01:00
Max Kostikov
70ee41f252 Process public tags cloud in background 2021-01-20 22:24:00 +01:00
Max Kostikov
491dffd9b7 Implement SQL query background caching 2021-01-20 22:18:27 +01:00
Max Kostikov
ad42890a0b Swap key and cat for running pid tracking 2021-01-20 22:15:01 +01:00
Mario
5a971a3731 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-20 21:14:29 +00:00
Max Kostikov
ab4455c54c Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!2
2021-01-20 22:12:15 +01:00
Max Kostikov
6cca06f641 Merge branch 'dev' into 'dev'
Use Zot6 on pinned content sync between clones

See merge request hubzilla/core!1893
2021-01-20 22:09:21 +01:00
Mario
c5d37a0831 remove logging 2021-01-20 20:43:51 +00:00
Mario
57645386b2 looks like we get arrays or json strings here for some reason 2021-01-20 20:42:59 +00:00
Mario
b242347fa1 onepoll via zot6 to /zotfeed which implements an outbox 2021-01-20 20:17:50 +00:00
Max Kostikov
15b2aa660b Update Pin.php 2021-01-20 13:53:09 +01:00
Max Kostikov
4da4f2367f Use Zot6 on pinned content sync between clones 2021-01-20 13:18:48 +01:00
Max Kostikov
9612a69a64 Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!1
2021-01-20 13:15:40 +01:00
Mario
4e9d8e1a83 fix abandon days setting for onepoll 2021-01-18 21:10:59 +00:00
Mario
6083bfea2f lib/activity cleanup and remove unused code - requires addon update 2021-01-18 20:39:23 +00:00
Mario
08264f8d11 more cleanup daemon/thumbnail 2021-01-18 14:35:40 +00:00
Mario
8b93136773 more cleanup daemon/queue 2021-01-18 14:35:00 +00:00
Mario
c7a82a6a84 more cleanup daemon/poller 2021-01-18 14:33:19 +00:00
Mario
ef67e18161 more cleanup daemon/onepoll 2021-01-18 14:29:01 +00:00
Mario
08d2fb4ed4 more cleanup daemon/onedirsync 2021-01-18 14:24:44 +00:00
Mario
836637621d more cleanup daemon/notifier 2021-01-18 14:23:23 +00:00
Mario
6e7a2d0d96 more cleanup daemon/master 2021-01-18 14:13:58 +00:00
Mario
101005f3d2 more cleanup daemon/importfile 2021-01-18 14:11:29 +00:00
Mario
8f88543478 more cleanup daemon/importdoc 2021-01-18 14:10:38 +00:00
Mario
f1ac5bb667 more cleanup daemon/gprobe 2021-01-18 14:09:48 +00:00
Mario
8e5df2dd22 more cleanup daemon/externals 2021-01-18 14:08:31 +00:00
Mario
441525750f more cleanup daemon/expire 2021-01-18 14:02:37 +00:00
Mario
9acfc44ac9 cleanup daemon/expire 2021-01-18 14:00:21 +00:00
Mario
d5bd09b983 cleanup daemon/deliver_hooks, daemon/directory 2021-01-18 13:49:58 +00:00
Mario
45350179b4 cleanup daemon/deliver 2021-01-18 13:41:34 +00:00
Mario
d0f3d2b2a5 cleanup daemon/curlauth 2021-01-18 13:40:01 +00:00
Mario
3742fe80fc only var can be passed by reference, cleanup 2021-01-18 13:37:54 +00:00
Mario
e191966e69 only var can be passed by reference, cleanup 2021-01-18 13:36:47 +00:00
Mario
2c8e122008 cleanup daemon/checksites 2021-01-18 13:29:48 +00:00
Mario
2729f466d5 cleanup 2021-01-18 13:23:29 +00:00
Mario
f4b71fbec1 cleanup 2021-01-18 13:21:13 +00:00
Mario
6695225492 cleanup 2021-01-18 13:08:13 +00:00
Mario
4f74d1d877 cleanup 2021-01-18 13:00:39 +00:00
Mario
bee84e9b00 whitespace 2021-01-18 12:56:07 +00:00
Mario
faaa2d4472 $match should be array 2021-01-18 11:21:37 +00:00
Mario
917c6caa14 force arg is not used anymore in drop_item_lolevel() 2021-01-18 08:46:37 +00:00
Mario
cd59c67c67 fix undefined variable 2021-01-18 08:43:08 +00:00
Mario
37f1b774b7 missing import 2021-01-17 15:19:00 +00:00
Mario
828636847e get_item_elements() check against zot6 2021-01-17 14:13:31 +00:00
Mario
06b5f71075 port util/connect to Lib/Connect 2021-01-17 14:06:35 +00:00
Mario
8d37a4239a mark_orphan_hubsxchans() check against zot6 2021-01-17 13:56:23 +00:00
Mario
a925b08e80 get_bookmark_link() check against zot6 2021-01-17 13:52:55 +00:00
Mario
46aefd8883 fix fetch vcard menu entry for zot6 connections 2021-01-17 13:41:27 +00:00
Mario
38a48de826 app_render() check against zot6 2021-01-17 13:35:13 +00:00
Mario
254e30bea1 version 5.2.1 2021-01-16 10:33:46 +01:00
Mario
a16692eeb0 changelog
(cherry picked from commit 485a232ae6)
2021-01-16 10:33:13 +01:00
Mario
485a232ae6 changelog 2021-01-16 09:31:51 +00:00
Mario
d3f8118874 wrong logic
(cherry picked from commit 0d544e2294)
2021-01-16 10:18:29 +01:00
Mario
0d544e2294 wrong logic 2021-01-16 09:17:45 +00:00
Mario
cb3131a166 also check for zot6
(cherry picked from commit 3bcb322156)
2021-01-16 10:14:16 +01:00
Mario
3105f514e4 make attach_upgrade() catch entries where only display_path is missing
(cherry picked from commit 42812078c5)
2021-01-16 10:13:43 +01:00
Mario
395b427787 cleanup mod like 2021-01-16 09:09:54 +00:00
Mario
4d63c37c38 HTTPSig::get_zotfinger_key() only takes the id arg 2021-01-15 21:23:14 +00:00
Mario
a2776ade81 exec is marked deprecated 2021-01-15 21:19:07 +00:00
Mario
5f5b3f3d4c remove unused global var 2021-01-15 21:02:13 +00:00
Mario
60b76c53fc fix undefined var 2021-01-15 20:58:31 +00:00
Mario
e55ea8b126 undefined variable $filename 2021-01-15 20:52:18 +00:00
Mario
889581e35b wrong variable name 2021-01-15 20:36:48 +00:00
Mario
f7222d43c9 only vars can be passed by reference 2021-01-15 20:26:22 +00:00
Mario
1e474c9689 unused variable and missing break statement 2021-01-15 20:14:48 +00:00
Mario
50fb658776 fix undefined variable 2021-01-15 20:10:44 +00:00
Mario
dde0f3a403 formatting 2021-01-15 20:03:49 +00:00
Mario
597d7bd532 formatting 2021-01-15 20:02:03 +00:00
Mario
aa27f93a9c cleanup unused/undefined variables 2021-01-15 20:00:47 +00:00
Mario
ae4b5231bb fix undefined vars in mod cal 2021-01-15 19:37:47 +00:00
Mario
28ef42a424 make functions public static 2021-01-15 19:31:50 +00:00
Mario
70233ea903 remove redundant import and add ext-zip to composer 2021-01-15 19:28:15 +00:00
Mario
63c15c2c8d remove redundant import 2021-01-15 19:11:14 +00:00
Mario
3e1f387b2b Receiver::run() does not take an argument 2021-01-15 19:09:27 +00:00
Mario
77c777512c fix issue in unused function 2021-01-15 19:04:20 +00:00
Mario
02059fb663 bump composer php version 2021-01-15 19:00:04 +00:00
Mario
3205429d24 more wiki issues 2021-01-15 18:57:56 +00:00
Mario
aa8eb9522f wiki issues 2021-01-15 18:55:07 +00:00
Mario
5030157246 argument must be of type boolean 2021-01-15 18:39:07 +00:00
Mario
a3bc9251bf $msg must be array 2021-01-15 18:37:08 +00:00
Mario
5a325cfa7b remove unused variables 2021-01-15 17:21:33 +00:00
Mario
583d3b5580 whitespace 2021-01-15 15:49:22 +00:00
Mario
43e3663721 fix wrong/undefined variables and add sleep interval to notifier calls 2021-01-15 15:48:17 +00:00
Mario
9f8a512eb5 only var can be passed by reference 2021-01-15 15:07:54 +00:00
Mario
3bcb322156 also check for zot6 2021-01-15 15:06:07 +00:00
Mario
1e645cabd4 style fixes 2021-01-15 15:00:53 +00:00
Mario
ee82763d45 add ext-json to composer 2021-01-15 14:47:26 +00:00
Mario
42812078c5 make attach_upgrade() catch entries where only display_path is missing 2021-01-15 10:00:13 +00:00
Mario
83f0c3d1dd some work to fix r_preview in list mode 2021-01-14 14:28:35 +00:00
Mario
e5a70744c0 update changelog
(cherry picked from commit 299c4bda1b)
2021-01-13 11:35:06 +01:00
Mario
5eefdc6485 Merge branch '5.2RC' 2021-01-13 09:50:53 +00:00
Mario
4d2bcbc583 release 5.2 2021-01-13 09:48:47 +00:00
Mario
299c4bda1b update changelog 2021-01-13 09:47:44 +00:00
Mario
f4b9291d42 Merge branch 'dev' into 5.2RC 2021-01-13 09:39:55 +00:00
Mario
b7afc905ec Revert "keyid adapt for backward compatibility to current release part 2"
This reverts commit efb8a29b5f.
2021-01-13 09:34:38 +00:00
Mario
01bd846433 Revert "keyid adapt for backward compatibility to current release"
This reverts commit ff100a499a.
2021-01-13 09:34:03 +00:00
Mario
08f717d4fc Merge branch 'dev' into 5.2RC 2021-01-13 09:01:31 +00:00
Mario
b9fd87b004 do not turn the groups own direkt messages into group items - fixes #1510 2021-01-13 08:54:58 +00:00
Mario
1615f2c79a Merge branch 'dev' into 5.2RC 2021-01-12 09:08:28 +00:00
Mario
f430db0de7 changelog 2021-01-12 09:04:32 +00:00
Mario
32eb603643 lukasreschke/id3parser is not maintained anymore. fix it so that composer dump-autoload will not complain 2021-01-12 08:52:08 +00:00
Mario
c3f387f22a more changelog 2021-01-12 08:35:22 +00:00
Mario
8703caff5f restrict length of short profile title/description to 190characters to omit sql warnings about too long string data 2021-01-12 08:25:09 +00:00
Mario
c5d50c9e47 Ãupdate changelog 2021-01-11 20:33:17 +00:00
Mario
fed4e3e03a Ãupdate changelog 2021-01-11 20:32:33 +00:00
Mario
9d1f73e179 5.2RC4 2021-01-11 19:02:26 +00:00
Mario
ba164d9488 Merge branch 'dev' into 5.2RC 2021-01-11 19:01:02 +00:00
Mario
3fe67eb646 more libzotdir
(cherry picked from commit e339e897ff)
2021-01-11 19:55:07 +01:00
Mario
12ba2c30b9 can not access global from statc method 2021-01-11 08:59:16 +00:00
Mario Vavti
7c1b41019e missing constant definition 2021-01-10 22:42:57 +01:00
Mario Vavti
707110e5a7 sync_directories() omit known dead sites 2021-01-10 21:46:31 +01:00
Mario Vavti
ba9a9cb016 undefined variable 2021-01-10 21:32:42 +01:00
Mario
c1c75c4b67 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-10 00:32:45 +00:00
Mario
0446349b89 missing use statement 2021-01-10 00:32:34 +00:00
Mario Vavti
915cb44601 typo 2021-01-09 23:06:56 +01:00
Mario
17a153fb6d Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-09 21:54:55 +00:00
Mario
e339e897ff more libzotdir 2021-01-09 21:54:41 +00:00
Mario
6b57f163bd fix markup
(cherry picked from commit 4ace4819ff)
2021-01-09 22:05:40 +01:00
Mario
4ace4819ff fix markup 2021-01-09 22:04:47 +01:00
mjfriaza
ce893122af Update Spanish translation
(cherry picked from commit c90d1fc8ef)
2021-01-09 22:02:35 +01:00
Mario
fb5188a8c6 Merge remote-tracking branch 'codeberg/dev' into dev 2021-01-09 21:01:24 +00:00
hubzilla
c17f452fc7 Merge pull request 'Update Spanish translation' (#2) from mjfriaza/hubzilla:dev into dev
Reviewed-on: https://codeberg.org/hubzilla/hubzilla/pulls/2
2021-01-09 21:59:22 +01:00
Mario
71b0f54b7a update sbom 2021-01-09 20:55:40 +00:00
Mario
d387d021fe update sbom 2021-01-09 20:54:48 +00:00
Mario
d6fefc3603 5.2RC3 2021-01-09 20:34:21 +00:00
Mario
efb8a29b5f keyid adapt for backward compatibility to current release part 2 2021-01-09 20:20:48 +00:00
Mario
ff100a499a keyid adapt for backward compatibility to current release 2021-01-09 19:57:55 +00:00
Mario
d89dc65330 remove redundant mail.apd
(cherry picked from commit 898df6287a)
2021-01-09 20:33:12 +01:00
Mario
fa41527f85 fix some php8 fatal errors
(cherry picked from commit 2522d42c71)
2021-01-09 20:32:40 +01:00
Mario
f48d844e42 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-09 19:27:46 +00:00
Mario
898df6287a remove redundant mail.apd 2021-01-09 19:27:32 +00:00
Mario
2522d42c71 fix some php8 fatal errors 2021-01-09 20:22:47 +01:00
Mario
39c5e85564 RC2 2021-01-09 15:50:57 +01:00
Mario
1294c05a91 version 2021-01-09 13:27:57 +00:00
Mario
64f802d4f6 fix error in sql query
(cherry picked from commit 0e2af40329)
2021-01-09 14:25:41 +01:00
Mario
61e782389c more streamline keyid 2021-01-09 13:24:32 +00:00
Mario
7cfb230a5e streamline keyid 2021-01-09 13:22:43 +00:00
Mario
0e2af40329 fix error in sql query 2021-01-09 13:05:31 +00:00
Mario
7f51ff0a8d set resource_type = group_item and resource_id = original mid for forum items so we do not need to query the body for the original mid on edit. 2021-01-08 21:27:06 +00:00
Mario Vavti
d1a61c6dce allow deletes for e.g. w2w posts where we are the author but item wall is not set. ownership is checked at the receiving side anyway 2021-01-08 13:12:01 +01:00
mjfriaza
c90d1fc8ef Update Spanish translation 2021-01-08 11:29:32 +01:00
Mario
42cd046e90 RC1 2021-01-06 20:37:04 +01:00
Mario
52fa350138 error in logic
(cherry picked from commit 16082456df)
2021-01-06 20:35:16 +01:00
Mario
4ea8357c6a remove logging
(cherry picked from commit 49cc69ecc5)
2021-01-06 20:35:03 +01:00
Mario
dd0da70b06 filter out self and child folders from the folder list
(cherry picked from commit a0c8e1959a)
2021-01-06 20:34:49 +01:00
Mario
d80f2a621d simplify attach_folder_select_list()
(cherry picked from commit c7010dac3c)
2021-01-06 20:33:59 +01:00
Mario
16082456df error in logic 2021-01-06 19:32:36 +00:00
Mario
49cc69ecc5 remove logging 2021-01-06 19:27:26 +00:00
Mario
a0c8e1959a filter out self and child folders from the folder list 2021-01-06 19:26:40 +00:00
Mario
c7010dac3c simplify attach_folder_select_list() 2021-01-06 19:22:29 +00:00
Mario
99bfc3aaa0 version 5.3 2021-01-05 08:48:30 +00:00
Mario
43b3922803 dump autoload 2021-01-05 08:45:23 +00:00
Mario
ca70ad1a9f version and strings 2021-01-05 08:44:10 +00:00
Mario Vavti
a250419b59 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-04 20:36:37 +01:00
Mario Vavti
291644f29d fix issue where categories were not saved on forum wall post 2021-01-04 20:36:24 +01:00
Mario
d4e97ab64c more work on tiles 2021-01-04 13:43:46 +00:00
Mario
e92f98d3c6 rounded corners 2021-01-04 11:14:01 +00:00
Mario
999aac19de missing translateable string and adapt icons 2021-01-04 11:09:12 +00:00
Mario
b2f6e5673d some work on the tiles view 2021-01-04 10:58:41 +00:00
Mario
f0d1c962a7 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2021-01-03 20:18:05 +00:00
Mario
6999b8d9b4 fix no channel_id provided for contact_remove() in reply_purge(). fix wrong notifier command 2021-01-03 20:17:45 +00:00
Max Kostikov
46e704d507 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1892
2021-01-03 17:05:03 +01:00
Max Kostikov
308e94ea79 Update hstrings.php 2021-01-03 16:43:45 +01:00
Max Kostikov
0c839b2738 Update hmessages.po 2021-01-03 16:43:22 +01:00
Mario
cff5859c59 mod cloud strings 2021-01-03 14:28:02 +00:00
Mario
6d95f5fc98 files_ng: slightly change the way we display link bbcode 2021-01-03 10:07:54 +00:00
Mario
7684861249 do not check against undefined variable 2021-01-02 21:37:06 +00:00
Mario
9759cb7075 fix typo 2021-01-02 21:18:49 +00:00
Mario
b3a5f9bef4 wrong variable 2021-01-02 21:10:47 +00:00
Mario
3e3b6cc1e1 wrong variable 2021-01-02 21:01:42 +00:00
Mario
474103dc82 remove unused code and fix width and height not defined 2021-01-02 20:56:18 +00:00
Mario
092a8f2d05 fix wrong variable 2021-01-02 20:39:58 +00:00
Mario
2bcf0c354a fix wrong variable 2021-01-02 20:39:47 +00:00
Mario
73cc756cac fix wrong variable 2021-01-02 20:38:56 +00:00
Mario
6091c2dba0 fix wrong variable 2021-01-02 20:38:44 +00:00
Mario
2862a73253 fix typo 2021-01-02 20:38:11 +00:00
Mario
850c3f2b6a fix typos 2021-01-02 18:58:20 +00:00
Mario
98f3e4cbd3 set is_owner does not need to be a per item flag. fix post button visible for collections 2021-01-02 18:53:23 +00:00
Mario
efc8ed4845 make share title h3 2021-01-02 11:20:03 +00:00
Mario
0bc4c7d1a0 version 5.0.8 2020-12-30 15:01:17 +00:00
Mario
be2e754d78 changelog
(cherry picked from commit 817e72846e)
2020-12-30 15:59:13 +01:00
Mario
817e72846e changelog 2020-12-30 14:55:00 +00:00
Mario
220768bffc escape both single and double quotes for the notifications title. fixes issue #1503
(cherry picked from commit 11d61a744d)
2020-12-30 15:40:15 +01:00
Mario Vavti
3cd64bcb22 random_profile: return zot6 entries
(cherry picked from commit 5cefdbf985)
2020-12-30 15:40:03 +01:00
Mario Vavti
86bfb07c29 dirserach: return zot6 entries
(cherry picked from commit 5485f96625)
2020-12-30 15:39:48 +01:00
Max Kostikov
ad08bd62aa Revert "Fix sync item with Zot connections"
This reverts commit 3db4aa69440553788d8f46cf4bbfb38ca4f09130


(cherry picked from commit c063fe0720)
2020-12-30 15:39:33 +01:00
Max Kostikov
d79cab0680 Deduplicate contacts list on autocomplete
(cherry picked from commit d889547b26)
2020-12-30 15:38:26 +01:00
Mario
d1d6f7d838 sse: fix issue with direct message notificationss
(cherry picked from commit d5eeb948d5)
2020-12-30 15:38:09 +01:00
Max Kostikov
e31a7e5c9d Do not revalidate cached photos
(cherry picked from commit ca051e943f)
2020-12-30 15:37:47 +01:00
Max Kostikov
e6f0d9887c Implement Imagemagick resources consumption limiting
(cherry picked from commit 36d89d02e1)
2020-12-30 15:37:28 +01:00
Mario
2855d84fba owa specify key
(cherry picked from commit f2258d4202)
2020-12-30 15:36:25 +01:00
Mario
3c19648a56 fix issue where an array was passed to get_key() instead of a string
(cherry picked from commit 81a1aedeb9)
2020-12-30 15:35:38 +01:00
Mario
8db367c743 remove fallback code - it will not be required if compression is dismissed 2020-12-30 14:30:39 +00:00
Mario
2c4fabba35 store zip files without compression 2020-12-30 14:12:08 +00:00
Mario
dff42ffb41 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2020-12-29 20:16:35 +00:00
Mario
11d61a744d escape both single and double quotes for the notifications title. fixes issue #1503 2020-12-29 20:16:23 +00:00
Mario Vavti
5cefdbf985 random_profile: return zot6 entries 2020-12-29 20:37:23 +01:00
Mario Vavti
5485f96625 dirserach: return zot6 entries 2020-12-29 20:36:41 +01:00
Mario
af0f46d23d Merge branch 'cloneissue' into 'dev'
Fix sync comments with clones

See merge request hubzilla/core!1889
2020-12-29 15:50:33 +01:00
Max Kostikov
c063fe0720 Revert "Fix sync item with Zot connections"
This reverts commit 3db4aa69440553788d8f46cf4bbfb38ca4f09130
2020-12-29 15:50:32 +01:00
Mario
203ba7343c Merge branch 'autocomplete' into 'dev'
Deduplicate contacts list on autocomplete

See merge request hubzilla/core!1891
2020-12-29 11:49:52 +01:00
Max Kostikov
d889547b26 Deduplicate contacts list on autocomplete 2020-12-29 11:49:52 +01:00
Mario
b66e19dc43 Merge branch 'photocache' into 'dev'
Do not revalidate cached photos

See merge request hubzilla/core!1890
2020-12-29 11:49:33 +01:00
Mario
c84e3334bf Merge branch 'tuneimagick' into 'dev'
Implement Imagemagick resources consumption limiting

See merge request hubzilla/core!1888
2020-12-29 11:49:11 +01:00
Mario
d5eeb948d5 sse: fix issue with direct message notificationss 2020-12-28 13:19:40 +00:00
Mario
9670833a5d files_ng: provide a fallback in case the server timed out on compressing the zip file 2020-12-28 10:12:25 +00:00
Max Kostikov
ca051e943f Do not revalidate cached photos 2020-12-26 14:24:04 +01:00
Max Kostikov
36d89d02e1 Implement Imagemagick resources consumption limiting 2020-12-26 14:10:56 +01:00
Mario
f4bfa77942 version bump 2020-12-23 09:16:45 +00:00
Mario
f2258d4202 owa specify key 2020-12-23 08:32:59 +00:00
Mario
d56bf34326 fix javascript warning 2020-12-23 08:22:31 +00:00
Mario
9fa3dee522 remove deprecated forum autocomplete code 2020-12-23 08:19:11 +00:00
Mario
7ee2192c29 provide some info and remove unused code 2020-12-22 13:33:54 +00:00
Mario
3a38292bab files_ng: improve download handlÃing 2020-12-22 13:23:20 +00:00
Mario
60cbb65d84 files_ng: omit parent folders of a download 2020-12-22 09:01:52 +00:00
Mario
d118ab71e6 files_ng: implement directory and bulk file download 2020-12-21 21:37:10 +00:00
Mario
81a1aedeb9 fix issue where an array was passed to get_key() instead of a string 2020-12-21 21:31:52 +00:00
Mario
1fd576436b changelog
(cherry picked from commit 638f7a1c89)
2020-12-21 09:44:38 +01:00
Mario
fac05e7dcd version 5.0.7 2020-12-21 09:05:29 +01:00
Max Kostikov
eef3126f0b Fix CardDAV address book ID
(cherry picked from commit 6579007ca0)
2020-12-21 09:04:36 +01:00
Max Kostikov
2df5a2a66d Use Zot6 for CardDAV and CalDAV sync between clones
(cherry picked from commit c596fb14bb)
2020-12-21 09:04:26 +01:00
Mario Vavti
01e7e3c24a handle owa with hubloc_id_url only
(cherry picked from commit ed4bf1c13d)
2020-12-21 09:04:04 +01:00
Mario
8112dee91e do not json_encode the attach array - fixes #1499
(cherry picked from commit 5b24225251)
2020-12-21 09:03:46 +01:00
Mario
638f7a1c89 changelog 2020-12-21 08:03:17 +00:00
Max Kostikov
5de4c3cc3f Merge branch 'dev' into 'dev'
Use Zot6 for CardDAV and CalDAV sync between clones

See merge request hubzilla/core!1886
2020-12-20 00:01:50 +01:00
Max Kostikov
6579007ca0 Fix CardDAV address book ID 2020-12-19 23:57:14 +01:00
Max Kostikov
c596fb14bb Use Zot6 for CardDAV and CalDAV sync between clones 2020-12-19 22:58:17 +01:00
Max Kostikov
116fc4e00d Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!4
2020-12-19 22:02:51 +01:00
Mario
57f6f54f29 refresh_all will be called from the notifier in Daemon/Directory 2020-12-19 15:21:34 +00:00
Mario
8640e6d1df deprecate ! and !! forum tags 2020-12-18 13:26:51 +00:00
Mario
801583fd07 flag forums where we do not have post permissions and filter them from the acl selector 2020-12-18 12:40:36 +00:00
Mario Vavti
4987534eba Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2020-12-18 10:02:43 +01:00
Mario Vavti
ed4bf1c13d handle owa with hubloc_id_url only 2020-12-18 10:02:13 +01:00
Mario
5b24225251 do not json_encode the attach array - fixes #1499 2020-12-17 18:57:04 +00:00
Mario
886be8c452 changelog for version 5.0.6
(cherry picked from commit 269efb9c1e)
2020-12-17 14:46:08 +01:00
Mario
269efb9c1e changelog for version 5.0.6 2020-12-17 13:45:14 +00:00
Mario Vavti
612448e4ae update to fix empty hubloc_id_url caused by clone import bug for zot hublocs which was fixed in 4693069a06 2020-12-17 13:29:15 +00:00
Mario Vavti
82db19d54c restrict owa to zot6 and zot network until the hubloc madness with activitypub and possibly also diaspora will be solved
(cherry picked from commit 7ebba75fa2)
2020-12-17 14:26:32 +01:00
Mario
06aa3e6b8c fix issue with abconfig when cloning a channel
(cherry picked from commit f13bff2a76)
2020-12-17 14:26:00 +01:00
Mario
abf985c69e owa: dismiss deleted hublocs
(cherry picked from commit 006a409eb8)
2020-12-17 14:25:06 +01:00
Mario
c176b54f6b use refresh_all in mod import
(cherry picked from commit 59f1c038fe)
2020-12-17 14:24:49 +01:00
Mario
b24e691e7e try to fix more hubloc anomalies: use refresh_all in remove_obsolete_hublocs() and use Libzot::encode_locations() instead of zot_encode_locations() in notifier
(cherry picked from commit dec4ceabb5)
2020-12-17 14:24:16 +01:00
Mario
c2e43dc1b0 fix missing hubloc_id_url for zot hubloc when importing a channel
(cherry picked from commit 4693069a06)
2020-12-17 14:23:09 +01:00
Mario
7b7739c32c try to prevent hubloc confusion in some places
(cherry picked from commit 61cfeb5bdb749319357912d958cd13304b895bce)

(cherry picked from commit 634ace552d)
2020-12-17 14:22:44 +01:00
Mario
269172406f make gprobe look for zot6 only
(cherry picked from commit 1d3437aa419adde319d2a3f5d98e7f8fe4418f27)

(cherry picked from commit 751a1ba969)
2020-12-17 14:20:58 +01:00
Mario
4c054d6de9 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2020-12-17 12:27:49 +00:00
Mario Vavti
34a58369f2 update to fix empty hubloc_id_url caused by clone import bug for zot hublocs which was fixed in 4693069a06 2020-12-17 13:27:11 +01:00
Mario Vavti
59b4764a15 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2020-12-17 12:46:33 +01:00
Mario Vavti
7ebba75fa2 restrict owa to zot6 and zot network until the hubloc madness with activitypub and possibly also diaspora will be solved 2020-12-17 12:46:22 +01:00
Mario
b2e80efe3f files_ng: provide bbcode snippets in the info panel 2020-12-17 10:04:24 +00:00
Mario
b4b566318a files_ng: fix regression in finding the right path in certain situations and add a info panel with attach and zrl bbcode 2020-12-16 16:57:56 +00:00
Mario
27df896a9c files_ng: implement lockview 2020-12-16 08:26:19 +00:00
Mario
8188a551f3 fix regression in files aclselect 2020-12-15 12:12:38 +00:00
Mario
f13bff2a76 fix issue with abconfig when cloning a channel 2020-12-15 11:29:45 +00:00
Mario
59f1c038fe use refresh_all in mod import 2020-12-15 10:04:22 +00:00
Mario
006a409eb8 owa: dismiss deleted hublocs 2020-12-15 08:40:02 +00:00
Mario
dec4ceabb5 try to fix more hubloc anomalies: use refresh_all in remove_obsolete_hublocs() and use Libzot::encode_locations() instead of zot_encode_locations() in notifier 2020-12-15 08:36:14 +00:00
Mario
4a902dbbbe fix file sync issues 2020-12-14 22:06:47 +00:00
Mario
8e488e2913 handle removal of terms in attach_delete() when deleting a ressource 2020-12-14 21:56:19 +00:00
Mario
e58e27ce22 sync categories 2020-12-14 21:38:49 +00:00
Mario
78c0926a64 improve when to show link to parent path 2020-12-14 20:22:13 +00:00
Mario
4693069a06 fix missing hubloc_id_url for zot hubloc when importing a channel 2020-12-14 14:06:07 +00:00
Mario
70e529ef5d add another parent element to wrap the tools 2020-12-14 11:17:36 +00:00
Mario
2a154f8c9a merge branch files_ng into dev 2020-12-14 11:02:20 +00:00
Mario
634ace552d try to prevent hubloc confusion in some places
(cherry picked from commit 61cfeb5bdb749319357912d958cd13304b895bce)
2020-12-12 22:41:38 +01:00
Mario
751a1ba969 make gprobe look for zot6 only
(cherry picked from commit 1d3437aa419adde319d2a3f5d98e7f8fe4418f27)
2020-12-12 22:41:11 +01:00
Mario
d95573741d changelog 2020-12-12 19:02:28 +00:00
Max Kostikov
faf4bcdd62 Remove duplicate delete terms query
(cherry picked from commit a27c593a2a)
2020-12-12 19:56:24 +01:00
Mario
badae90051 Merge branch 'dev' into 'dev'
Remove duplicate delete terms query

See merge request hubzilla/core!1885
2020-12-12 19:44:01 +01:00
Max Kostikov
a27c593a2a Remove duplicate delete terms query 2020-12-12 19:43:57 +01:00
Mario
f699442bec bump version 2020-12-12 19:40:49 +01:00
Mario
8720931a53 fix hubloc issue in mod getfile
(cherry picked from commit b0b9b9f28974f9016e47491e81876224c57a7e3b)

(cherry picked from commit 8c1c49a45e)
2020-12-12 19:36:42 +01:00
Max Kostikov
600dcdfc58 Remove duplicate delete terms query 2020-12-12 10:10:32 +01:00
Max Kostikov
a4b83327c2 Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!3
2020-12-12 10:07:39 +01:00
Mario
8c1c49a45e fix hubloc issue in mod getfile
(cherry picked from commit b0b9b9f28974f9016e47491e81876224c57a7e3b)
2020-12-11 12:35:54 +01:00
Mario
b1f0014429 Merge branch 'dev' into 'dev'
Skip profile photo query from addons for undefined channel id

See merge request hubzilla/core!1884
2020-12-07 11:08:41 +01:00
Max Kostikov
d984918c75 Skip profile photo query from addons for undefined channel id 2020-12-07 11:08:41 +01:00
Mario
21ac4b5139 remove announce activity from response activites array
(cherry picked from commit 52c78c757ae73082ed29e48707b2313e65020db3)
2020-12-07 11:03:03 +01:00
Max Kostikov
92eb7a0be4 Formatting 2020-12-04 14:45:27 +01:00
Max Kostikov
b26b1c0820 Skip profile photo query from addons for undefined channel id 2020-12-04 14:36:29 +01:00
Max Kostikov
a9dd6d6bdb Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!2
2020-12-04 14:33:34 +01:00
Mario
d60c53cd12 version 5.0.4 2020-12-01 08:46:22 +00:00
Mario
6b0fe6e0a0 changelog
(cherry picked from commit 9c7ec55b40)
2020-12-01 09:45:09 +01:00
Mario
9c7ec55b40 changelog 2020-12-01 08:43:59 +00:00
Mario
28f1f4cbdc missing parenthesis
(cherry picked from commit 45b41f0787)
2020-12-01 09:38:59 +01:00
Mario
508b3ce730 Ãfix regerssion in updating the primary
(cherry picked from commit c47434634d)
2020-12-01 09:38:48 +01:00
Mario
87ecc61fb4 dismiss title in response activity
(cherry picked from commit eb2ad3fc438544192cda95d88a4c2a54ec1e0014)

(cherry picked from commit b89355b9d8)
2020-12-01 09:38:17 +01:00
Mario
ce4d664abc Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2020-12-01 08:31:50 +00:00
Mario
45b41f0787 missing parenthesis 2020-12-01 08:31:27 +00:00
Mario
c47434634d Ãfix regerssion in updating the primary 2020-12-01 08:31:15 +00:00
Mario
b89355b9d8 dismiss title in response activity
(cherry picked from commit eb2ad3fc438544192cda95d88a4c2a54ec1e0014)
2020-11-28 11:40:03 +01:00
Mario
3f40d6f7b7 run composer install --no-dev 2020-11-27 11:09:48 +00:00
Mario
155daac8ad run composer install --no-dev 2020-11-27 11:08:45 +00:00
Mario
f9d24d07dd composer autoload dump 2020-11-27 10:50:46 +00:00
Mario
d91e35e197 bring back require but with the correct path 2020-11-27 10:47:24 +00:00
Mario
a967dd9d13 fix languagedetect warnming 2020-11-27 08:04:41 +00:00
Mario
f4bb7bcbff update composer libs 2020-11-27 08:04:00 +00:00
Mario
0f6166da00 Merge branch 'dev' 2020-11-26 18:43:53 +00:00
Mario
07e5b8295e changelog 2020-11-26 18:41:51 +00:00
Mario
9afdf86961 coverage config 2020-11-26 12:10:16 +00:00
Mario
f4f1974be0 those would require dbunit 2020-11-26 12:01:15 +00:00
Mario
6f6399ca0f fix test 2020-11-26 11:43:07 +00:00
Mario
5018c0fbb8 add dms/phpunit-arraysubset-asserts 2020-11-26 11:37:13 +00:00
Mario
188975ccbd update gitlab-ci 2020-11-26 11:20:16 +00:00
Mario
5e1addc75e revert folder renaming 2020-11-26 11:14:40 +00:00
Mario
138beeac41 wrong path 2020-11-26 10:24:00 +00:00
Mario
187364d94a set xdebug.mode=coverage in php.ini 2020-11-26 10:21:13 +00:00
Mario
6e74e76fcd update phpunit.xml 2020-11-26 10:12:35 +00:00
Mario
615424d272 update ci file 2020-11-26 10:04:33 +00:00
Mario
d40a7a609e run vendor/bin/phpunit --migrate-configuration 2020-11-26 10:03:39 +00:00
Mario
0ec40f00a9 minor adjustion 2020-11-26 09:52:24 +00:00
Mario
de054026f2 try phpunit 9, remove dbunit (not compatible and abandoned), re-enable xdebug 2020-11-26 09:26:37 +00:00
Mario
175b45d1ed update php-mock 2020-11-26 08:56:38 +00:00
Mario
e236b77817 more psr-4 autoloading standard 2020-11-26 08:48:09 +00:00
Mario
21cd4a1b48 psr-4 autoloading standard 2020-11-26 08:43:03 +00:00
Mario
e9a50371f5 comment out xdebug 2020-11-26 08:30:06 +00:00
Mario
71f8a08e5f update phpunit 2020-11-26 08:19:51 +00:00
Mario
4419c93d80 this should not be required anymore 2020-11-26 07:58:57 +00:00
Mario
fcc13ce02c version 2020-11-25 18:45:37 +00:00
Mario
941db04260 add a uuid version 5 based uuid to imported feeds. if rewrite author for sourced items, also rewrite mid to be fetchable 2020-11-25 13:52:27 +00:00
Mario
87d7a3053a do not reset item_origin to 1 for deleted items to prevent possible looping and do not set item_uplink for sourced rss items - we can not sen anything to them. 2020-11-25 11:01:25 +00:00
Mario
ae11b2c281 profile_load() requires channel_address 2020-11-24 22:14:24 +00:00
Mario
f43577ec27 add logging 2020-11-23 21:26:52 +00:00
Mario
c648c38fb0 fix warning 2020-11-23 20:23:17 +00:00
Mario
34d54fd309 simplify code and fix issue with categories 2020-11-23 19:57:28 +00:00
Mario
891b1428cc do not use chanlink_url() at this place 2020-11-23 18:23:46 +00:00
Mario
453dd38e51 missing include 2020-11-23 14:01:04 +00:00
Mario
f59aefd3d9 store actor of fetched acivities 2020-11-23 09:10:53 +00:00
Mario
451468d129 fix mod item issue with remote channels 2020-11-22 16:37:20 +00:00
Mario
c0adf31da9 fix like issue with remote channels 2020-11-22 13:07:03 +00:00
Mario
bb43c57b07 make simple update more simple again 2020-11-21 20:57:50 +00:00
Mario
6c94bbc93f collase the updated content 2020-11-21 20:52:38 +00:00
Mario
50422c608f fix #1492 2020-11-21 20:35:38 +00:00
Mario
7639157a49 restrict returned html usage to local_channel() until some issues will be worked out 2020-11-21 20:15:05 +00:00
Mario
f74cfaec5f fix pubstream id issue 2020-11-21 10:22:23 +00:00
Mario
d559b4a201 deliver to local hub first 2020-11-21 10:21:14 +00:00
Mario
2d4064aca4 returning the rendered html when liking a post or comment 2020-11-20 20:38:10 +00:00
Mario
337d8ea78c minor cleanup 2020-11-20 14:42:46 +00:00
Mario
4c0a26dbf9 move post_comment() handling via ctrl-enter out of handle_comment_form() - to many issues with multiple triggers 2020-11-20 10:45:35 +00:00
Mario
885edd6261 version 2020-11-20 09:15:19 +00:00
Mario
011de75706 returning the rendered html when posting a comment will make the following update (and its implication in mod pubstream) obsolete 2020-11-20 09:14:46 +00:00
Mario
852e456d44 this is silly but it seems to be required for firefox to stop scrolling in certain conditions 2020-11-18 20:34:41 +00:00
Mario
18136788e4 be more specific 2020-11-18 20:33:32 +00:00
Mario
f1101808b7 fix regression in relation to pustream notifications 2020-11-18 17:09:53 +00:00
Mario
791d5098a0 fix regression 2020-11-18 12:28:20 +00:00
Mario
f2fd12fbe5 Do away with auto updates except for our own actions. We might consider to re-implement this for single thread view like eg /display. Instead of calculating scroll positions during updates, keep track of expanded items and set the expanded state when updating - this fixes issue #1488 2020-11-18 09:52:44 +00:00
Mario
b5ab77908e implement submit on ctrl-enter for post editor and comments 2020-11-17 09:09:36 +00:00
Mario
25620081a1 translation 2020-11-16 09:36:27 +00:00
Mario
5750e6cada Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2020-11-16 09:34:08 +00:00
Mario
394aa76a8f changelog 2020-11-16 09:33:57 +00:00
Mario
35c4deb884 work around an edge case in acl selector
(cherry picked from commit e7c83a81c7)
2020-11-16 10:31:14 +01:00
Mario
0daccead12 changellog 2020-11-16 09:29:49 +00:00
Mario
e7c83a81c7 work around an edge case in acl selector 2020-11-16 09:28:18 +00:00
Mario
dcf8830752 Merge branch 'dev' 2020-11-16 08:26:44 +00:00
Mario
3d519f478a changelog 2020-11-15 13:49:25 +00:00
Mario
3f0fc40ef8 fix ping_site() 2020-11-15 13:44:13 +00:00
Mario
820494c7a6 deprecate daemon/ratenotif 2020-11-15 12:34:10 +00:00
Mario
60b82d3690 more changelog 2020-11-15 11:49:16 +00:00
Mario
57d9b1b332 fix directory post url 2020-11-15 11:48:23 +00:00
Mario
67f8b78a7d changelog 2020-11-15 11:35:26 +00:00
Mario
aada997601 Merge branch 'dev' of https://framagit.org/hubzilla/core into dev 2020-11-15 11:03:47 +00:00
Mario
e5dd108bd7 outq_hash is unique - no need for limit 2020-11-15 11:03:17 +00:00
Mario
ad91ab68ce cleanup 2020-11-15 11:02:21 +00:00
Max Kostikov
66c3c32154 Merge branch 'dev' into 'dev'
Update Russian translation

See merge request hubzilla/core!1883
2020-11-15 11:17:59 +01:00
Max Kostikov
c9ce562369 Update hmessages.po 2020-11-15 11:10:49 +01:00
Max Kostikov
a1f01529a7 Update hstrings.php 2020-11-15 11:10:28 +01:00
Max Kostikov
38985dc4e2 Merge branch 'dev' into 'dev'
Dev sync

See merge request kostikov/core!1
2020-11-15 11:09:44 +01:00
me
78f150cfbc air.s1: field templates checkbox/input/select and one new 2020-11-14 23:37:18 +01:00
Mario
e74c52094f remove dot 2020-11-14 21:37:49 +00:00
Mario
e05f1f95cf bump version 2020-11-14 21:31:45 +00:00
Mario
b63c5f2785 Polling fallback to server sent events. Polling is the default. SSE must be enabled in /admin/site > Advanced > Enable SSE Notifications if desired. 2020-11-14 21:28:50 +00:00
Mario
685c569eaf minor queue adjustments 2020-11-13 13:49:39 +00:00
Mario
b6e3469519 update to fix more broken hublocs and version bump 2020-11-13 09:26:04 +00:00
Mario
16071f300e better check for valid inbox 2020-11-13 09:18:54 +00:00
Mario
a8de999b7c do not store actors without an inbox - they are not valid 2020-11-12 20:17:03 +00:00
Mario
0dcbcf93c2 some work on include/import 2020-11-12 11:50:00 +00:00
Mario
06273e980e Merge branch 'dev' 2020-11-12 09:00:56 +00:00
Mario
c879e5de44 changelog and version bump 2020-11-12 08:57:51 +00:00
Mario
890290fff0 log the body if fetch failed 2020-11-11 12:10:35 +00:00
Mario
cddae14352 do not log exception - it could exhaust memory 2020-11-09 11:31:20 +00:00
Mario
b3e6a3c1e2 make share titles h3 to reflect the original titlÃe size 2020-11-08 19:07:44 +00:00
Mario
255b6a14a8 less hubloc confusion 2020-11-08 12:55:32 +00:00
12653 changed files with 1092053 additions and 454044 deletions

156
.debianinstall/README.md Normal file
View File

@@ -0,0 +1,156 @@
# How to use
## Disclaimers
- **This script does work with a fresh install of Debian 12 only**.
- Do not use if you have already installed and configured a webserver or sql server that was not installed by this script.
### Keep it Simple and Stupid
The script keeps everything as simple as possible (KISS):
- Apache as webserver (there is no choice to use another webserver like nginx)
- default PHP version of Debian
- one single Hubzilla intance only
- re-running the script does no harm
### When to use other Scripts
Use the scripts under [homeinstall](https://framagit.org/hubzilla/core/-/tree/master/.homeinstall)
if you look for more choices. The main differences are:
- Apache or nginx as webserver
- install multiple instances (domains) that run side by side on the server
- adds apache vhosts (instead of using the standard doc root /var/www/html)
- install PHP from https://packages.sury.org/php/ (instead of using the Debian repository)
- graphical installer whiptail
- The script stops (fails) if it finds results of a previous installation. (The [debian-setup.sh](https://framagit.org/ojrandom/core/-/tree/dev/.debianinstall) will just jump over it.)
- If something fails the script tries to clean up everything that was installed up to the point of failure. (That might cause trouble if certbot registered a certificate already.)
- The script under [homeinstall](https://framagit.org/hubzilla/core/-/tree/master/.homeinstall) seems to be an older version of the scripts used for Streams, i.e. [autoinstall](https://codeberg.org/streams/streams/src/branch/dev/contrib/autoinstall) and [easyinstall](https://codeberg.org/streams/streams/src/branch/dev/contrib/easyinstall)
## Preconditions
Hardware
+ internet connection and router at home
+ computer connected to your router (a Raspberry 4 will do for very small Hubs)
Software
+ fresh installation of Debian 12 (bookworm) or Raspberry Pi OS
+ router with open ports 80 and 443 for your web server
You can of course run the script on a VPS or any distant server as long as the above software requirements are satisfied.
## How to run the script
+ Register your own domain (for example at selfHOST) or a free subdomain (for example at freeDNS)
+ Log on to your fresh Debian
- apt-get install git
- mkdir -p /var/www
- cd /var/www
- git clone https://framagit.org/hubzilla/core.git html
- cd html/.debianinstall
- cp config.txt.template config.txt
- nano config.txt
- read the comments carefully
- enter your values: db pass, domain
- (optionally) Enter your values for dyn DNS
- ./debian-setup.sh as root
- ... wait, wait, wait until the script is finished
+ Open your domain with a browser and step throught the initial configuration of your hubzilla instance.
- default database name = hubzilla
- default dababase user = hubzilla
## Optional - Switch verification of email on/off
Do this just before you register the first user without email verification.
In a terminal
su -
cd /var/www/html
Check the current setting
util/config system verify_email
Switch the verification off
util/config system verify_email 0
Check if updates from the repository do work
util/udall
## What the script will do for you...
+ install everything required by your hubzilla instance, basically a web server (Apache), PHP, a database (MySQL), certbot,...
+ create a database
+ run certbot to have everything for a secure connection (httpS)
+ create a script for daily maintenance
- renew certfificate (letsencrypt)
- update of your hubzilla instance for core and addons (git)
- update of Debian
- restart
+ create cron jobs for
- DynDNS (selfHOST.de or freedns.afraid.org) every 5 minutes
- Master.php for your hubzilla instance every 10 minutes
- daily maintenance script every day at 05:30
The script is known to work without adjustments with
+ Hardware
- standard PC with Debian 12 (bookworm)
- Raspberry 5 with Raspberry Pi OS, Debian 12
- for tesing purposes: under localhost inside a virtual machine, [KVM](https://wiki.debian.org/KVM)
+ DynDNS
- selfHOST.de
- freedns.afraid.org
# Step-by-Step - some Details
## Preparations
## Configure your Router
Your webserver has to be visible in the internet.
Open the ports 80 and 443 on your router for your Debian. Make sure your web server is marked as "exposed host".
## Preparations Dynamic IP Address
Follow the instructions in .debianinstall/config.txt.
In short...
Your Hubzilla server must be reachable by a domain that you can type in your browser
cooldomain.org
You can use subdomains as well
my.cooldomain.org
There are two ways to get a domain...
### Method 1: Buy a Domain
...for example buy at selfHOST.de
The cost is 1,50 € per month (2019).
### Method 2: Register a free subdomain
...for example register at freedns.afraid.org
## Note on Rasperry
It is recommended to run the Raspi without graphical frontend (X-Server). Use...
sudo raspi-config
to boot the Rapsi to the client console.

View File

@@ -0,0 +1,110 @@
###############################################
### MANDATORY - database password #############
#
# Please give your database password
# It is better to not use blanks inside the password.
# Example: db_pass=pass_word_with_no_blanks_in_it
db_pass=
###############################################
### MANDATORY - let's encrypt #################
#
# Zot requires encrypted communication via secure HTTP (HTTPS).
# This script automates installation of an SSL certificate from
# Let's Encrypt (https://letsencrypt.org)
#
# Please give the domain name of your hub/instance
#
# Example: my.cooldomain.org
# Example: cooldomain.org
#
# You might use "localhost" for a LOCAL TEST installation.
# This is usefull if you want to debug the server inside a VM.
#
# Example: localhost
#
# Email is optional if you use "localhost".
#
#
le_domain=
le_email=
###############################################
### OPTIONAL - selfHOST - dynamic IP address ##
#
# 1. Register a domain at selfhost.de
# - choose offer "DOMAIN dynamisch" 1,50€/mon at 04/2019
# 2. Get your configuration for dynamic IP update
# - Log in at selfhost.de
# - go to "DynDNS Accounte"
# - klick "Details" of your (freshly) registered domain
# - You will find the configuration there
# - Benutzername (user name) > use this for "selfhost_user="
# - Passwort (pass word) > use this for "selfhost_pass="
#
#
selfhost_user=
selfhost_pass=
###############################################
### OPTIONAL - FreeDNS - dynamic IP address ###
#
# Please give the alpha-numeric-key of freedns
#
# Get a free subdomain from freedns and use it for your dynamic ip address
# Documentation under http://www.techjawab.com/2013/06/setup-dynamic-dns-dyndns-for-free-on.html
#
# - Register for a Free domain at http://freedns.afraid.org/signup/
# - WATCH THIS: Make sure you choose a domain with as less subdomains as
# possible. Why? Let's encrpyt issues a limited count of certificates each
# day. Possible other users of this domain will try to issue a certificate
# at the same day.
# - Logon to FreeDNS (where you just registered)
# - Goto http://freedns.afraid.org/dynamic/
# - Right click on "Direct Link" and copy the URL and paste it somewhere.
# - You should notice a large and unique alpha-numeric key in the URL
#
# http://freedns.afraid.org/dynamic/update.php?alpha-numeric-key
#
# Provided your url from freedns is
#
# http://freedns.afraid.org/dynamic/update.php?U1Z6aGt2R0NzMFNPNWRjbWxxZGpsd093OjE1Mzg5NDE5
#
# Then you have to provide
#
# freedns_key=U1Z6aGt2R0NzMFNPNWRjbWxxZGpsd093OjE1Mzg5NDE5
#
#
freedns_key=
###############################################
### OPTIONAL - do not mess with things below ##
# (...if you are not certain)
#
# Usually you are done here
# Everything below is OPTIONAL
#
###############################################
#
# Database for your hub/instance
# If left empty, both your database and user will be named after your zot instance (hubzilla, zap or misty)
# Use custom name, at least fo the database, if you plan to run more than one hub/instance on the same server
#
db_name=hubzilla
db_user=hubzilla
#
#
# Password for package mysql-server
# Example: mysqlpass=aberhallo
# Example: mysqlpass="aber hallo has blanks in it"
#
mysqlpass=$db_pass
# Password for package phpmyadmin
# Example: phpmyadminpass=aberhallo
# Example: phpmyadminpass="aber hallo has blanks in it"
phpmyadminpass=$db_pass

View File

@@ -0,0 +1,543 @@
#!/bin/bash
#
# How to use
# ----------
#
# This file automates the installation of hubzilla: https://framagit.org/hubzilla/core
# under Debian Linux "bookworm"
#
# 1) Copy the file "config.txt.template" to "config.txt"
# Follow the instuctions there
#
# 2) Switch to user "root" by typing "su -"
#
# 3) Run with "./debian-setup.sh"
# If this fails check if you can execute the script.
# - To make it executable type "chmod +x debian-setup.sh"
# - or run "bash debian-setup.sh"
#
#
# What does this script do basically?
# -----------------------------------
#
# This file automates the installation of a Hubzilla instance under Debian Linux
# - install
# * apache webserver,
# * php,
# * mariadb,
# * adminer,
# * addons
# - configure cron
# * "Master.php" for regular background processes of your hubzilla instance
# * "apt-get update" and "apt-get dist-upgrade" and "apt-get autoremove" to keep linux up-to-date
# * run command to keep the IP up-to-date > DynDNS provided by selfHOST.de or freedns.afraid.org
# - run letsencrypt to create, register and use a certifacte for https
#
#
# Credits
# -------
#
# The script is derived from the easyinstall script of the Streams repository, which is based on
# - Tom Wiedenhöfts (OJ Random) script homeinstall (for Hubzilla, ZAP,...) that was based on
# - Thomas Willinghams script "debian-setup.sh" which he used to install the red#matrix.
function check_sanity {
# Do some sanity checking.
print_info "Sanity check..."
if [ $(/usr/bin/id -u) != "0" ]
then
die 'Must be run by root user'
fi
if [ -f /etc/lsb-release ]
then
die "Distribution is not supported"
fi
if [ ! -f /etc/debian_version ]
then
die "Debian is supported only"
fi
if ! grep -q 'Linux 12' /etc/issue
then
die "Linux 12 (bookworm) is supported only"x
fi
}
function check_config {
print_info "config check..."
# Check for required parameters
if [ -z "$db_pass" ]
then
die "db_pass not set in $configfile"
fi
if [ -z "$le_domain" ]
then
die "le_domain not set in $configfile"
fi
}
function die {
echo "ERROR: $1" > /dev/null 1>&2
exit 1
}
function update_upgrade {
print_info "updated and upgrade..."
# Run through the apt-get update/upgrade first. This should be done before
# we try to install any package
apt-get -q -y update && apt-get -q -y dist-upgrade && apt-get -q -y autoremove
print_info "updated and upgraded linux"
}
function nocheck_install {
# export DEBIAN_FRONTEND=noninteractive ... answers from the package configuration database
# - q ... without progress information
# - y ... answer interactive questions with "yes"
# DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends -q -y install $2
# DEBIAN_FRONTEND=noninteractive apt-get --install-suggests -q -y install $1
DEBIAN_FRONTEND=noninteractive apt-get -q -y install $1
print_info "installed $1"
}
function print_info {
echo -n -e '\e[1;34m'
echo -n $1
echo -e '\e[0m'
}
function print_warn {
echo -n -e '\e[1;31m'
echo -n $1
echo -e '\e[0m'
}
function stop_zotserver {
print_info "stopping apache..."
systemctl stop apache2
print_info "stopping mysql db..."
systemctl stop mariadb
}
function install_apache {
print_info "installing apache..."
nocheck_install "apache2 apache2-utils"
a2enmod rewrite
systemctl restart apache2
}
function install_imagemagick {
print_info "installing imagemagick..."
nocheck_install "imagemagick"
}
function install_curl {
print_info "installing curl..."
nocheck_install "curl"
}
function install_wget {
print_info "installing wget..."
nocheck_install "wget"
}
function install_sendmail {
print_info "installing sendmail..."
nocheck_install "sendmail sendmail-bin"
}
function install_php {
# openssl and mbstring are included in libapache2-mod-php
print_info "installing php..."
nocheck_install "libapache2-mod-php php php-pear php-curl php-gd php-mbstring php-xml php-zip php-intl php-bcmath"
phpversion=$(php -v|grep --only-matching --perl-regexp "(PHP )\d+\.\\d+\.\\d+"|cut -c 5-7)
sed -i "s/^upload_max_filesize =.*/upload_max_filesize = 100M/g" /etc/php/$phpversion/apache2/php.ini
sed -i "s/^post_max_size =.*/post_max_size = 100M/g" /etc/php/$phpversion/apache2/php.ini
}
function install_composer {
print_info "We check if Composer is already downloaded"
if [ ! -f /usr/local/bin/composer ]
then
EXPECTED_CHECKSUM="`wget -qO- https://composer.github.io/installer.sig`"
wget https://getcomposer.org/installer -O composer-setup.php
ACTUAL_CHECKSUM="$(php -r "echo hash_file('sha384', 'composer-setup.php');")"
if [ "$EXPECTED_CHECKSUM" != "$ACTUAL_CHECKSUM" ]
then
>&2 echo 'ERROR: Invalid installer checksum'
rm composer-setup.php
die 'ERROR: Invalid installer checksum'
fi
php composer-setup.php --quiet
RESULT=$?
composer --version
rm composer-setup.php
# exit $RESULT
# We install Composer globally
mv composer.phar /usr/local/bin/composer
print_info "Composer was successfully downloaded."
else
print_info "Composer is already downloaded on this system."
fi
cd $install_path
export COMPOSER_ALLOW_SUPERUSER=1;
/usr/local/bin/composer install --no-dev --quiet
/usr/local/bin/composer show
export COMPOSER_ALLOW_SUPERUSER=0;
}
function install_mysql {
print_info "installing mysql..."
if [ -z "$mysqlpass" ]
then
die "mysqlpass not set in $configfile"
fi
if type mysql ; then
echo "Yes, mysql is installed"
else
echo "mariadb-server"
nocheck_install "mariadb-server"
systemctl status mariadb
systemctl start mariadb
mysql --user=root <<_EOF_
UPDATE mysql.user SET Password=PASSWORD('${mysqlpass}') WHERE User='root';
DELETE FROM mysql.user WHERE User='';
DROP DATABASE IF EXISTS test;
DELETE FROM mysql.db WHERE Db='test' OR Db='test\\_%';
FLUSH PRIVILEGES;
_EOF_
fi
}
function install_adminer {
print_info "installing adminer..."
nocheck_install "adminer"
if [ ! -f /etc/adminer/adminer.conf ]
then
echo "Alias /adminer /usr/share/adminer/adminer" > /etc/adminer/adminer.conf
ln -s /etc/adminer/adminer.conf /etc/apache2/conf-available/adminer.conf
else
print_info "file /etc/adminer/adminer.conf exists already"
fi
a2enmod rewrite
if [ ! -f /etc/apache2/apache2.conf ]
then
die "could not find file /etc/apache2/apache2.conf"
fi
sed -i \
"s/AllowOverride None/AllowOverride all/" \
/etc/apache2/apache2.conf
a2enconf adminer
systemctl restart mariadb
systemctl reload apache2
}
function create_zotserver_db {
print_info "creating zotserver database..."
if [ -z "$db_name" ]
then
die "db_name not set in $configfile"
fi
if [ -z "$db_user" ]
then
die "db_user not set in $configfile"
fi
if [ -z "$db_pass" ]
then
die "db_pass not set in $configfile"
fi
systemctl restart mariadb
# Make sure we don't write over an already existing database if we install more than one Zot hub/instance
if [ -z $(mysql -h localhost -u root -p$mysqlpass -e "SHOW DATABASES;" | grep $db_name) ]
then
Q1="CREATE DATABASE IF NOT EXISTS $db_name;"
Q2="GRANT USAGE ON *.* TO $db_user@localhost IDENTIFIED BY '$db_pass';"
Q3="GRANT ALL PRIVILEGES ON $db_name.* to $db_user@localhost identified by '$db_pass';"
Q4="FLUSH PRIVILEGES;"
SQL="${Q1}${Q2}${Q3}${Q4}"
mysql -uroot -p$mysqlpass -e "$SQL"
else
echo "database $db_name does exist already"
Q1="CREATE DATABASE IF NOT EXISTS $db_name;"
Q2="GRANT USAGE ON *.* TO $db_user@localhost IDENTIFIED BY '$db_pass';"
Q3="GRANT ALL PRIVILEGES ON $db_name.* to $db_user@localhost identified by '$db_pass';"
Q4="FLUSH PRIVILEGES;"
SQL="${Q1}${Q2}${Q3}${Q4}"
mysql -uroot -p$mysqlpass -e "$SQL"
fi
}
function run_freedns {
print_info "run freedns (dynamic IP)..."
if [ -z "$freedns_key" ]
then
print_info "freedns was not started because 'freedns_key' is empty in $configfile"
else
if [ -n "$selfhost_user" ]
then
die "You can not use freeDNS AND selfHOST for dynamic IP updates ('freedns_key' AND 'selfhost_user' set in $configfile)"
fi
wget --no-check-certificate -O - http://freedns.afraid.org/dynamic/update.php?$freedns_key
fi
}
function install_run_selfhost {
print_info "install and start selfhost (dynamic IP)..."
if [ -z "$selfhost_user" ]
then
print_info "selfHOST was not started because 'selfhost_user' is empty in $configfile"
else
if [ -n "$freedns_key" ]
then
die "You can not use freeDNS AND selfHOST for dynamic IP updates ('freedns_key' AND 'selfhost_user' set in $configfile)"
fi
if [ -z "$selfhost_pass" ]
then
die "selfHOST was not started because 'selfhost_pass' is empty in $configfile"
fi
if [ ! -d $selfhostdir ]
then
mkdir $selfhostdir
fi
# the old way
# https://carol.selfhost.de/update?username=123456&password=supersafe
#
# the prefered way
if [ ! -f $selfhostdir/$selfhostscript ]
then
wget --output-document=$selfhostdir/$selfhostscript https://jonaspasche.de/selfhost-updater
if [ ! -s $selfhostdir/$selfhostscript ]
then
die "Failed to download selfHOST file for dynDNS"
fi
echo "router" > $selfhostdir/device
echo "$selfhost_user" > $selfhostdir/user
echo "$selfhost_pass" > $selfhostdir/pass
print_info "Wrote file to update dynamic IP. File: $selfhostdir/$selfhostscript"
fi
print_info "executing $selfhostdir/$selfhostscript update..."
bash $selfhostdir/$selfhostscript update
fi
}
function ping_domain {
print_info "ping domain $domain..."
# Is the domain resolved? Try to ping 6 times à 10 seconds
COUNTER=0
for i in {1..6}
do
print_info "loop $i for ping -c 1 $domain ..."
if ping -c 4 -W 1 $le_domain
then
print_info "$le_domain resolved"
break
else
if [ $i -gt 5 ]
then
die "Failed to: ping -c 1 $domain not resolved"
fi
fi
sleep 10
done
sleep 5
}
function configure_cron_freedns {
print_info "configure cron for freedns..."
if [ -z "$freedns_key" ]
then
print_info "freedns is not configured because freedns_key is empty in $configfile"
else
# Use cron for dynamich ip update
# - at reboot
# - every 30 minutes
if [ -z "`grep 'freedns.afraid.org' /etc/crontab`" ]
then
echo "@reboot root http://freedns.afraid.org/dynamic/update.php?$freedns_key > /dev/null 2>&1" >> /etc/crontab
echo "*/30 * * * * root wget --no-check-certificate -O - http://freedns.afraid.org/dynamic/update.php?$freedns_key > /dev/null 2>&1" >> /etc/crontab
else
print_info "cron for freedns was configured already"
fi
fi
}
function configure_cron_selfhost {
print_info "configure cron for selfhost..."
if [ -z "$selfhost_user" ]
then
print_info "selfhost is not configured because selfhost_key is empty in $configfile"
else
# Use cron for dynamich ip update
# - at reboot
# - every 5 minutes
if [ -z "`grep 'selfhost-updater.sh' /etc/crontab`" ]
then
echo "@reboot root bash /etc/selfhost/selfhost-updater.sh update > /dev/null 2>&1" >> /etc/crontab
echo "*/5 * * * * root /bin/bash /etc/selfhost/selfhost-updater.sh update > /dev/null 2>&1" >> /etc/crontab
else
print_info "cron for selfhost was configured already"
fi
fi
}
function install_letsencrypt {
print_info "installing let's encrypt ..."
# check if user gave domain
if [ -z "$le_domain" ]
then
die "Failed to install let's encrypt: 'le_domain' is empty in $configfile"
fi
if [ -z "$le_email" ]
then
die "Failed to install let's encrypt: 'le_email' is empty in $configfile"
fi
nocheck_install "certbot python3-certbot-apache"
print_info "run certbot ..."
certbot --apache -w $install_path -d $le_domain -m $le_email --agree-tos --non-interactive --redirect --hsts --uir
service apache2 restart
}
function check_https {
print_info "checking httpS > testing ..."
url_https=https://$le_domain
wget_output=$(wget -nv --spider --max-redirect 0 $url_https)
if [ $? -ne 0 ]
then
print_warn "check not ok"
else
print_info "check ok"
fi
}
function install_zotserver {
print_info "installing addons..."
cd $install_path
util/add_addon_repo https://framagit.org/hubzilla/addons hzaddons
mkdir -p "store/[data]/smarty3"
# chmod -R 777 store
touch .htconfig.php
# The next run of $cron_job (daily-update script) will correct the permissions of the next line
chmod ou+w .htconfig.php
cd /var/www/
chown -R www-data:www-data $install_path
chown root:www-data $install_path/
chown root:www-data $install_path/.htaccess
chmod 0644 $install_path/.htaccess
print_info "installed addons"
}
function configure_cron_daily {
print_info "configuring cron..."
# every 10 min for poller.php
if [ -z "`grep 'php Zotlabs/Daemon/Master.php' /etc/crontab`" ]
then
echo "*/10 * * * * www-data cd $install_path; php Zotlabs/Daemon/Master.php Cron >> /dev/null 2>&1" >> /etc/crontab
fi
# Run external script daily at 05:30
# - stop apache/nginx and mysql-server
# - renew the certificate of letsencrypt
# - update repository core and addon
# - update and upgrade linux
# - reboot is done by "shutdown -h now" because "reboot" hangs sometimes depending on the system
echo "#!/bin/sh" > /var/www/$cron_job
echo "#" >> /var/www/$cron_job
echo "echo \" \"" >> /var/www/$cron_job
echo "echo \"+++ \$(date) +++\"" >> /var/www/$cron_job
echo "echo \" \"" >> /var/www/$cron_job
echo "echo \"\$(date) - stopping apache and mysql...\"" >> /var/www/$cron_job
echo "service apache2 stop" >> /var/www/$cron_job
echo "systemctl stop mysql.service # to avoid inconsistencies" >> /var/www/$cron_job
echo "#" >> /var/www/$cron_job
echo "echo \"\$(date) - renew certificate...\"" >> /var/www/$cron_job
echo "certbot renew --noninteractive" >> /var/www/$cron_job
echo "#" >> /var/www/$cron_job
echo "echo \"\$(date) - db size...\"" >> /var/www/$cron_job
echo "du -h /var/lib/mysql/ | grep mysql/" >> /var/www/$cron_job
echo "#" >> /var/www/$cron_job
echo "# update of $le_domain Zot hub/instance" >> /var/www/$cron_job
echo "echo \"\$(date) - updating core and addons...\"" >> /var/www/$cron_job
echo "echo \"reaching git repository for $le_domain $zotserver hub/instance...\"" >> /var/www/$cron_job
echo "(cd $install_path ; util/udall)" >> /var/www/$cron_job
echo "chown -R www-data:www-data $install_path # make all accessible for the webserver" >> /var/www/$cron_job
echo "chown root:www-data $install_path/.htaccess" >> /var/www/$cron_job
echo "chmod 0644 $install_path/.htaccess # www-data can read but not write it" >> /var/www/$cron_job
echo "echo \"\$(date) - updating linux...\"" >> /var/www/$cron_job
echo "apt-get -q -y update && apt-get -q -y dist-upgrade && apt-get -q -y autoremove # update linux and upgrade" >> /var/www/$cron_job
echo "echo \"\$(date) - Update finished. Rebooting...\"" >> /var/www/$cron_job
echo "#" >> /var/www/$cron_job
echo "shutdown -r now" >> /var/www/$cron_job
chmod a+x /var/www/$cron_job
# If global cron job does not exist we add it to /etc/crontab
if grep -q $cron_job /etc/crontab
then
echo "cron job already in /etc/crontab"
else
echo "30 05 * * * root /bin/bash /var/www/$cron_job >> /var/www/daily-updates.log 2>&1" >> /etc/crontab
echo "0 0 1 * * root rm /var/www/daily-updates.log" >> /etc/crontab
fi
# This is active after either "reboot" or cron reload"
systemctl restart cron
print_info "configured cron for updates/upgrades"
}
########################################################################
# START OF PROGRAM
########################################################################
export PATH=/bin:/usr/bin:/sbin:/usr/sbin
check_sanity
print_info "We're installing a $zotserver instance"
install_path="$(dirname "$(pwd)")"
# Read config file edited by user
configfile=config.txt
source $configfile
selfhostdir=/etc/selfhost
selfhostscript=selfhost-updater.sh
cron_job="cron_job.sh"
#set -x # activate debugging from here
zotserver=hubzilla
check_config
stop_zotserver
update_upgrade
install_curl
install_wget
install_sendmail
install_apache
install_imagemagick
install_php
install_composer
install_mysql
install_adminer
create_zotserver_db
run_freedns
install_run_selfhost
ping_domain
configure_cron_freedns
configure_cron_selfhost
if [ "$le_domain" != "localhost" ]
then
install_letsencrypt
check_https
else
print_info "is localhost - skipped installation of letsencrypt and configuration of apache for https"
fi
install_zotserver
configure_cron_daily
#set +x # stop debugging from here

38
.gitignore vendored Executable file → Normal file
View File

@@ -33,8 +33,10 @@ apps/
home.html
# page header plugin
pageheader.html
# Ignore site TOS
# Ignore site TOS & gddpr
doc/SiteTOS.md
doc/*/SiteTOS.md
doc/*/gdpr.md
# themes except for redbasic
view/theme/*
!view/theme/redbasic
@@ -46,7 +48,10 @@ doc/html/
.zotshrc
# external repositories for themes/addons
extend/
# files generated by phpunit
# exclude test results and cache
tests/.cache
tests/.phpunit*
tests/results/
## exclude IDE files
@@ -55,6 +60,7 @@ tests/results/
.buildpath
.externalToolBuilders
.settings/
.pydevproject
# NetBeans project folder
nbproject/
# Kdevelop project files
@@ -62,7 +68,6 @@ nbproject/
# PHPStorm
.idea/
## composer
# locally installed composer binary
composer.phar
@@ -75,3 +80,30 @@ composer.phar
vendor/**/tests/
vendor/**/Test/
vendor/sabre/*/examples/
# Exclude dev dependencies
vendor/bin/pdepend
vendor/bin/php-parse
vendor/bin/phpcbf
vendor/bin/phpcs
vendor/bin/phpmd
vendor/bin/phpstan*
vendor/bin/phpunit
vendor/composer/pcre/
vendor/composer/xdebug-handler/
vendor/dms/
vendor/doctrine/
vendor/myclabs/
vendor/nikic/
vendor/pdepend/
vendor/phar-io/
vendor/php-mock/
vendor/phpmd/
vendor/phpstan
vendor/phpunit/
vendor/psr/container/
vendor/sebastian/
vendor/squizlabs/
vendor/theseer/
# /info is a directory containing site-specific HTML documents
/info/

View File

@@ -1,9 +1,5 @@
# Select image from https://hub.docker.com/_/php/
#image: php:7.3
# Use a prepared Hubzilla image to optimise pipeline duration
image: registry.gitlab.com/dawnbreak/hubzilla/core:php7.3
stages:
- pretest
- test
- deploy
@@ -22,6 +18,7 @@ variables:
# Ignore a Composer warning
COMPOSER_ALLOW_SUPERUSER: 1
# Configure MySQL/MariaDB service (https://hub.docker.com/_/mysql/, https://hub.docker.com/_/mariadb/)
DB_HOST: mysql
MYSQL_DATABASE: hello_world_test
MYSQL_ROOT_PASSWORD: mysql
# Configure PostgreSQL service (https://hub.docker.com/_/postgres/)
@@ -29,48 +26,55 @@ variables:
POSTGRES_USER: ci-user
POSTGRES_PASSWORD: ci-pass
before_script:
# pecl and composer do not work with PHP production restrictions (from Hubzilla Docker image)
- if [ -f /usr/local/etc/php/conf.d/z_prod.ini ]; then mv /usr/local/etc/php/conf.d/z_prod.ini /usr/local/etc/php/conf.d/z_prod.ini.off; fi
# Install & enable Xdebug for code coverage reports
- pecl install xdebug
- docker-php-ext-enable xdebug
# Install composer
- curl -sS https://getcomposer.org/installer | php
# Install dev libraries from composer
- php ./composer.phar install --no-progress
# hidden job definition with template for MySQL/MariaDB
.job_template_mysql: &job_definition_mysql
stage: test
variables:
HZ_TEST_DB_HOST: $DB_HOST
HZ_TEST_DB_TYPE: mysql
HZ_TEST_DB_USER: root
HZ_TEST_DB_PASS: $MYSQL_ROOT_PASSWORD
HZ_TEST_DB_DATABASE: $MYSQL_DATABASE
script:
- echo "USE $MYSQL_DATABASE; $(cat ./install/schema_mysql.sql)" | mysql --user=root --password="$MYSQL_ROOT_PASSWORD" --host=mysql "$MYSQL_DATABASE"
- echo "SHOW DATABASES;" | mysql --user=root --password="$MYSQL_ROOT_PASSWORD" --host=mysql "$MYSQL_DATABASE"
- echo "USE $MYSQL_DATABASE; SHOW TABLES;" | mysql --user=root --password="$MYSQL_ROOT_PASSWORD" --host=mysql "$MYSQL_DATABASE"
- vendor/bin/phpunit --configuration tests/phpunit.xml --coverage-text
# Import hubzilla's DB schema
- echo "USE $MYSQL_DATABASE; $(cat ./install/schema_mysql.sql)" | mysql --user=root --password="$MYSQL_ROOT_PASSWORD" --host="$DB_HOST" --skip-ssl "$MYSQL_DATABASE"
# Show databases and relations/tables of hubzilla's database
- echo "SHOW DATABASES;" | mysql --user=root --password="$MYSQL_ROOT_PASSWORD" --host="$DB_HOST" --skip-ssl "$MYSQL_DATABASE"
- echo "USE $MYSQL_DATABASE; SHOW TABLES;" | mysql --user=root --password="$MYSQL_ROOT_PASSWORD" --host="$DB_HOST" --skip-ssl "$MYSQL_DATABASE"
# Run the actual tests
- touch dbfail.out
- vendor/bin/phpunit -d memory_limit=256M --configuration tests/phpunit.xml --no-progress --stop-on-error --coverage-text --colors=never --log-junit tests/results/junit.xml || exit_code=$?
- if [ $exit_code -ne 0 ]; then echo "Test barfed!"; cat dbfail.out; exit $exit_code; fi
coverage: '/^\s*Lines:\s*\d+.\d+\%/'
# hidden job definition with template for PostgreSQL
.job_template_postgres: &job_definition_postgres
stage: test
services:
- postgres:latest
variables:
HZ_TEST_DB_HOST: postgres
HZ_TEST_DB_TYPE: postgres
HZ_TEST_DB_USER: $POSTGRES_USER
HZ_TEST_DB_PASS: $POSTGRES_PASSWORD
HZ_TEST_DB_DATABASE: $POSTGRES_DB
script:
- export PGPASSWORD=$POSTGRES_PASSWORD
- psql --version
- psql -h "postgres" -U "$POSTGRES_USER" -d "$POSTGRES_DB" -c "SELECT VERSION();"
# Import hubzilla's DB schema
- psql -h "postgres" -U "$POSTGRES_USER" -v ON_ERROR_STOP=1 --quiet "$POSTGRES_DB" < ./install/schema_postgres.sql
# Show databases and relations/tables of hubzilla's database
#- psql -h "postgres" -U "$POSTGRES_USER" -l
#- psql -h "postgres" -U "$POSTGRES_USER" -d "$POSTGRES_DB" -c "\dt;"
# Run the actual tests
- vendor/bin/phpunit --configuration tests/phpunit-pgsql.xml --testdox
- export PGPASSWORD=$POSTGRES_PASSWORD
- psql --version
- psql -h "postgres" -U "$POSTGRES_USER" -d "$POSTGRES_DB" -c "SELECT VERSION();"
# Import hubzilla's DB schema
- psql -h "postgres" -U "$POSTGRES_USER" -v ON_ERROR_STOP=1 --quiet "$POSTGRES_DB" < ./install/schema_postgres.sql
# Show databases and relations/tables of hubzilla's database
- psql -h "postgres" -U "$POSTGRES_USER" -l
- psql -h "postgres" -U "$POSTGRES_USER" -d "$POSTGRES_DB" -c "\dt;"
# Run the actual tests
- touch dbfail.out
- vendor/bin/phpunit -d memory_limit=256M --configuration tests/phpunit.xml --no-progress --stop-on-error --coverage-text --colors=never --log-junit tests/results/junit.xml || exit_code=$?
- if [ $exit_code -ne 0 ]; then echo "Test barfed!"; cat dbfail.out; exit $exit_code; fi
coverage: '/^\s*Lines:\s*\d+.\d+\%/'
# hidden job definition with artifacts config template
.artifacts_template:
artifacts: &artifacts_template
.artifacts_template: &artifacts_template
artifacts:
expire_in: 1 week
# Gitlab should show the results, but has problems parsing PHPUnit's junit file.
reports:
@@ -80,57 +84,64 @@ before_script:
paths:
- tests/results/
default:
image: php:8.2
before_script:
# Install & enable Xdebug for code coverage reports
- apt-get update
- apt-get install -yqq libicu-dev libjpeg-dev libpng-dev libpq-dev libyaml-dev libgmp-dev libzip-dev mariadb-client postgresql-client unzip zip
- pecl install xdebug yaml
- docker-php-ext-enable xdebug yaml
- docker-php-ext-configure gd --with-jpeg=/usr/include/
- docker-php-ext-install gd gmp intl pdo_mysql pdo_pgsql zip exif
# PHP7.3 with MySQL 5.7
php7.3_mysql5.7:
<<: *job_definition_mysql
# Install composer
- curl -sS https://getcomposer.org/installer | php
# Install dev libraries from composer
- php ./composer.phar install --no-progress
# php.ini settings
- echo 'xdebug.mode=coverage' >> /usr/local/etc/php/php.ini
check_templates:
stage: pretest
script:
- touch .htconfig.php
- php util/precompile_smarty3.php
phpstan:
stage: pretest
script:
- touch .htconfig.php
- vendor/bin/phpstan --memory-limit=512M
# PHP8.2 with MySQL 8.0
php8.2_mysql8.0.22:
services:
- mysql:5.7
# PHP7.3 with MySQL 8 (latest)
php7.3_mysql8:
- mysql:8.0
<<: *job_definition_mysql
<<: *artifacts_template
# PHP8.2 with MariaDB 10.6
php8.2_mariadb10.6:
services:
- name: mysql:8
command: ["--default-authentication-plugin=mysql_native_password"]
# PHP7.3 with MariaDB 10.2
php7.3_mariadb10.2:
- name: mariadb:10.6
alias: mysql
<<: *job_definition_mysql
<<: *artifacts_template
# PHP8.2 with PostgreSQL 14
php8.2_postgres14:
services:
- name: mariadb:10.2
alias: mysql
# PHP7.3 with MariaDB 10.3 (latest)
php7.3_mariadb10.3:
<<: *job_definition_mysql
image: registry.gitlab.com/dawnbreak/hubzilla/core:php7.3
services:
- name: mariadb:10.3
alias: mysql
# PHP7.3 with PostgreSQL latest (11)
php7.3_postgres11:
- postgres:14-alpine
<<: *job_definition_postgres
artifacts: *artifacts_template
# PHP7.3 with PostgreSQL latest (11)
php7.3_postgres11:
<<: *job_definition_postgres
image: registry.gitlab.com/dawnbreak/hubzilla/core:php7.3
artifacts: *artifacts_template
<<: *artifacts_template
# Generate Doxygen API Documentation and deploy it as GitLab pages
pages:
stage: deploy
cache: {}
image: php:7-cli-alpine
image: php:8-cli-alpine
before_script:
- apk update
- apk add doxygen ttf-freefont graphviz

0
.homeinstall/zotserver-setup.sh Executable file → Normal file
View File

View File

@@ -25,10 +25,10 @@ AddType audio/ogg .oga
# in CGI mode.
RewriteCond %{REQUEST_URI} ^/\.well\-known/.*
RewriteRule ^(.*)$ index.php?q=$1 [E=REMOTE_USER:%{HTTP:Authorization},L,QSA]
RewriteRule ^(.*)$ index.php?q=$1 "[E=REMOTE_USER:%{HTTP:Authorization},L,QSA,B= ?]"
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?q=$1 [E=REMOTE_USER:%{HTTP:Authorization},L,QSA]
RewriteRule ^(.*)$ index.php?q=$1 "[E=REMOTE_USER:%{HTTP:Authorization},L,QSA,B= ?]"
</IfModule>

0
.openshift/action_hooks/deploy Executable file → Normal file
View File

0
.openshift/cron/weekly/chronograph Executable file → Normal file
View File

82
.phpcs.xml Normal file
View File

@@ -0,0 +1,82 @@
<?xml version="1.0"?>
<ruleset
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
name="PHP_CodeSniffer"
xsi:noNamespaceSchemaLocation="phpcs.xsd"
>
<description>PHP CodeSniffer config for Hubzilla</description>
<file>app</file>
<file>boot.php</file>
<file>include</file>
<file>index.php</file>
<file>install</file>
<file>library</file>
<file>tests</file>
<file>util</file>
<file>view</file>
<file>Zotlabs</file>
<rule ref="Generic">
<exclude name="Generic.Arrays.ArrayIndent"/>
<exclude name="Generic.Arrays.DisallowLongArraySyntax"/>
<exclude name="Generic.Arrays.DisallowShortArraySyntax"/>
<exclude name="Generic.Files.EndFileNoNewline"/>
<exclude name="Generic.Files.LowercasedFilename"/>
<exclude name="Generic.Formatting.MultipleStatementAlignment"/>
<exclude name="Generic.Formatting.SpaceAfterNot"/>
<exclude name="Generic.Functions.FunctionCallArgumentSpacing"/>
<exclude name="Generic.Functions.OpeningFunctionBraceBsdAllman"/>
<exclude name="Generic.NamingConventions.CamelCapsFunctionName"/>
<exclude name="Generic.PHP.ClosingPHPTag"/>
<exclude name="Generic.PHP.RequireStrictTypes"/>
<exclude name="Generic.PHP.UpperCaseConstant"/>
<exclude name="Generic.WhiteSpace.DisallowTabIndent"/>
<exclude name="Generic.WhiteSpace.ScopeIndent"/>
<exclude name="Generic.Commenting.DocComment.ContentAfterOpen"/>
<exclude name="Generic.Commenting.DocComment.ContentBeforeClose"/>
<exclude name="Generic.Commenting.DocComment.LongNotCapital"/>
<exclude name="Generic.Commenting.DocComment.MissingShort"/>
<exclude name="Generic.Commenting.DocComment.NonParamGroup"/>
<exclude name="Generic.Commenting.DocComment.ParamNotFirst"/>
<exclude name="Generic.Commenting.DocComment.ShortNotCapital"/>
<exclude name="Generic.Commenting.DocComment.SpacingAfter"/>
<exclude name="Generic.Commenting.DocComment.SpacingBeforeShort"/>
<exclude name="Generic.Commenting.DocComment.TagValueIndent"/>
<exclude name="Generic.ControlStructures.InlineControlStructure.NotAllowed"/>
<exclude name="Generic.Files.OneClassPerFile.MultipleFound"/>
<exclude name="Generic.Files.OneObjectStructurePerFile.MultipleFound"/>
<exclude name="Generic.Formatting.SpaceAfterCast.NoSpace"/>
<exclude name="Generic.Classes.OpeningBraceSameLine.BraceOnNewLine" />
<exclude name="Generic.WhiteSpace.DisallowSpaceIndent.SpacesUsed" />
<exclude name="Generic.Functions.OpeningFunctionBraceKernighanRitchie.BraceOnNewLine" />
</rule>
<!--
Warn about lines longer than 100 columns, lines longer than 150
columns will flag an error.
-->
<rule ref="Generic.Files.LineLength">
<properties>
<property name="lineLimit" value="100" />
<property name="absoluteLineLimit" value="150" />
</properties>
</rule>
<!--
Mark deprecated functions.
-->
<rule ref="Generic.PHP.DeprecatedFunctions">
<properties>
<property name="forbiddenFunctions" type="array" extend="true">
<element key="load_config" value="Zotlabs\Lib\Config::Load" />
<element key="get_config" value="Zotlabs\Lib\Config::Get" />
<element key="set_config" value="Zotlabs\Lib\Config::Set" />
<element key="del_config" value="Zotlabs\Lib\Config::Delete" />
</property>
</properties>
</rule>
</ruleset>

2065
CHANGELOG

File diff suppressed because it is too large Load Diff

42
SBOM.md
View File

@@ -2,31 +2,37 @@
|Name|Version|License|Source|
|----|-------|-------|------|
|blueimp/jquery-file-upload|10.31.0.0|MIT|https://github.com/vkhramtsov/jQuery-File-Upload.git|
|blueimp/jquery-file-upload|10.32.0.0|MIT|https://github.com/vkhramtsov/jQuery-File-Upload.git|
|brick/math|0.9.3.0|MIT|https://github.com/brick/math.git|
|bshaffer/oauth2-server-php|1.11.1.0|MIT|https://github.com/bshaffer/oauth2-server-php.git|
|commerceguys/intl|1.0.5.0|MIT|https://github.com/commerceguys/intl.git|
|commerceguys/intl|1.1.0.0|MIT|https://github.com/commerceguys/intl.git|
|desandro/imagesloaded|4.1.4.0|MIT|https://github.com/desandro/imagesloaded.git|
|ezyang/htmlpurifier|4.13.0.0|LGPL-2.1-or-later|https://github.com/ezyang/htmlpurifier.git|
|league/html-to-markdown|4.10.0.0|MIT|https://github.com/thephpleague/html-to-markdown.git|
|jbroadway/urlify|1.2.2.0|BSD-3-Clause-Clear|https://github.com/jbroadway/urlify.git|
|league/html-to-markdown|5.0.1.0|MIT|https://github.com/thephpleague/html-to-markdown.git|
|lukasreschke/id3parser|0.0.3.0|GPL|https://github.com/LukasReschke/ID3Parser.git|
|michelf/php-markdown|1.9.0.0|BSD-3-Clause|https://github.com/michelf/php-markdown.git|
|paragonie/random_compat|9.99.99.0|MIT|https://github.com/paragonie/random_compat.git|
|pear/text_languagedetect|1.0.0.0|BSD-2-Clause|https://github.com/pear/Text_LanguageDetect.git|
|psr/log|1.1.3.0|MIT|https://github.com/php-fig/log.git|
|ramsey/uuid|3.9.3.0|MIT|https://github.com/ramsey/uuid.git|
|sabre/dav|4.1.1.0|BSD-3-Clause|https://github.com/sabre-io/dav.git|
|sabre/event|5.1.0.0|BSD-3-Clause|https://github.com/sabre-io/event.git|
|sabre/http|5.1.0.0|BSD-3-Clause|https://github.com/sabre-io/http.git|
|sabre/uri|2.2.0.0|BSD-3-Clause|https://github.com/sabre-io/uri.git|
|sabre/vobject|4.3.1.0|BSD-3-Clause|https://github.com/sabre-io/vobject.git|
|sabre/xml|2.2.1.0|BSD-3-Clause|https://github.com/sabre-io/xml.git|
|simplepie/simplepie|1.5.5.0|BSD-3-Clause|https://github.com/simplepie/simplepie.git|
|smarty/smarty|3.1.36.0|LGPL-3.0|https://github.com/smarty-php/smarty.git|
|symfony/polyfill-ctype|1.13.1.0|MIT|https://github.com/symfony/polyfill-ctype.git|
|twbs/bootstrap|4.5.2.0|MIT|https://github.com/twbs/bootstrap.git|
|pear/text_languagedetect|1.0.1.0|BSD-2-Clause|https://github.com/pear/Text_LanguageDetect.git|
|phpseclib/phpseclib|2.0.33.0|MIT|https://github.com/phpseclib/phpseclib.git|
|psr/log|1.1.4.0|MIT|https://github.com/php-fig/log.git|
|ramsey/collection|1.2.2.0|MIT|https://github.com/ramsey/collection.git|
|ramsey/uuid|4.2.3.0|MIT|https://github.com/ramsey/uuid.git|
|sabre/dav|4.1.5.0|BSD-3-Clause|https://github.com/sabre-io/dav.git|
|sabre/event|5.1.2.0|BSD-3-Clause|https://github.com/sabre-io/event.git|
|sabre/http|5.1.1.0|BSD-3-Clause|https://github.com/sabre-io/http.git|
|sabre/uri|2.2.1.0|BSD-3-Clause|https://github.com/sabre-io/uri.git|
|sabre/vobject|4.3.5.0|BSD-3-Clause|https://github.com/sabre-io/vobject.git|
|sabre/xml|2.2.3.0|BSD-3-Clause|https://github.com/sabre-io/xml.git|
|simplepie/simplepie|1.5.6.0|BSD-3-Clause|https://github.com/simplepie/simplepie.git|
|smarty/smarty|3.1.39.0|LGPL-3.0|https://github.com/smarty-php/smarty.git|
|symfony/polyfill-ctype|1.23.0.0|MIT|https://github.com/symfony/polyfill-ctype.git|
|symfony/polyfill-php80|1.23.1.0|MIT|https://github.com/symfony/polyfill-php80.git|
|symfony/polyfill-php81|1.23.0.0|MIT|https://github.com/symfony/polyfill-php81.git|
|twbs/bootstrap|5.1.3.0|MIT|https://github.com/twbs/bootstrap.git|
|voku/portable-ascii|1.5.6.0|MIT|https://github.com/voku/portable-ascii.git|
|voku/stop-words|2.0.1.0|MIT|https://github.com/voku/stop-words.git|
|fullcalendar/fullcalendar|4.4.2.0|MIT|https://github.com/fullcalendar/fullcalendar.git|
|miromannino/Justified-Gallery|3.8.1.0|MIT|https://github.com/miromannino/Justified-Gallery.git|
|fengyuanchen/cropperjs|1.5.7.0|MIT|https://github.com/fengyuanchen/cropperjs.git|
|ForkAwesome/Fork-Awesome|1.1.7.0|MIT,SIL OFL,CC BY 3.0|https://github.com/ForkAwesome/Fork-Awesome.git|
|leafo/sticky-kit|1.1.2.0|MIT|https://github.com/leafo/sticky-kit.git|
|jquery/jquery|3.5.1.0|MIT|https://github.com/jquery/jquery.git|

31
SECURITY.md Normal file
View File

@@ -0,0 +1,31 @@
# Hubzilla Security Policy
The [Hubzilla] Project takes security, privacy and user control over personal data seriously. We ask that any security issues be disclosed to us in a responsible manner to allow us time to remediate the issues, and site administrators time to upgrade before information about the issue is made public.
This document outlines security procedures and policies for the Hubzilla project. It covers the following components:
* The Hubzilla core repository: https://framagit.org/hubzilla/core
* The official addon repository: https://framagit.org/hubzilla/addons
* The official themes repository: https://framagit.org/hubzilla/themes
* The official widgets repository: https://framagit.org/hubzilla/widgets
## Coordinated Disclosure Guidelines
We are committed to working with security researchers to verify, reproduce, and respond to legitimate reported vulnerabilities. You can help us by following these simple guidelines:
* Submit suspected vulnerabilities by email to `security@hubzilla.org`, or as a confidential issue in the relevant repository listed above.
* Provide clear instructions on how to reproduce the issue, and if possible, a minimal Proof of Concept (PoC) exploit.
* We will acknowledge your submission as soon as we can, and will keep you updated as it is being processed. We may ask for more information, or clarifications about the issue or the steps to reproduce it during this time.
* We will assign a CVE to the issue once it is confirmed.
* We will do our best to fix the issue as soon as we can after it has been confirmed. We request that information about the vulnerability or details about how to exploit it is not disclosed to other parties until after the fix is released and some time has passed, to allow site administrators to upgrade. We will normally make the CVE public one month after a fix has been released. (This grace period can differ based on severity, and can be negotiated.)
* Please perform all tests against a local instance of the software, and refrain from running any Denial of Service or automated testing tools against public hubs or the project managers (and their partners') infrastructure.
* If the issue belongs to a third party module that we depend on, we may help with reporting it upstream if the submitter wants us to.
## Comments on this Policy
We welcome comments and suggestions for improving this policy. You can reach us at:
* Our ticketing system: https://framagit.org/hubzilla/core/-/issues
* By sending us an email at `security@hubzilla.org`.
[Hubzilla]: https://hubzilla.org

10
ServiceWorker.js Normal file
View File

@@ -0,0 +1,10 @@
// This file should be served from the web root to avoid scope and cookie related issues with some browsers
self.addEventListener('install', function(e) {
console.log('install event');
});
self.addEventListener('fetch', function(e) {
// nothing here yet
return;
});

View File

@@ -2,6 +2,7 @@
namespace Zotlabs\Access;
/**
* @brief AccessList class which represents individual content ACLs.
*
@@ -17,29 +18,48 @@ class AccessList {
* @brief Allow contacts
* @var string
*/
private $allow_cid;
private ?string $allow_cid;
/**
* @brief Allow groups
* @var string
*/
private $allow_gid;
private ?string $allow_gid;
/**
* @brief Deny contacts
* @var string
*/
private $deny_cid;
private ?string $deny_cid;
/**
* @brief Deny groups
* @var string
*/
private $deny_gid;
private ?string $deny_gid;
/**
* @brief Indicates if we are using the default constructor values or
* values that have been set explicitly.
* @var boolean
*/
private $explicit;
private bool $explicit;
/**
* @brief Keys required by the constructor if the channel array is given.
*/
private const REQUIRED_KEYS_CONSTRUCTOR = [
'channel_allow_cid',
'channel_allow_gid',
'channel_deny_cid',
'channel_deny_gid'
];
/**
* @brief Keys required by the set method.
*/
private const REQUIRED_KEYS_SET = [
'allow_cid',
'allow_gid',
'deny_cid',
'deny_gid'
];
/**
* @brief Constructor for AccessList class.
@@ -53,8 +73,9 @@ class AccessList {
* * \e string \b channel_deny_cid => string of denied cids
* * \e string \b channel_deny_gid => string of denied gids
*/
function __construct($channel) {
if($channel) {
function __construct(array $channel) {
if ($channel) {
$this->validate_input_array($channel, self::REQUIRED_KEYS_CONSTRUCTOR);
$this->allow_cid = $channel['channel_allow_cid'];
$this->allow_gid = $channel['channel_allow_gid'];
$this->deny_cid = $channel['channel_deny_cid'];
@@ -70,13 +91,24 @@ class AccessList {
$this->explicit = false;
}
private function validate_input_array(array $arr, array $required_keys) : void {
$missing_keys = array_diff($required_keys, array_keys($arr));
if (!empty($missing_keys)) {
throw new \Exception(
'Invalid AccessList object: Expected array with keys: '
. implode(', ', $missing_keys)
);
}
}
/**
* @brief Get if we are using the default constructor values
* or values that have been set explicitly.
*
* @return boolean
*/
function get_explicit() {
function get_explicit() : bool {
return $this->explicit;
}
@@ -94,12 +126,13 @@ class AccessList {
* * \e string \b deny_gid => string of denied gids
* @param boolean $explicit (optional) default true
*/
function set($arr, $explicit = true) {
function set(array $arr, bool $explicit = true) : void {
$this->validate_input_array($arr, self::REQUIRED_KEYS_SET);
$this->allow_cid = $arr['allow_cid'];
$this->allow_gid = $arr['allow_gid'];
$this->deny_cid = $arr['deny_cid'];
$this->deny_gid = $arr['deny_gid'];
$this->explicit = $explicit;
}
@@ -113,7 +146,7 @@ class AccessList {
* * \e string \b deny_cid => string of denied cids
* * \e string \b deny_gid => string of denied gids
*/
function get() {
function get() : array {
return [
'allow_cid' => $this->allow_cid,
'allow_gid' => $this->allow_gid,
@@ -139,7 +172,12 @@ class AccessList {
* * \e array|string \b group_deny => array with gids or comma-seperated string
* @param boolean $explicit (optional) default true
*/
function set_from_array($arr, $explicit = true) {
function set_from_array(array $arr, bool $explicit = true) : void {
$arr['contact_allow'] = $arr['contact_allow'] ?? [];
$arr['group_allow'] = $arr['group_allow'] ?? [];
$arr['contact_deny'] = $arr['contact_deny'] ?? [];
$arr['group_deny'] = $arr['group_deny'] ?? [];
$this->allow_cid = perms2str((is_array($arr['contact_allow']))
? $arr['contact_allow'] : explode(',', $arr['contact_allow']));
$this->allow_gid = perms2str((is_array($arr['group_allow']))
@@ -157,7 +195,7 @@ class AccessList {
*
* @return boolean Return true if any of allow_* deny_* values is set.
*/
function is_private() {
function is_private() : bool {
return (($this->allow_cid || $this->allow_gid || $this->deny_cid || $this->deny_gid) ? true : false);
}

View File

@@ -2,6 +2,7 @@
namespace Zotlabs\Access;
use App;
use Zotlabs\Lib\PConfig;
/**
@@ -39,10 +40,10 @@ class PermissionLimits {
*/
static public function Std_Limits() {
$limits = [];
$perms = Permissions::Perms();
$perms = Permissions::Perms();
foreach($perms as $k => $v) {
if(strstr($k, 'view'))
foreach ($perms as $k => $v) {
if (strstr($k, 'view'))
$limits[$k] = PERMS_PUBLIC;
else
$limits[$k] = PERMS_SPECIFIC;
@@ -77,15 +78,15 @@ class PermissionLimits {
* * \b array with all permission limits, if $perm is not set
*/
static public function Get($channel_id, $perm = '') {
if($perm) {
if ($perm) {
return intval(PConfig::Get($channel_id, 'perm_limits', $perm));
}
PConfig::Load($channel_id);
if(array_key_exists($channel_id, \App::$config)
&& array_key_exists('perm_limits', \App::$config[$channel_id]))
return \App::$config[$channel_id]['perm_limits'];
if (array_key_exists($channel_id, App::$config)
&& array_key_exists('perm_limits', App::$config[$channel_id]))
return App::$config[$channel_id]['perm_limits'];
return false;
}
}
}

View File

@@ -2,6 +2,8 @@
namespace Zotlabs\Access;
use Zotlabs\Lib\Config;
/**
* @brief PermissionRoles class.
*
@@ -17,7 +19,7 @@ class PermissionRoles {
* @return number
*/
static public function version() {
return 2;
return 3;
}
static function role_perms($role) {
@@ -27,6 +29,53 @@ class PermissionRoles {
$ret['role'] = $role;
switch($role) {
case 'public':
$ret['default_collection'] = false;
$ret['perms_connect'] = [
'view_stream', 'view_profile', 'view_contacts', 'view_storage', 'view_pages', 'view_wiki',
'send_stream', 'post_comments', 'post_mail', 'post_wall', 'chat', 'post_like', 'republish'
];
$ret['limits'] = PermissionLimits::Std_Limits();
$ret['limits']['post_comments'] = PERMS_AUTHED;
$ret['limits']['post_like'] = PERMS_AUTHED;
$ret['limits']['chat'] = PERMS_AUTHED;
break;
// Hubzilla default role
case 'personal':
$ret['default_collection'] = true;
$ret['perms_connect'] = [
'view_stream', 'view_profile', 'view_contacts', 'view_storage', 'view_pages', 'view_wiki',
'send_stream', 'post_comments', 'post_mail', 'chat', 'post_like'
];
$ret['limits'] = PermissionLimits::Std_Limits();
$ret['limits']['view_contacts'] = PERMS_SPECIFIC;
break;
case 'group':
$ret['default_collection'] = false;
$ret['perms_connect'] = [
'view_stream', 'view_profile', 'view_contacts', 'view_storage',
'view_pages', 'view_wiki', 'post_wall', 'post_comments',
'post_mail', 'post_like', 'chat'
];
$ret['limits'] = PermissionLimits::Std_Limits();
$ret['channel_type'] = 'group';
break;
// Provide some defaults for the custom role so that we do not start
// with no permissions at all if we create a new channel with this role
case 'custom':
$ret['default_collection'] = true;
$ret['perms_connect'] = [
'view_stream', 'view_profile', 'view_contacts', 'view_storage', 'view_pages', 'view_wiki',
'send_stream', 'post_comments', 'post_mail', 'chat', 'post_like'
];
$ret['limits'] = PermissionLimits::Std_Limits();
break;
/*
case 'social':
$ret['perms_auto'] = false;
$ret['default_collection'] = false;
@@ -193,13 +242,14 @@ class PermissionRoles {
$ret['channel_type'] = 'group';
break;
*/
case 'custom':
default:
break;
}
$x = get_config('system','role_perms');
$x = Config::Get('system','role_perms');
// let system settings over-ride any or all
if($x && is_array($x) && array_key_exists($role,$x))
$ret = array_merge($ret,$x[$role]);
@@ -218,13 +268,13 @@ class PermissionRoles {
// set permissionlimits for this permission here, for example:
// if($perm === 'mynewperm')
// \Zotlabs\Access\PermissionLimits::Set($uid,$perm,1);
// PermissionLimits::Set($uid,$perm,1);
if($perm === 'view_wiki')
\Zotlabs\Access\PermissionLimits::Set($uid, $perm, PERMS_PUBLIC);
PermissionLimits::Set($uid, $perm, PERMS_PUBLIC);
if($perm === 'write_wiki')
\Zotlabs\Access\PermissionLimits::Set($uid, $perm, PERMS_SPECIFIC);
PermissionLimits::Set($uid, $perm, PERMS_SPECIFIC);
// set autoperms here if applicable
@@ -262,11 +312,11 @@ class PermissionRoles {
case 'view_wiki':
set_abconfig($uid,$ab['abook_xchan'],'my_perms',$perm,
intval(get_abconfig($uid,$ab['abook_xchan'],'my_perms','view_pages')));
break;
case 'write_wiki':
set_abconfig($uid,$ab['abook_xchan'],'my_perms',$perm,
intval(get_abconfig($uid,$ab['abook_xchan'],'my_perms','write_pages')));
break;
default:
break;
}
@@ -284,6 +334,7 @@ class PermissionRoles {
*/
static public function roles() {
$roles = [
t('Social Networking') => [
'social_federation' => t('Social - Federation'),
'social' => t('Social - Mostly Public'),
@@ -317,4 +368,29 @@ class PermissionRoles {
return $roles;
}
}
/**
* @brief Array with translated role names and grouping.
*
* Return an associative array with role names that can be used
* to create select groups like in \e field_select_grouped.tpl.
*
* @return array
*/
static public function channel_roles() {
$channel_roles = [
//'public' => [t('Public'), t('A very permissive role suited for participation in the fediverse')],
//'personal' => [t('Personal'), t('The $Projectname default role suited for a personal channel')],
//'forum' => [t('Community forum'), t('This role configures your channel to act as an community forum')],
//'custom' => [t('Custom'), t('This role comes with the presets of the personal role but allows you to configure it to your needs')]
'public' => t('Public'),
'personal' => t('Personal'),
'group' => t('Community forum'),
'custom' => t('Custom')
];
call_hooks('list_channel_roles', $channel_roles);
return $channel_roles;
}
}

View File

@@ -41,7 +41,7 @@ class Permissions {
* @return number
*/
static public function version() {
return 2;
return 3;
}
/**
@@ -65,17 +65,17 @@ class Permissions {
'write_wiki' => t('Can write to my wiki pages'),
'post_wall' => t('Can post on my channel (wall) page'),
'post_comments' => t('Can comment on or like my posts'),
'post_mail' => t('Can send me private mail messages'),
'post_mail' => t('Can send me direct messages'),
'post_like' => t('Can like/dislike profiles and profile things'),
'tag_deliver' => t('Can forward to all my channel connections via ! mentions in posts'),
'chat' => t('Can chat with me'),
'republish' => t('Can source my public posts in derived channels'),
'republish' => t('Can source/mirror my public posts in derived channels'),
//'tag_deliver' => t('Can forward to my contacts via direct messages (forum)'),
'delegate' => t('Can administer my channel')
];
$x = [
'permissions' => $perms,
'filter' => $filter
'filter' => $filter
];
/**
* @hooks permissions_list
@@ -84,7 +84,7 @@ class Permissions {
*/
call_hooks('permissions_list', $x);
return($x['permissions']);
return ($x['permissions']);
}
/**
@@ -96,10 +96,10 @@ class Permissions {
*/
static public function BlockedAnonPerms() {
$res = [];
$res = [];
$perms = PermissionLimits::Std_limits();
foreach($perms as $perm => $limit) {
if($limit != PERMS_PUBLIC) {
foreach ($perms as $perm => $limit) {
if ($limit != PERMS_PUBLIC) {
$res[] = $perm;
}
}
@@ -111,7 +111,7 @@ class Permissions {
*/
call_hooks('write_perms', $x);
return($x['permissions']);
return ($x['permissions']);
}
/**
@@ -120,20 +120,20 @@ class Permissions {
* Converts [ 0 => 'view_stream', ... ]
* to [ 'view_stream' => 1 ] for any permissions in $arr;
* Undeclared permissions which exist in Perms() are added and set to 0.
*
*
* @param array $arr
* @return array
*/
static public function FilledPerms($arr) {
if(is_null($arr)) {
if (is_null($arr)) {
btlogger('FilledPerms: null');
$arr = [];
}
$everything = self::Perms();
$ret = [];
foreach($everything as $k => $v) {
if(in_array($k, $arr))
$ret = [];
foreach ($everything as $k => $v) {
if (in_array($k, $arr))
$ret[$k] = 1;
else
$ret[$k] = 0;
@@ -155,9 +155,9 @@ class Permissions {
*/
static public function OPerms($arr) {
$ret = [];
if($arr) {
foreach($arr as $k => $v) {
$ret[] = [ 'name' => $k, 'value' => $v ];
if ($arr) {
foreach ($arr as $k => $v) {
$ret[] = ['name' => $k, 'value' => $v];
}
}
return $ret;
@@ -170,15 +170,16 @@ class Permissions {
* @return boolean|array
*/
static public function FilledAutoperms($channel_id) {
if(! intval(get_pconfig($channel_id,'system','autoperms')))
if (!intval(get_pconfig($channel_id, 'system', 'autoperms')))
return false;
$arr = [];
$r = q("select * from pconfig where uid = %d and cat = 'autoperms'",
intval($channel_id)
);
if($r) {
foreach($r as $rr) {
if ($r) {
foreach ($r as $rr) {
$arr[$rr['k']] = intval($rr['v']);
}
}
@@ -193,11 +194,11 @@ class Permissions {
* @return boolean true if all perms from $p1 exist also in $p2
*/
static public function PermsCompare($p1, $p2) {
foreach($p1 as $k => $v) {
if(! array_key_exists($k, $p2))
foreach ($p1 as $k => $v) {
if (!array_key_exists($k, $p2))
return false;
if($p1[$k] != $p2[$k])
if ($p1[$k] != $p2[$k])
return false;
}
@@ -211,87 +212,25 @@ class Permissions {
* @return array Associative array with
* * \e array \b perms Permission array
* * \e int \b automatic 0 or 1
* * \e srtring \b role
*/
static public function connect_perms($channel_id) {
$my_perms = [];
$permcat = null;
$automatic = 0;
$my_perms = [];
$permcat = null;
$automatic = get_pconfig($channel_id, 'system', 'autoperms');
// If a default permcat exists, use that
$pc = ((feature_enabled($channel_id,'permcats')) ? get_pconfig($channel_id,'system','default_permcat') : 'default');
if(! in_array($pc, [ '','default' ])) {
$pcp = new Zlib\Permcat($channel_id);
$permcat = $pcp->fetch($pc);
if($permcat && $permcat['perms']) {
foreach($permcat['perms'] as $p) {
$my_perms[$p['name']] = $p['value'];
}
$pc = get_pconfig($channel_id, 'system', 'default_permcat', 'default');
$pcp = new Zlib\Permcat($channel_id);
$permcat = $pcp->fetch($pc);
if ($permcat && $permcat['perms']) {
foreach ($permcat['perms'] as $p) {
$my_perms[$p['name']] = $p['value'];
}
}
// look up the permission role to see if it specified auto-connect
// and if there was no permcat or a default permcat, set the perms
// from the role
$role = get_pconfig($channel_id,'system','permissions_role');
if($role) {
$xx = PermissionRoles::role_perms($role);
if($xx['perms_auto'])
$automatic = 1;
if((! $my_perms) && ($xx['perms_connect'])) {
$default_perms = $xx['perms_connect'];
$my_perms = Permissions::FilledPerms($default_perms);
}
}
// If we reached this point without having any permission information,
// it is likely a custom permissions role. First see if there are any
// automatic permissions.
if(! $my_perms) {
$m = Permissions::FilledAutoperms($channel_id);
if($m) {
$automatic = 1;
$my_perms = $m;
}
}
// If we reached this point with no permissions, the channel is using
// custom perms but they are not automatic. They will be stored in abconfig with
// the channel's channel_hash (the 'self' connection).
if(! $my_perms) {
$r = q("select channel_hash from channel where channel_id = %d",
intval($channel_id)
);
if($r) {
$x = q("select * from abconfig where chan = %d and xchan = '%s' and cat = 'my_perms'",
intval($channel_id),
dbesc($r[0]['channel_hash'])
);
if($x) {
foreach($x as $xv) {
$my_perms[$xv['k']] = intval($xv['v']);
}
}
}
}
return ( [ 'perms' => $my_perms, 'automatic' => $automatic ] );
}
static public function serialise($p) {
$n = [];
if($p) {
foreach($p as $k => $v) {
if(intval($v)) {
$n[] = $k;
}
}
}
return implode(',',$n);
return (['perms' => $my_perms, 'automatic' => $automatic, 'role' => $pc]);
}
}

View File

@@ -0,0 +1,776 @@
<?php
namespace Zotlabs\ActivityStreams;
use Zotlabs\Lib\BaseObject;
class ASObject extends BaseObject
{
public $id;
public $type;
public $attachment;
public $attributedTo;
public $audience;
public $content;
public $context;
public $name;
public $endTime;
public $generator;
public $icon;
public $image;
public $inReplyTo;
public $location;
public $preview;
public $published;
public $replies;
public $startTime;
public $summary;
public $tag;
public $updated;
public $url;
public $to;
public $bto;
public $cc;
public $bcc;
public $mediaType;
public $duration;
public $source;
// Extension properties
public $signature;
public $proof;
public $sensitive;
public $replyTo;
public $wall;
public $isContainedConversation;
public $expires;
public $canReply;
public $canSearch;
public $directMessage;
public $commentPolicy;
/**
* @return mixed
*/
public function getDirectMessage()
{
return $this->directMessage;
}
/**
* @param mixed $directMessage
* @return ASObject
*/
public function setDirectMessage($directMessage)
{
$this->directMessage = $directMessage;
return $this;
}
/**
* @return mixed
*/
public function getSignature()
{
return $this->signature;
}
/**
* @param mixed $signature
* @return ASObject
*/
public function setSignature($signature)
{
$this->signature = $signature;
return $this;
}
/**
* @return mixed
*/
public function getProof()
{
return $this->proof;
}
/**
* @param mixed $proof
* @return ASObject
*/
public function setProof($proof)
{
$this->proof = $proof;
return $this;
}
/**
* @return mixed
*/
public function getSensitive()
{
return $this->sensitive;
}
/**
* @param mixed $sensitive
* @return ASObject
*/
public function setSensitive($sensitive)
{
$this->sensitive = $sensitive;
return $this;
}
/**
* @return mixed
*/
public function getReplyTo()
{
return $this->replyTo;
}
/**
* @param mixed $replyTo
* @return ASObject
*/
public function setReplyTo($replyTo)
{
$this->replyTo = $replyTo;
return $this;
}
/**
* @return mixed
*/
public function getWall()
{
return $this->wall;
}
/**
* @param mixed $wall
* @return ASObject
*/
public function setWall($wall)
{
$this->wall = $wall;
return $this;
}
/**
* @return mixed
*/
public function getIsContainedConversation()
{
return $this->isContainedConversation;
}
/**
* @param mixed $isContainedConversation
* @return ASObject
*/
public function setIsContainedConversation($isContainedConversation)
{
$this->isContainedConversation = $isContainedConversation;
return $this;
}
/**
* @return mixed
*/
public function getExpires()
{
return $this->expires;
}
/**
* @param mixed $expires
* @return ASObject
*/
public function setExpires($expires)
{
$this->expires = $expires;
return $this;
}
/**
* @return mixed
*/
public function getCanReply()
{
return $this->canReply;
}
/**
* @param mixed $canReply
* @return ASObject
*/
public function setCanReply($canReply)
{
$this->canReply = $canReply;
return $this;
}
/**
* @return mixed
*/
public function getCanSearch()
{
return $this->canSearch;
}
/**
* @param mixed $canSearch
* @return ASObject
*/
public function setCanSearch($canSearch)
{
$this->canSearch = $canSearch;
return $this;
}
/**
* @return mixed
*/
public function getCommentPolicy()
{
return $this->commentPolicy;
}
/**
* @param mixed $commentPolicy
* @return ASObject
*/
public function setCommentPolicy($commentPolicy)
{
$this->commentPolicy = $commentPolicy;
return $this;
}
/**
* @return mixed
*/
public function getId()
{
return $this->id;
}
/**
* @param mixed $id
* @return ASObject
*/
public function setId($id)
{
$this->id = $id;
return $this;
}
/**
* @return mixed
*/
public function getType()
{
return $this->type;
}
/**
* @param mixed $type
* @return ASObject
*/
public function setType($type)
{
$this->type = $type;
return $this;
}
/**
* @return mixed
*/
public function getAttachment()
{
return $this->attachment;
}
/**
* @param mixed $attachment
* @return ASObject
*/
public function setAttachment($attachment)
{
$this->attachment = $attachment;
return $this;
}
/**
* @return mixed
*/
public function getAttributedTo()
{
return $this->attributedTo;
}
/**
* @param mixed $attributedTo
* @return ASObject
*/
public function setAttributedTo($attributedTo)
{
$this->attributedTo = $attributedTo;
return $this;
}
/**
* @return mixed
*/
public function getAudience()
{
return $this->audience;
}
/**
* @param mixed $audience
* @return ASObject
*/
public function setAudience($audience)
{
$this->audience = $audience;
return $this;
}
/**
* @return mixed
*/
public function getContent()
{
return $this->content;
}
/**
* @param mixed $content
* @return ASObject
*/
public function setContent($content)
{
$this->content = $content;
return $this;
}
/**
* @return mixed
*/
public function getContext()
{
return $this->context;
}
/**
* @param mixed $context
* @return ASObject
*/
public function setContext($context)
{
$this->context = $context;
return $this;
}
/**
* @return mixed
*/
public function getName()
{
return $this->name;
}
/**
* @param mixed $name
* @return ASObject
*/
public function setName($name)
{
$this->name = $name;
return $this;
}
/**
* @return mixed
*/
public function getEndTime()
{
return $this->endTime;
}
/**
* @param mixed $endTime
* @return ASObject
*/
public function setEndTime($endTime)
{
$this->endTime = $endTime;
return $this;
}
/**
* @return mixed
*/
public function getGenerator()
{
return $this->generator;
}
/**
* @param mixed $generator
* @return ASObject
*/
public function setGenerator($generator)
{
$this->generator = $generator;
return $this;
}
/**
* @return mixed
*/
public function getIcon()
{
return $this->icon;
}
/**
* @param mixed $icon
* @return ASObject
*/
public function setIcon($icon)
{
$this->icon = $icon;
return $this;
}
/**
* @return mixed
*/
public function getImage()
{
return $this->image;
}
/**
* @param mixed $image
* @return ASObject
*/
public function setImage($image)
{
$this->image = $image;
return $this;
}
/**
* @return mixed
*/
public function getInReplyTo()
{
return $this->inReplyTo;
}
/**
* @param mixed $inReplyTo
* @return ASObject
*/
public function setInReplyTo($inReplyTo)
{
$this->inReplyTo = $inReplyTo;
return $this;
}
/**
* @return mixed
*/
public function getLocation()
{
return $this->location;
}
/**
* @param mixed $location
* @return ASObject
*/
public function setLocation($location)
{
$this->location = $location;
return $this;
}
/**
* @return mixed
*/
public function getPreview()
{
return $this->preview;
}
/**
* @param mixed $preview
* @return ASObject
*/
public function setPreview($preview)
{
$this->preview = $preview;
return $this;
}
/**
* @return mixed
*/
public function getPublished()
{
return $this->published;
}
/**
* @param mixed $published
* @return ASObject
*/
public function setPublished($published)
{
$this->published = $published;
return $this;
}
/**
* @return mixed
*/
public function getReplies()
{
return $this->replies;
}
/**
* @param mixed $replies
* @return ASObject
*/
public function setReplies($replies)
{
$this->replies = $replies;
return $this;
}
/**
* @return mixed
*/
public function getStartTime()
{
return $this->startTime;
}
/**
* @param mixed $startTime
* @return ASObject
*/
public function setStartTime($startTime)
{
$this->startTime = $startTime;
return $this;
}
/**
* @return mixed
*/
public function getSummary()
{
return $this->summary;
}
/**
* @param mixed $summary
* @return ASObject
*/
public function setSummary($summary)
{
$this->summary = $summary;
return $this;
}
/**
* @return mixed
*/
public function getTag()
{
return $this->tag;
}
/**
* @param mixed $tag
* @return ASObject
*/
public function setTag($tag)
{
$this->tag = $tag;
return $this;
}
/**
* @return mixed
*/
public function getUpdated()
{
return $this->updated;
}
/**
* @param mixed $updated
* @return ASObject
*/
public function setUpdated($updated)
{
$this->updated = $updated;
return $this;
}
/**
* @return mixed
*/
public function getUrl()
{
return $this->url;
}
/**
* @param mixed $url
* @return ASObject
*/
public function setUrl($url)
{
$this->url = $url;
return $this;
}
/**
* @return mixed
*/
public function getTo()
{
return $this->to;
}
/**
* @param mixed $to
* @return ASObject
*/
public function setTo($to)
{
$this->to = $to;
return $this;
}
/**
* @return mixed
*/
public function getBto()
{
return $this->bto;
}
/**
* @param mixed $bto
* @return ASObject
*/
public function setBto($bto)
{
$this->bto = $bto;
return $this;
}
/**
* @return mixed
*/
public function getCc()
{
return $this->cc;
}
/**
* @param mixed $cc
* @return ASObject
*/
public function setCc($cc)
{
$this->cc = $cc;
return $this;
}
/**
* @return mixed
*/
public function getBcc()
{
return $this->bcc;
}
/**
* @param mixed $bcc
* @return ASObject
*/
public function setBcc($bcc)
{
$this->bcc = $bcc;
return $this;
}
/**
* @return mixed
*/
public function getMediaType()
{
return $this->mediaType;
}
/**
* @param mixed $mediaType
* @return ASObject
*/
public function setMediaType($mediaType)
{
$this->mediaType = $mediaType;
return $this;
}
/**
* @return mixed
*/
public function getDuration()
{
return $this->duration;
}
/**
* @param mixed $duration
* @return ASObject
*/
public function setDuration($duration)
{
$this->duration = $duration;
return $this;
}
/**
* @return mixed
*/
public function getSource()
{
return $this->source;
}
/**
* @param mixed $source
* @return ASObject
*/
public function setSource($source)
{
$this->source = $source;
return $this;
}
}

View File

@@ -0,0 +1,122 @@
<?php
namespace Zotlabs\ActivityStreams;
class Activity extends ASObject
{
public $actor;
public $object;
public $target;
public $result;
public $origin;
public $instrument;
/**
* @return mixed
*/
public function getActor()
{
return $this->actor;
}
/**
* @param mixed $actor
* @return Activity
*/
public function setActor($actor)
{
$this->actor = $actor;
return $this;
}
/**
* @return mixed
*/
public function getObject()
{
return $this->object;
}
/**
* @param mixed $object
* @return Activity
*/
public function setObject($object)
{
$this->object = $object;
return $this;
}
/**
* @return mixed
*/
public function getTarget()
{
return $this->target;
}
/**
* @param mixed $target
* @return Activity
*/
public function setTarget($target)
{
$this->target = $target;
return $this;
}
/**
* @return mixed
*/
public function getResult()
{
return $this->result;
}
/**
* @param mixed $result
* @return Activity
*/
public function setResult($result)
{
$this->result = $result;
return $this;
}
/**
* @return mixed
*/
public function getOrigin()
{
return $this->origin;
}
/**
* @param mixed $origin
* @return Activity
*/
public function setOrigin($origin)
{
$this->origin = $origin;
return $this;
}
/**
* @return mixed
*/
public function getInstrument()
{
return $this->instrument;
}
/**
* @param mixed $instrument
* @return Activity
*/
public function setInstrument($instrument)
{
$this->instrument = $instrument;
return $this;
}
}

View File

@@ -0,0 +1,428 @@
<?php
namespace Zotlabs\ActivityStreams;
class Actor extends ASObject
{
public $inbox;
public $outbox;
public $followers;
public $following;
public $permissions; /* extension property */
public $endpoints;
public $publicKey;
public $preferredUsername;
public $alsoKnownAs;
// Extension properties
public $movedTo;
public $copiedTo;
public $discoverable;
public $manuallyApprovesFollowers;
public $webfinger;
public $canSearch;
public $indexable;
public $assertionMethod;
public $gateways;
public $openwebauth;
public $authredirect;
/**
* @return mixed
*/
public function getAlsoKnownAs()
{
return $this->alsoKnownAs;
}
/**
* @param mixed $alsoKnownAs
* @return Actor
*/
public function setAlsoKnownAs($alsoKnownAs)
{
$this->alsoKnownAs = $alsoKnownAs;
return $this;
}
/**
* @return mixed
*/
public function getMovedTo()
{
return $this->movedTo;
}
/**
* @return mixed
*/
public function getCopiedTo()
{
return $this->copiedTo;
}
/**
* @param mixed $copiedTo
* @return Actor
*/
public function setCopiedTo($copiedTo)
{
$this->copiedTo = $copiedTo;
return $this;
}
/**
* @param mixed $movedTo
* @return Actor
*/
public function setMovedTo($movedTo)
{
$this->movedTo = $movedTo;
return $this;
}
/**
* @return mixed
*/
public function getDiscoverable()
{
return $this->discoverable;
}
/**
* @param mixed $discoverable
* @return Actor
*/
public function setDiscoverable($discoverable)
{
$this->discoverable = $discoverable;
return $this;
}
/**
* @return mixed
*/
public function getManuallyApprovesFollowers()
{
return $this->manuallyApprovesFollowers;
}
/**
* @param mixed $manuallyApprovesFollowers
* @return Actor
*/
public function setManuallyApprovesFollowers($manuallyApprovesFollowers)
{
$this->manuallyApprovesFollowers = $manuallyApprovesFollowers;
return $this;
}
/**
* @return mixed
*/
public function getPreferredUsername()
{
return $this->preferredUsername;
}
/**
* @param mixed $preferredUsername
* @return Actor
*/
public function setPreferredUsername($preferredUsername)
{
$this->preferredUsername = $preferredUsername;
return $this;
}
/**
* @return mixed
*/
public function getId()
{
return $this->id;
}
/**
* @param mixed $id
* @return Actor
*/
public function setId($id)
{
$this->id = $id;
return $this;
}
/**
* @return mixed
*/
public function getType()
{
return $this->type;
}
/**
* @param mixed $type
* @return Actor
*/
public function setType($type)
{
$this->type = $type;
return $this;
}
/**
* @return mixed
*/
public function getInbox()
{
return $this->inbox;
}
/**
* @param mixed $inbox
* @return Actor
*/
public function setInbox($inbox)
{
$this->inbox = $inbox;
return $this;
}
/**
* @return mixed
*/
public function getOutbox()
{
return $this->outbox;
}
/**
* @param mixed $outbox
* @return Actor
*/
public function setOutbox($outbox)
{
$this->outbox = $outbox;
return $this;
}
/**
* @return mixed
*/
public function getFollowers()
{
return $this->followers;
}
/**
* @param mixed $followers
* @return Actor
*/
public function setFollowers($followers)
{
$this->followers = $followers;
return $this;
}
/**
* @return mixed
*/
public function getFollowing()
{
return $this->following;
}
/**
* @param mixed $following
* @return Actor
*/
public function setFollowing($following)
{
$this->following = $following;
return $this;
}
/**
* @return mixed
*/
public function getEndpoints()
{
return $this->endpoints;
}
/**
* @param mixed $endpoints
* @return Actor
*/
public function setEndpoints($endpoints)
{
$this->endpoints = $endpoints;
return $this;
}
/**
* @return mixed
*/
public function getPublicKey()
{
return $this->publicKey;
}
/**
* @param mixed $publicKey
* @return Actor
*/
public function setPublicKey($publicKey)
{
$this->publicKey = $publicKey;
return $this;
}
/**
* @return mixed
*/
public function getWebfinger()
{
return $this->webfinger;
}
/**
* @param mixed $webfinger
* @return Actor
*/
public function setWebfinger($webfinger)
{
$this->webfinger = $webfinger;
return $this;
}
/**
* @return mixed
*/
public function getCanSearch()
{
return $this->canSearch;
}
/**
* @param mixed $canSearch
* @return Actor
*/
public function setCanSearch($canSearch)
{
$this->canSearch = $canSearch;
return $this;
}
/**
* @return mixed
*/
public function getIndexable()
{
return $this->indexable;
}
/**
* @param mixed $indexable
* @return Actor
*/
public function setIndexable($indexable)
{
$this->indexable = $indexable;
return $this;
}
/**
* @return mixed
*/
public function getAssertionMethod()
{
return $this->assertionMethod;
}
/**
* @param mixed $assertionMethod
* @return Actor
*/
public function setAssertionMethod($assertionMethod)
{
$this->assertionMethod = $assertionMethod;
return $this;
}
/**
* @return mixed
*/
public function getGateways()
{
return $this->gateways;
}
/**
* @param mixed $gateways
* @return Actor
*/
public function setGateways($gateways)
{
$this->gateways = $gateways;
return $this;
}
/**
* @return mixed
*/
public function getPermissions()
{
return $this->permissions;
}
/**
* @param mixed $permissions
* @return Actor
*/
public function setPermissions($permissions)
{
$this->permissions = $permissions;
return $this;
}
/**
* @return mixed
*/
public function getOpenwebauth()
{
return $this->openwebauth;
}
/**
* @param mixed $openwebauth
* @return Actor
*/
public function setOpenwebauth($openwebauth)
{
$this->openwebauth = $openwebauth;
return $this;
}
/**
* @return mixed
*/
public function getAuthredirect()
{
return $this->authredirect;
}
/**
* @param mixed $authredirect
* @return Actor
*/
public function setAuthredirect($authredirect)
{
$this->authredirect = $authredirect;
return $this;
}
}

View File

@@ -0,0 +1,87 @@
<?php
namespace Zotlabs\ActivityStreams;
class AssertionMethod extends ASObject
{
public $id;
public $type;
public $controller;
public $publicKeyMultibase;
/**
* @return mixed
*/
public function getId()
{
return $this->id;
}
/**
* @param mixed $id
* @return AssertionMethod
*/
public function setId($id)
{
$this->id = $id;
return $this;
}
/**
* @return mixed
*/
public function getType()
{
return $this->type;
}
/**
* @param mixed $type
* @return AssertionMethod
*/
public function setType($type)
{
$this->type = $type;
return $this;
}
/**
* @return mixed
*/
public function getController()
{
return $this->controller;
}
/**
* @param mixed $controller
* @return AssertionMethod
*/
public function setController($controller)
{
$this->controller = $controller;
return $this;
}
/**
* @return mixed
*/
public function getPublicKeyMultibase()
{
return $this->publicKeyMultibase;
}
/**
* @param mixed $publicKeyMultibase
* @return AssertionMethod
*/
public function setPublicKeyMultibase($publicKeyMultibase)
{
$this->publicKeyMultibase = $publicKeyMultibase;
return $this;
}
}

View File

@@ -0,0 +1,124 @@
<?php
namespace Zotlabs\ActivityStreams;
class Collection extends ASObject
{
public int $totalItems;
public string $current;
public string $first;
public string $last;
public array $items;
public mixed $collectionOf;
/**
* @return int
*/
public function getTotalItems(): int
{
return $this->totalItems;
}
/**
* @param mixed $totalItems
* @return Collection
*/
public function setTotalItems(mixed $totalItems): static
{
$this->totalItems = $totalItems;
return $this;
}
/**
* @return string
*/
public function getCurrent(): string
{
return $this->current;
}
/**
* @param mixed $current
* @return Collection
*/
public function setCurrent(mixed $current): static
{
$this->current = $current;
return $this;
}
/**
* @return string
*/
public function getFirst(): string
{
return $this->first;
}
/**
* @param mixed $first
* @return Collection
*/
public function setFirst(mixed $first): static
{
$this->first = $first;
return $this;
}
/**
* @return string
*/
public function getLast(): string
{
return $this->last;
}
/**
* @param mixed $last
* @return Collection
*/
public function setLast(mixed $last): static
{
$this->last = $last;
return $this;
}
/**
* @return array
*/
public function getItems(): array
{
return $this->items;
}
/**
* @param mixed $items
* @return Collection
*/
public function setItems(mixed $items): static
{
$this->items = $items;
return $this;
}
/**
* @return mixed
*/
public function getCollectionOf(): mixed
{
return $this->collectionOf;
}
/**
* @param mixed $collectionOf
* @return Collection
*/
public function setCollectionOf(mixed $collectionOf): static
{
$this->collectionOf = $collectionOf;
return $this;
}
}

View File

@@ -0,0 +1,73 @@
<?php
namespace Zotlabs\ActivityStreams;
class CollectionPage extends Collection
{
public $partOf;
public $next;
public $prev;
// startIndex only applies for OrderedCollectionPage. See
// https://www.w3.org/ns/activitystreams#OrderedCollectionPage
// It is provided here to avoid multiple inheritance
public $startIndex;
/**
* @return mixed
*/
public function getPartOf()
{
return $this->partOf;
}
/**
* @param mixed $partOf
* @return CollectionPage
*/
public function setPartOf($partOf)
{
$this->partOf = $partOf;
return $this;
}
/**
* @return mixed
*/
public function getNext()
{
return $this->next;
}
/**
* @param mixed $next
* @return CollectionPage
*/
public function setNext($next)
{
$this->next = $next;
return $this;
}
/**
* @return mixed
*/
public function getPrev()
{
return $this->prev;
}
/**
* @param mixed $prev
* @return CollectionPage
*/
public function setPrev($prev)
{
$this->prev = $prev;
return $this;
}
}

View File

@@ -0,0 +1,104 @@
<?php
namespace Zotlabs\ActivityStreams;
class IntransitiveActivity extends ASObject
{
public $actor;
public $target;
public $result;
public $origin;
public $instrument;
/**
* @return mixed
*/
public function getActor()
{
return $this->actor;
}
/**
* @param mixed $actor
* @return IntransitiveActivity
*/
public function setActor($actor)
{
$this->actor = $actor;
return $this;
}
/**
* @return mixed
*/
public function getTarget()
{
return $this->target;
}
/**
* @param mixed $target
* @return IntransitiveActivity
*/
public function setTarget($target)
{
$this->target = $target;
return $this;
}
/**
* @return mixed
*/
public function getResult()
{
return $this->result;
}
/**
* @param mixed $result
* @return IntransitiveActivity
*/
public function setResult($result)
{
$this->result = $result;
return $this;
}
/**
* @return mixed
*/
public function getOrigin()
{
return $this->origin;
}
/**
* @param mixed $origin
* @return IntransitiveActivity
*/
public function setOrigin($origin)
{
$this->origin = $origin;
return $this;
}
/**
* @return mixed
*/
public function getInstrument()
{
return $this->instrument;
}
/**
* @param mixed $instrument
* @return IntransitiveActivity
*/
public function setInstrument($instrument)
{
$this->instrument = $instrument;
return $this;
}
}

View File

@@ -0,0 +1,183 @@
<?php
namespace Zotlabs\ActivityStreams;
use Zotlabs\Lib\BaseObject;
class Link extends BaseObject
{
public $type;
public $href;
public $rel;
public $mediaType;
public $name;
public $hreflang;
public $height;
public $width;
public $preview;
/**
* @return mixed
*/
public function getType()
{
return $this->type;
}
/**
* @param mixed $type
* @return Link
*/
public function setType($type)
{
$this->type = $type;
return $this;
}
/**
* @return mixed
*/
public function getHref()
{
return $this->href;
}
/**
* @param mixed $href
* @return Link
*/
public function setHref($href)
{
$this->href = $href;
return $this;
}
/**
* @return mixed
*/
public function getRel()
{
return $this->rel;
}
/**
* @param mixed $rel
* @return Link
*/
public function setRel($rel)
{
$this->rel = $rel;
return $this;
}
/**
* @return mixed
*/
public function getMediaType()
{
return $this->mediaType;
}
/**
* @param mixed $mediaType
* @return Link
*/
public function setMediaType($mediaType)
{
$this->mediaType = $mediaType;
return $this;
}
/**
* @return mixed
*/
public function getName()
{
return $this->name;
}
/**
* @param mixed $name
* @return Link
*/
public function setName($name)
{
$this->name = $name;
return $this;
}
/**
* @return mixed
*/
public function getHreflang()
{
return $this->hreflang;
}
/**
* @param mixed $hreflang
* @return Link
*/
public function setHreflang($hreflang)
{
$this->hreflang = $hreflang;
return $this;
}
/**
* @return mixed
*/
public function getHeight()
{
return $this->height;
}
/**
* @param mixed $height
* @return Link
*/
public function setHeight($height)
{
$this->height = $height;
return $this;
}
/**
* @return mixed
*/
public function getWidth()
{
return $this->width;
}
/**
* @param mixed $width
* @return Link
*/
public function setWidth($width)
{
$this->width = $width;
return $this;
}
/**
* @return mixed
*/
public function getPreview()
{
return $this->preview;
}
/**
* @param mixed $preview
* @return Link
*/
public function setPreview($preview)
{
$this->preview = $preview;
return $this;
}
}

View File

@@ -0,0 +1,8 @@
<?php
namespace Zotlabs\ActivityStreams;
class OrderedCollection extends Collection
{
}

View File

@@ -0,0 +1,92 @@
<?php
namespace Zotlabs\ActivityStreams;
/**
* According to the specification, OrderedCollectionPage extends
* both OrderedCollection and CollectionPage, but PHP is still a bit awkward
* when it comes to multiple inheritance. Rather than try and do this with
* traits, we'll just include the CollectionPage elements here - as this only
* consists of three properties.
*/
class OrderedCollectionPage extends OrderedCollection
{
public $partOf;
public $next;
public $prev;
public $startIndex;
/**
* @return mixed
*/
public function getPartOf()
{
return $this->partOf;
}
/**
* @param mixed $partOf
* @return OrderedCollectionPage
*/
public function setPartOf($partOf)
{
$this->partOf = $partOf;
return $this;
}
/**
* @return mixed
*/
public function getNext()
{
return $this->next;
}
/**
* @param mixed $next
* @return OrderedCollectionPage
*/
public function setNext($next)
{
$this->next = $next;
return $this;
}
/**
* @return mixed
*/
public function getPrev()
{
return $this->prev;
}
/**
* @param mixed $prev
* @return OrderedCollectionPage
*/
public function setPrev($prev)
{
$this->prev = $prev;
return $this;
}
/**
* @return mixed
*/
public function getStartIndex()
{
return $this->startIndex;
}
/**
* @param mixed $startIndex
* @return OrderedCollectionPage
*/
public function setStartIndex($startIndex)
{
$this->startIndex = $startIndex;
return $this;
}
}

View File

@@ -0,0 +1,125 @@
<?php
namespace Zotlabs\ActivityStreams;
class Place extends ASObject
{
public $accuracy;
public $altitude;
public $latitude;
public $longitude;
public $radius;
public $units;
/**
* @return mixed
*/
public function getAccuracy()
{
return $this->accuracy;
}
/**
* @param mixed $accuracy
* @return Place
*/
public function setAccuracy($accuracy)
{
$this->accuracy = $accuracy;
return $this;
}
/**
* @return mixed
*/
public function getAltitude()
{
return $this->altitude;
}
/**
* @param mixed $altitude
* @return Place
*/
public function setAltitude($altitude)
{
$this->altitude = $altitude;
return $this;
}
/**
* @return mixed
*/
public function getLatitude()
{
return $this->latitude;
}
/**
* @param mixed $latitude
* @return Place
*/
public function setLatitude($latitude)
{
$this->latitude = $latitude;
return $this;
}
/**
* @return mixed
*/
public function getLongitude()
{
return $this->longitude;
}
/**
* @param mixed $longitude
* @return Place
*/
public function setLongitude($longitude)
{
$this->longitude = $longitude;
return $this;
}
/**
* @return mixed
*/
public function getRadius()
{
return $this->radius;
}
/**
* @param mixed $radius
* @return Place
*/
public function setRadius($radius)
{
$this->radius = $radius;
return $this;
}
/**
* @return mixed
*/
public function getUnits()
{
return $this->units;
}
/**
* @param mixed $units
* @return Place
*/
public function setUnits($units)
{
$this->units = $units;
return $this;
}
}

View File

@@ -0,0 +1,29 @@
<?php
namespace Zotlabs\ActivityStreams;
class Profile extends ASObject
{
public $describes;
/**
* @return mixed
*/
public function getDescribes()
{
return $this->describes;
}
/**
* @param mixed $describes
* @return Profile
*/
public function setDescribes($describes)
{
$this->describes = $describes;
return $this;
}
}

View File

@@ -0,0 +1,68 @@
<?php
namespace Zotlabs\ActivityStreams;
class PublicKey extends ASObject
{
public $owner;
public $signatureAlgorithm;
public $publicKeyPem;
/**
* @return mixed
*/
public function getOwner()
{
return $this->owner;
}
/**
* @param mixed $owner
* @return PublicKey
*/
public function setOwner($owner)
{
$this->owner = $owner;
return $this;
}
/**
* @return mixed
*/
public function getSignatureAlgorithm()
{
return $this->signatureAlgorithm;
}
/**
* @param mixed $signatureAlgorithm
* @return PublicKey
*/
public function setSignatureAlgorithm($signatureAlgorithm)
{
$this->signatureAlgorithm = $signatureAlgorithm;
return $this;
}
/**
* @return mixed
*/
public function getPublicKeyPem()
{
return $this->publicKeyPem;
}
/**
* @param mixed $publicKeyPem
* @return PublicKey
*/
public function setPublicKeyPem($publicKeyPem)
{
$this->publicKeyPem = $publicKeyPem;
return $this;
}
}

View File

@@ -0,0 +1,67 @@
<?php
namespace Zotlabs\ActivityStreams;
class Question extends ASObject
{
public $oneOf;
public $anyOf;
public $closed;
/**
* @return mixed
*/
public function getOneOf()
{
return $this->oneOf;
}
/**
* @param mixed $oneOf
* @return Question
*/
public function setOneOf($oneOf)
{
$this->oneOf = $oneOf;
return $this;
}
/**
* @return mixed
*/
public function getAnyOf()
{
return $this->anyOf;
}
/**
* @param mixed $anyOf
* @return Question
*/
public function setAnyOf($anyOf)
{
$this->anyOf = $anyOf;
return $this;
}
/**
* @return mixed
*/
public function getClosed()
{
return $this->closed;
}
/**
* @param mixed $closed
* @return Question
*/
public function setClosed($closed)
{
$this->closed = $closed;
return $this;
}
}

View File

@@ -0,0 +1,67 @@
<?php
namespace Zotlabs\ActivityStreams;
class Relationship extends ASObject
{
public $subject;
public $object;
public $relationship;
/**
* @return mixed
*/
public function getSubject()
{
return $this->subject;
}
/**
* @param mixed $subject
* @return Relationship
*/
public function setSubject($subject)
{
$this->subject = $subject;
return $this;
}
/**
* @return mixed
*/
public function getObject()
{
return $this->object;
}
/**
* @param mixed $object
* @return Relationship
*/
public function setObject($object)
{
$this->object = $object;
return $this;
}
/**
* @return mixed
*/
public function getRelationship()
{
return $this->relationship;
}
/**
* @param mixed $relationship
* @return Relationship
*/
public function setRelationship($relationship)
{
$this->relationship = $relationship;
return $this;
}
}

View File

@@ -0,0 +1,65 @@
<?php
namespace Zotlabs\ActivityStreams;
class Signature extends ASObject
{
public $nonce;
public $creator;
public $signatureValue;
/**
* @return mixed
*/
public function getCreator()
{
return $this->creator;
}
/**
* @param mixed $creator
* @return Signature
*/
public function setCreator($creator)
{
$this->creator = $creator;
return $this;
}
/**
* @return mixed
*/
public function getSignatureValue()
{
return $this->signatureValue;
}
/**
* @param mixed $signatureValue
* @return Signature
*/
public function setSignatureValue($signatureValue)
{
$this->signatureValue = $signatureValue;
return $this;
}
/**
* @return mixed
*/
public function getNonce()
{
return $this->nonce;
}
/**
* @param mixed $nonce
* @return Signature
*/
public function setNonce($nonce)
{
$this->nonce = $nonce;
return $this;
}
}

View File

@@ -0,0 +1,48 @@
<?php
namespace Zotlabs\ActivityStreams;
class Tombstone extends ASObject
{
public $formerType;
public $deleted;
/**
* @return mixed
*/
public function getFormerType()
{
return $this->formerType;
}
/**
* @param mixed $formerType
* @return Tombstone
*/
public function setFormerType($formerType)
{
$this->formerType = $formerType;
return $this;
}
/**
* @return mixed
*/
public function getDeleted()
{
return $this->deleted;
}
/**
* @param mixed $deleted
* @return Tombstone
*/
public function setDeleted($deleted)
{
$this->deleted = $deleted;
return $this;
}
}

View File

@@ -0,0 +1,8 @@
<?php
namespace Zotlabs\ActivityStreams;
class UnhandledElementException extends \Exception
{
}

View File

@@ -2,13 +2,13 @@
namespace Zotlabs\Daemon;
require_once('include/zot.php');
class Addon {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
call_hooks('daemon_addon',$argv);
call_hooks('daemon_addon', $argv);
return;
}
}

View File

@@ -2,26 +2,32 @@
namespace Zotlabs\Daemon;
class Cache_embeds {
static public function run($argc,$argv) {
if(! $argc == 2)
if(!$argc == 2) {
return;
}
$c = q("select body from item where id = %d ",
dbesc(intval($argv[1]))
$c = q("select uid, aid, body, item_private from item where uuid = '%s'",
dbesc($argv[1])
);
if(! $c)
if(!$c) {
return;
}
$item = $c[0];
// bbcode conversion by default processes embeds that aren't already cached.
// Ignore the returned html output.
// Ignore the returned html output.
bbcode($item['body']);
// photocache addon hook to prefetch one copy of public item images for the sys channel
call_hooks('cache_prefetch_hook', $item);
return;
}
}

View File

@@ -0,0 +1,42 @@
<?php
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Cache;
use Zotlabs\Lib\Config;
class Cache_query {
static public function run($argc, $argv) {
if(! $argc == 3)
return;
$r = null;
$key = $argv[1];
$pid = Config::Get('procid', $key, false);
if ($pid && (function_exists('posix_kill') ? posix_kill($pid, 0) : true)) {
logger($key . ': procedure already run with pid ' . $pid, LOGGER_DEBUG);
return;
}
$pid = getmypid();
Config::Set('procid', $key, $pid);
array_shift($argv);
array_shift($argv);
$arr = json_decode(base64_decode($argv[0]), true);
$r = call_user_func_array('q', $arr);
if(is_array($r)) {
Cache::set($key, serialize($r));
}
Config::Delete('procid', $key);
return;
}
}

View File

@@ -0,0 +1,34 @@
<?php
namespace Zotlabs\Daemon;
class Channel_purge {
static public function run($argc,$argv) {
cli_startup();
$channel_id = intval($argv[1]);
$channel = q("select * from channel where channel_id = %d and channel_removed = 1",
intval($channel_id)
);
if (! $channel) {
return;
}
do {
$r = q("select id from item where uid = %d and item_deleted = 0 limit 1000",
intval($channel_id)
);
if ($r) {
foreach ($r as $rv) {
drop_item($rv['id'], uid: $channel_id);
}
}
} while ($r);
return;
}
}

View File

@@ -2,39 +2,44 @@
namespace Zotlabs\Daemon;
require_once('include/zot.php');
use Zotlabs\Lib\Config;
require_once('include/hubloc.php');
class Checksites {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
logger('checksites: start');
if(($argc > 1) && ($argv[1]))
$site_id = '';
$sql_options = '';
if (($argc > 1) && ($argv[1]))
$site_id = $argv[1];
if($site_id)
if ($site_id)
$sql_options = " and site_url = '" . dbesc($argv[1]) . "' ";
$days = intval(get_config('system','sitecheckdays'));
if($days < 1)
$days = intval(Config::Get('system', 'sitecheckdays'));
if ($days < 1)
$days = 30;
$r = q("select * from site where site_dead = 0 and site_update < %s - INTERVAL %s and site_type = %d $sql_options ",
db_utcnow(), db_quoteinterval($days . ' DAY'),
db_utcnow(),
db_quoteinterval($days . ' DAY'),
intval(SITE_TYPE_ZOT)
);
if(! $r)
if (!$r)
return;
foreach($r as $rr) {
if(! strcasecmp($rr['site_url'],z_root()))
foreach ($r as $rr) {
if (!strcasecmp($rr['site_url'], z_root()))
continue;
$x = ping_site($rr['site_url']);
if($x['success']) {
if ($x['success']) {
logger('checksites: ' . $rr['site_url']);
q("update site set site_update = '%s' where site_url = '%s' ",
dbesc(datetime_convert()),

View File

@@ -9,6 +9,7 @@ class Cli_suggest {
static public function run($argc,$argv) {
update_suggestions();
return;
}
}

View File

@@ -0,0 +1,83 @@
<?php
namespace Zotlabs\Daemon;
use Zotlabs\Web\HTTPSig;
use Zotlabs\Lib\PConfig;
require_once('include/cli_startup.php');
require_once('include/attach.php');
require_once('include/import.php');
class Content_importer {
static public function run($argc,$argv) {
cli_startup();
$page = $argv[1];
$since = $argv[2];
$until = $argv[3];
$channel_address = $argv[4];
$hz_server = urldecode($argv[5]);
$m = parse_url($hz_server);
$channel = channelx_by_nick($channel_address);
if(! $channel) {
logger('channel not found');
return;
}
$headers = [
'X-API-Token' => random_string(),
'X-API-Request' => $hz_server . '/api/z/1.0/item/export_page?f=&since=' . urlencode($since) . '&until=' . urlencode($until) . '&page=' . $page ,
'Host' => $m['host'],
'(request-target)' => 'get /api/z/1.0/item/export_page?f=&since=' . urlencode($since) . '&until=' . urlencode($until) . '&page=' . $page ,
];
$headers = HTTPSig::create_sig($headers,$channel['channel_prvkey'], channel_url($channel),true,'sha512');
$redirects = 0;
$x = z_fetch_url(
$hz_server . '/api/z/1.0/item/export_page?f=&since=' . urlencode($since) . '&until=' . urlencode($until) . '&page=' . $page,
false,
$redirects,
[ 'headers' => $headers ]
);
// logger('item fetch: ' . print_r($x,true));
if(! $x['success']) {
logger('no API response',LOGGER_DEBUG);
killme();
}
$j = json_decode($x['body'], true);
if($j && empty($j['item'])) {
PConfig::Set($channel['channel_id'], 'import', 'content_completed', 1);
return;
}
$saved_notification_flags = notifications_off($channel['channel_id']);
import_items($channel,$j['item'],false,((array_key_exists('relocate',$j)) ? $j['relocate'] : null));
notifications_on($channel['channel_id'], $saved_notification_flags);
PConfig::Set($channel['channel_id'], 'import', 'content_progress', [
'items_total' => $j['items_total'],
'items_page' => $j['items_page'],
'items_current_page' => count($j['item']),
'last_page' => $page,
'next_cmd' => ['Content_importer', sprintf('%d',$page + 1), $since, $until, $channel['channel_address'], urlencode($hz_server)]
]);
$page++;
Master::Summon([ 'Content_importer', sprintf('%d',$page), $since, $until, $channel['channel_address'], urlencode($hz_server) ]);
return;
}
}

93
Zotlabs/Daemon/Convo.php Normal file
View File

@@ -0,0 +1,93 @@
<?php
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Activity;
use Zotlabs\Lib\ActivityStreams;
use Zotlabs\Lib\ASCollection;
use Zotlabs\Lib\ASCache;
use Zotlabs\Lib\Config;
class Convo {
static public function run($argc, $argv) {
logger('convo invoked: ' . print_r($argv, true));
if ($argc < 4) {
return;
}
$channels = explode(',', $argv[1]);
if (!$channels) {
return;
}
$observer_hash = $argv[2];
if (!$observer_hash) {
return;
}
$mid = $argv[3];
if (!$mid) {
return;
}
$force = $argv[4] ?? false;
$interval = Config::Get('queueworker', 'queue_interval', 500000);
foreach ($channels as $channel_id) {
$channel = channelx_by_n($channel_id);
$obj = new ASCollection($mid, $channel);
$messages = $obj->get();
if (!$messages) {
continue;
}
foreach ($messages as $message) {
$network_fetch = false;
if (is_string($message)) {
$cached = ASCache::Get($message);
if ($cached) {
// logger('convo_cached: ' . $message);
$data = $cached;
}
else {
// logger('convo_fetching: ' . $message);
$network_fetch = true;
$data = Activity::fetch($message, $channel);
if ($data) {
ASCache::Set($message, $data);
}
}
}
else {
$data = $message;
}
if (!$network_fetch) {
// Add some delay so that the DB will not be overwhelmed
// Fetched from network will already have a slight delay
usleep($interval);
}
$AS = new ActivityStreams($data);
if ($AS->is_valid() && is_array($AS->obj)) {
$item = Activity::decode_note($AS);
$item['item_fetched'] = true;
Activity::store($channel, $observer_hash, $AS, $item, false, $force);
}
}
}
return;
}
}

View File

@@ -2,40 +2,57 @@
namespace Zotlabs\Daemon;
use DBA;
use Zotlabs\Lib\Config;
use Zotlabs\Lib\ObjCache;
use Zotlabs\Lib\Libsync;
use Zotlabs\Lib\Libzotdir;
class Cron {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
$maxsysload = intval(get_config('system','maxloadavg'));
if($maxsysload < 1)
$maxsysload = intval(Config::Get('system', 'maxloadavg'));
if ($maxsysload < 1)
$maxsysload = 50;
if(function_exists('sys_getloadavg')) {
if (function_exists('sys_getloadavg')) {
$load = sys_getloadavg();
if(intval($load[0]) > $maxsysload) {
if (intval($load[0]) > $maxsysload) {
logger('system: load ' . $load . ' too high. Cron deferred to next scheduled run.');
return;
}
}
/*
// Check for a lockfile. If it exists, but is over an hour old, it's stale. Ignore it.
$lockfile = 'store/[data]/cron';
if((file_exists($lockfile)) && (filemtime($lockfile) > (time() - 3600))
&& (! get_config('system','override_cron_lockfile'))) {
if ((file_exists($lockfile)) && (filemtime($lockfile) > (time() - 3600))
&& (!Config::Get('system', 'override_cron_lockfile'))) {
logger("cron: Already running");
return;
}
// Create a lockfile. Needs two vars, but $x doesn't need to contain anything.
$x = '';
file_put_contents($lockfile, $x);
*/
logger('cron: start');
// If this is a directory server, request a sync with an upstream
// directory at least once a day, up to once every poll interval.
// Pull remote changes and push local changes.
// potential issue: how do we keep from creating an endless update loop?
$dirmode = Config::Get('system', 'directory_mode');
if ($dirmode == DIRECTORY_MODE_SECONDARY || $dirmode == DIRECTORY_MODE_PRIMARY) {
Libzotdir::sync_directories($dirmode);
}
// run queue delivery process in the background
Master::Summon(array('Queue'));
Master::Summon(array('Poller'));
/**
@@ -46,27 +63,29 @@ class Cron {
db_utcnow(),
db_quoteinterval('3 MINUTE')
);
// expire any expired mail
q("delete from mail where expires > '%s' and expires < %s ",
dbesc(NULL_DATE),
db_utcnow()
);
require_once('include/account.php');
remove_expired_registrations();
$interval = Config::Get('queueworker', 'queue_interval', 500000);
// expire any expired items
$r = q("select id,item_wall from item where expires > '2001-01-01 00:00:00' and expires < %s
$r = q("select id, uid, item_wall from item where expires > '2001-01-01 00:00:00' and expires < %s
and item_deleted = 0 ",
db_utcnow()
);
if($r) {
require_once('include/items.php');
foreach($r as $rr) {
drop_item($rr['id'],false,(($rr['item_wall']) ? DROPITEM_PHASE1 : DROPITEM_NORMAL));
if($rr['item_wall']) {
if ($r) {
foreach ($r as $rr) {
// pass uid of the message for permission check as we are running as a daemon process with no session.
drop_item($rr['id'], (($rr['item_wall']) ? DROPITEM_PHASE1 : DROPITEM_NORMAL), uid: intval($rr['uid']));
if ($rr['item_wall']) {
// The notifier isn't normally invoked unless item_drop is interactive.
Master::Summon( [ 'Notifier', 'drop', $rr['id'] ] );
Master::Summon(['Notifier', 'drop', $rr['id']]);
if ($interval) {
usleep($interval);
}
}
}
}
@@ -75,12 +94,12 @@ class Cron {
// delete expired access tokens
$r = q("select atoken_id from atoken where atoken_expires > '%s' and atoken_expires < %s",
dbesc(NULL_DATE),
dbesc(DBA::$dba->get_null_date()),
db_utcnow()
);
if($r) {
if ($r) {
require_once('include/security.php');
foreach($r as $rr) {
foreach ($r as $rr) {
atoken_delete($rr['atoken_id']);
}
}
@@ -90,33 +109,36 @@ class Cron {
// or dead entries.
$r = q("select channel_id from channel where channel_dirdate < %s - INTERVAL %s and channel_removed = 0",
db_utcnow(),
db_utcnow(),
db_quoteinterval('30 DAY')
);
if($r) {
foreach($r as $rr) {
Master::Summon(array('Directory',$rr['channel_id'],'force'));
if($interval)
@time_sleep_until(microtime(true) + (float) $interval);
if ($r) {
foreach ($r as $rr) {
Master::Summon(array('Directory', $rr['channel_id'], 'force'));
if ($interval) {
usleep($interval);
}
}
}
// Clean expired photos from cache
$r = q("SELECT DISTINCT xchan, content FROM photo WHERE photo_usage = %d AND expires < %s - INTERVAL %s",
intval(PHOTO_CACHE),
db_utcnow(),
db_quoteinterval(get_config('system','active_expire_days', '30') . ' DAY')
db_quoteinterval(Config::Get('system', 'default_expire_days', 30) . ' DAY')
);
if($r) {
if ($r) {
q("DELETE FROM photo WHERE photo_usage = %d AND expires < %s - INTERVAL %s",
intval(PHOTO_CACHE),
db_utcnow(),
db_quoteinterval(get_config('system','active_expire_days', '30') . ' DAY')
db_quoteinterval(Config::Get('system', 'default_expire_days', 30) . ' DAY')
);
foreach($r as $rr) {
foreach ($r as $rr) {
$file = dbunescbin($rr['content']);
if(is_file($file)) {
if (is_file($file)) {
@unlink($file);
@rmdir(dirname($file));
logger('info: deleted cached photo file ' . $file, LOGGER_DEBUG);
@@ -126,80 +148,63 @@ class Cron {
// publish any applicable items that were set to be published in the future
// (time travel posts). Restrict to items that have come of age in the last
// couple of days to limit the query to something reasonable.
// couple of days to limit the query to something reasonable.
$r = q("select id from item where item_delayed = 1 and created <= %s and created > '%s' ",
$r = q("select * from item where item_delayed = 1 and created <= %s and created > '%s' ",
db_utcnow(),
dbesc(datetime_convert('UTC','UTC','now - 2 days'))
dbesc(datetime_convert('UTC', 'UTC', 'now - 2 days'))
);
if($r) {
foreach($r as $rr) {
$x = q("update item set item_delayed = 0 where id = %d",
intval($rr['id'])
);
if($x) {
$z = q("select * from item where id = %d",
intval($message_id)
);
if($z) {
xchan_query($z);
$sync_item = fetch_post_tags($z);
Libsync::build_sync_packet($sync_item[0]['uid'],
[
'item' => [ encode_item($sync_item[0],true) ]
]
);
if ($r) {
xchan_query($r);
$items = fetch_post_tags($r);
foreach ($items as $item) {
$item['item_delayed'] = 0;
$post = item_store_update($item);
if($post['success']) {
Master::Summon(['Notifier', 'wall-new', $post['item_id']]);
if (!empty($post['approval_id'])) {
Master::Summon(['Notifier', 'wall-new', $post['approval_id']]);
}
Master::Summon(array('Notifier','wall-new',$rr['id']));
}
}
}
// check if any connections transitioned to zot6 and upgrade the connections to zot6 at this hub if so.
require_once('include/connections.php');
z6trans_connections();
require_once('include/attach.php');
attach_upgrade();
$abandon_days = intval(get_config('system','account_abandon_days'));
if($abandon_days < 1)
$abandon_days = 0;
if ($interval) {
usleep($interval);
}
}
}
// once daily run birthday_updates and then expire in background
// FIXME: add birthday updates, both locally and for xprof for use
// by directory servers
$d1 = intval(get_config('system','last_expire_day'));
$d2 = intval(datetime_convert('UTC','UTC','now','d'));
$d1 = intval(Config::Get('system', 'last_expire_day'));
$d2 = intval(datetime_convert('UTC', 'UTC', 'now', 'd'));
// Allow somebody to staggger daily activities if they have more than one site on their server,
// or if it happens at an inconvenient (busy) hour.
$h1 = intval(get_config('system','cron_hour'));
$h2 = intval(datetime_convert('UTC','UTC','now','G'));
$h1 = intval(Config::Get('system', 'cron_hour'));
$h2 = intval(datetime_convert('UTC', 'UTC', 'now', 'G'));
if(($d2 != $d1) && ($h1 == $h2)) {
if (($d2 != $d1) && ($h1 == $h2)) {
Master::Summon(array('Cron_daily'));
}
// update any photos which didn't get imported properly
// This should be rare
$r = q("select xchan_photo_l, xchan_hash from xchan where xchan_photo_l != '' and xchan_photo_m = ''
$r = q("select xchan_photo_l, xchan_hash from xchan where xchan_photo_l != '' and xchan_photo_m = ''
and xchan_photo_date < %s - INTERVAL %s",
db_utcnow(),
db_utcnow(),
db_quoteinterval('1 DAY')
);
if($r) {
if ($r) {
require_once('include/photo/photo_driver.php');
foreach($r as $rr) {
foreach ($r as $rr) {
$photos = import_xchan_photo($rr['xchan_photo_l'], $rr['xchan_hash'], false, true);
$x = q("update xchan set xchan_photo_l = '%s', xchan_photo_m = '%s', xchan_photo_s = '%s', xchan_photo_mimetype = '%s'
q("update xchan set xchan_photo_l = '%s', xchan_photo_m = '%s', xchan_photo_s = '%s', xchan_photo_mimetype = '%s'
where xchan_hash = '%s'",
dbesc($photos[0]),
dbesc($photos[1]),
@@ -211,36 +216,99 @@ class Cron {
}
// pull in some public posts
// pull in some public posts if allowed
$disable_discover_tab = get_config('system','disable_discover_tab') || get_config('system','disable_discover_tab') === false;
if(! $disable_discover_tab)
Master::Summon(array('Externals'));
$disable_externals = Config::Get('system', 'disable_discover_tab') || Config::Get('system', 'disable_discover_tab') === false || Config::Get('system', 'site_firehose');
if (!$disable_externals)
Master::Summon(['Externals']);
$generation = 0;
$restart = false;
$restart = false;
if(($argc > 1) && ($argv[1] == 'restart')) {
$restart = true;
if (($argc > 1) && ($argv[1] == 'restart')) {
$restart = true;
$generation = intval($argv[2]);
if(! $generation)
if (!$generation)
return;
}
reload_plugins();
$d = datetime_convert();
// TODO check to see if there are any cronhooks before wasting a process
if(! $restart)
if (!$restart)
Master::Summon(array('Cronhooks'));
set_config('system','lastcron',datetime_convert());
//All done - clear the lockfile
@unlink($lockfile);
// move as obj cache to fs
if (!Config::Get('system', 'as_objects_moved')) {
$results = dbq("select iconfig.*, item.mid from iconfig left join item on iid = item.id where cat = 'activitypub' and k = 'rawmsg' limit 300");
if ($results) {
foreach ($results as $result) {
if (is_string($result['v'])) {
if (str_starts_with($result['v'], '{')) {
$result['v'] = json_decode($result['v'], true);
}
elseif (str_starts_with($result['v'], 'json:')) {
$result['v'] = json_unserialize($result['v']);
}
elseif (preg_match('|^a:[0-9]+:{.*}$|s', $result['v'])) {
$result['v'] = unserialize($result['v'], ['allowed_classes' => false]);
}
}
if (is_array($result['v'])) {
ObjCache::Set($result['mid'], $result['v']);
}
q("delete from iconfig where id = %d",
intval($result['id'])
);
}
}
else {
Config::Set('system', 'as_objects_moved', 1);
}
}
// move diaspora obj cache to fs
if (!Config::Get('system', 'diaspora_objects_moved')) {
$results = dbq("select iconfig.*, item.mid from iconfig left join item on iid = item.id where cat = 'diaspora' and k = 'fields' limit 300");
if ($results) {
foreach ($results as $result) {
if (is_string($result['v'])) {
if (str_starts_with($result['v'], '{')) {
$result['v'] = json_decode($result['v'], true);
}
elseif (str_starts_with($result['v'], 'json:')) {
$result['v'] = json_unserialize($result['v']);
}
elseif (preg_match('|^a:[0-9]+:{.*}$|s', $result['v'])) {
$result['v'] = unserialize($result['v'], ['allowed_classes' => false]);
}
}
if (is_array($result['v'])) {
ObjCache::Set($result['mid'], $result['v'], 'diaspora');
}
q("delete from iconfig where id = %d",
intval($result['id'])
);
}
}
else {
Config::Set('system', 'diaspora_objects_moved', 1);
}
}
Config::Set('system', 'lastcron', datetime_convert());
//All done - clear the lockfile
//@unlink($lockfile);
return;
}

View File

@@ -2,9 +2,12 @@
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Config;
use Zotlabs\Lib\Libzotdir;
class Cron_daily {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
logger('cron_daily: start');
@@ -13,15 +16,12 @@ class Cron_daily {
*
*/
require_once('include/dir_fns.php');
check_upstream_directory();
Libzotdir::check_upstream_directory();
// Fire off the Cron_weekly process if it's the correct day.
$d3 = intval(datetime_convert('UTC','UTC','now','N'));
if($d3 == 7) {
$d3 = intval(datetime_convert('UTC', 'UTC', 'now', 'N'));
if ($d3 == 7) {
Master::Summon(array('Cron_weekly'));
}
@@ -50,10 +50,26 @@ class Cron_daily {
dbesc('sse_id.%')
);
// Clean up emdedded content cache
// Mark items seen after X days (default 90)
$r = dbq("select channel_id from channel where channel_removed = 0");
if ($r) {
foreach ($r as $rr) {
$mark_seen_days = get_pconfig($rr['channel_id'], 'system', 'mark_seen_days', 90);
q("UPDATE item SET item_unseen = 0 WHERE
uid = %d AND item_unseen = 1
AND created < %s - INTERVAL %s",
intval($rr['channel_id']),
db_utcnow(),
db_quoteinterval($mark_seen_days . ' DAY')
);
}
}
// Clean up cache
q("DELETE FROM cache WHERE updated < %s - INTERVAL %s",
db_utcnow(),
db_quoteinterval(get_config('system','active_expire_days', '30') . ' DAY')
db_utcnow(),
db_quoteinterval(Config::Get('system', 'cache_expire_days', 7) . ' DAY')
);
//update statistics in config
@@ -67,8 +83,8 @@ class Cron_daily {
// expire old delivery reports
$keep_reports = intval(get_config('system','expire_delivery_reports'));
if($keep_reports === 0)
$keep_reports = intval(Config::Get('system', 'expire_delivery_reports'));
if ($keep_reports === 0)
$keep_reports = 10;
q("delete from dreport where dreport_time < %s - INTERVAL %s",
@@ -79,32 +95,21 @@ class Cron_daily {
// expire any expired accounts
downgrade_accounts();
// If this is a directory server, request a sync with an upstream
// directory at least once a day, up to once every poll interval.
// Pull remote changes and push local changes.
// potential issue: how do we keep from creating an endless update loop?
$dirmode = get_config('system','directory_mode');
if($dirmode == DIRECTORY_MODE_SECONDARY || $dirmode == DIRECTORY_MODE_PRIMARY) {
require_once('include/dir_fns.php');
sync_directories($dirmode);
}
Master::Summon(array('Expire'));
Master::Summon(array('Cli_suggest'));
remove_obsolete_hublocs();
remove_duplicate_singleton_hublocs();
z6_discover();
$date = datetime_convert();
call_hooks('cron_daily', $date);
call_hooks('cron_daily',datetime_convert());
set_config('system','last_expire_day',intval(datetime_convert('UTC','UTC','now','d')));
Config::Set('system', 'last_expire_day', intval(datetime_convert('UTC', 'UTC', 'now', 'd')));
/**
* End Cron Daily
*/
return;
}
}

View File

@@ -2,37 +2,40 @@
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Config;
class Cron_weekly {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
/**
* Cron Weekly
*
*
* Actions in the following block are executed once per day only on Sunday (once per week).
*
*/
call_hooks('cron_weekly',datetime_convert());
$date = datetime_convert();
call_hooks('cron_weekly', $date);
z_check_cert();
prune_hub_reinstalls();
mark_orphan_hubsxchans();
// Find channels that were removed in the last three weeks, but
// Find channels that were removed in the last three weeks, but
// haven't been finally cleaned up. These should be older than 10
// days to ensure that "purgeall" messages have gone out or bounced
// or timed out.
// days to ensure that "purgeall" messages have gone out or bounced
// or timed out.
$r = q("select channel_id from channel where channel_removed = 1 and
$r = q("select channel_id from channel where channel_removed = 1 and
channel_deleted > %s - INTERVAL %s and channel_deleted < %s - INTERVAL %s",
db_utcnow(), db_quoteinterval('21 DAY'),
db_utcnow(), db_quoteinterval('10 DAY')
);
if($r) {
foreach($r as $rv) {
if ($r) {
foreach ($r as $rv) {
channel_remove_final($rv['channel_id']);
}
}
@@ -43,14 +46,14 @@ class Cron_weekly {
db_utcnow(), db_quoteinterval('14 DAY')
);
$dirmode = intval(get_config('system','directory_mode'));
if($dirmode === DIRECTORY_MODE_SECONDARY || $dirmode === DIRECTORY_MODE_PRIMARY) {
logger('regdir: ' . print_r(z_fetch_url(get_directory_primary() . '/regdir?f=&url=' . urlencode(z_root()) . '&realm=' . urlencode(get_directory_realm())),true));
$dirmode = intval(Config::Get('system', 'directory_mode'));
if ($dirmode === DIRECTORY_MODE_SECONDARY || $dirmode === DIRECTORY_MODE_PRIMARY) {
logger('regdir: ' . print_r(z_fetch_url(get_directory_primary() . '/regdir?f=&url=' . urlencode(z_root()) . '&realm=' . urlencode(get_directory_realm())), true));
}
// Check for dead sites
Master::Summon(array('Checksites'));
// update searchable doc indexes
Master::Summon(array('Importdoc'));
@@ -58,5 +61,6 @@ class Cron_weekly {
* End Cron Weekly
*/
return;
}
}
}

View File

@@ -2,6 +2,8 @@
namespace Zotlabs\Daemon;
use App;
// generate a curl compatible cookie file with an authenticated session for the given channel_id.
// If this file is then used with curl and the destination url is sent through zid() or manually
// manipulated to add a zid, it should allow curl to provide zot magic-auth across domains.
@@ -10,15 +12,15 @@ namespace Zotlabs\Daemon;
class CurlAuth {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
if($argc != 2)
if ($argc != 2)
return;
\App::$session->start();
App::$session->start();
$_SESSION['authenticated'] = 1;
$_SESSION['uid'] = $argv[1];
$_SESSION['uid'] = $argv[1];
$x = session_id();
@@ -29,14 +31,14 @@ class CurlAuth {
$output = '';
if($e) {
if ($e) {
$lines = file($f);
if($lines) {
foreach($lines as $line) {
if(strlen($line) > 0 && $line[0] != '#' && substr_count($line, "\t") == 6) {
if ($lines) {
foreach ($lines as $line) {
if (strlen($line) > 0 && $line[0] != '#' && substr_count($line, "\t") == 6) {
$tokens = explode("\t", $line);
$tokens = array_map('trim', $tokens);
if($tokens[4] > time()) {
if ($tokens[4] > time()) {
$output .= $line . "\n";
}
}
@@ -46,9 +48,9 @@ class CurlAuth {
}
}
$t = time() + (24 * 3600);
file_put_contents($f, $output . 'HttpOnly_' . \App::get_hostname() . "\tFALSE\t/\tTRUE\t$t\tPHPSESSID\t" . $x, (($e) ? FILE_APPEND : 0));
file_put_contents($f, $output . 'HttpOnly_' . App::get_hostname() . "\tFALSE\t/\tTRUE\t$t\tPHPSESSID\t" . $x, (($e) ? FILE_APPEND : 0));
file_put_contents($c,$x);
file_put_contents($c, $x);
return;
}

View File

@@ -2,92 +2,34 @@
namespace Zotlabs\Daemon;
use Zotlabs\Lib\DReport;
require_once('include/zot.php');
require_once('include/queue_fn.php');
use Zotlabs\Lib\Queue;
class Deliver {
static public function run($argc,$argv) {
if($argc < 2)
static public function run($argc, $argv) {
if ($argc < 2)
return;
logger('deliver: invoked: ' . print_r($argv,true), LOGGER_DATA);
logger('deliver: invoked: ' . print_r($argv, true), LOGGER_DATA);
for($x = 1; $x < $argc; $x ++) {
for ($x = 1; $x < $argc; $x++) {
if(! $argv[$x])
if (!$argv[$x])
continue;
$dresult = null;
$r = q("select * from outq where outq_hash = '%s' limit 1",
$r = q("select * from outq where outq_hash = '%s'",
dbesc($argv[$x])
);
if($r) {
$notify = json_decode($r[0]['outq_notify'],true);
// Messages without an outq_msg will need to go via the web, even if it's a
// local delivery. This includes conversation requests and refresh packets.
if(($r[0]['outq_posturl'] === z_root() . '/post') && ($r[0]['outq_msg'])) {
logger('deliver: local delivery', LOGGER_DEBUG);
// local delivery
// we should probably batch these and save a few delivery processes
if($r[0]['outq_msg']) {
$m = json_decode($r[0]['outq_msg'],true);
if(array_key_exists('message_list',$m)) {
foreach($m['message_list'] as $mm) {
$msg = array('body' => json_encode(array('success' => true, 'pickup' => array(array('notify' => $notify,'message' => $mm)))));
zot_import($msg,z_root());
}
}
else {
$msg = array('body' => json_encode(array('success' => true, 'pickup' => array(array('notify' => $notify,'message' => $m)))));
$dresult = zot_import($msg,z_root());
}
remove_queue_item($r[0]['outq_hash']);
if($dresult && is_array($dresult)) {
// delivery reports for local deliveries do not require encryption
foreach($dresult as $xx) {
if(is_array($xx) && array_key_exists('message_id',$xx)) {
if(DReport::is_storable($xx)) {
q("insert into dreport ( dreport_mid, dreport_site, dreport_recip, dreport_name, dreport_result, dreport_time, dreport_xchan ) values ( '%s', '%s', '%s', '%s', '%s', '%s', '%s' ) ",
dbesc($xx['message_id']),
dbesc($xx['location']),
dbesc($xx['recipient']),
dbesc(($xx['name']) ? $xx['name'] : EMPTY_STR),
dbesc($xx['status']),
dbesc(datetime_convert($xx['date'])),
dbesc($xx['sender'])
);
}
}
}
}
q("delete from dreport where dreport_queue = '%s'",
dbesc($argv[$x])
);
continue;
}
}
// otherwise it's a remote delivery - call queue_deliver() with the $immediate flag
queue_deliver($r[0],true);
if ($r) {
Queue::deliver($r[0], true);
}
}
return;
}
}

View File

@@ -2,21 +2,22 @@
namespace Zotlabs\Daemon;
require_once('include/zot.php');
class Deliver_hooks {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
if($argc < 2)
if ($argc < 2)
return;
$r = q("select * from item where id = '%d'",
intval($argv[1])
);
if($r)
call_hooks('notifier_normal',$r[0]);
if ($r) {
call_hooks('notifier_normal', $r[0]);
}
return;
}
}

View File

@@ -0,0 +1,25 @@
<?php
namespace Zotlabs\Daemon;
require_once('include/connections.php');
/*
* Daemon to remove 'item' resources in the background from a removed connection
*/
class Delxitems {
static public function run($argc, $argv) {
cli_startup();
if($argc != 3) {
return;
}
remove_abook_items($argv[1], $argv[2]);
return;
}
}

View File

@@ -2,46 +2,47 @@
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Config;
use Zotlabs\Lib\Libzot;
use Zotlabs\Lib\Libzotdir;
use Zotlabs\Lib\Queue;
class Directory {
static public function run($argc,$argv){
static public function run($argc, $argv) {
if($argc < 2)
if ($argc < 2)
return;
$force = false;
$force = false;
$pushall = true;
if($argc > 2) {
if($argv[2] === 'force')
if ($argc > 2) {
if ($argv[2] === 'force')
$force = true;
if($argv[2] === 'nopush')
if ($argv[2] === 'nopush')
$pushall = false;
}
}
logger('directory update', LOGGER_DEBUG);
$dirmode = get_config('system','directory_mode');
if($dirmode === false)
$dirmode = Config::Get('system', 'directory_mode');
if ($dirmode === false)
$dirmode = DIRECTORY_MODE_NORMAL;
$x = q("select * from channel where channel_id = %d limit 1",
intval($argv[1])
);
if(! $x)
if (!$x)
return;
$channel = $x[0];
if($dirmode != DIRECTORY_MODE_NORMAL) {
if ($dirmode != DIRECTORY_MODE_NORMAL) {
// this is an in-memory update and we don't need to send a network packet.
Libzotdir::local_dir_update($argv[1],$force);
Libzotdir::local_dir_update($argv[1], $force);
q("update channel set channel_dirdate = '%s' where channel_id = %d",
dbesc(datetime_convert()),
@@ -49,8 +50,9 @@ class Directory {
);
// Now update all the connections
if($pushall)
Master::Summon(array('Notifier','refresh_all',$channel['channel_id']));
if ($pushall) {
Master::Summon(array('Notifier', 'refresh_all', $channel['channel_id']));
}
return;
}
@@ -58,24 +60,23 @@ class Directory {
// otherwise send the changes upstream
$directory = Libzotdir::find_upstream_directory($dirmode);
$url = $directory['url'] . '/post';
$url = $directory['url'] . '/zot';
// ensure the upstream directory is updated
$packet = Libzot::build_packet($channel,(($force) ? 'force_refresh' : 'refresh'));
$z = Libzot::zot($url,$packet,$channel);
$packet = Libzot::build_packet($channel, (($force) ? 'force_refresh' : 'refresh'));
$z = Libzot::zot($url, $packet, $channel);
// re-queue if unsuccessful
if(! $z['success']) {
if (!$z['success']) {
/** @FIXME we aren't updating channel_dirdate if we have to queue
* the directory packet. That means we'll try again on the next poll run.
*/
$hash = random_string();
$hash = new_uuid();
Queue::insert(array(
'hash' => $hash,
@@ -94,8 +95,10 @@ class Directory {
}
// Now update all the connections
if($pushall)
Master::Summon(array('Notifier','refresh_all',$channel['channel_id']));
if ($pushall) {
Master::Summon(array('Notifier', 'refresh_all', $channel['channel_id']));
}
return;
}
}

View File

@@ -2,53 +2,55 @@
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Config;
require_once('include/items.php');
class Expire {
static public function run($argc,$argv){
static public function run($argc, $argv) {
cli_startup();
$pid = get_config('expire', 'procid', false);
$pid = Config::Get('procid', 'expire', false);
if ($pid && (function_exists('posix_kill') ? posix_kill($pid, 0) : true)) {
logger('Expire: procedure already run with pid ' . $pid, LOGGER_DEBUG);
return;
logger('procedure already run with pid ' . $pid, LOGGER_DEBUG);
return;
}
$pid = getmypid();
set_config('expire', 'procid', $pid);
Config::Set('procid', 'expire', $pid);
// perform final cleanup on previously delete items
$r = q("select id from item where item_deleted = 1 and item_pending_remove = 0 and changed < %s - INTERVAL %s",
db_utcnow(), db_quoteinterval('10 DAY')
$r = q("select id, uid from item where item_deleted = 1 and item_pending_remove = 0 and changed < %s - INTERVAL %s",
db_utcnow(),
db_quoteinterval('10 DAY')
);
if ($r) {
foreach ($r as $rr) {
drop_item($rr['id'], false, DROPITEM_PHASE2);
drop_item($rr['id'], DROPITEM_PHASE2, uid: $rr['uid']);
}
}
// physically remove anything that has been deleted for more than two months
/** @FIXME - this is a wretchedly inefficient query */
$r = q("delete from item where item_pending_remove = 1 and changed < %s - INTERVAL %s",
db_utcnow(), db_quoteinterval('36 DAY')
q("delete from item where item_pending_remove = 1 and changed < %s - INTERVAL %s",
db_utcnow(),
db_quoteinterval('36 DAY')
);
/** @FIXME make this optional as it could have a performance impact on large sites */
if (intval(get_config('system', 'optimize_items')))
if (intval(Config::Get('system', 'optimize_items')))
q("optimize table item");
logger('expire: start with pid ' . $pid, LOGGER_DEBUG);
$site_expire = intval(get_config('system', 'default_expire_days'));
$commented_days = intval(get_config('system','active_expire_days'));
$site_expire = intval(Config::Get('system', 'default_expire_days', 30));
$commented_days = intval(Config::Get('system', 'active_expire_days', 7));
logger('site_expire: ' . $site_expire);
$r = q("SELECT channel_id, channel_system, channel_address, channel_expire_days from channel where true");
$r = dbq("SELECT channel_id, channel_system, channel_address, channel_expire_days from channel where true");
if ($r) {
foreach ($r as $rr) {
@@ -58,17 +60,18 @@ class Expire {
continue;
// service class default (if non-zero) over-rides the site default
$service_class_expire = service_class_fetch($rr['channel_id'], 'expire_days');
if (intval($service_class_expire))
$channel_expire = $service_class_expire;
else
$channel_expire = $site_expire;
if (intval($channel_expire) && (intval($channel_expire) < intval($rr['channel_expire_days'])) ||
intval($rr['channel_expire_days'] == 0)) {
$expire_days = $channel_expire;
} else {
}
else {
$expire_days = $rr['channel_expire_days'];
}
@@ -83,8 +86,7 @@ class Expire {
// this should probably just fetch the channel_expire_days from the sys channel,
// but there's no convenient way to set it.
$expire_days = get_config('system', 'sys_expire_days');
$expire_days = Config::Get('system', 'sys_expire_days');
if ($expire_days === false)
$expire_days = 30;
@@ -93,13 +95,16 @@ class Expire {
}
logger('Expire: sys interval: ' . $expire_days, LOGGER_DEBUG);
if ($expire_days)
if ($expire_days) {
item_expire($x['channel_id'], $expire_days, $commented_days);
}
logger('Expire: sys: done', LOGGER_DEBUG);
}
del_config('expire', 'procid');
Config::Delete('procid', 'expire');
return;
}
}

View File

@@ -2,97 +2,157 @@
namespace Zotlabs\Daemon;
require_once('include/zot.php');
use Zotlabs\Lib\Activity;
use Zotlabs\Lib\Libzot;
use Zotlabs\Lib\ActivityStreams;
use Zotlabs\Lib\ASCollection;
require_once('include/channel.php');
class Externals {
static public function run($argc,$argv){
static public function run($argc, $argv) {
$total = 0;
logger('externals: start');
$importer = get_sys_channel();
$total = 0;
$attempts = 0;
$url = '';
logger('externals: startup', LOGGER_DEBUG);
// pull in some public posts
while ($total == 0 && $attempts < 3) {
$arr = ['url' => ''];
call_hooks('externals_url_select', $arr);
while($total == 0 && $attempts < 3) {
$arr = array('url' => '');
call_hooks('externals_url_select',$arr);
if($arr['url']) {
if ($arr['url']) {
$url = $arr['url'];
}
}
else {
$networks = ['zot6'];
if (plugin_is_installed('pubcrawl')) {
$networks[] = 'activitypub';
}
stringify_array_elms($networks);
$networks_str = implode(',', $networks);
$randfunc = db_getfunc('RAND');
// fixme this query does not deal with directory realms.
// fixme this query does not deal with directory realms.
//$r = q("select site_url, site_pull from site where site_url != '%s'
//and site_flags != %d and site_type = %d
//and site_dead = 0 and site_project like '%s' and site_version > '5.3.1' order by $randfunc limit 1",
//dbesc(z_root()),
//intval(DIRECTORY_MODE_STANDALONE),
//intval(SITE_TYPE_ZOT),
//dbesc('hubzilla%')
//);
$r = q("select site_url, site_pull from site where site_url != '%s' and site_flags != %d and site_type = %d and site_dead = 0 order by $randfunc limit 1",
$r = q("SELECT * FROM hubloc
LEFT JOIN abook ON abook_xchan = hubloc_hash
LEFT JOIN site ON site_url = hubloc_url WHERE
hubloc_network IN ( $networks_str ) AND
abook_xchan IS NULL AND
hubloc_url != '%s' AND
hubloc_updated > '%s' AND
hubloc_primary = 1 AND hubloc_deleted = 0 AND
site_dead = 0
ORDER BY $randfunc LIMIT 1",
dbesc(z_root()),
intval(DIRECTORY_MODE_STANDALONE),
intval(SITE_TYPE_ZOT)
datetime_convert('UTC', 'UTC', 'now - 30 days')
);
if($r)
$url = $r[0]['site_url'];
if ($r) {
$contact = $r[0];
$url = $contact['hubloc_id_url'];
}
}
$attempts++;
if (!$url) {
continue;
}
$blacklisted = false;
if(! check_siteallowed($url)) {
if (!check_siteallowed($contact['hubloc_url'])) {
logger('blacklisted site: ' . $url);
$blacklisted = true;
}
$attempts ++;
// make sure we can eventually break out if somebody blacklists all known sites
if($blacklisted) {
if($attempts > 20)
if ($blacklisted) {
if ($attempts > 5)
break;
$attempts --;
$attempts--;
continue;
}
if($url) {
if($r[0]['site_pull'] > NULL_DATE)
$mindate = urlencode(datetime_convert('','',$r[0]['site_pull'] . ' - 1 day'));
else {
$days = get_config('externals','since_days');
if($days === false)
$days = 15;
$mindate = urlencode(datetime_convert('','','now - ' . intval($days) . ' days'));
}
$cl = Activity::get_actor_collections($contact['hubloc_hash']);
if(empty($cl)) {
$cl = get_xconfig($contact['hubloc_hash'], 'activitypub', 'collections');
}
$feedurl = $url . '/zotfeed?f=&mindate=' . $mindate;
logger('externals: pulling public content from ' . $feedurl, LOGGER_DEBUG);
$x = z_fetch_url($feedurl);
if(($x) && ($x['success'])) {
q("update site set site_pull = '%s' where site_url = '%s'",
dbesc(datetime_convert()),
dbesc($url)
);
$j = json_decode($x['body'],true);
if($j['success'] && $j['messages']) {
$sys = get_sys_channel();
foreach($j['messages'] as $message) {
// on these posts, clear any route info.
$message['route'] = '';
$results = process_delivery(array('hash' => 'undefined'), get_item_elements($message),
array(array('hash' => $sys['xchan_hash'])), false, true);
$total ++;
}
logger('externals: import_public_posts: ' . $total . ' messages imported', LOGGER_DEBUG);
}
if (is_array($cl) && array_key_exists('outbox', $cl)) {
$url = $cl['outbox'];
}
else {
$url = str_replace('/channel/', '/outbox/', $contact['hubloc_id_url']);
if ($url) {
$url .= '?top=1';
}
}
if ($url) {
logger('fetching outbox: ' . $url);
$obj = new ASCollection($url, $importer, 0, 10);
$messages = $obj->get();
if ($messages) {
foreach ($messages as $message) {
if (is_string($message)) {
$message = Activity::fetch($message, $importer);
}
if ($message['type'] !== 'Create') {
continue;
}
if ($contact['hubloc_network'] === 'zot6') {
// make sure we only fetch top level items
if (isset($message['object']['inReplyTo'])) {
continue;
}
$obj_id = $message['object']['id'] ?? $message['object'];
Libzot::fetch_conversation($importer, $obj_id);
$total++;
continue;
}
$AS = new ActivityStreams($message);
if ($AS->is_valid() && is_array($AS->obj)) {
$item = Activity::decode_note($AS);
$item['item_fetched'] = true;
Activity::store($importer, $contact['hubloc_hash'], $AS, $item);
$total++;
}
}
}
logger('fetched messages count: ' . $total);
}
}
return;
}
}

View File

@@ -0,0 +1,44 @@
<?php
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Activity;
class Fetchparents {
static public function run($argc, $argv) {
logger('Fetchparents invoked: ' . print_r($argv, true));
if ($argc < 4) {
return;
}
$channels = explode(',', $argv[1]);
if (!$channels) {
return;
}
$observer_hash = $argv[2];
if (!$observer_hash) {
return;
}
$mid = $argv[3];
if (!$mid) {
return;
}
$force = $argv[4] ?? false;
foreach ($channels as $channel_id) {
$channel = channelx_by_n($channel_id);
Activity::fetch_and_store_parents($channel, $observer_hash, $mid, null, $force);
}
Activity::init_background_fetch($observer_hash);
return;
}
}

View File

@@ -0,0 +1,77 @@
<?php
namespace Zotlabs\Daemon;
use Zotlabs\Web\HTTPSig;
use Zotlabs\Lib\PConfig;
require_once('include/cli_startup.php');
require_once('include/attach.php');
require_once('include/import.php');
class File_importer {
static public function run($argc,$argv) {
cli_startup();
$page = $argv[1];
$channel_address = $argv[2];
$hz_server = urldecode($argv[3]);
$m = parse_url($hz_server);
$channel = channelx_by_nick($channel_address);
if(! $channel) {
logger('channel not found');
return;
}
$headers = [
'X-API-Token' => random_string(),
'X-API-Request' => $hz_server . '/api/z/1.0/file/export_page?f=records=1&page=' . $page,
'Host' => $m['host'],
'(request-target)' => 'get /api/z/1.0/file/export_page?f=records=1&page=' . $page,
];
$headers = HTTPSig::create_sig($headers,$channel['channel_prvkey'],channel_url($channel),true,'sha512');
// TODO: implement total count
$redirects = 0;
$x = z_fetch_url(
$hz_server . '/api/z/1.0/file/export_page?f=records=1&page=' . $page,
false,
$redirects,
[ 'headers' => $headers ]
);
// logger('file fetch: ' . print_r($x,true));
if(! $x['success']) {
logger('no API response',LOGGER_DEBUG);
killme();
}
$j = json_decode($x['body'],true);
if(! is_array($j['results'][0]['attach']) || ! count($j['results'][0]['attach'])) {
PConfig::Set($channel['channel_id'], 'import', 'files_completed', 1);
return;
}
$r = sync_files($channel, $j['results']);
PConfig::Set($channel['channel_id'], 'import', 'files_progress', [
'files_total' => $j['total'],
'files_page' => 1, // export page atm returns just one file
'last_page' => $page,
'next_cmd' => ['File_importer',sprintf('%d',$page + 1), $channel['channel_address'], urlencode($hz_server)]
]);
$page++;
Master::Summon([ 'File_importer',sprintf('%d',$page), $channel['channel_address'], urlencode($hz_server) ]);
return;
}
}

View File

@@ -9,27 +9,38 @@ use Zotlabs\Lib\Zotfinger;
// performs zot_finger on $argv[1], which is a hex_encoded webbie/reddress
class Gprobe {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
if($argc != 2)
if ($argc != 2)
return;
$url = hex2bin($argv[1]);
$is_webbie = false;
$r = null;
if(! strpos($url,'@'))
return;
if (filter_var($url, FILTER_VALIDATE_EMAIL)) {
$is_webbie = true;
$r = q("select * from hubloc where hubloc_addr = '%s' limit 1",
dbesc($url)
);
$r = q("select * from hubloc where hubloc_addr = '%s' and hubloc_network = 'zot6' limit 1",
dbesc($url)
);
}
elseif (filter_var($url, FILTER_VALIDATE_URL)) {
$r = q("select * from hubloc where hubloc_id_url = '%s' and hubloc_network = 'zot6' limit 1",
dbesc($url)
);
}
if(! $r) {
$href = Webfinger::zot_url(punify($url));
if($href) {
$zf = Zotfinger::exec($href, null);
if (!$r) {
if ($is_webbie) {
$url = Webfinger::zot_url(punify($url));
}
if(is_array($zf) && array_path_exists('signature/signer',$zf) && $zf['signature']['signer'] === $href && intval($zf['signature']['header_valid'])) {
$xc = Libzot::import_xchan($zf['data']);
if ($url) {
$zf = Zotfinger::exec($url, null);
if (is_array($zf) && array_path_exists('signature/signer', $zf) && $zf['signature']['signer'] === $url && intval($zf['signature']['header_valid'])) {
Libzot::import_xchan($zf['data']);
}
}
}

35
Zotlabs/Daemon/Importdoc.php Executable file → Normal file
View File

@@ -5,31 +5,52 @@ namespace Zotlabs\Daemon;
class Importdoc {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
require_once('include/help.php');
self::update_docs_dir('doc/*');
$sys = get_sys_channel();
// remove old files that weren't updated (indicates they were most likely deleted).
$i = q("select id from item where uid = %d and item_type = 5 and edited < %s - INTERVAL %s",
intval($sys['channel_id']),
db_utcnow(),
db_quoteinterval('14 DAY')
);
if ($i) {
foreach ($i as $iv) {
drop_item($iv['id'], uid: $sys['channel_id']);
}
}
return;
}
static public function update_docs_dir($s) {
$f = basename($s);
$d = dirname($s);
if($s === 'doc/html')
if ($s === 'doc/html') {
return;
}
$files = glob("$d/$f");
if($files) {
foreach($files as $fi) {
if($fi === 'doc/html') {
if ($files) {
foreach ($files as $fi) {
if ($fi === 'doc/html') {
continue;
}
if(is_dir($fi)) {
if (is_dir($fi)) {
self::update_docs_dir("$fi/*");
}
else {
// don't update media content
if(strpos(z_mime_content_type($fi),'text') === 0) {
if (strpos(z_mime_content_type($fi), 'text') === 0) {
store_doc_file($fi);
}
}

View File

@@ -6,22 +6,21 @@ use Zotlabs\Lib\Libsync;
class Importfile {
static public function run($argc,$argv){
static public function run($argc, $argv) {
logger('Importfile: ' . print_r($argv,true));
logger('Importfile: ' . print_r($argv, true));
if($argc < 3)
if ($argc < 3)
return;
$channel = channelx_by_n($argv[1]);
if(! $channel)
if (!$channel)
return;
$srcfile = $argv[2];
$folder = (($argc > 3) ? $argv[3] : '');
$dstname = (($argc > 4) ? $argv[4] : '');
$hash = random_string();
$hash = random_string();
$arr = [
'src' => $srcfile,
@@ -35,15 +34,15 @@ class Importfile {
'replace' => true
];
if($folder)
if ($folder)
$arr['folder'] = $folder;
attach_store($channel,$channel['channel_hash'],'import',$arr);
attach_store($channel, $channel['channel_hash'], 'import', $arr);
$sync = attach_export_data($channel, $hash);
if ($sync)
Libsync::build_sync_packet($channel['channel_id'], ['file' => [$sync]]);
$sync = attach_export_data($channel,$hash);
if($sync)
Libsync::build_sync_packet($channel['channel_id'],array('file' => array($sync)));
return;
}
}

View File

@@ -2,58 +2,69 @@
namespace Zotlabs\Daemon;
if(array_search( __file__ , get_included_files()) === 0) {
use Zotlabs\Lib\QueueWorker;
if (array_search(__file__, get_included_files()) === 0) {
require_once('include/cli_startup.php');
array_shift($argv);
$argc = count($argv);
if($argc)
Master::Release($argc,$argv);
if ($argc)
Master::Release($argc, $argv);
return;
}
class Master {
static public function Summon($arr) {
QueueWorker::Summon($arr);
return;
/*
$hookinfo = [
'argv'=>$arr
'argv' => $arr
];
call_hooks ('daemon_master_summon',$hookinfo);
call_hooks('daemon_master_summon', $hookinfo);
$arr = $hookinfo['argv'];
$arr = $hookinfo['argv'];
$argc = count($arr);
if ((!is_array($arr) || (count($arr) < 1))) {
logger("Summon handled by hook.",LOGGER_DEBUG);
if ((!is_array($arr) || ($argc < 1))) {
logger("Summon handled by hook.", LOGGER_DEBUG);
return;
}
$phpbin = get_config('system','phpbin','php');
proc_run($phpbin,'Zotlabs/Daemon/Master.php',$arr);
$phpbin = Config::Get('system', 'phpbin', 'php');
proc_run($phpbin, 'Zotlabs/Daemon/Master.php', $arr);
*/
}
static public function Release($argc,$argv) {
static public function Release($argc, $argv) {
cli_startup();
QueueWorker::Release($argv);
return;
/*
$hookinfo = [
'argv'=>$argv
'argv' => $argv
];
call_hooks ('daemon_master_release',$hookinfo);
call_hooks('daemon_master_release', $hookinfo);
$argv = $hookinfo['argv'];
$argc = count($argv);
if ((!is_array($argv) || (count($argv) < 1))) {
logger("Release handled by hook.",LOGGER_DEBUG);
if ((!is_array($argv) || ($argc < 1))) {
logger("Release handled by hook.", LOGGER_DEBUG);
return;
}
logger('Master: release: ' . json_encode($argv), LOGGER_ALL,LOG_DEBUG);
$cls = '\\Zotlabs\\Daemon\\' . $argv[0];
$cls::run($argc,$argv);
logger('Master: release: ' . json_encode($argv), LOGGER_ALL, LOG_DEBUG);
$cls = '\\Zotlabs\\Daemon\\' . $argv[0];
$cls::run($argc, $argv);
*/
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -2,74 +2,64 @@
namespace Zotlabs\Daemon;
require_once('include/zot.php');
require_once('include/dir_fns.php');
use Zotlabs\Lib\Libzot;
use Zotlabs\Lib\Libzotdir;
class Onedirsync {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
logger('onedirsync: start ' . intval($argv[1]));
if(($argc > 1) && (intval($argv[1])))
$update_id = intval($argv[1]);
if(! $update_id) {
logger('onedirsync: no update');
if ($argc < 2 || is_int($argv[1]) === false) {
logger('onedirsync: no update id');
return;
}
$r = q("select * from updates where ud_id = %d limit 1",
logger('onedirsync: start ' . intval($argv[1]));
$update_id = intval($argv[1]);
if (!$update_id) {
logger('onedirsync: no update id');
return;
}
$r = q("select * from updates where ud_id = %d",
intval($update_id)
);
if(! $r)
return;
if(($r[0]['ud_flags'] & UPDATE_FLAGS_UPDATED) || (! $r[0]['ud_addr']))
return;
// Have we probed this channel more recently than the other directory server
// (where we received this update from) ?
// If we have, we don't need to do anything except mark any older entries updated
$x = q("select * from updates where ud_addr = '%s' and ud_date > '%s' and ( ud_flags & %d )>0 order by ud_date desc limit 1",
dbesc($r[0]['ud_addr']),
dbesc($r[0]['ud_date']),
intval(UPDATE_FLAGS_UPDATED)
);
if($x) {
$y = q("update updates set ud_flags = ( ud_flags | %d ) where ud_addr = '%s' and ( ud_flags & %d ) = 0 and ud_date != '%s'",
intval(UPDATE_FLAGS_UPDATED),
dbesc($r[0]['ud_addr']),
intval(UPDATE_FLAGS_UPDATED),
dbesc($x[0]['ud_date'])
);
if (!$r) {
logger('onedirsync: update id not found');
return;
}
// ignore doing an update if this ud_addr refers to a known dead hubloc
$h = q("select * from hubloc where hubloc_addr = '%s' limit 1",
dbesc($r[0]['ud_addr'])
$h = q("select * from hubloc where hubloc_id_url = '%s' order by hubloc_id desc",
dbesc($r[0]['ud_addr']),
);
if(($h) && ($h[0]['hubloc_status'] & HUBLOC_OFFLINE)) {
$y = q("update updates set ud_flags = ( ud_flags | %d ) where ud_addr = '%s' and ( ud_flags & %d ) = 0 ",
intval(UPDATE_FLAGS_UPDATED),
dbesc($r[0]['ud_addr']),
intval(UPDATE_FLAGS_UPDATED)
);
$h = Libzot::zot_record_preferred($h);
if (($h) && (($h['hubloc_status'] & HUBLOC_OFFLINE) || $h['hubloc_deleted'] || $h['hubloc_error'])) {
// 2023-04-12: Try to update anyway since the info is not always correct
// This might change after all directory servers run the new code.
// q("update updates set ud_flags = 9 where ud_hash = '%s' and ud_flags != 9",
// dbesc($r[0]['ud_hash'])
//);
// return;
}
// we might have to pull this out some day, but for now update_directory_entry()
// runs zot_finger() and is kind of zot specific
if ($h && $h['hubloc_network'] !== 'zot6') {
return;
}
// we might have to pull this out some day, but for now update_directory_entry()
// runs zot_finger() and is kind of zot specific
if($h && $h[0]['hubloc_network'] !== 'zot')
return;
update_directory_entry($r[0]);
Libzotdir::update_directory_entry($r[0]);
return;
}

View File

@@ -2,92 +2,99 @@
namespace Zotlabs\Daemon;
use DBA;
use Zotlabs\Lib\Activity;
use Zotlabs\Lib\ActivityStreams;
use Zotlabs\Lib\ASCollection;
use Zotlabs\Lib\Config;
use Zotlabs\Lib\Libzot;
require_once('include/zot.php');
require_once('include/socgraph.php');
require_once('include/feedutils.php');
class Onepoll {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
logger('onepoll: start');
if(($argc > 1) && (intval($argv[1])))
$contact_id = intval($argv[1]);
if(! $contact_id) {
if ($argc < 2 || is_int($argv[1]) === false) {
logger('onepoll: no contact');
return;
}
$d = datetime_convert();
logger('onepoll: start');
$contacts = q("SELECT abook.*, xchan.*, account.*
FROM abook LEFT JOIN account on abook_account = account_id left join xchan on xchan_hash = abook_xchan
where abook_id = %d
and abook_pending = 0 and abook_archived = 0 and abook_blocked = 0 and abook_ignored = 0
AND (( account_flags = %d ) OR ( account_flags = %d )) limit 1",
intval($contact_id),
intval(ACCOUNT_OK),
intval(ACCOUNT_UNVERIFIED)
);
$contact_id = intval($argv[1]);
if(! $contacts) {
if (!$contact_id) {
logger('onepoll: no contact');
return;
}
$sql_extra = '';
$allow_feeds = Config::Get('system', 'feed_contacts');
if(!$allow_feeds) {
$sql_extra = ' and abook_feed = 0 ';
}
$contacts = q("SELECT abook.*, xchan.* FROM abook
LEFT JOIN xchan ON xchan_hash = abook_xchan
WHERE abook_id = %d",
$contact_id
);
if (!$contacts) {
logger('onepoll: abook_id not found: ' . $contact_id);
return;
}
$contact = $contacts[0];
$t = $contact['abook_updated'];
$contact = $contacts[0];
$importer_uid = $contact['abook_channel'];
$r = q("SELECT * from channel left join xchan on channel_hash = xchan_hash where channel_id = %d limit 1",
intval($importer_uid)
);
if(! $r)
$importer = channelx_by_n($importer_uid);
if (!$importer)
return;
$importer = $r[0];
logger("onepoll: poll: ($contact_id) IMPORTER: {$importer['xchan_name']}, CONTACT: {$contact['xchan_name']}");
logger("onepoll: poll: ({$contact['id']}) IMPORTER: {$importer['xchan_name']}, CONTACT: {$contact['xchan_name']}");
$last_update = ((($contact['abook_updated'] === $contact['abook_created']) || ($contact['abook_updated'] <= NULL_DATE))
? datetime_convert('UTC','UTC','now - 7 days')
: datetime_convert('UTC','UTC',$contact['abook_updated'] . ' - 2 days')
$last_update = ((($contact['abook_updated'] === $contact['abook_created']) || ($contact['abook_updated'] <= DBA::$dba->get_null_date()))
? datetime_convert('UTC', 'UTC', 'now - 7 days')
: datetime_convert('UTC', 'UTC', $contact['abook_updated'] . ' - 2 days')
);
if($contact['xchan_network'] === 'rss') {
if ($contact['xchan_network'] === 'rss') {
logger('onepoll: processing feed ' . $contact['xchan_name'], LOGGER_DEBUG);
$alive = handle_feed($importer['channel_id'],$contact_id,$contact['xchan_hash']);
if ($alive) {
q("update abook set abook_connected = '%s' where abook_id = %d",
$alive = handle_feed($importer['channel_id'], $contact_id, $contact['xchan_hash']);
if (!$alive) {
q("update abook set abook_updated = '%s' where abook_id = %d",
dbesc(datetime_convert()),
intval($contact['abook_id'])
);
return;
}
q("update abook set abook_updated = '%s', abook_connected = '%s' where abook_id = %d",
dbesc(datetime_convert()),
dbesc(datetime_convert()),
intval($contact['abook_id'])
);
return;
}
if(! in_array($contact['xchan_network'],['zot','zot6']))
if ($contact['xchan_network'] !== 'zot6')
return;
// update permissions
if($contact['xchan_network'] === 'zot6')
$x = Libzot::refresh($contact,$importer);
if($contact['xchan_network'] === 'zot')
$x = zot_refresh($contact,$importer);
$x = Libzot::refresh($contact, $importer);
$responded = false;
$updated = datetime_convert();
$connected = datetime_convert();
if(! $x) {
if (!$x) {
// mark for death by not updating abook_connected, this is caught in include/poller.php
q("update abook set abook_updated = '%s' where abook_id = %d",
dbesc($updated),
@@ -103,83 +110,88 @@ class Onepoll {
$responded = true;
}
if(! $responded)
if (!$responded)
return;
if($contact['xchan_connurl']) {
$fetch_feed = true;
$x = null;
$fetch_feed = true;
// They haven't given us permission to see their stream
// They haven't given us permission to see their stream
$can_view_stream = intval(get_abconfig($importer_uid, $contact['abook_xchan'], 'their_perms', 'view_stream'));
$can_view_stream = intval(get_abconfig($importer_uid,$contact['abook_xchan'],'their_perms','view_stream'));
if (!$can_view_stream) {
$fetch_feed = false;
}
if(! $can_view_stream)
$fetch_feed = false;
// we haven't given them permission to send us their stream
$can_send_stream = intval(get_abconfig($importer_uid, $contact['abook_xchan'], 'my_perms', 'send_stream'));
// we haven't given them permission to send us their stream
if (!$can_send_stream) {
$fetch_feed = false;
}
$can_send_stream = intval(get_abconfig($importer_uid,$contact['abook_xchan'],'my_perms','send_stream'));
if(! $can_send_stream)
$fetch_feed = false;
if ($fetch_feed) {
if($fetch_feed) {
$max = intval(Config::Get('system', 'max_imported_posts', 30));
if(strpos($contact['xchan_connurl'],z_root()) === 0) {
// local channel - save a network fetch
$c = channelx_by_hash($contact['xchan_hash']);
if($c) {
$x = [
'success' => true,
'body' => json_encode( [
'success' => true,
'messages' => zot_feed($c['channel_id'], $importer['xchan_hash'], [ 'mindate' => $last_update ])
])
];
}
if (intval($max)) {
$cl = Activity::get_actor_collections($contact['abook_xchan']);
if(empty($cl)) {
$cl = get_xconfig($contact['abook_xchan'], 'activitypub', 'collections');
}
if (is_array($cl) && array_key_exists('outbox', $cl)) {
$url = $cl['outbox'];
}
else {
// remote fetch
$feedurl = str_replace('/poco/','/zotfeed/',$contact['xchan_connurl']);
$feedurl .= '?f=&mindate=' . urlencode($last_update) . '&zid=' . $importer['channel_address'] . '@' . \App::get_hostname();
$recurse = 0;
$x = z_fetch_url($feedurl, false, $recurse, [ 'session' => true ]);
$url = str_replace('/poco/', '/outbox/', $contact['xchan_connurl']);
}
logger('feed_update: ' . print_r($x,true), LOGGER_DATA);
}
if ($url) {
logger('fetching outbox');
$url = $url . '?date_begin=' . urlencode($last_update);
if(($x) && ($x['success'])) {
$total = 0;
logger('onepoll: feed update ' . $contact['xchan_name'] . ' ' . $feedurl);
$j = json_decode($x['body'],true);
if($j['success'] && $j['messages']) {
foreach($j['messages'] as $message) {
$results = process_delivery(array('hash' => $contact['xchan_hash']), get_item_elements($message),
array(array('hash' => $importer['xchan_hash'])), false);
logger('onepoll: feed_update: process_delivery: ' . print_r($results,true), LOGGER_DATA);
$total ++;
if($contact['xchan_network'] === 'zot6') {
$url = $url . '&top=1';
}
$obj = new ASCollection($url, $importer, 0, $max);
$messages = $obj->get();
if ($messages) {
foreach ($messages as $message) {
if (is_string($message)) {
$message = Activity::fetch($message, $importer);
}
if ($contact['xchan_network'] === 'zot6') {
// make sure we only fetch top level items
if ($message['type'] === 'Create' && !isset($message['object']['inReplyTo'])) {
Libzot::fetch_conversation($importer, $message['object']['id']);
}
continue;
}
$AS = new ActivityStreams($message);
if ($AS->is_valid() && is_array($AS->obj)) {
$item = Activity::decode_note($AS);
$item['item_fetched'] = true;
Activity::store($importer, $contact['abook_xchan'], $AS, $item);
}
}
}
logger("onepoll: $total messages processed");
}
}
}
// update the poco details for this connection
$r = q("SELECT xlink_id from xlink where xlink_xchan = '%s' and xlink_updated > %s - INTERVAL %s and xlink_static = 0 limit 1",
intval($contact['xchan_hash']),
db_utcnow(),
db_quoteinterval('1 DAY')
);
if($contact['xchan_connurl']) {
$r = q("SELECT xlink_id from xlink
where xlink_xchan = '%s' and xlink_updated > %s - INTERVAL %s and xlink_static = 0 limit 1",
intval($contact['xchan_hash']),
db_utcnow(), db_quoteinterval('1 DAY')
);
if(! $r) {
poco_load($contact['xchan_hash'],$contact['xchan_connurl']);
}
if (!$r) {
poco_load($contact['xchan_hash'], $contact['xchan_connurl']);
}
return;

View File

@@ -2,205 +2,203 @@
namespace Zotlabs\Daemon;
use DBA;
use Zotlabs\Lib\Config;
class Poller {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
$maxsysload = intval(get_config('system','maxloadavg'));
if($maxsysload < 1)
$maxsysload = intval(Config::Get('system', 'maxloadavg'));
if ($maxsysload < 1)
$maxsysload = 50;
if(function_exists('sys_getloadavg')) {
if (function_exists('sys_getloadavg')) {
$load = sys_getloadavg();
if(intval($load[0]) > $maxsysload) {
if (intval($load[0]) > $maxsysload) {
logger('system: load ' . $load . ' too high. Poller deferred to next scheduled run.');
return;
}
}
$interval = intval(get_config('system','poll_interval'));
if(! $interval)
$interval = ((get_config('system','delivery_interval') === false) ? 3 : intval(get_config('system','delivery_interval')));
// Check for a lockfile. If it exists, but is over an hour old, it's stale. Ignore it.
$lockfile = 'store/[data]/poller';
if((file_exists($lockfile)) && (filemtime($lockfile) > (time() - 3600))
&& (! get_config('system','override_poll_lockfile'))) {
logger("poller: Already running");
return;
}
// Create a lockfile. Needs two vars, but $x doesn't need to contain anything.
file_put_contents($lockfile, $x);
$interval = Config::Get('queueworker', 'queue_interval', 500000);
logger('poller: start');
$manual_id = 0;
$generation = 0;
$force = false;
$force = false;
$restart = false;
if(($argc > 1) && ($argv[1] == 'force'))
if (($argc > 1) && ($argv[1] == 'force'))
$force = true;
if(($argc > 1) && ($argv[1] == 'restart')) {
$restart = true;
if (($argc > 1) && ($argv[1] == 'restart')) {
$generation = intval($argv[2]);
if(! $generation)
if (!$generation)
return;
}
if(($argc > 1) && intval($argv[1])) {
if (($argc > 1) && intval($argv[1])) {
$manual_id = intval($argv[1]);
$force = true;
}
$sql_extra = (($manual_id) ? " AND abook_id = " . intval($manual_id) . " " : "");
reload_plugins();
$d = datetime_convert();
// Only poll from those with suitable relationships
$abandon_sql = (($abandon_days)
? sprintf(" AND account_lastlog > %s - INTERVAL %s ", db_utcnow(), db_quoteinterval(intval($abandon_days).' DAY'))
: ''
$abandon_days = intval(Config::Get('system', 'account_abandon_days', 0));
$abandon_sql = (($abandon_days)
? sprintf(" AND account_lastlog > %s - INTERVAL %s ", db_utcnow(), db_quoteinterval(intval($abandon_days) . ' DAY'))
: ''
);
$allow_feeds = Config::Get('system', 'feed_contacts');
if(!$allow_feeds) {
$sql_extra .= ' and abook_feed = 0 ';
}
$randfunc = db_getfunc('RAND');
$contacts = q("SELECT abook.abook_updated, abook.abook_connected, abook.abook_feed,
abook.abook_channel, abook.abook_id, abook.abook_archived, abook.abook_pending,
abook.abook_ignored, abook.abook_blocked,
xchan.xchan_network,
account.account_lastlog, account.account_flags
FROM abook LEFT JOIN xchan on abook_xchan = xchan_hash
account.account_lastlog, account.account_flags
FROM abook LEFT JOIN xchan on abook_xchan = xchan_hash
LEFT JOIN account on abook_account = account_id
where abook_self = 0
$sql_extra
where abook_self = 0 and abook_pending = 0 and abook_archived = 0 and abook_blocked = 0 and abook_ignored = 0
$sql_extra
AND (( account_flags = %d ) OR ( account_flags = %d )) $abandon_sql ORDER BY $randfunc",
intval(ACCOUNT_OK),
intval(ACCOUNT_UNVERIFIED) // FIXME
);
if($contacts) {
if ($contacts) {
foreach ($contacts as $contact) {
foreach($contacts as $contact) {
$update = false;
$update = false;
$t = $contact['abook_updated'];
$c = $contact['abook_connected'];
if(intval($contact['abook_feed'])) {
$min = service_class_fetch($contact['abook_channel'],'minimum_feedcheck_minutes');
if(! $min)
$min = intval(get_config('system','minimum_feedcheck_minutes'));
if(! $min)
if (intval($contact['abook_feed'])) {
$min = service_class_fetch($contact['abook_channel'], 'minimum_feedcheck_minutes');
if (!$min)
$min = intval(Config::Get('system', 'minimum_feedcheck_minutes'));
if (!$min)
$min = 60;
$x = datetime_convert('UTC','UTC',"now - $min minutes");
if($c < $x) {
Master::Summon(array('Onepoll',$contact['abook_id']));
if($interval)
@time_sleep_until(microtime(true) + (float) $interval);
if ($t !== $c) {
// if the last fetch failed only attempt fetch once a day
$min = 60 * 24;
}
$x = datetime_convert('UTC', 'UTC', "now - $min minutes");
if ($t < $x) {
Master::Summon(['Onepoll', $contact['abook_id']]);
if ($interval) {
usleep($interval);
}
}
continue;
}
if(! in_array($contact['xchan_network'],['zot','zot6']))
if ($contact['xchan_network'] !== 'zot6')
continue;
if($c == $t) {
if(datetime_convert('UTC','UTC', 'now') > datetime_convert('UTC','UTC', $t . " + 1 day"))
if ($c == $t) {
if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 day"))
$update = true;
}
else {
// if we've never connected with them, start the mark for death countdown from now
if($c <= NULL_DATE) {
$r = q("update abook set abook_connected = '%s' where abook_id = %d",
if ($c <= DBA::$dba->get_null_date()) {
q("update abook set abook_connected = '%s' where abook_id = %d",
dbesc(datetime_convert()),
intval($contact['abook_id'])
);
$c = datetime_convert();
$c = datetime_convert();
$update = true;
}
// He's dead, Jim
if(strcmp(datetime_convert('UTC','UTC', 'now'),datetime_convert('UTC','UTC', $c . " + 30 day")) > 0) {
$r = q("update abook set abook_archived = 1 where abook_id = %d",
if (strcmp(datetime_convert('UTC', 'UTC', 'now'), datetime_convert('UTC', 'UTC', $c . " + 30 day")) > 0) {
q("update abook set abook_archived = 1 where abook_id = %d",
intval($contact['abook_id'])
);
$update = false;
continue;
}
if(intval($contact['abook_archived'])) {
$update = false;
if (intval($contact['abook_archived'])) {
continue;
}
// might be dead, so maybe don't poll quite so often
// recently deceased, so keep up the regular schedule for 3 days
if((strcmp(datetime_convert('UTC','UTC', 'now'),datetime_convert('UTC','UTC', $c . " + 3 day")) > 0)
&& (strcmp(datetime_convert('UTC','UTC', 'now'),datetime_convert('UTC','UTC', $t . " + 1 day")) > 0))
if ((strcmp(datetime_convert('UTC', 'UTC', 'now'), datetime_convert('UTC', 'UTC', $c . " + 3 day")) > 0)
&& (strcmp(datetime_convert('UTC', 'UTC', 'now'), datetime_convert('UTC', 'UTC', $t . " + 1 day")) > 0))
$update = true;
// After that back off and put them on a morphine drip
if(strcmp(datetime_convert('UTC','UTC', 'now'),datetime_convert('UTC','UTC', $t . " + 2 day")) > 0) {
if (strcmp(datetime_convert('UTC', 'UTC', 'now'), datetime_convert('UTC', 'UTC', $t . " + 2 day")) > 0) {
$update = true;
}
}
if(intval($contact['abook_pending']) || intval($contact['abook_archived']) || intval($contact['abook_ignored']) || intval($contact['abook_blocked']))
if (intval($contact['abook_pending']) || intval($contact['abook_archived']) || intval($contact['abook_ignored']) || intval($contact['abook_blocked']))
continue;
if((! $update) && (! $force))
continue;
if ((!$update) && (!$force))
continue;
Master::Summon(array('Onepoll',$contact['abook_id']));
if($interval)
@time_sleep_until(microtime(true) + (float) $interval);
Master::Summon(['Onepoll', $contact['abook_id']]);
if ($interval) {
usleep($interval);
}
}
}
if($dirmode == DIRECTORY_MODE_SECONDARY || $dirmode == DIRECTORY_MODE_PRIMARY) {
$r = q("SELECT u.ud_addr, u.ud_id, u.ud_last FROM updates AS u INNER JOIN (SELECT ud_addr, max(ud_id) AS ud_id FROM updates WHERE ( ud_flags & %d ) = 0 AND ud_addr != '' AND ( ud_last <= '%s' OR ud_last > %s - INTERVAL %s ) GROUP BY ud_addr) AS s ON s.ud_id = u.ud_id ",
intval(UPDATE_FLAGS_UPDATED),
dbesc(NULL_DATE),
db_utcnow(), db_quoteinterval('7 DAY')
$dirmode = intval(Config::Get('system', 'directory_mode'));
if ($dirmode == DIRECTORY_MODE_SECONDARY || $dirmode == DIRECTORY_MODE_PRIMARY) {
$r = q("SELECT * FROM updates WHERE ud_update = 1 AND (ud_last = '%s' OR ud_last > %s - INTERVAL %s)",
dbesc(DBA::$dba->get_null_date()),
db_utcnow(),
db_quoteinterval('7 DAY')
);
if($r) {
foreach($r as $rr) {
if ($r) {
foreach ($r as $rr) {
// If they didn't respond when we attempted before, back off to once a day
// After 7 days we won't bother anymore
if($rr['ud_last'] > NULL_DATE)
if($rr['ud_last'] > datetime_convert('UTC','UTC', 'now - 1 day'))
if ($rr['ud_last'] > DBA::$dba->get_null_date())
if ($rr['ud_last'] > datetime_convert('UTC', 'UTC', 'now - 1 day'))
continue;
Master::Summon(array('Onedirsync',$rr['ud_id']));
if($interval)
@time_sleep_until(microtime(true) + (float) $interval);
Master::Summon(['Onedirsync', $rr['ud_id']]);
if ($interval) {
usleep($interval);
}
}
}
}
}
set_config('system','lastpoll',datetime_convert());
//All done - clear the lockfile
@unlink($lockfile);
Config::Set('system', 'lastpoll', datetime_convert());
return;
}

View File

@@ -2,84 +2,64 @@
namespace Zotlabs\Daemon;
require_once('include/queue_fn.php');
require_once('include/zot.php');
use Zotlabs\Lib\Queue as LibQueue;
class Queue {
static public function run($argc,$argv) {
require_once('include/items.php');
require_once('include/bbcode.php');
if($argc > 1)
$queue_id = $argv[1];
else
$queue_id = EMPTY_STR;
static public function run($argc, $argv) {
$queue_id = ($argc > 1) ? $argv[1] : '';
logger('queue: start');
// delete all queue items more than 3 days old
// but first mark these sites dead if we haven't heard from them in a month
$r = q("select outq_posturl from outq where outq_created < %s - INTERVAL %s",
db_utcnow(), db_quoteinterval('3 DAY')
$oldqItems = q("select outq_posturl, outq_hash from outq where outq_created < %s - INTERVAL %s",
db_utcnow(),
db_quoteinterval('3 DAY')
);
if($r) {
foreach($r as $rr) {
$site_url = '';
$h = parse_url($rr['outq_posturl']);
$desturl = $h['scheme'] . '://' . $h['host'] . (($h['port']) ? ':' . $h['port'] : '');
if ($oldqItems) {
foreach ($oldqItems as $qItem) {
$h = parse_url($qItem['outq_posturl']);
$site_url = $h['scheme'] . '://' . $h['host'] . ((!empty($h['port'])) ? ':' . $h['port'] : '');
q("update site set site_dead = 1 where site_dead = 0 and site_url = '%s' and site_update < %s - INTERVAL %s",
dbesc($desturl),
db_utcnow(), db_quoteinterval('1 MONTH')
dbesc($site_url),
db_utcnow(),
db_quoteinterval('1 MONTH')
);
}
$old_hashes = ids_to_querystr($oldqItems, 'outq_hash', true);
logger('Removing ' . count($oldqItems) . ' old queue entries');
dbq("DELETE FROM outq WHERE outq_hash IN ($old_hashes)");
}
$r = q("DELETE FROM outq WHERE outq_created < %s - INTERVAL %s",
db_utcnow(), db_quoteinterval('3 DAY')
);
$deliveries = [];
if($queue_id) {
$r = q("SELECT * FROM outq WHERE outq_hash = '%s' LIMIT 1",
if ($queue_id) {
$qItems = q("SELECT * FROM outq WHERE outq_hash = '%s' LIMIT 1",
dbesc($queue_id)
);
logger('queue deliver: ' . $qItems[0]['outq_hash'] . ' to ' . $qItems[0]['outq_posturl'], LOGGER_DEBUG);
LibQueue::deliver($qItems[0]);
}
else {
// For the first 12 hours we'll try to deliver every 15 minutes
// After that, we'll only attempt delivery once per hour.
// This currently only handles the default queue drivers ('zot' or '') which we will group by posturl
// so that we don't start off a thousand deliveries for a couple of dead hubs.
// The zot driver will deliver everything destined for a single hub once contact is made (*if* contact is made).
// Other drivers will have to do something different here and may need their own query.
// Note: this requires some tweaking as new posts to long dead hubs once a day will keep them in the
// "every 15 minutes" category. We probably need to prioritise them when inserted into the queue
// or just prior to this query based on recent and long-term delivery history. If we have good reason to believe
// the site is permanently down, there's no reason to attempt delivery at all, or at most not more than once
// or twice a day.
$sqlrandfunc = db_getfunc('rand');
$r = q("SELECT *,$sqlrandfunc as rn FROM outq WHERE outq_delivered = 0 and outq_scheduled < %s order by rn limit 1",
$qItems = q("SELECT outq_hash FROM outq WHERE outq_scheduled < %s ",
db_utcnow()
);
while ($r) {
foreach($r as $rv) {
queue_deliver($rv);
}
$r = q("SELECT *,$sqlrandfunc as rn FROM outq WHERE outq_delivered = 0 and outq_scheduled < %s order by rn limit 1",
db_utcnow()
);
}
}
if(! $r)
return;
foreach($r as $rv) {
queue_deliver($rv);
}
if ($qItems) {
foreach ($qItems as $qItem) {
$deliveries[] = $qItem['outq_hash'];
}
shuffle($deliveries);
do_delivery($deliveries, true);
}
}
}
}

View File

@@ -1,121 +0,0 @@
<?php
namespace Zotlabs\Daemon;
require_once('include/zot.php');
require_once('include/queue_fn.php');
class Ratenotif {
static public function run($argc,$argv) {
require_once("datetime.php");
require_once('include/items.php');
if($argc < 3)
return;
logger('ratenotif: invoked: ' . print_r($argv,true), LOGGER_DEBUG);
$cmd = $argv[1];
$item_id = $argv[2];
if($cmd === 'rating') {
$r = q("select * from xlink where xlink_id = %d and xlink_static = 1 limit 1",
intval($item_id)
);
if(! $r) {
logger('rating not found');
return;
}
$encoded_item = array(
'type' => 'rating',
'encoding' => 'zot',
'target' => $r[0]['xlink_link'],
'rating' => intval($r[0]['xlink_rating']),
'rating_text' => $r[0]['xlink_rating_text'],
'signature' => $r[0]['xlink_sig'],
'edited' => $r[0]['xlink_updated']
);
}
$channel = channelx_by_hash($r[0]['xlink_xchan']);
if(! $channel) {
logger('no channel');
return;
}
$primary = get_directory_primary();
if(! $primary)
return;
$interval = ((get_config('system','delivery_interval') !== false)
? intval(get_config('system','delivery_interval')) : 2 );
$deliveries_per_process = intval(get_config('system','delivery_batch_count'));
if($deliveries_per_process <= 0)
$deliveries_per_process = 1;
$deliver = array();
$x = z_fetch_url($primary . '/regdir');
if($x['success']) {
$j = json_decode($x['body'],true);
if($j && $j['success'] && is_array($j['directories'])) {
foreach($j['directories'] as $h) {
if($h == z_root())
continue;
$hash = random_string();
$n = zot_build_packet($channel,'notify',null,null,'',$hash);
queue_insert(array(
'hash' => $hash,
'account_id' => $channel['channel_account_id'],
'channel_id' => $channel['channel_id'],
'posturl' => $h . '/post',
'notify' => $n,
'msg' => json_encode($encoded_item)
));
$x = q("select count(outq_hash) as total from outq where outq_delivered = 0");
if(intval($x[0]['total']) > intval(get_config('system','force_queue_threshold',300))) {
logger('immediate delivery deferred.', LOGGER_DEBUG, LOG_INFO);
update_queue_item($hash);
continue;
}
$deliver[] = $hash;
if(count($deliver) >= $deliveries_per_process) {
Master::Summon(array('Deliver',$deliver));
$deliver = array();
if($interval)
@time_sleep_until(microtime(true) + (float) $interval);
}
}
// catch any stragglers
if(count($deliver)) {
Master::Summon(array('Deliver',$deliver));
}
}
}
logger('ratenotif: complete.');
return;
}
}

View File

@@ -2,33 +2,34 @@
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Config;
class Thumbnail {
static public function run($argc,$argv) {
static public function run($argc, $argv) {
if(! $argc == 2)
if (!$argc == 2)
return;
$c = q("select * from attach where hash = '%s' ",
dbesc($argv[1])
);
if(! $c)
if (!$c)
return;
$attach = $c[0];
$preview_style = intval(get_config('system','thumbnail_security',0));
$preview_width = intval(get_config('system','thumbnail_width',300));
$preview_height = intval(get_config('system','thumbnail_height',300));
$preview_style = intval(Config::Get('system', 'thumbnail_security', 0));
$preview_width = intval(Config::Get('system', 'thumbnail_width', 300));
$preview_height = intval(Config::Get('system', 'thumbnail_height', 300));
$p = [
'attach' => $attach,
'preview_style' => $preview_style,
'preview_width' => $preview_width,
'preview_height' => $preview_height,
'thumbnail' => null
'thumbnail' => null
];
/**
@@ -40,39 +41,40 @@ class Thumbnail {
* * \e string \b thumbnail
*/
call_hooks('thumbnail',$p);
if($p['thumbnail']) {
call_hooks('thumbnail', $p);
if ($p['thumbnail']) {
return;
}
$default_controller = null;
$files = glob('Zotlabs/Thumbs/*.php');
if($files) {
foreach($files as $f) {
$clsname = '\\Zotlabs\\Thumbs\\' . ucfirst(basename($f,'.php'));
if(class_exists($clsname)) {
if ($files) {
foreach ($files as $f) {
$clsname = '\\Zotlabs\\Thumbs\\' . ucfirst(basename($f, '.php'));
if (class_exists($clsname)) {
$x = new $clsname();
if(method_exists($x,'Match')) {
if (method_exists($x, 'Match')) {
$matched = $x->Match($attach['filetype']);
if($matched) {
$x->Thumb($attach,$preview_style,$preview_width,$preview_height);
if ($matched) {
$x->Thumb($attach, $preview_style, $preview_width, $preview_height);
}
}
if(method_exists($x,'MatchDefault')) {
$default_matched = $x->MatchDefault(substr($attach['filetype'],0,strpos($attach['filetype'],'/')));
if($default_matched) {
if (method_exists($x, 'MatchDefault')) {
$default_matched = $x->MatchDefault(substr($attach['filetype'], 0, strpos($attach['filetype'], '/')));
if ($default_matched) {
$default_controller = $x;
}
}
}
}
}
if(($default_controller)
&& ((! file_exists(dbunescbin($attach['content']) . '.thumb'))
if (($default_controller)
&& ((!file_exists(dbunescbin($attach['content']) . '.thumb'))
|| (filectime(dbunescbin($attach['content']) . 'thumb') < (time() - 60)))) {
$default_controller->Thumb($attach,$preview_style,$preview_width,$preview_height);
$default_controller->Thumb($attach, $preview_style, $preview_width, $preview_height);
}
return;
}
}

View File

@@ -0,0 +1,37 @@
<?php
/** @file */
namespace Zotlabs\Daemon;
class Xchan_photo {
static public function run($argc, $argv) {
if ($argc < 3) {
return;
}
$url = hex2bin($argv[1]);
$xchan = hex2bin($argv[2]);
$force = $argv[3];
$photos = import_xchan_photo($url, $xchan, false, $force);
if ($photos) {
$result = q("update xchan set xchan_photo_date = '%s', xchan_photo_l = '%s', xchan_photo_m = '%s', xchan_photo_s = '%s', xchan_photo_mimetype = '%s' where xchan_hash = '%s'",
dbescdate(datetime_convert()),
dbesc($photos[0]),
dbesc($photos[1]),
dbesc($photos[2]),
dbesc($photos[3]),
dbesc($xchan)
);
if (! $result) {
logger("xchan photo update failed for $url");
}
}
return;
}
}

View File

@@ -0,0 +1,37 @@
<?php
namespace Zotlabs\Daemon;
use Zotlabs\Lib\Libzot;
class Zotconvo {
static public function run($argc, $argv) {
logger('Zotconvo invoked: ' . print_r($argv, true));
if ($argc < 3) {
return;
}
$channels = explode(',', $argv[1]);
if (!$channels) {
return;
}
$mid = $argv[2];
if (!$mid) {
return;
}
$force = $argv[3] ?? false;
foreach ($channels as $channel_id) {
$channel = channelx_by_n($channel_id);
Libzot::fetch_conversation($channel, $mid, $force);
}
return;
}
}

352
Zotlabs/Entity/Account.php Normal file
View File

@@ -0,0 +1,352 @@
<?php
namespace Zotlabs\Entity;
use Zotlabs\Lib\BaseObject;
class Account extends BaseObject
{
public $account_id;
public $account_parent;
public $account_default_channel;
public $account_salt;
public $account_password;
public $account_email;
public $account_external;
public $account_language;
public $account_created;
public $account_lastlog;
public $account_flags;
public $account_roles;
public $account_reset;
public $account_expires;
public $account_expire_notified;
public $account_service_class;
public $account_level;
public $account_password_change;
/**
* @return mixed
*/
public function getId()
{
return $this->account_id;
}
/**
* @param mixed $account_id
* @return Account
*/
public function setId($account_id)
{
$this->account_id = $account_id;
return $this;
}
/**
* @return mixed
*/
public function getParent()
{
return $this->account_parent;
}
/**
* @param mixed $account_parent
* @return Account
*/
public function setParent($account_parent)
{
$this->account_parent = $account_parent;
return $this;
}
/**
* @return mixed
*/
public function getDefaultChannel()
{
return $this->account_default_channel;
}
/**
* @param mixed $account_default_channel
* @return Account
*/
public function setDefaultChannel($account_default_channel)
{
$this->account_default_channel = $account_default_channel;
return $this;
}
/**
* @return mixed
*/
public function getSalt()
{
return $this->account_salt;
}
/**
* @param mixed $account_salt
* @return Account
*/
public function setSalt($account_salt)
{
$this->account_salt = $account_salt;
return $this;
}
/**
* @return mixed
*/
public function getPassword()
{
return $this->account_password;
}
/**
* @param mixed $account_password
* @return Account
*/
public function setPassword($account_password)
{
$this->account_password = $account_password;
return $this;
}
/**
* @return mixed
*/
public function getEmail()
{
return $this->account_email;
}
/**
* @param mixed $account_email
* @return Account
*/
public function setEmail($account_email)
{
$this->account_email = $account_email;
return $this;
}
/**
* @return mixed
*/
public function getExternal()
{
return $this->account_external;
}
/**
* @param mixed $account_external
* @return Account
*/
public function setExternal($account_external)
{
$this->account_external = $account_external;
return $this;
}
/**
* @return mixed
*/
public function getLanguage()
{
return $this->account_language;
}
/**
* @param mixed $account_language
* @return Account
*/
public function setLanguage($account_language)
{
$this->account_language = $account_language;
return $this;
}
/**
* @return mixed
*/
public function getCreated()
{
return $this->account_created;
}
/**
* @param mixed $account_created
* @return Account
*/
public function setCreated($account_created)
{
$this->account_created = $account_created;
return $this;
}
/**
* @return mixed
*/
public function getLastlog()
{
return $this->account_lastlog;
}
/**
* @param mixed $account_lastlog
* @return Account
*/
public function setLastlog($account_lastlog)
{
$this->account_lastlog = $account_lastlog;
return $this;
}
/**
* @return mixed
*/
public function getFlags()
{
return $this->account_flags;
}
/**
* @param mixed $account_flags
* @return Account
*/
public function setFlags($account_flags)
{
$this->account_flags = $account_flags;
return $this;
}
/**
* @return mixed
*/
public function getRoles()
{
return $this->account_roles;
}
/**
* @param mixed $account_roles
* @return Account
*/
public function setRoles($account_roles)
{
$this->account_roles = $account_roles;
return $this;
}
/**
* @return mixed
*/
public function getReset()
{
return $this->account_reset;
}
/**
* @param mixed $account_reset
* @return Account
*/
public function setReset($account_reset)
{
$this->account_reset = $account_reset;
return $this;
}
/**
* @return mixed
*/
public function getExpires()
{
return $this->account_expires;
}
/**
* @param mixed $account_expires
* @return Account
*/
public function setExpires($account_expires)
{
$this->account_expires = $account_expires;
return $this;
}
/**
* @return mixed
*/
public function getExpireNotified()
{
return $this->account_expire_notified;
}
/**
* @param mixed $account_expire_notified
* @return Account
*/
public function setExpireNotified($account_expire_notified)
{
$this->account_expire_notified = $account_expire_notified;
return $this;
}
/**
* @return mixed
*/
public function getServiceClass()
{
return $this->account_service_class;
}
/**
* @param mixed $account_service_class
* @return Account
*/
public function setServiceClass($account_service_class)
{
$this->account_service_class = $account_service_class;
return $this;
}
/**
* @return mixed
*/
public function getLevel()
{
return $this->account_level;
}
/**
* @param mixed $account_level
* @return Account
*/
public function setLevel($account_level)
{
$this->account_level = $account_level;
return $this;
}
/**
* @return mixed
*/
public function getPasswordChange()
{
return $this->account_password_change;
}
/**
* @param mixed $account_password_change
* @return Account
*/
public function setPasswordChange($account_password_change)
{
$this->account_password_change = $account_password_change;
return $this;
}
}

714
Zotlabs/Entity/Channel.php Normal file
View File

@@ -0,0 +1,714 @@
<?php
namespace Zotlabs\Entity;
use Zotlabs\Lib\BaseObject;
class Channel extends BaseObject
{
public $channel_id;
public $channel_account_id;
public $channel_primary;
public $channel_name;
public $channel_parent;
public $channel_address;
public $channel_guid;
public $channel_guid_sig;
public $channel_hash;
public $channel_timezone;
public $channel_location;
public $channel_theme;
public $channel_startpage;
public $channel_pubkey;
public $channel_prvkey;
public $channel_epubkey;
public $channel_eprvkey;
public $channel_notifyflags;
public $channel_pageflags;
public $channel_dirdate;
public $channel_lastpost;
public $channel_deleted;
public $channel_active;
public $channel_max_anon_mail;
public $channel_max_friend_req;
public $channel_expire_days;
public $channel_passwd_reset;
public $channel_default_group;
public $channel_allow_cid;
public $channel_allow_gid;
public $channel_deny_cid;
public $channel_deny_gid;
public $channel_removed;
public $channel_system;
public $channel_moved;
public $channel_password;
public $channel_salt;
/**
* @return mixed
*/
public function getId()
{
return $this->channel_id;
}
/**
* @param mixed $channel_id
* @return Channel
*/
public function setId($channel_id)
{
$this->channel_id = $channel_id;
return $this;
}
/**
* @return mixed
*/
public function getAccountId()
{
return $this->channel_account_id;
}
/**
* @param mixed $channel_account_id
* @return Channel
*/
public function setAccountId($channel_account_id)
{
$this->channel_account_id = $channel_account_id;
return $this;
}
/**
* @return mixed
*/
public function getPrimary()
{
return $this->channel_primary;
}
/**
* @param mixed $channel_primary
* @return Channel
*/
public function setPrimary($channel_primary)
{
$this->channel_primary = $channel_primary;
return $this;
}
/**
* @return mixed
*/
public function getName()
{
return $this->channel_name;
}
/**
* @param mixed $channel_name
* @return Channel
*/
public function setName($channel_name)
{
$this->channel_name = $channel_name;
return $this;
}
/**
* @return mixed
*/
public function getParent()
{
return $this->channel_parent;
}
/**
* @param mixed $channel_parent
* @return Channel
*/
public function setParent($channel_parent)
{
$this->channel_parent = $channel_parent;
return $this;
}
/**
* @return mixed
*/
public function getAddress()
{
return $this->channel_address;
}
/**
* @param mixed $channel_address
* @return Channel
*/
public function setAddress($channel_address)
{
$this->channel_address = $channel_address;
return $this;
}
/**
* @return mixed
*/
public function getGuid()
{
return $this->channel_guid;
}
/**
* @param mixed $channel_guid
* @return Channel
*/
public function setGuid($channel_guid)
{
$this->channel_guid = $channel_guid;
return $this;
}
/**
* @return mixed
*/
public function getGuidSig()
{
return $this->channel_guid_sig;
}
/**
* @param mixed $channel_guid_sig
* @return Channel
*/
public function setGuidSig($channel_guid_sig)
{
$this->channel_guid_sig = $channel_guid_sig;
return $this;
}
/**
* @return mixed
*/
public function getHash()
{
return $this->channel_hash;
}
/**
* @param mixed $channel_hash
* @return Channel
*/
public function setHash($channel_hash)
{
$this->channel_hash = $channel_hash;
return $this;
}
/**
* @return mixed
*/
public function getTimezone()
{
return $this->channel_timezone;
}
/**
* @param mixed $channel_timezone
* @return Channel
*/
public function setTimezone($channel_timezone)
{
$this->channel_timezone = $channel_timezone;
return $this;
}
/**
* @return mixed
*/
public function getLocation()
{
return $this->channel_location;
}
/**
* @param mixed $channel_location
* @return Channel
*/
public function setLocation($channel_location)
{
$this->channel_location = $channel_location;
return $this;
}
/**
* @return mixed
*/
public function getTheme()
{
return $this->channel_theme;
}
/**
* @param mixed $channel_theme
* @return Channel
*/
public function setTheme($channel_theme)
{
$this->channel_theme = $channel_theme;
return $this;
}
/**
* @return mixed
*/
public function getStartpage()
{
return $this->channel_startpage;
}
/**
* @param mixed $channel_startpage
* @return Channel
*/
public function setStartpage($channel_startpage)
{
$this->channel_startpage = $channel_startpage;
return $this;
}
/**
* @return mixed
*/
public function getPubkey()
{
return $this->channel_pubkey;
}
/**
* @param mixed $channel_pubkey
* @return Channel
*/
public function setPubkey($channel_pubkey)
{
$this->channel_pubkey = $channel_pubkey;
return $this;
}
/**
* @return mixed
*/
public function getPrvkey()
{
return $this->channel_prvkey;
}
/**
* @param mixed $channel_prvkey
* @return Channel
*/
public function setPrvkey($channel_prvkey)
{
$this->channel_prvkey = $channel_prvkey;
return $this;
}
/**
* @return mixed
*/
public function getEpubkey()
{
return $this->channel_epubkey;
}
/**
* @param mixed $channel_epubkey
* @return Channel
*/
public function setEpubkey($channel_epubkey)
{
$this->channel_epubkey = $channel_epubkey;
return $this;
}
/**
* @return mixed
*/
public function getEprvkey()
{
return $this->channel_eprvkey;
}
/**
* @param mixed $channel_eprvkey
* @return Channel
*/
public function setEprvkey($channel_eprvkey)
{
$this->channel_eprvkey = $channel_eprvkey;
return $this;
}
/**
* @return mixed
*/
public function getNotifyflags()
{
return $this->channel_notifyflags;
}
/**
* @param mixed $channel_notifyflags
* @return Channel
*/
public function setNotifyflags($channel_notifyflags)
{
$this->channel_notifyflags = $channel_notifyflags;
return $this;
}
/**
* @return mixed
*/
public function getPageflags()
{
return $this->channel_pageflags;
}
/**
* @param mixed $channel_pageflags
* @return Channel
*/
public function setPageflags($channel_pageflags)
{
$this->channel_pageflags = $channel_pageflags;
return $this;
}
/**
* @return mixed
*/
public function getDirdate()
{
return $this->channel_dirdate;
}
/**
* @param mixed $channel_dirdate
* @return Channel
*/
public function setDirdate($channel_dirdate)
{
$this->channel_dirdate = $channel_dirdate;
return $this;
}
/**
* @return mixed
*/
public function getLastpost()
{
return $this->channel_lastpost;
}
/**
* @param mixed $channel_lastpost
* @return Channel
*/
public function setLastpost($channel_lastpost)
{
$this->channel_lastpost = $channel_lastpost;
return $this;
}
/**
* @return mixed
*/
public function getDeleted()
{
return $this->channel_deleted;
}
/**
* @param mixed $channel_deleted
* @return Channel
*/
public function setDeleted($channel_deleted)
{
$this->channel_deleted = $channel_deleted;
return $this;
}
/**
* @return mixed
*/
public function getActive()
{
return $this->channel_active;
}
/**
* @param mixed $channel_active
* @return Channel
*/
public function setActive($channel_active)
{
$this->channel_active = $channel_active;
return $this;
}
/**
* @return mixed
*/
public function getMaxAnonMail()
{
return $this->channel_max_anon_mail;
}
/**
* @param mixed $channel_max_anon_mail
* @return Channel
*/
public function setMaxAnonMail($channel_max_anon_mail)
{
$this->channel_max_anon_mail = $channel_max_anon_mail;
return $this;
}
/**
* @return mixed
*/
public function getMaxFriendReq()
{
return $this->channel_max_friend_req;
}
/**
* @param mixed $channel_max_friend_req
* @return Channel
*/
public function setMaxFriendReq($channel_max_friend_req)
{
$this->channel_max_friend_req = $channel_max_friend_req;
return $this;
}
/**
* @return mixed
*/
public function getExpireDays()
{
return $this->channel_expire_days;
}
/**
* @param mixed $channel_expire_days
* @return Channel
*/
public function setExpireDays($channel_expire_days)
{
$this->channel_expire_days = $channel_expire_days;
return $this;
}
/**
* @return mixed
*/
public function getPasswdReset()
{
return $this->channel_passwd_reset;
}
/**
* @param mixed $channel_passwd_reset
* @return Channel
*/
public function setPasswdReset($channel_passwd_reset)
{
$this->channel_passwd_reset = $channel_passwd_reset;
return $this;
}
/**
* @return mixed
*/
public function getDefaultGroup()
{
return $this->channel_default_group;
}
/**
* @param mixed $channel_default_group
* @return Channel
*/
public function setDefaultGroup($channel_default_group)
{
$this->channel_default_group = $channel_default_group;
return $this;
}
/**
* @return mixed
*/
public function getAllowCid()
{
return $this->channel_allow_cid;
}
/**
* @param mixed $channel_allow_cid
* @return Channel
*/
public function setAllowCid($channel_allow_cid)
{
$this->channel_allow_cid = $channel_allow_cid;
return $this;
}
/**
* @return mixed
*/
public function getAllowGid()
{
return $this->channel_allow_gid;
}
/**
* @param mixed $channel_allow_gid
* @return Channel
*/
public function setAllowGid($channel_allow_gid)
{
$this->channel_allow_gid = $channel_allow_gid;
return $this;
}
/**
* @return mixed
*/
public function getDenyCid()
{
return $this->channel_deny_cid;
}
/**
* @param mixed $channel_deny_cid
* @return Channel
*/
public function setDenyCid($channel_deny_cid)
{
$this->channel_deny_cid = $channel_deny_cid;
return $this;
}
/**
* @return mixed
*/
public function getDenyGid()
{
return $this->channel_deny_gid;
}
/**
* @param mixed $channel_deny_gid
* @return Channel
*/
public function setDenyGid($channel_deny_gid)
{
$this->channel_deny_gid = $channel_deny_gid;
return $this;
}
/**
* @return mixed
*/
public function getRemoved()
{
return $this->channel_removed;
}
/**
* @param mixed $channel_removed
* @return Channel
*/
public function setRemoved($channel_removed)
{
$this->channel_removed = $channel_removed;
return $this;
}
/**
* @return mixed
*/
public function getSystem()
{
return $this->channel_system;
}
/**
* @param mixed $channel_system
* @return Channel
*/
public function setSystem($channel_system)
{
$this->channel_system = $channel_system;
return $this;
}
/**
* @return mixed
*/
public function getMoved()
{
return $this->channel_moved;
}
/**
* @param mixed $channel_moved
* @return Channel
*/
public function setMoved($channel_moved)
{
$this->channel_moved = $channel_moved;
return $this;
}
/**
* @return mixed
*/
public function getPassword()
{
return $this->channel_password;
}
/**
* @param mixed $channel_password
* @return Channel
*/
public function setPassword($channel_password)
{
$this->channel_password = $channel_password;
return $this;
}
/**
* @return mixed
*/
public function getSalt()
{
return $this->channel_salt;
}
/**
* @param mixed $channel_salt
* @return Channel
*/
public function setSalt($channel_salt)
{
$this->channel_salt = $channel_salt;
return $this;
}
}

1498
Zotlabs/Entity/Item.php Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -1,15 +1,57 @@
<?php
/*
* SPDX-FileCopyrightText: 2025 The Hubzilla Community
* SPDX-FileContributor: redmatrix
* SPDX-FileContributor: Klaus Weidenbach
* SPDX-FileContributor: zotlabs
* SPDX-FileContributor: Harald Eilertsen <haraldei@anduin.net>
*
* SPDX-License-Identifier: MIT
*/
namespace Zotlabs\Extend;
use App;
/**
* @brief Hook class.
* A class for hooking into Hubzilla.
*
* Hooks are functions that Hubzilla will invoke at certain points in the code
* during execution. An addon can register a callback handler that will be
* called whenever the specified hook is invoked. A callback handler is a
* function that takes a reference to an array containing the callback
* arguments as it's only argument.
*
* @see call_hooks
* @see load_hooks
*/
class Hook {
/**
* Register a callback handler for a hook.
*
* A callback handler is a function that takes a reference to an array
* containing the callback arguments as it's only argument.
*
* The contents and meaning of the array depends on the hook invoked. By
* modifying the contents of the array the hook can pass data back to the
* caller.
*
* Once the `Hook::register` function has been called, the callback may be
* invoked.
*
* @param string $hook The name of the hook to register a handler for.
* @param string $file The source file of the callback handler.
* @param string|array $function
* The function name of the callback handler, as a
* string or an array.
* @param int $version Hook interface version, allways 1.
* @param int $priority The priority of the callback handler, higher
* numbers takes precedence.
*
* @return true if the handler was already registered, otherwise the result
* from inserting the hook in the database.
*/
static public function register($hook,$file,$function,$version = 1,$priority = 0) {
if(is_array($function)) {
$function = serialize($function);
@@ -45,6 +87,14 @@ class Hook {
return $r;
}
/**
* Register an array of hook callback handlers.
*
* All of the handlers must be in the same source file.
*
* @param string $file The source file of the callback handlers.
* @param array $arr An array of `hookname => functionname` pairs.
*/
static public function register_array($file,$arr) {
if($arr) {
foreach($arr as $k => $v) {
@@ -54,6 +104,20 @@ class Hook {
}
/**
* Unregister a hook callback handler.
*
* @param string $hook The name of the hook to register a callback handler for.
* @param string $file The source file of the hook callback handler.
* @param string|array $function
* The function name of the callback handler, as a
* string or an array.
* @param int $version Hook interface version, allways 1.
* @param int $priority The priority of the callback handler, higher
* numbers takes precedence.
*
* @return The result of the database delete operation.
*/
static public function unregister($hook,$file,$function,$version = 1,$priority = 0) {
if(is_array($function)) {
$function = serialize($function);
@@ -70,11 +134,13 @@ class Hook {
}
/**
* @brief Unregister all hooks with this file component.
* Unregister all hooks handlers from a given source file.
*
* Useful for addon upgrades where you want to clean out old interfaces.
*
* @param string $file
* @param string $file The source file where the hook handlers were defined.
*
* @return The result from the database delete operation.
*/
static public function unregister_by_file($file) {
$r = q("DELETE FROM hook WHERE file = '%s' ",
@@ -85,25 +151,20 @@ class Hook {
}
/**
* @brief Inserts a hook into a page request.
* Inserts a hook into a page request.
*
* Insert a short-lived hook into the running page request.
* Hooks are normally persistent so that they can be called
* across asynchronous processes such as delivery and poll
* processes.
* Insert a short-lived hook into the running page request. Hooks are
* normally persistent so that they can be called across asynchronous
* processes such as delivery and poll processes.
*
* insert_hook lets you attach a hook callback immediately
* which will not persist beyond the life of this page request
* or the current process.
* This function lets you attach a hook callback immediately which will not
* persist beyond the life of this page request or the current process.
*
* @param string $hook
* name of hook to attach callback
* @param string $fn
* function name of callback handler
* @param int $version
* hook interface version, 0 uses two callback params, 1 uses one callback param
* @param int $priority
* currently not implemented in this function, would require the hook array to be resorted
* @param string $hook Name of hook to attach callback.
* @param string|array $fn Name of callback handler as a string or array.
* @param int $version Hook interface version, allways 1.
* @param int $priority Currently not implemented in this function,
* would require the hook array to be resorted.
*/
static public function insert($hook, $fn, $version = 0, $priority = 0) {
if(is_array($fn)) {
@@ -119,4 +180,4 @@ class Hook {
App::$hooks[$hook][] = array('', $fn, $priority, $version);
}
}
}

View File

@@ -1,22 +1,106 @@
<?php
/*
* SPDX-FileCopyrightText: 2018 The Hubzilla Community
* SPDX-FileContributor: Zotlabs
* SPDX-FileContributor: Mario <mario@mariovavti.com>
* SPDX-FileContributor: Harald Eilertsen <haraldei@anduin.net>
*
* SPDX-License-Identifier: MIT
*/
namespace Zotlabs\Extend;
use Zotlabs\Lib\Config;
/**
* Class for managing routes.
*
* Routes connect a URL path to a module that will handle requests to that
* path.
*
* For example by registering a route like this:
*
* ```php
* Route::register(
* __DIR__ . '/Mod_Myroute.php',
* 'myroute'
* );
* ```
*
* Hubzilla will direct requests to the '/myroute' URL path to the 'Myroute'
* controller located in the '/Mod_Myroute.php' file in the same directory as
* the file this code was called from.
*
* Routes are stored persistently, so this function will typically be called from
* the `<addon>_load()` function if called from an addon. Accordingly, the route must
* be unregistered when no longer needed, like this:
*
* ```php
* Route::unregister(
* __DIR__ . '/Mod_Myroute.php',
* 'myroute'
* );
* ```
*
* This will typically be called from the `<addon>_unload()` function in an addon.
*/
class Route {
static function register($file,$modname) {
/**
* Register a new route.
*
* Example:
* ```php
* Route::register(
* __DIR__ . '/Mod_Myroute.php',
* 'myroute'
* );
* ```
*
* The route is stored persistently, and must be unregistered when no longer needed.
*
* @param string $file The file containing the controller for handling requests to this route.
* @param string $modname The name of the module (URL path).
*
* @see {@link Zotlabs::Extend::Route.unregister() unregister()}
* @see {@link Zotlabs::Extend::Route.unregister_by_file() unregister_by_file()}
*/
public static function register(string $file, string $modname): void {
$rt = self::get();
foreach ($rt as $r) {
if ($r[0] === $file && $r[1] === $modname) {
return;
}
}
$rt[] = [ $file, $modname ];
self::set($rt);
}
static function unregister($file,$modname) {
/**
* Unregister a route.
*
* Example:
* ```php
* Route::unregister(
* __DIR__ . '/Mod_Myroute.php',
* 'myroute'
* );
* ```
*
* @param string $file The file containing the controller for handling requests to this route.
* @param string $modname The name of the module (URL path).
*
* @see {@link Zotlabs::Extend::Route.register() register()}
* @see {@link Zotlabs::Extend::Route.unregister_by_file() unregister_by_file()}
*/
public static function unregister(string $file, string $modname): void {
$rt = self::get();
if($rt) {
$n = [];
foreach($rt as $r) {
if($r[0] !== $file && $r[1] !== $modname) {
if(!($r[0] === $file && $r[1] === $modname)) {
$n[] = $r;
}
}
@@ -24,7 +108,23 @@ class Route {
}
}
static function unregister_by_file($file) {
/**
* Unregister all routes by source file.
*
* Removes all persistently stored routes with hanclers in the
* given source file.
*
* Example:
* ```php
* Route::unregister_by_file(__DIR__ . '/Mod_Myroute.php');
* ```
*
* @param string $file The file containing the controllers to remove.
*
* @see {@link Zotlabs::Extend::Route.register() register()}
* @see {@link Zotlabs::Extend::Route.unregister() unregister()}
*/
public static function unregister_by_file(string $file): void {
$rt = self::get();
if($rt) {
$n = [];
@@ -37,12 +137,19 @@ class Route {
}
}
static function get() {
return get_config('system','routes',[]);
/**
* Get an array of all defined routes.
*
* @return An array of routes, where each entry is an array
* containing two elements, the file, and the module
* name.
*/
public static function get(): array {
return Config::Get('system','routes',[]);
}
static function set($r) {
return set_config('system','routes',$r);
private static function set(array $r): mixed {
return Config::Set('system','routes',$r);
}
}

View File

@@ -2,11 +2,19 @@
namespace Zotlabs\Extend;
use Zotlabs\Lib\Config;
class Widget {
static function register($file,$widget) {
$rt = self::get();
foreach ($rt as $r) {
if ($r[0] === $file && $r[1] === $widget) {
return;
}
}
$rt[] = [ $file, $widget ];
self::set($rt);
}
@@ -16,7 +24,7 @@ class Widget {
if($rt) {
$n = [];
foreach($rt as $r) {
if($r[0] !== $file && $r[1] !== $widget) {
if(!($r[0] === $file && $r[1] === $widget)) {
$n[] = $r;
}
}
@@ -38,10 +46,10 @@ class Widget {
}
static function get() {
return get_config('system','widgets',[]);
return Config::Get('system','widgets',[]);
}
static function set($r) {
return set_config('system','widgets',$r);
return Config::Set('system','widgets',$r);
}
}

View File

@@ -1,6 +1,6 @@
<?php
namespace Zotlabs\Identity\BasicId;
namespace Zotlabs\Identity;
class BasicId {

View File

@@ -2,6 +2,8 @@
namespace Zotlabs\Identity;
use Zotlabs\Lib\Config;
class OAuth2Server extends \OAuth2\Server {
public function __construct(OAuth2Storage $storage, $config = null) {
@@ -24,8 +26,8 @@ class OAuth2Server extends \OAuth2\Server {
$keyStorage = new \OAuth2\Storage\Memory( [
'keys' => [
'public_key' => get_config('system', 'pubkey'),
'private_key' => get_config('system', 'prvkey')
'public_key' => Config::Get('system', 'pubkey'),
'private_key' => Config::Get('system', 'prvkey')
]
]);

View File

@@ -1,5 +1,5 @@
<?php
namespace Zotlabs\Identity\ProfilePhoto;
namespace Zotlabs\Identity;
class ProfilePhoto {

69
Zotlabs/Lib/ASCache.php Normal file
View File

@@ -0,0 +1,69 @@
<?php /** @file */
namespace Zotlabs\Lib;
/**
* A wrapper for the cache api
*/
class ASCache {
public static function isEnabled()
{
return Config::Get('system', 'as_object_cache_enabled', true);
}
public static function getAge(): string
{
return Config::Get('system', 'as_object_cache_time', '10 MINUTE');
}
public static function Get(string $key): array
{
if (!self::isEnabled()) {
return [];
}
$ret = Cache::get($key, self::getAge());
if ($ret) {
return json_unserialize($ret);
}
return [];
}
public static function Set(string $key, array $obj): void
{
if (!self::isEnabled()) {
return;
}
if (!self::isCacheable($obj)) {
return;
}
Cache::set($key, json_serialize($obj));
}
public static function isCacheable(array $obj): bool
{
$to = [];
$cc = [];
if (isset($obj['to'])) {
$to = is_array($obj['to']) ? $obj['to'] : [$obj['to']];
}
if (isset($obj['cc'])) {
$cc = is_array($obj['cc']) ? $obj['cc'] : [$obj['cc']];
}
$receivers = array_merge($to, $cc);
if ($receivers && !in_array(ACTIVITY_PUBLIC_INBOX, $receivers)) {
return false;
}
return true;
}
}

View File

@@ -0,0 +1,179 @@
<?php
namespace Zotlabs\Lib;
/**
* Class for dealing with fetching ActivityStreams collections (ordered or unordered, normal or paged).
* Construct with either an existing object or url and an optional channel to sign requests.
* $direction is 0 (default) to fetch from the beginning, and 1 to fetch from the end and reverse order the resultant array.
* An optional limit to the number of records returned may also be specified.
* Use $class->get() to return an array of collection members.
*/
class ASCollection {
private $channel = null;
private $nextpage = null;
private $limit = 0;
private $direction = 0; // 0 = forward, 1 = reverse
private $data = [];
private $history = [];
function __construct($obj, $channel = null, $direction = 0, $limit = 0) {
$this->channel = $channel;
$this->direction = $direction;
$this->limit = $limit;
$data = null;
if (is_array($obj)) {
$data = $obj;
}
if (is_string($obj)) {
$cached = ASCache::Get($obj);
if ($cached) {
// logger('cached: ' . $obj);
$data = $cached;
}
else {
// logger('fetching: ' . $obj);
$data = Activity::fetch($obj, $channel);
if ($data) {
ASCache::Set($obj, $data);
}
}
$this->history[] = $obj;
}
if (!is_array($data)) {
return;
}
if (!in_array($data['type'], ['Collection', 'OrderedCollection', 'OrderedCollectionPage'])) {
return false;
}
if ($this->direction) {
if (array_key_exists('last', $data) && $data['last']) {
$this->nextpage = $data['last'];
}
}
else {
if (array_key_exists('first', $data) && $data['first']) {
$this->nextpage = $data['first'];
}
}
if (isset($data['items']) && is_array($data['items'])) {
$this->data = (($this->direction) ? array_reverse($data['items']) : $data['items']);
}
elseif (isset($data['orderedItems']) && is_array($data['orderedItems'])) {
$this->data = (($this->direction) ? array_reverse($data['orderedItems']) : $data['orderedItems']);
}
if ($this->limit) {
if (count($this->data) > $limit) {
$this->data = array_slice($this->data, 0, $limit);
return;
}
}
do {
$x = $this->next();
} while ($x);
}
function get() {
return $this->data;
}
function next() {
if (!$this->nextpage) {
return false;
}
$data = null;
if (is_array($this->nextpage)) {
$data = $this->nextpage;
}
if (is_string($this->nextpage)) {
if (in_array($this->nextpage, $this->history)) {
// recursion detected
return false;
}
$cached = ASCache::Get($this->nextpage);
if ($cached) {
// logger('cached: ' . $this->nextpage);
$data = $cached;
}
else {
$data = Activity::fetch($this->nextpage, $this->channel);
if ($data) {
// logger('fetching: ' . $this->nextpage);
ASCache::Set($this->nextpage, $data);
}
}
$this->history[] = $this->nextpage;
}
if (!is_array($data)) {
return false;
}
if (!in_array($data['type'], ['CollectionPage', 'OrderedCollectionPage'])) {
return false;
}
$this->setnext($data);
if (isset($data['items']) && is_array($data['items'])) {
$this->data = array_merge($this->data, (($this->direction) ? array_reverse($data['items']) : $data['items']));
}
elseif (isset($data['orderedItems']) && is_array($data['orderedItems'])) {
$this->data = array_merge($this->data, (($this->direction) ? array_reverse($data['orderedItems']) : $data['orderedItems']));
}
if ($this->limit) {
if (count($this->data) > $this->limit) {
$this->data = array_slice($this->data, 0, $this->limit);
$this->nextpage = false;
return true;
}
}
return true;
}
function setnext($data) {
if ($this->direction) {
if (array_key_exists('prev', $data) && $data['prev']) {
$this->nextpage = $data['prev'];
}
elseif (array_key_exists('first', $data) && $data['first']) {
$this->nextpage = $data['first'];
}
else {
$this->nextpage = false;
}
}
else {
if (array_key_exists('next', $data) && $data['next']) {
$this->nextpage = $data['next'];
}
elseif (array_key_exists('last', $data) && $data['last']) {
$this->nextpage = $data['last'];
}
else {
$this->nextpage = false;
}
}
logger('nextpage: ' . $this->nextpage, LOGGER_DEBUG);
}
}

View File

@@ -6,12 +6,17 @@ namespace Zotlabs\Lib;
class AbConfig {
static public function Load($chan,$xhash,$family = '') {
if($family)
$where = '';
if($family) {
$where = sprintf(" and cat = '%s' ",dbesc($family));
}
$r = q("select * from abconfig where chan = %d and xchan = '%s' $where",
intval($chan),
dbesc($xhash)
);
return $r;
}
@@ -21,7 +26,7 @@ class AbConfig {
intval($chan),
dbesc($xhash),
dbesc($family),
dbesc($key)
dbesc($key)
);
if($r) {
return ((preg_match('|^a:[0-9]+:{.*}$|s', $r[0]['v'])) ? unserialize($r[0]['v']) : $r[0]['v']);
@@ -41,19 +46,19 @@ class AbConfig {
dbesc($xhash),
dbesc($family),
dbesc($key),
dbesc($dbvalue)
dbesc($dbvalue)
);
}
else {
$r = q("update abconfig set v = '%s' where chan = %d and xchan = '%s' and cat = '%s' and k = '%s' ",
dbesc($dbvalue),
dbesc($dbvalue),
dbesc($chan),
dbesc($xhash),
dbesc($family),
dbesc($key)
);
}
if($r)
return $value;
return false;

View File

@@ -1,38 +1,37 @@
<?php
<?php
namespace Zotlabs\Lib;
use Zotlabs\Lib\Libsync;
class AccessList {
static function add($uid,$name,$public = 0) {
$ret = false;
static function add($uid, $name, $public = 0) {
$ret = false;
$hash = '';
if ($uid && $name) {
$r = self::byname($uid,$name); // check for dups
$r = self::by_name($uid, $name); // check for dups
if ($r !== false) {
// This could be a problem.
// This could be a problem.
// Let's assume we've just created a list which we once deleted
// all the old members are gone, but the list remains so we don't break any security
// access lists. What we're doing here is reviving the dead list, but old content which
// was restricted to this list may now be seen by the new list members.
// was restricted to this list may now be seen by the new list members.
$z = q("SELECT * FROM pgrp WHERE id = %d LIMIT 1",
intval($r)
);
if(($z) && $z[0]['deleted']) {
if (($z) && $z[0]['deleted']) {
q('UPDATE pgrp SET deleted = 0 WHERE id = %d', intval($z[0]['id']));
notice( t('A deleted list with this name was revived. Existing item permissions <strong>may</strong> apply to this list and any future members. If this is not what you intended, please create another list with a different name.') . EOL);
notice(t('A deleted privacy group with this name was revived. Existing item permissions <strong>may</strong> apply to this privacy group and any future members. If this is not what you intended, please create another privacy group with a different name.') . EOL);
}
return true;
$hash = self::by_id($uid, $r);
return $hash;
}
$hash = new_uuid();
$r = q("INSERT INTO pgrp ( hash, uid, visible, gname )
$r = q("INSERT INTO pgrp ( hash, uid, visible, gname )
VALUES( '%s', %d, %d, '%s' ) ",
dbesc($hash),
intval($uid),
@@ -42,12 +41,12 @@ class AccessList {
$ret = $r;
}
Libsync::build_sync_packet($uid,null,true);
return $ret;
Libsync::build_sync_packet($uid, null, true);
return (($ret) ? $hash : $ret);
}
static function remove($uid,$name) {
static function remove($uid, $name) {
$ret = false;
if ($uid && $name) {
$r = q("SELECT id, hash FROM pgrp WHERE uid = %d AND gname = '%s' LIMIT 1",
@@ -55,36 +54,36 @@ class AccessList {
dbesc($name)
);
if ($r) {
$group_id = $r[0]['id'];
$group_id = $r[0]['id'];
$group_hash = $r[0]['hash'];
}
else {
return false;
}
// remove group from default posting lists
$r = q("SELECT channel_default_group, channel_allow_gid, channel_deny_gid FROM channel WHERE channel_id = %d LIMIT 1",
intval($uid)
intval($uid)
);
if ($r) {
$user_info = array_shift($r);
$change = false;
$change = false;
if ($user_info['channel_default_group'] == $group_hash) {
$user_info['channel_default_group'] = '';
$change = true;
$change = true;
}
if (strpos($user_info['channel_allow_gid'], '<' . $group_hash . '>') !== false) {
$user_info['channel_allow_gid'] = str_replace('<' . $group_hash . '>', '', $user_info['channel_allow_gid']);
$change = true;
$change = true;
}
if (strpos($user_info['channel_deny_gid'], '<' . $group_hash . '>') !== false) {
$user_info['channel_deny_gid'] = str_replace('<' . $group_hash . '>', '', $user_info['channel_deny_gid']);
$change = true;
$change = true;
}
if ($change) {
q("UPDATE channel SET channel_default_group = '%s', channel_allow_gid = '%s', channel_deny_gid = '%s'
q("UPDATE channel SET channel_default_group = '%s', channel_allow_gid = '%s', channel_deny_gid = '%s'
WHERE channel_id = %d",
intval($user_info['channel_default_group']),
dbesc($user_info['channel_allow_gid']),
@@ -110,16 +109,16 @@ class AccessList {
}
Libsync::build_sync_packet($uid,null,true);
Libsync::build_sync_packet($uid, null, true);
return $ret;
}
// returns the integer id of an access group owned by $uid and named $name
// or false.
static function byname($uid,$name) {
if (! ($uid && $name)) {
static function by_name($uid, $name) {
if (!($uid && $name)) {
return false;
}
$r = q("SELECT id FROM pgrp WHERE uid = %d AND gname = '%s' LIMIT 1",
@@ -132,11 +131,11 @@ class AccessList {
return false;
}
static function by_id($uid,$id) {
if (! ($uid && $id)) {
static function by_id($uid, $id) {
if (!($uid && $id)) {
return false;
}
$r = q("SELECT * FROM pgrp WHERE uid = %d AND id = %d and deleted = 0",
intval($uid),
intval($id)
@@ -147,10 +146,8 @@ class AccessList {
return false;
}
static function rec_byhash($uid,$hash) {
if (! ( $uid && $hash)) {
static function by_hash($uid, $hash) {
if (!($uid && $hash)) {
return false;
}
$r = q("SELECT * FROM pgrp WHERE uid = %d AND hash = '%s' LIMIT 1",
@@ -163,46 +160,46 @@ class AccessList {
return false;
}
static function member_remove($uid, $name, $member, $gid = 0) {
if (!$gid) {
$gid = self::by_name($uid, $name);
}
static function member_remove($uid,$name,$member) {
$gid = self::byname($uid,$name);
if (! $gid) {
return false;
}
if (! ($uid && $gid && $member)) {
if (!($uid && $gid && $member)) {
return false;
}
$r = q("DELETE FROM pgrp_member WHERE uid = %d AND gid = %d AND xchan = '%s' ",
intval($uid),
intval($gid),
dbesc($member)
);
Libsync::build_sync_packet($uid,null,true);
Libsync::build_sync_packet($uid, null, true);
return $r;
}
static function member_add($uid,$name,$member,$gid = 0) {
if (! $gid) {
$gid = self::byname($uid,$name);
static function member_add($uid, $name, $member, $gid = 0) {
if (!$gid) {
$gid = self::by_name($uid, $name);
}
if (! ($gid && $uid && $member)) {
if (!($gid && $uid && $member)) {
return false;
}
$r = q("SELECT * FROM pgrp_member WHERE uid = %d AND gid = %d AND xchan = '%s' LIMIT 1",
$r = q("SELECT * FROM pgrp_member WHERE uid = %d AND gid = %d AND xchan = '%s' LIMIT 1",
intval($uid),
intval($gid),
dbesc($member)
);
if ($r) {
return true; // You might question this, but
// we indicate success because the group member was in fact created
// -- It was just created at another time
return true;
// You might question this, but
// we indicate success because the group member was in fact created
// -- It was just created at another time
}
else {
else {
$r = q("INSERT INTO pgrp_member (uid, gid, xchan)
VALUES( %d, %d, '%s' ) ",
intval($uid),
@@ -210,15 +207,14 @@ class AccessList {
dbesc($member)
);
}
Libsync::build_sync_packet($uid,null,true);
Libsync::build_sync_packet($uid, null, true);
return $r;
}
static function members($uid, $gid) {
$ret = [];
if (intval($gid)) {
$r = q("SELECT * FROM pgrp_member
$r = q("SELECT * FROM pgrp_member
LEFT JOIN abook ON abook_xchan = pgrp_member.xchan left join xchan on xchan_hash = abook_xchan
WHERE gid = %d AND abook_channel = %d and pgrp_member.uid = %d and xchan_deleted = 0 and abook_self = 0 and abook_blocked = 0 and abook_pending = 0 ORDER BY xchan_name ASC ",
intval($gid),
@@ -232,7 +228,7 @@ class AccessList {
return $ret;
}
static function members_xchan($uid,$gid) {
static function members_xchan($uid, $gid) {
$ret = [];
if (intval($gid)) {
$r = q("SELECT xchan FROM pgrp_member WHERE gid = %d AND uid = %d",
@@ -248,99 +244,75 @@ class AccessList {
return $ret;
}
static function members_profile_xchan($uid,$gid) {
static function profile_members_xchan($uid,$gid) {
$ret = [];
if (intval($gid)) {
if(intval($gid)) {
$r = q("SELECT abook_xchan as xchan from abook left join profile on abook_profile = profile_guid where profile.id = %d and profile.uid = %d",
intval($gid),
intval($uid)
);
if ($r) {
foreach($r as $rv) {
$ret[] = $rv['xchan'];
if($r) {
foreach($r as $rr) {
$ret[] = $rr['xchan'];
}
}
}
return $ret;
}
static function select($uid, $options) {
$selected = $options['selected'] ?? '';
$form_id = $options['form_id'] ?? 'accesslist_select';
$label = $options['label'] ?? t('Select a privacy group');
$before = $options['before'] ?? [];
$after = $options['after'] ?? [];
static function select($uid,$group = '') {
$grps = [];
$o = '';
$grps[] = [
'name' => '',
'id' => '0',
'selected' => false
];
if ($before) {
$grps[] = $before;
}
$r = q("SELECT * FROM pgrp WHERE deleted = 0 AND uid = %d ORDER BY gname ASC",
intval($uid)
);
$grps[] = [ 'name' => '', 'hash' => '0', 'selected' => '' ];
if ($r) {
foreach ($r as $rr) {
$grps[] = [ 'name' => $rr['gname'], 'id' => $rr['hash'], 'selected' => (($group == $rr['hash']) ? 'true' : '') ];
}
}
return replace_macros(get_markup_template('group_selection.tpl'), [
'$label' => t('Add new connections to this access list'),
'$groups' => $grps
]);
}
static function widget($every="connections",$each="lists",$edit = false, $group_id = 0, $cid = '',$mode = 1) {
$o = '';
$groups = [];
$r = q("SELECT * FROM pgrp WHERE deleted = 0 AND uid = %d ORDER BY gname ASC",
intval($_SESSION['uid'])
);
$member_of = [];
if ($cid) {
$member_of = self::containing(local_channel(),$cid);
}
if ($r) {
foreach ($r as $rr) {
$selected = (($group_id == $rr['id']) ? ' group-selected' : '');
if ($edit) {
$groupedit = [ 'href' => "lists/".$rr['id'], 'title' => t('edit') ];
}
else {
$groupedit = null;
}
$groups[] = [
'id' => $rr['id'],
'enc_cid' => base64url_encode($cid),
'cid' => $cid,
'text' => $rr['gname'],
'selected' => $selected,
'href' => (($mode == 0) ? $each.'?f=&gid='.$rr['id'] : $each."/".$rr['id']) . ((x($_GET,'new')) ? '&new=' . $_GET['new'] : '') . ((x($_GET,'order')) ? '&order=' . $_GET['order'] : ''),
'edit' => $groupedit,
'ismember' => in_array($rr['id'],$member_of),
if($r) {
foreach($r as $rr) {
$grps[] = [
'name' => $rr['gname'],
'id' => $rr['hash'],
'selected' => ($selected == $rr['hash'])
];
}
}
return replace_macros(get_markup_template('group_side.tpl'), [
'$title' => t('Lists'),
'$edittext' => t('Edit list'),
'$createtext' => t('Create new list'),
'$ungrouped' => (($every === 'contacts') ? t('Channels not in any access list') : ''),
'$groups' => $groups,
'$add' => t('add'),
]);
if ($after) {
$grps[] = $after;
}
logger('select: ' . print_r($grps,true), LOGGER_DATA);
$o = replace_macros(get_markup_template('group_selection.tpl'), array(
'$label' => $label,
'$form_id' => $form_id,
'$groups' => $grps
));
return $o;
}
static function expand($g) {
if (! (is_array($g) && count($g))) {
if (!(is_array($g) && count($g))) {
return [];
}
@@ -350,8 +322,8 @@ class AccessList {
// private profile linked virtual groups
foreach ($g as $gv) {
if (substr($gv,0,3) === 'vp.') {
$profile_hash = substr($gv,3);
if (substr($gv, 0, 3) === 'vp.') {
$profile_hash = substr($gv, 3);
if ($profile_hash) {
$r = q("select abook_xchan from abook where abook_profile = '%s'",
dbesc($profile_hash)
@@ -366,10 +338,10 @@ class AccessList {
else {
$x[] = $gv;
}
}
}
if ($x) {
stringify_array_elms($x,true);
stringify_array_elms($x, true);
$groups = implode(',', $x);
if ($groups) {
$r = q("SELECT xchan FROM pgrp_member WHERE gid IN ( select id from pgrp where hash in ( $groups ))");
@@ -383,9 +355,8 @@ class AccessList {
return $ret;
}
static function member_of($c) {
$r = q("SELECT pgrp.gname, pgrp.id FROM pgrp LEFT JOIN pgrp_member ON pgrp_member.gid = pgrp.id
$r = q("SELECT pgrp.gname, pgrp.id FROM pgrp LEFT JOIN pgrp_member ON pgrp_member.gid = pgrp.id
WHERE pgrp_member.xchan = '%s' AND pgrp.deleted = 0 ORDER BY pgrp.gname ASC ",
dbesc($c)
);
@@ -393,7 +364,7 @@ class AccessList {
return $r;
}
static function containing($uid,$c) {
static function containing($uid, $c) {
$r = q("SELECT gid FROM pgrp_member WHERE uid = %d AND pgrp_member.xchan = '%s' ",
intval($uid),
@@ -405,7 +376,8 @@ class AccessList {
foreach ($r as $rv)
$ret[] = $rv['gid'];
}
return $ret;
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -7,26 +7,28 @@ namespace Zotlabs\Lib;
*
* Parses an ActivityStream JSON string.
*/
class ActivityStreams {
public $raw = null;
public $data = null;
public $valid = false;
public $deleted = false;
public $id = '';
public $parent_id = '';
public $type = '';
public $actor = null;
public $obj = null;
public $tgt = null;
public $origin = null;
public $owner = null;
public $signer = null;
public $ldsig = null;
public $sigok = false;
public $recips = null;
public $raw = null;
public $data = null;
public $meta = null;
public $valid = false;
public $deleted = false;
public $portable_id = null;
public $id = '';
public $parent_id = '';
public $type = '';
public $actor = null;
public $obj = null;
public $tgt = null;
public $origin = null;
public $owner = null;
public $signer = null;
public $sig = null;
public $sigok = false;
public $recips = null;
public $raw_recips = null;
public $saved_recips = null;
/**
* @brief Constructor for ActivityStreams.
@@ -35,92 +37,127 @@ class ActivityStreams {
*
* @param string $string
*/
function __construct($string) {
function __construct($string, $portable_id = null) {
$this->raw = $string;
if(!$string)
return;
if(is_array($string)) {
$this->raw = $string;
$this->portable_id = $portable_id;
if (is_array($string)) {
$this->data = $string;
$this->raw = json_encode($string, JSON_UNESCAPED_SLASHES);
}
else {
$this->data = json_decode($string, true);
}
if($this->data) {
if ($this->data) {
// verify and unpack JSalmon signature if present
if(is_array($this->data) && array_key_exists('signed',$this->data)) {
if (is_array($this->data) && array_key_exists('signed', $this->data)) {
$ret = JSalmon::verify($this->data);
$tmp = JSalmon::unpack($this->data['data']);
if($ret && $ret['success']) {
if($ret['signer']) {
$saved = json_encode($this->data,JSON_UNESCAPED_SLASHES);
$this->data = $tmp;
$this->data['signer'] = $ret['signer'];
$this->data['signed_data'] = $saved;
if($ret['hubloc']) {
$this->data['hubloc'] = $ret['hubloc'];
if ($ret && $ret['success']) {
if ($ret['signer']) {
$saved = json_encode($this->data, JSON_UNESCAPED_SLASHES);
$this->data = $tmp;
$this->meta['signer'] = $ret['signer'];
$this->meta['signed_data'] = $saved;
if ($ret['hubloc']) {
$this->meta['hubloc'] = $ret['hubloc'];
}
}
}
}
// This indicates only that we have sucessfully decoded JSON.
$this->valid = true;
if(array_key_exists('type',$this->data) && array_key_exists('actor',$this->data) && array_key_exists('object',$this->data)) {
if($this->data['type'] === 'Delete' && $this->data['actor'] === $this->data['object']) {
// Special handling for Mastodon "delete actor" activities which will often fail to verify
// because the key cannot be fetched. We will catch this condition elsewhere.
if (is_array($this->data) && array_key_exists('type', $this->data) && array_key_exists('actor', $this->data) && array_key_exists('object', $this->data)) {
if ($this->data['type'] === 'Delete' && $this->data['actor'] === $this->data['object']) {
$this->deleted = $this->data['actor'];
$this->valid = false;
$this->valid = false;
}
}
}
if($this->is_valid()) {
$this->id = $this->get_property_obj('id');
// Attempt to assemble an Activity from what we were given.
if ($this->is_valid()) {
$this->id = $this->get_property_obj('id');
if (!$this->id) {
logger('Data with mmissing id: ' . print_r($this->data, true));
return;
}
// cache for future use
ASCache::Set($this->id, $this->data);
$this->type = $this->get_primary_type();
$this->actor = $this->get_actor('actor','','');
$this->actor = $this->get_actor('actor', '', '');
$this->obj = $this->get_compound_property('object');
$this->tgt = $this->get_compound_property('target');
$this->origin = $this->get_compound_property('origin');
$this->recips = $this->collect_recips();
$this->ldsig = $this->get_compound_property('signature');
if($this->ldsig) {
$this->signer = $this->get_compound_property('creator',$this->ldsig);
if($this->signer && is_array($this->signer) && array_key_exists('publicKey',$this->signer) && is_array($this->signer['publicKey']) && $this->signer['publicKey']['publicKeyPem']) {
$this->sigok = LDSignatures::verify($this->data,$this->signer['publicKey']['publicKeyPem']);
$this->sig = $this->get_compound_property('proof');
if ($this->sig) {
$this->checkEddsaSignature(); // will set signer and sigok if everything works out
}
// Try LDSignatures if edsig failed
if (!$this->sigok) {
$this->sig = $this->get_compound_property('signature');
if ($this->sig) {
$this->signer = $this->get_actor('creator', $this->sig);
if ($this->signer && is_array($this->signer) && array_key_exists('publicKey', $this->signer) && is_array($this->signer['publicKey']) && $this->signer['publicKey']['publicKeyPem']) {
$this->sigok = LDSignatures::verify($this->data, $this->signer['publicKey']['publicKeyPem']);
}
}
}
if(! $this->obj) {
$this->obj = $this->data;
if (!$this->obj) {
$this->obj = $this->data;
$this->type = 'Create';
if(! $this->actor) {
$this->actor = $this->get_actor('attributedTo',$this->obj);
if (!$this->actor) {
$this->actor = $this->get_actor('attributedTo', $this->obj);
}
}
// fetch recursive or embedded activities
if ($this->obj && is_array($this->obj) && array_key_exists('object',$this->obj)) {
$this->obj['object'] = $this->get_compound_property($this->obj['object']);
// Fetch recursive or embedded activities
if ($this->obj && is_array($this->obj) && array_key_exists('object', $this->obj)) {
$this->obj['object'] = $this->get_compound_property('object', $this->obj);
}
if($this->obj && is_array($this->obj) && $this->obj['actor'])
$this->obj['actor'] = $this->get_actor('actor',$this->obj);
if($this->tgt && is_array($this->tgt) && $this->tgt['actor'])
$this->tgt['actor'] = $this->get_actor('actor',$this->tgt);
// Enumerate and store actors in referenced objects
$this->parent_id = $this->get_property_obj('inReplyTo');
if((! $this->parent_id) && is_array($this->obj)) {
$this->parent_id = $this->obj['inReplyTo'];
if ($this->obj && is_array($this->obj) && isset($this->obj['actor'])) {
$this->obj['actor'] = $this->get_actor('actor', $this->obj);
}
if((! $this->parent_id) && is_array($this->obj)) {
if ($this->tgt && is_array($this->tgt) && isset($this->tgt['actor'])) {
$this->tgt['actor'] = $this->get_actor('actor', $this->tgt);
}
// Determine if this is a followup or response activity
$this->parent_id = ((is_array($this->get_property_obj('inReplyTo'))) ? $this->get_property_obj('inReplyTo')['id'] : $this->get_property_obj('inReplyTo'));
if (!$this->parent_id && isset($this->obj['inReplyTo'])) {
$this->parent_id = ((is_array($this->obj['inReplyTo'])) ? $this->obj['inReplyTo']['id'] : $this->obj['inReplyTo']);
}
if (!$this->parent_id && isset($this->obj['id'])) {
$this->parent_id = $this->obj['id'];
}
}
}
@@ -137,51 +174,74 @@ class ActivityStreams {
$this->saved_recips = $arr;
}
/**
* @brief get single property from Activity object
*
* @param string $property
* @param mixed $default return value if property or object not set
* or object is a string id which could not be fetched.
* @return mixed
*/
public function objprop(string $property, mixed $default = false): mixed {
$x = $this->get_property_obj($property, $this->obj);
return (isset($x)) ? $x : $default;
}
/**
* @brief Collects all recipients.
*
* @param string $base
* @param mixed $base
* @param string $namespace (optional) default empty
* @return array
*/
function collect_recips($base = '', $namespace = '') {
$x = [];
public function collect_recips(mixed $base = '', string $namespace = ''): array {
$result = [];
$tmp = [];
$fields = [ 'to', 'cc', 'bto', 'bcc', 'audience'];
foreach($fields as $f) {
$y = $this->get_compound_property($f, $base, $namespace);
if($y) {
if (! is_array($this->raw_recips)) {
$this->raw_recips = [];
}
if (! is_array($y)) {
$y = [ $y ];
}
$this->raw_recips[$f] = $y;
$x = array_merge($x, $y);
$fields = ['to', 'cc', 'bto', 'bcc', 'audience'];
foreach ($fields as $field) {
// don't expand these yet
$values = $this->get_property_obj($field, $base, $namespace);
if ($values) {
$values = force_array($values);
$tmp[$field] = $values;
$result = array_values(array_unique(array_merge($result, $values)));
}
// Merge the object recipients if they exist.
$values = $this->objprop($field);
if ($values) {
$values = force_array($values);
$tmp[$field] = ((isset($tmp[$field])) ? array_merge($tmp[$field], $values) : $values);
$result = array_values(array_unique(array_merge($result, $values)));
}
// remove duplicates
if (isset($tmp[$field])) {
$tmp[$field] = array_values(array_unique($tmp[$field]));
}
}
// not yet ready for prime time
// $x = $this->expand($x,$base,$namespace);
return $x;
$this->raw_recips = $tmp;
// not yet ready for prime time
// $result = $this->expand($result,$base,$namespace);
return $result;
}
function expand($arr,$base = '',$namespace = '') {
function expand($arr, $base = '', $namespace = '') {
$ret = [];
// right now use a hardwired recursion depth of 5
for($z = 0; $z < 5; $z ++) {
if(is_array($arr) && $arr) {
foreach($arr as $a) {
if(is_array($a)) {
for ($z = 0; $z < 5; $z++) {
if (is_array($arr) && $arr) {
foreach ($arr as $a) {
if (is_array($a)) {
$ret[] = $a;
}
else {
$x = $this->get_compound_property($a,$base,$namespace);
if($x) {
$ret = array_merge($ret,$x);
$x = $this->get_compound_property($a, $base, $namespace);
if ($x) {
$ret = array_merge($ret, $x);
}
}
}
@@ -202,33 +262,33 @@ class ActivityStreams {
*/
function get_namespace($base, $namespace) {
if(! $namespace)
if (!$namespace)
return '';
$key = null;
foreach( [ $this->data, $base ] as $b ) {
if(! $b)
foreach ([$this->data, $base] as $b) {
if (!$b)
continue;
if(array_key_exists('@context', $b)) {
if(is_array($b['@context'])) {
foreach($b['@context'] as $ns) {
if(is_array($ns)) {
foreach($ns as $k => $v) {
if($namespace === $v)
if (array_key_exists('@context', $b)) {
if (is_array($b['@context'])) {
foreach ($b['@context'] as $ns) {
if (is_array($ns)) {
foreach ($ns as $k => $v) {
if ($namespace === $v)
$key = $k;
}
}
else {
if($namespace === $ns) {
if ($namespace === $ns) {
$key = '';
}
}
}
}
else {
if($namespace === $b['@context']) {
if ($namespace === $b['@context']) {
$key = '';
}
}
@@ -248,14 +308,14 @@ class ActivityStreams {
*/
function get_property_obj($property, $base = '', $namespace = '') {
$prefix = $this->get_namespace($base, $namespace);
if($prefix === null)
if ($prefix === null)
return null;
$base = (($base) ? $base : $this->data);
$base = (($base) ? $base : $this->data);
$propname = (($prefix) ? $prefix . ':' : '') . $property;
if(! is_array($base)) {
btlogger('not an array: ' . print_r($base,true));
if (!is_array($base)) {
btlogger('not an array: ' . print_r($base, true));
return null;
}
@@ -270,23 +330,38 @@ class ActivityStreams {
* @return NULL|mixed
*/
function fetch_property($url) {
return self::fetch($url);
}
function fetch_property($url, $channel = null) {
$x = null;
static function fetch($url, $channel = null) {
return Activity::fetch($url, $channel);
if (str_starts_with($url, z_root() . '/item/')) {
$x = Activity::fetch_local($url, $this->portable_id ?? '');
logger('local: ' . print_r($x,true));
}
if (!$x) {
$x = Activity::fetch($url, $channel);
if ($x === null && strpos($url, '/channel/')) {
// look for other nomadic channels which might be alive
$zf = Zotfinger::exec($url, $channel);
if ($zf) {
$url = $zf['signature']['signer'];
$x = Activity::fetch($url, $channel);
}
}
}
return $x;
}
static function is_an_actor($s) {
return (in_array($s, [ 'Application','Group','Organization','Person','Service' ]));
return (in_array($s, ['Application', 'Group', 'Organization', 'Person', 'Service']));
}
static function is_response_activity($s) {
if (! $s) {
if (!$s) {
return false;
}
return (in_array($s, [ 'Like', 'Dislike', 'Flag', 'Block', 'Announce', 'Accept', 'Reject', 'TentativeAccept', 'TentativeReject', 'emojiReaction', 'EmojiReaction', 'EmojiReact' ]));
return (in_array($s, ['Announce', 'Like', 'Dislike', 'Flag', 'Block', 'Accept', 'Reject', 'TentativeAccept', 'TentativeReject', 'emojiReaction', 'EmojiReaction', 'EmojiReact']));
}
/**
@@ -298,30 +373,27 @@ class ActivityStreams {
* @return NULL|mixed
*/
function get_actor($property,$base='',$namespace = '') {
function get_actor($property, $base = '', $namespace = '') {
$x = $this->get_property_obj($property, $base, $namespace);
if($this->is_url($x)) {
// SECURITY: If we have already stored the actor profile, re-generate it
// from cached data - don't refetch it from the network
$r = q("select * from xchan left join hubloc on xchan_hash = hubloc_hash where hubloc_id_url = '%s' limit 1",
dbesc($x)
);
if($r) {
$y = Activity::encode_person($r[0]);
$y['cached'] = true;
if ($this->is_url($x)) {
$y = Activity::get_actor($x);
if ($y) {
return $y;
}
}
$actor = $this->get_compound_property($property,$base,$namespace,true);
if(is_array($actor) && self::is_an_actor($actor['type'])) {
if(array_key_exists('id',$actor) && (! array_key_exists('inbox',$actor))) {
$actor = $this->get_compound_property($property, $base, $namespace, true);
if (is_array($actor) && self::is_an_actor($actor['type'])) {
if (array_key_exists('id', $actor) && (!array_key_exists('inbox', $actor))) {
$actor = $this->fetch_property($actor['id']);
}
return $actor;
}
return null;
return Activity::get_unknown_actor($this->data);
}
@@ -336,31 +408,44 @@ class ActivityStreams {
*/
function get_compound_property($property, $base = '', $namespace = '', $first = false) {
$x = $this->get_property_obj($property, $base, $namespace);
if($this->is_url($x)) {
$y = $this->fetch_property($x);
if ($this->is_url($x)) {
$cached = ASCache::Get($x);
if ($cached) {
// logger('AS cached: ' . $x);
$y = $cached;
}
else {
// logger('AS fetching: ' . $x);
$y = $this->fetch_property($x);
if ($y) {
ASCache::Set($x, $y);
}
}
if (is_array($y)) {
$x = $y;
}
}
// verify and unpack JSalmon signature if present
if(is_array($x) && array_key_exists('signed',$x)) {
if (is_array($x) && array_key_exists('signed', $x)) {
$ret = JSalmon::verify($x);
$tmp = JSalmon::unpack($x['data']);
if($ret && $ret['success']) {
if($ret['signer']) {
$saved = json_encode($x,JSON_UNESCAPED_SLASHES);
$x = $tmp;
$x['signer'] = $ret['signer'];
$x['signed_data'] = $saved;
if($ret['hubloc']) {
$x['hubloc'] = $ret['hubloc'];
if ($ret && $ret['success']) {
if ($ret['signer']) {
$saved = json_encode($x, JSON_UNESCAPED_SLASHES);
$x = $tmp;
$x['meta']['signer'] = $ret['signer'];
$x['meta']['signed_data'] = $saved;
if ($ret['hubloc']) {
$x['meta']['hubloc'] = $ret['hubloc'];
}
}
}
}
if($first && is_array($x) && array_key_exists(0,$x)) {
if ($first && is_array($x) && array_key_exists(0, $x)) {
return $x[0];
}
@@ -374,7 +459,7 @@ class ActivityStreams {
* @return boolean
*/
function is_url($url) {
if(($url) && (! is_array($url)) && (strpos($url, 'http') === 0)) {
if (($url) && (!is_array($url)) && (strpos($url, 'http') === 0)) {
return true;
}
@@ -389,13 +474,13 @@ class ActivityStreams {
* @return NULL|mixed
*/
function get_primary_type($base = '', $namespace = '') {
if(! $base)
if (!$base)
$base = $this->data;
$x = $this->get_property_obj('type', $base, $namespace);
if(is_array($x)) {
foreach($x as $y) {
if(strpos($y, ':') === false) {
if (is_array($x)) {
foreach ($x as $y) {
if (strpos($y, ':') === false) {
return $y;
}
}
@@ -409,16 +494,102 @@ class ActivityStreams {
return $x;
}
static function is_as_request() {
static function is_as_request($channel = null) {
$x = getBestSupportedMimeType([
'application/ld+json;profile="https://www.w3.org/ns/activitystreams"',
'application/activity+json',
'application/ld+json;profile="http://www.w3.org/ns/activitystreams"'
]);
$hookdata = [];
if ($channel)
$hookdata['channel'] = $channel;
return(($x) ? true : false);
$hookdata['data'] = ['application/x-zot-activity+json'];
call_hooks('is_as_request', $hookdata);
$x = getBestSupportedMimeType($hookdata['data']);
return (($x) ? true : false);
}
static function get_accept_header_string($channel = null) {
$ret = '';
$hookdata = [];
if ($channel)
$hookdata['channel'] = $channel;
$hookdata['data'] = ['application/x-zot-activity+json'];
call_hooks('get_accept_header_string', $hookdata);
$ret = implode(', ', $hookdata['data']);
return $ret;
}
public function checkEddsaSignature() {
$publicKey = null;
$signer = $this->get_property_obj('verificationMethod', $this->sig);
if ($signer && str_starts_with($signer, 'did:key:')) {
$publicKey = str_replace('did:key:', '', $signer);
$this->signer = ['id' => $signer];
if (strpos($publicKey, '#') !== false) {
$publicKey = substr($publicKey,0, strpos($publicKey, '#'));
}
}
else {
$parseUrl = parse_url($signer);
if (isset($parseUrl['fragment'])) {
if (str_starts_with($parseUrl['fragment'], 'z6Mk')) {
$publicKey = $parseUrl['fragment'];
}
unset($parseUrl['fragment']);
}
if (isset($parseUrl['query'])) {
unset($parseUrl['query']);
}
$url = unparse_url($parseUrl);
$this->signer = ['id' => $url];
$hublocs = Activity::get_actor_hublocs($url);
$hasStoredKey = false;
if ($hublocs) {
foreach ($hublocs as $hubloc) {
if ($publicKey && $hubloc['xchan_epubkey'] === $publicKey) {
$hasStoredKey = true;
break;
}
}
}
if (!$hasStoredKey) {
$this->signer = Activity::get_actor($url);
if (isset($this->signer['assertionMethod'])) {
if (!isset($this->signer['assertionMethod'][0])) {
$this->signer['assertionMethod'] = [$this->signer['assertionMethod']];
}
foreach($this->signer['assertionMethod'] as $am) {
if ($url === $am['controller'] &&
$am['type'] === 'Multikey' &&
str_starts_with($am['publicKeyMultibase'], 'z6Mk')
) {
$publicKey = $am['publicKeyMultibase'];
}
}
}
}
}
if ($publicKey) {
$this->sigok = (new JcsEddsa2022)->verify($this->data, $publicKey);
}
}
}

View File

@@ -2,7 +2,8 @@
namespace Zotlabs\Lib;
use Zotlabs\Lib\Libsync;
use App;
use Zotlabs\Lib\Config;
require_once('include/plugin.php');
require_once('include/channel.php');
@@ -21,9 +22,10 @@ class Apps {
* @brief
*
* @param boolean $translate (optional) default true
* @param boolean $sync (optional) default false used if called from sync_sysapps()
* @return array
*/
static public function get_system_apps($translate = true) {
static public function get_system_apps($translate = true, $sync = false) {
$ret = [];
if(is_dir('apps'))
@@ -33,7 +35,7 @@ class Apps {
if($files) {
foreach($files as $f) {
$x = self::parse_app_description($f,$translate);
$x = self::parse_app_description($f, $translate, $sync);
if($x) {
$ret[] = $x;
}
@@ -45,7 +47,7 @@ class Apps {
$path = explode('/',$f);
$plugin = trim($path[1]);
if(plugin_is_installed($plugin)) {
$x = self::parse_app_description($f,$translate);
$x = self::parse_app_description($f, $translate, $sync);
if($x) {
$x['plugin'] = $plugin;
$ret[] = $x;
@@ -64,19 +66,19 @@ class Apps {
}
static public function get_base_apps() {
$x = get_config('system','base_apps',[
$x = Config::Get('system','base_apps',[
'Connections',
'Contact Roles',
'Network',
'Settings',
'Files',
'Channel Home',
'View Profile',
'Channel',
'Photos',
'Calendar',
'Directory',
'Search',
'Help',
'Profile Photo'
'HQ',
'Post'
]);
/**
@@ -158,7 +160,7 @@ class Apps {
foreach(self::$available_apps as $iapp) {
if($iapp['app_id'] == hash('whirlpool',$app['name'])) {
$notfound = false;
if(($iapp['app_version'] !== $app['version'])
if((isset($app['version']) && $iapp['app_version'] !== $app['version'])
|| ($app['plugin'] && (! $iapp['app_plugin']))) {
return intval($iapp['app_id']);
}
@@ -207,9 +209,10 @@ class Apps {
*
* @param string $f filename
* @param boolean $translate (optional) default true
* @param boolean $sync (optional) default false
* @return boolean|array
*/
static public function parse_app_description($f, $translate = true) {
static public function parse_app_description($f, $translate = true, $sync = false) {
$ret = [];
$matches = [];
@@ -234,6 +237,7 @@ class Apps {
$ret['photo'] = $baseurl . '/' . get_default_profile_photo(80);
$ret['type'] = 'system';
$ret['plugin'] = '';
foreach($ret as $k => $v) {
if(strpos($v,'http') === 0) {
@@ -255,7 +259,7 @@ class Apps {
if(array_key_exists('categories',$ret))
$ret['categories'] = str_replace(array('\'','"'),array('&#39;','&dquot;'),$ret['categories']);
if(array_key_exists('requires',$ret)) {
if(array_key_exists('requires',$ret) && !$sync) {
$requires = explode(',',$ret['requires']);
foreach($requires as $require) {
$require = trim(strtolower($require));
@@ -298,7 +302,7 @@ class Apps {
break;
default:
if($config)
$unset = ((get_config('system', $require[0]) == $require[1]) ? false : true);
$unset = ((Config::Get('system', $require[0]) == $require[1]) ? false : true);
else
$unset = ((local_channel() && feature_enabled(local_channel(),$require)) ? false : true);
if($unset)
@@ -307,14 +311,16 @@ class Apps {
}
}
}
if($ret) {
if($translate)
self::translate_system_apps($ret);
return $ret;
if(empty($ret)) {
return false;
}
return false;
if($translate) {
self::translate_system_apps($ret);
}
return $ret;
}
@@ -335,20 +341,18 @@ class Apps {
'Suggest Channels' => t('Suggest Channels'),
'Login' => t('Login'),
'Channel Manager' => t('Channel Manager'),
'Network' => t('Stream'),
'Network' => t('Network'),
'Settings' => t('Settings'),
'Files' => t('Files'),
'Webpages' => t('Webpages'),
'Wiki' => t('Wiki'),
'Channel Home' => t('Channel Home'),
'Channel' => t('Channel'),
'View Profile' => t('View Profile'),
'Photos' => t('Photos'),
'Calendar' => t('Calendar'),
'Directory' => t('Directory'),
'Help' => t('Help'),
'Mail' => t('Mail'),
'Mood' => t('Mood'),
'Poke' => t('Poke'),
'Chat' => t('Chat'),
'Search' => t('Search'),
'Probe' => t('Probe'),
@@ -371,7 +375,7 @@ class Apps {
'OAuth Apps Manager' => t('OAuth Apps Manager'),
'OAuth2 Apps Manager' => t('OAuth2 Apps Manager'),
'PDL Editor' => t('PDL Editor'),
'Permission Categories' => t('Permission Categories'),
'Contact Roles' => t('Contact Roles'),
'Public Stream' => t('Public Stream'),
'My Chatrooms' => t('My Chatrooms'),
'Channel Export' => t('Channel Export')
@@ -414,15 +418,32 @@ class Apps {
static public function app_render($papp, $mode = 'view') {
$installed = false;
if(! $papp)
if(!$papp) {
return;
}
if(! $papp['photo'])
/**
* @hooks app_render_before
* Hook to manipulate the papp array before rendering
*/
$hookinfo = [
'name' => $papp['name'],
'photo' => $papp['photo']
];
call_hooks('app_render_manipulate_photo', $hookinfo);
// We will only allow to manipulate the photo
$papp['photo'] = $hookinfo['photo'];
if(!$papp['photo']) {
$papp['photo'] = 'icon:gear';
}
self::translate_system_apps($papp);
if(trim($papp['plugin']) && (! plugin_is_installed(trim($papp['plugin']))))
if(isset($papp['plugin']) && trim($papp['plugin']) && (! plugin_is_installed(trim($papp['plugin']))))
return '';
$papp['papp'] = self::papp_encode($papp);
@@ -503,7 +524,7 @@ class Apps {
break;
default:
if($config)
$unset = ((get_config('system', $require[0]) === $require[1]) ? false : true);
$unset = ((Config::Get('system', $require[0]) === $require[1]) ? false : true);
else
$unset = ((local_channel() && feature_enabled(local_channel(),$require)) ? false : true);
if($unset)
@@ -517,14 +538,19 @@ class Apps {
$hosturl = '';
if(local_channel()) {
if(self::app_installed(local_channel(),$papp) && !$papp['deleted'])
if(self::app_installed(local_channel(),$papp)) {
$installed = true;
}
if ($installed && isset($papp['deleted']) && $papp['deleted']) {
$installed = false;
}
$hosturl = z_root() . '/';
}
elseif(remote_channel()) {
$observer = \App::get_observer();
if($observer && $observer['xchan_network'] === 'zot') {
if($observer && $observer['xchan_network'] === 'zot6') {
// some folks might have xchan_url redirected offsite, use the connurl
$x = parse_url($observer['xchan_connurl']);
if($x) {
@@ -536,13 +562,47 @@ class Apps {
$install_action = (($installed) ? t('Update') : t('Install'));
$icon = ((strpos($papp['photo'],'icon:') === 0) ? substr($papp['photo'],5) : '');
if (!$installed && $mode === 'module') {
$_SESSION['return_url'] = App::$query_string;
return replace_macros(get_markup_template('app_install.tpl'), [
'$papp' => $papp,
'$install' => $install_action
]);
}
if($mode === 'navbar') {
return replace_macros(get_markup_template('app_nav_pinned.tpl'),array(
'$app' => $papp,
'$icon' => $icon,
));
}
if($mode === 'nav') {
return replace_macros(get_markup_template('app_nav.tpl'),array(
'$app' => $papp,
'$icon' => $icon,
));
}
if($mode === 'inline') {
return replace_macros(get_markup_template('app_inline.tpl'),array(
'$app' => $papp,
'$icon' => $icon,
'$installed' => $installed,
'$purchase' => ((isset($papp['page']) && (! $installed)) ? t('Purchase') : ''),
'$action_label' => $install_action
));
}
if(in_array($mode, ['nav-order', 'nav-order-pinned'])) {
return replace_macros(get_markup_template('app_order.tpl'),array(
'$app' => $papp,
'$icon' => $icon,
'$hosturl' => $hosturl,
'$mode' => $mode
));
}
if($mode === 'install') {
$papp['embed'] = true;
}
@@ -551,20 +611,18 @@ class Apps {
'$app' => $papp,
'$icon' => $icon,
'$hosturl' => $hosturl,
'$purchase' => (($papp['page'] && (! $installed)) ? t('Purchase') : ''),
'$purchase' => ((isset($papp['page']) && (! $installed)) ? t('Purchase') : ''),
'$installed' => $installed,
'$action_label' => (($hosturl && in_array($mode, ['view','install'])) ? $install_action : ''),
'$edit' => ((local_channel() && $installed && $mode == 'edit') ? t('Edit') : ''),
'$delete' => ((local_channel() && $mode == 'edit') ? t('Delete') : ''),
'$undelete' => ((local_channel() && $mode == 'edit') ? t('Undelete') : ''),
'$settings_url' => ((local_channel() && $installed && $mode == 'list') ? $papp['settings_url'] : ''),
'$deleted' => $papp['deleted'],
'$feature' => (($papp['embed'] || $mode == 'edit') ? false : true),
'$pin' => (($papp['embed'] || $mode == 'edit') ? false : true),
'$featured' => ((strpos($papp['categories'], 'nav_featured_app') === false) ? false : true),
'$pinned' => ((strpos($papp['categories'], 'nav_pinned_app') === false) ? false : true),
'$navapps' => (($mode == 'nav') ? true : false),
'$order' => (($mode === 'nav-order' || $mode === 'nav-order-pinned') ? true : false),
'$settings_url' => ((local_channel() && $installed && $mode == 'list' && isset($papp['settings_url'])) ? $papp['settings_url'] : ''),
'$deleted' => $papp['deleted'] ?? false,
'$feature' => ((isset($papp['embed']) || $mode == 'edit') ? false : true),
'$pin' => ((isset($papp['embed']) || $mode == 'edit') ? false : true),
'$featured' => ((isset($papp['categories']) && strpos($papp['categories'], 'nav_featured_app') !== false) ? true : false),
'$pinned' => ((isset($papp['categories']) && strpos($papp['categories'], 'nav_pinned_app') !== false) ? true : false),
'$mode' => $mode,
'$add' => t('Add to app-tray'),
'$remove' => t('Remove from app-tray'),
@@ -574,6 +632,7 @@ class Apps {
));
}
static public function app_install($uid,$app) {
if(! is_array($app)) {
@@ -588,10 +647,12 @@ class Apps {
$app['uid'] = $uid;
if(self::app_installed($uid,$app,true))
if(self::app_installed($uid,$app,true)) {
$x = self::app_update($app);
else
}
else {
$x = self::app_store($app);
}
if($x['success']) {
$r = q("select * from app where app_id = '%s' and app_channel = %d limit 1",
@@ -599,13 +660,12 @@ class Apps {
intval($uid)
);
if($r) {
if(($app['uid']) && (! $r[0]['app_system'])) {
if($app['categories'] && (! $app['term'])) {
if($app['uid']) {
if((isset($app['categories']) && $app['categories']) && !(isset($app['term']) && $app['term'])) {
$r[0]['term'] = q("select * from term where otype = %d and oid = %d",
intval(TERM_OBJ_APP),
intval($r[0]['id'])
);
Libsync::build_sync_packet($uid,array('app' => $r[0]));
}
}
}
@@ -634,6 +694,7 @@ class Apps {
}
}
}
return true;
}
@@ -645,38 +706,35 @@ class Apps {
dbesc($app['guid']),
intval($uid)
);
if($x) {
if(! intval($x[0]['app_deleted'])) {
$x[0]['app_deleted'] = 1;
if(self::can_delete($uid,$app)) {
q("delete from app where app_id = '%s' and app_channel = %d",
dbesc($app['guid']),
intval($uid)
);
q("delete from term where otype = %d and oid = %d",
intval(TERM_OBJ_APP),
intval($x[0]['id'])
);
/**
* @hooks app_destroy
* Called after app entry got removed from database
* and provide app array from database.
*/
call_hooks('app_destroy', $x[0]);
}
else {
q("update app set app_deleted = 1 where app_id = '%s' and app_channel = %d",
dbesc($app['guid']),
intval($uid)
);
}
if(! intval($x[0]['app_system'])) {
Libsync::build_sync_packet($uid,array('app' => $x));
}
}
else {
self::app_undestroy($uid,$app);
}
if($x && intval($x[0]['app_deleted'])) {
self::app_undestroy($uid, $app);
return;
}
if(self::can_delete($uid,$app)) {
q("delete from app where app_id = '%s' and app_channel = %d",
dbesc($app['guid']),
intval($uid)
);
q("delete from term where otype = %d and oid = %d",
intval(TERM_OBJ_APP),
intval($x[0]['id'])
);
/**
* @hooks app_destroy
* Called after app entry got removed from database
* and provide app array from database.
*/
call_hooks('app_destroy', $x[0]);
}
else {
q("update app set app_deleted = 1 where app_id = '%s' and app_channel = %d",
dbesc($app['guid']),
intval($uid)
);
}
}
}
@@ -693,13 +751,11 @@ class Apps {
dbesc($app['guid']),
intval($uid)
);
if($x) {
if($x[0]['app_system']) {
q("update app set app_deleted = 0 where app_id = '%s' and app_channel = %d",
dbesc($app['guid']),
intval($uid)
);
}
if($x && intval($x[0]['app_deleted']) && $x[0]['app_system']) {
q("update app set app_deleted = 0 where app_id = '%s' and app_channel = %d",
dbesc($app['guid']),
intval($uid)
);
}
}
}
@@ -905,7 +961,7 @@ class Apps {
$conf = (($menu === 'nav_featured_app') ? 'app_order' : 'app_pin_order');
$x = (($uid) ? get_pconfig($uid,'system',$conf) : get_config('system',$conf));
$x = (($uid) ? get_pconfig($uid,'system',$conf) : Config::Get('system',$conf));
if(($x) && (! is_array($x))) {
$y = explode(',',$x);
$y = array_map('trim',$y);
@@ -972,12 +1028,7 @@ class Apps {
if(! $syslist)
return;
foreach($syslist as $k => $li) {
if($li['guid'] === $guid) {
$position = $k;
break;
}
}
$position = array_find_key($syslist, fn ($v) => $v['guid'] === $guid);
if(! $position)
return;
@@ -1026,12 +1077,7 @@ class Apps {
if(! $syslist)
return;
foreach($syslist as $k => $li) {
if($li['guid'] === $guid) {
$position = $k;
break;
}
}
$position = array_find_key($syslist, fn ($v) => $v['guid'] === $guid);
if($position >= count($syslist) - 1)
return;
@@ -1150,7 +1196,7 @@ class Apps {
$ret['success'] = true;
$ret['app_id'] = $darray['app_id'];
}
if($arr['categories']) {
if(isset($arr['categories']) && $arr['categories']) {
$x = q("select id from app where app_id = '%s' and app_channel = %d limit 1",
dbesc($darray['app_id']),
intval($darray['app_channel'])
@@ -1158,9 +1204,9 @@ class Apps {
$y = explode(',',$arr['categories']);
if($y) {
foreach($y as $t) {
$t = trim($t);
$t = escape_tags(trim($t));
if($t) {
store_item_tag($darray['app_channel'],$x[0]['id'],TERM_OBJ_APP,TERM_CATEGORY,escape_tags($t),escape_tags(z_root() . '/apps/?f=&cat=' . escape_tags($t)));
store_item_tag($darray['app_channel'], $x[0]['id'], TERM_OBJ_APP, TERM_CATEGORY, $t, z_root() . '/apps/?f=&cat=' . $t);
}
}
}
@@ -1248,7 +1294,7 @@ class Apps {
intval(TERM_OBJ_APP),
intval($x[0]['id'])
);
if($arr['categories']) {
if(isset($arr['categories']) && $arr['categories']) {
$y = explode(',',$arr['categories']);
if($y) {
foreach($y as $t) {
@@ -1276,58 +1322,58 @@ class Apps {
$ret['type'] = 'personal';
if($app['app_id'])
if(!empty($app['app_id']))
$ret['guid'] = $app['app_id'];
if($app['app_sig'])
if(!empty($app['app_sig']))
$ret['sig'] = $app['app_sig'];
if($app['app_author'])
if(!empty($app['app_author']))
$ret['author'] = $app['app_author'];
if($app['app_name'])
if(!empty($app['app_name']))
$ret['name'] = $app['app_name'];
if($app['app_desc'])
if(!empty($app['app_desc']))
$ret['desc'] = $app['app_desc'];
if($app['app_url'])
if(!empty($app['app_url']))
$ret['url'] = $app['app_url'];
if($app['app_photo'])
if(!empty($app['app_photo']))
$ret['photo'] = $app['app_photo'];
if($app['app_icon'])
if(!empty($app['app_icon']))
$ret['icon'] = $app['app_icon'];
if($app['app_version'])
if(!empty($app['app_version']))
$ret['version'] = $app['app_version'];
if($app['app_addr'])
if(!empty($app['app_addr']))
$ret['addr'] = $app['app_addr'];
if($app['app_price'])
if(!empty($app['app_price']))
$ret['price'] = $app['app_price'];
if($app['app_page'])
if(!empty($app['app_page']))
$ret['page'] = $app['app_page'];
if($app['app_requires'])
if(!empty($app['app_requires']))
$ret['requires'] = $app['app_requires'];
if($app['app_system'])
if(!empty($app['app_system']))
$ret['system'] = $app['app_system'];
if($app['app_options'])
if(!empty($app['app_options']))
$ret['options'] = $app['app_options'];
if($app['app_plugin'])
if(!empty($app['app_plugin']))
$ret['plugin'] = trim($app['app_plugin']);
if($app['app_deleted'])
if(!empty($app['app_deleted']))
$ret['deleted'] = $app['app_deleted'];
if($app['term']) {
if(!empty($app['term']) && is_array($app['term'])) {
$s = '';
foreach($app['term'] as $t) {
if($s)
@@ -1356,4 +1402,17 @@ class Apps {
return chunk_split(base64_encode(json_encode($papp)),72,"\n");
}
static public function get_papp($app) {
$r = q("select * from app where app_id = '%s' and app_channel = 0 limit 1",
dbesc(hash('whirlpool', $app))
);
if ($r) {
$papp = self::app_encode($r[0]);
return $papp;
}
return false;
}
}

View File

@@ -0,0 +1,80 @@
<?php
namespace Zotlabs\Lib;
use Zotlabs\ActivityStreams\UnhandledElementException;
class BaseObject
{
public $string;
public $ldContext;
/**
* @param $input
* @param $strict
* @throws UnhandledElementException if $strict
*/
public function __construct($input = null, $strict = false)
{
if (isset($input)) {
if (is_string($input)) {
$this->string = $input;
}
elseif(is_array($input)) {
foreach ($input as $key => $value) {
$key = ($key === '@context') ? 'ldContext' : $key;
if ($strict && !property_exists($this, $key)) {
throw new UnhandledElementException("Unhandled element: $key");
}
$this->{$key} = $value;
}
}
}
return $this;
}
public function getDataType($element, $object = null)
{
$object = $object ?? $this;
$type = gettype($object[$element]);
if ($type === 'array' && array_is_list($object[$element])) {
return 'list';
}
return $type;
}
public function toArray()
{
if ($this->string) {
return $this->string;
}
$returnValue = [];
foreach ((array) $this as $key => $value) {
if (isset($value)) {
$key = ($key === 'ldContext') ? '@context' : $key;
$returnValue[$key] = (($value instanceof BaseObject) ? $value->toArray() : $value);
}
}
return $returnValue;
}
/**
* @return mixed
*/
public function getLdContext()
{
return $this->ldContext;
}
/**
* @param mixed $ldContext
* @return BaseObject
*/
public function setLdContext($ldContext)
{
$this->ldContext = $ldContext;
return $this;
}
}

View File

@@ -2,53 +2,56 @@
namespace Zotlabs\Lib;
/**
* cache api
*/
use Zotlabs\Lib\Config;
/**
* cache api
*/
class Cache {
/**
* @brief Returns cached content
*
*
* @param string $key
* @param string $age in SQL format, default is '30 DAY'
* @return string
*/
public static function get($key, $age = '') {
$hash = hash('whirlpool',$key);
public static function get($key, $age = '') {
// $hash = hash('whirlpool',$key);
$hash = uuid_from_url($key);
$r = q("SELECT v FROM cache WHERE k = '%s' AND updated > %s - INTERVAL %s LIMIT 1",
dbesc($hash),
db_utcnow(),
db_quoteinterval(($age ? $age : get_config('system','object_cache_days', '30') . ' DAY'))
db_quoteinterval(($age ? $age : Config::Get('system','object_cache_days', '30') . ' DAY'))
);
if ($r)
return $r[0]['v'];
return null;
}
public static function set($key,$value) {
// $hash = hash('whirlpool',$key);
$hash = uuid_from_url($key);
$hash = hash('whirlpool',$key);
$r = q("SELECT * FROM cache WHERE k = '%s' limit 1",
$r = q("SELECT * FROM cache WHERE k = '%s' LIMIT 1",
dbesc($hash)
);
if($r) {
q("UPDATE cache SET v = '%s', updated = '%s' WHERE k = '%s'",
dbesc($value),
dbesc(datetime_convert()),
dbesc($hash));
dbesc($hash)
);
}
else {
q("INSERT INTO cache ( k, v, updated) VALUES ('%s','%s','%s')",
q("INSERT INTO cache (k, v, updated) VALUES ('%s', '%s', '%s')",
dbesc($hash),
dbesc($value),
dbesc(datetime_convert()));
dbesc(datetime_convert())
);
}
}
}

View File

@@ -181,7 +181,7 @@ class Chatroom {
}
function leave($observer_xchan, $room_id, $client) {
public static function leave($observer_xchan, $room_id, $client) {
if(! $room_id || ! $observer_xchan)
return;

View File

@@ -2,6 +2,7 @@
namespace Zotlabs\Lib;
use App;
class Config {
@@ -14,20 +15,41 @@ class Config {
* @param string $family
* The category of the configuration value
*/
static public function Load($family) {
if(! array_key_exists($family, \App::$config))
\App::$config[$family] = array();
public static function Load($family, $recursionCounter = 0) {
if (! array_key_exists($family, App::$config)) {
App::$config[$family] = [];
}
if(! array_key_exists('config_loaded', \App::$config[$family])) {
// We typically continue when presented with minor DB issues,
// but loading the site configuration is more important.
// Check for query returning false and give it approx 30 seconds
// to recover if there's a problem. This is intended to fix a
// rare issue on Galera where temporary sync issues were causing
// the site encryption keys to be regenerated, which was causing
// communication issues for members.
// This code probably belongs at the database layer, but we don't
// necessarily want to shut the site down for problematic queries
// caused by bad data. That could be used in a denial of service
// attack. Those do need to be (and they are) logged.
if (! array_key_exists('config_loaded', App::$config[$family])) {
$r = q("SELECT * FROM config WHERE cat = '%s'", dbesc($family));
if($r !== false) {
if($r) {
foreach($r as $rr) {
$k = $rr['k'];
\App::$config[$family][$k] = $rr['v'];
}
if ($r === false && !App::$install) {
sleep(3);
$recursionCounter ++;
if ($recursionCounter > 10) {
system_unavailable();
}
\App::$config[$family]['config_loaded'] = true;
self::Load($family, $recursionCounter);
}
elseif (is_array($r)) {
foreach ($r as $rr) {
$k = $rr['k'];
App::$config[$family][$k] = $rr['v'];
}
App::$config[$family]['config_loaded'] = true;
}
}
}
@@ -46,19 +68,19 @@ class Config {
* @return mixed
* Return the set value, or false if the database update failed
*/
static public function Set($family, $key, $value) {
public static function Set($family, $key, $value) {
// manage array value
$dbvalue = ((is_array($value)) ? serialize($value) : $value);
$dbvalue = ((is_array($value)) ? 'json:' . json_encode($value) : $value);
$dbvalue = ((is_bool($dbvalue)) ? intval($dbvalue) : $dbvalue);
if(self::Get($family, $key) === false || (! self::get_from_storage($family, $key))) {
if (self::Get($family, $key) === false || (! self::get_from_storage($family, $key))) {
$ret = q("INSERT INTO config ( cat, k, v ) VALUES ( '%s', '%s', '%s' ) ",
dbesc($family),
dbesc($key),
dbesc($dbvalue)
);
if($ret) {
\App::$config[$family][$key] = $value;
if ($ret) {
App::$config[$family][$key] = $value;
$ret = $value;
}
return $ret;
@@ -70,8 +92,8 @@ class Config {
dbesc($key)
);
if($ret) {
\App::$config[$family][$key] = $value;
if ($ret) {
App::$config[$family][$key] = $value;
$ret = $value;
}
@@ -93,21 +115,37 @@ class Config {
* The category of the configuration value
* @param string $key
* The configuration key to query
* @param string $default (optional) default false
* @param mixed $default (optional) default false
* @return mixed Return value or false on error or if not set
*/
static public function Get($family, $key, $default = false) {
if((! array_key_exists($family, \App::$config)) || (! array_key_exists('config_loaded', \App::$config[$family])))
self::Load($family);
public static function Get($family, $key, $default = false) {
if(array_key_exists('config_loaded', \App::$config[$family])) {
if(! array_key_exists($key, \App::$config[$family])) {
if ((! array_key_exists($family, App::$config)) || (! array_key_exists('config_loaded', App::$config[$family]))) {
self::Load($family);
}
if (array_key_exists('config_loaded', App::$config[$family])) {
if (! array_key_exists($key, App::$config[$family])) {
return $default;
}
return ((! is_array(\App::$config[$family][$key])) && (preg_match('|^a:[0-9]+:{.*}$|s', \App::$config[$family][$key]))
? unserialize(\App::$config[$family][$key])
: \App::$config[$family][$key]
);
$value = App::$config[$family][$key];
if (! is_array($value)) {
if (str_starts_with($value, 'json:')) {
return json_unserialize($value);
} else if (preg_match('|^a:[0-9]+:{.*}$|s', $value)) {
// Unserialize in inherently unsafe. Try to mitigate by not
// allowing unserializing objects. Only kept for backwards
// compatibility. JSON serialization should be prefered.
return unserialize($value, array('allowed_classes' => false));
} else {
return $value;
}
}
else {
return $value;
}
}
return $default;
@@ -125,12 +163,13 @@ class Config {
* The configuration key to delete
* @return mixed
*/
static public function Delete($family, $key) {
public static function Delete($family, $key) {
$ret = false;
if(array_key_exists($family, \App::$config) && array_key_exists($key, \App::$config[$family]))
unset(\App::$config[$family][$key]);
if (array_key_exists($family, App::$config) && array_key_exists($key, App::$config[$family])) {
unset(App::$config[$family][$key]);
}
$ret = q("DELETE FROM config WHERE cat = '%s' AND k = '%s'",
dbesc($family),
@@ -153,7 +192,7 @@ class Config {
* The configuration key to query
* @return mixed
*/
static private function get_from_storage($family,$key) {
private static function get_from_storage($family, $key) {
$ret = q("SELECT * FROM config WHERE cat = '%s' AND k = '%s' LIMIT 1",
dbesc($family),
dbesc($key)
@@ -161,5 +200,4 @@ class Config {
return $ret;
}
}

View File

@@ -5,8 +5,7 @@ namespace Zotlabs\Lib;
use App;
use Zotlabs\Access\Permissions;
use Zotlabs\Daemon\Master;
use Zotlabs\Lib\Config;
class Connect {
@@ -25,10 +24,16 @@ class Connect {
$uid = $channel['channel_id'];
if (strpos($url,'@') === false && strpos($url,'/') === false) {
// If we get just a channel name and it is not an URL turn it into a local webbie
if (!str_contains($url, '@') && strpos($url,'/') === false) {
$url = $url . '@' . App::get_hostname();
}
// Remove a possible leading @
if (str_starts_with($url, '@')) {
$url = ltrim($url, '@');
}
$result = [ 'success' => false, 'message' => '' ];
$my_perms = false;
@@ -69,7 +74,8 @@ class Connect {
$xchan_hash = '';
$sql_options = (($protocol) ? " and xchan_network = '" . dbesc($protocol) . "' " : '');
$r = q("select * from xchan where ( xchan_hash = '%s' or xchan_url = '%s' or xchan_addr = '%s') $sql_options ",
// We need both, the xchan and the hubloc here hence use JOIN instead of LEFT JOIN
$r = q("SELECT * FROM xchan JOIN hubloc ON xchan_hash = hubloc_hash WHERE ( xchan_hash = '%s' or xchan_url = '%s' or xchan_addr = '%s') $sql_options ORDER BY hubloc_id DESC",
dbesc($url),
dbesc($url),
dbesc($url)
@@ -80,12 +86,13 @@ class Connect {
// reset results to the best record or the first if we don't have the best
// note: this is a single record and not an array of results
$r = Libzot::zot_record_preferred($r,'xchan_network');
$r = Libzot::zot_record_preferred($r, 'xchan_network');
}
$singleton = false;
$d = false;
$wf = false;
if (! $r) {
@@ -94,7 +101,7 @@ class Connect {
$wf = discover_by_webbie($url,$protocol);
if (! $wf) {
$feeds = get_config('system','feed_contacts');
$feeds = Config::Get('system','feed_contacts');
if (($feeds) && (in_array($protocol, [ '', 'feed', 'rss' ]))) {
$d = discover_by_url($url);
@@ -108,10 +115,12 @@ class Connect {
if ($wf || $d) {
$xchan_hash = (($wf) ? $wf : $url);
// something was discovered - find the record which was just created.
$r = q("select * from xchan where ( xchan_hash = '%s' or xchan_url = '%s' or xchan_addr = '%s' ) $sql_options",
dbesc(($wf) ? $wf : $url),
dbesc($xchan_hash),
dbesc($url),
dbesc($url)
);
@@ -119,7 +128,7 @@ class Connect {
// convert to a single record (once again preferring a zot solution in the case of multiples)
if ($r) {
$r = Libzot::zot_record_preferred($r,'xchan_network');
$r = Libzot::zot_record_preferred($r, 'xchan_network');
}
}
@@ -146,7 +155,7 @@ class Connect {
}
$allowed = ((in_array($xchan['xchan_network'],['rss','zot','zot6'])) ? 1 : 0);
$allowed = ((in_array($xchan['xchan_network'],['rss', 'zot6'])) ? 1 : 0);
$hookdata = ['channel_id' => $uid, 'follow_address' => $url, 'xchan' => $xchan, 'allowed' => $allowed, 'singleton' => 0];
call_hooks('follow_allow',$hookdata);
@@ -207,13 +216,13 @@ class Connect {
}
$my_perms = $p['perms'];
$profile_assign = get_pconfig($uid,'system','profile_assign','');
// See if we are already connected by virtue of having an abook record
$r = q("select abook_id, abook_xchan, abook_pending, abook_instance from abook
$r = q("select abook_id, abook_xchan, abook_pending, abook_instance from abook
where abook_xchan = '%s' and abook_channel = %d limit 1",
dbesc($xchan_hash),
intval($uid)
@@ -261,7 +270,8 @@ class Connect {
'abook_feed' => intval(($xchan['xchan_network'] === 'rss') ? 1 : 0),
'abook_created' => datetime_convert(),
'abook_updated' => datetime_convert(),
'abook_instance' => (($singleton) ? z_root() : '')
'abook_instance' => (($singleton) ? z_root() : ''),
'abook_role' => get_pconfig($uid, 'system', 'default_permcat', 'default')
]
);
}
@@ -282,7 +292,7 @@ class Connect {
// fetch the entire record
$r = q("select abook.*, xchan.* from abook left join xchan on abook_xchan = xchan_hash
$r = q("select abook.*, xchan.* from abook left join xchan on abook_xchan = xchan_hash
where abook_xchan = '%s' and abook_channel = %d limit 1",
dbesc($xchan_hash),
intval($uid)
@@ -300,7 +310,7 @@ class Connect {
/** If there is a default group for this channel, add this connection to it */
if ($default_group) {
$g = AccessList::rec_byhash($uid,$default_group);
$g = AccessList::by_hash($uid,$default_group);
if ($g) {
AccessList::member_add($uid,'',$xchan_hash,$g['id']);
}

211
Zotlabs/Lib/Crypto.php Normal file
View File

@@ -0,0 +1,211 @@
<?php
namespace Zotlabs\Lib;
use Exception;
use Zotlabs\Lib\Config;
class Crypto {
public static $openssl_algorithms = [
// zot6 nickname, opensslname, keylength, ivlength
['aes256ctr', 'aes-256-ctr', 32, 16],
['camellia256cfb', 'camellia-256-cfb', 32, 16],
['cast5cfb', 'cast5-cfb', 16, 8],
['aes256cbc', 'aes-256-cbc', 32, 16] // remove after legacy zot has been sunset
];
public static function methods() {
$ret = [];
foreach (self::$openssl_algorithms as $ossl) {
$ret[] = $ossl[0] . '.oaep';
}
call_hooks('crypto_methods', $ret);
return $ret;
}
public static function signing_methods() {
$ret = ['sha256'];
call_hooks('signing_methods', $ret);
return $ret;
}
public static function new_keypair($bits) {
$openssl_options = [
'digest_alg' => 'sha1',
'private_key_bits' => $bits,
'encrypt_key' => false
];
$conf = Config::Get('system', 'openssl_conf_file');
if ($conf) {
$openssl_options['config'] = $conf;
}
$result = openssl_pkey_new($openssl_options);
if (empty($result)) {
return false;
}
// Get private key
$response = ['prvkey' => '', 'pubkey' => ''];
openssl_pkey_export($result, $response['prvkey']);
// Get public key
$pkey = openssl_pkey_get_details($result);
$response['pubkey'] = $pkey["key"];
return $response;
}
public static function sign($data, $key, $alg = 'sha256') {
if (!$key) {
return false;
}
$sig = '';
openssl_sign($data, $sig, $key, $alg);
return $sig;
}
public static function verify($data, $sig, $key, $alg = 'sha256') {
if (!$key) {
return false;
}
if (!$alg) {
$alg = 'sha256';
}
try {
$verify = openssl_verify($data, $sig, $key, $alg);
} catch (Exception $e) {
$verify = (-1);
}
if ($verify === (-1)) {
while ($msg = openssl_error_string()) {
logger('openssl_verify: ' . $msg, LOGGER_NORMAL, LOG_ERR);
}
btlogger('openssl_verify: key: ' . $key, LOGGER_DEBUG, LOG_ERR);
}
return (($verify > 0) ? true : false);
}
public static function encapsulate($data, $pubkey, $alg) {
if (!($alg && $pubkey)) {
return $data;
}
$alg_base = $alg;
$padding = OPENSSL_PKCS1_PADDING;
$exts = explode('.', $alg);
if (count($exts) > 1) {
switch ($exts[1]) {
case 'oaep':
$padding = OPENSSL_PKCS1_OAEP_PADDING;
break;
default:
break;
}
$alg_base = $exts[0];
}
$method = null;
foreach (self::$openssl_algorithms as $ossl) {
if ($ossl[0] === $alg_base) {
$method = $ossl;
break;
}
}
if ($method) {
$result = ['encrypted' => true];
$key = openssl_random_pseudo_bytes(256);
$iv = openssl_random_pseudo_bytes(256);
$key1 = substr($key, 0, $method[2]);
$iv1 = substr($iv, 0, $method[3]);
$result['data'] = base64url_encode(openssl_encrypt($data, $method[1], $key1, OPENSSL_RAW_DATA, $iv1), true);
openssl_public_encrypt($key, $k, $pubkey, $padding);
openssl_public_encrypt($iv, $i, $pubkey, $padding);
$result['alg'] = $alg;
$result['key'] = base64url_encode($k, true);
$result['iv'] = base64url_encode($i, true);
return $result;
}
else {
$x = ['data' => $data, 'pubkey' => $pubkey, 'alg' => $alg, 'result' => $data];
call_hooks('crypto_encapsulate', $x);
return $x['result'];
}
}
public static function unencapsulate($data, $prvkey) {
if (!(is_array($data) && array_key_exists('encrypted', $data) && array_key_exists('alg', $data) && $data['alg'])) {
logger('not encrypted');
return $data;
}
$alg_base = $data['alg'];
$padding = OPENSSL_PKCS1_PADDING;
$exts = explode('.', $data['alg']);
if (count($exts) > 1) {
switch ($exts[1]) {
case 'oaep':
$padding = OPENSSL_PKCS1_OAEP_PADDING;
break;
default:
break;
}
$alg_base = $exts[0];
}
$method = null;
foreach (self::$openssl_algorithms as $ossl) {
if ($ossl[0] === $alg_base) {
$method = $ossl;
break;
}
}
if ($method) {
openssl_private_decrypt(base64url_decode($data['key']), $k, $prvkey, $padding);
openssl_private_decrypt(base64url_decode($data['iv']), $i, $prvkey, $padding);
return openssl_decrypt(base64url_decode($data['data']), $method[1], substr($k, 0, $method[2]), OPENSSL_RAW_DATA, substr($i, 0, $method[3]));
}
else {
$x = ['data' => $data, 'prvkey' => $prvkey, 'alg' => $data['alg'], 'result' => $data];
call_hooks('crypto_unencapsulate', $x);
return $x['result'];
}
}
}

View File

@@ -1,21 +1,39 @@
<?php
/**
* A class to handle database schema upgrades.
*
* SPDX-FileCopyrightText: 2024 Hubzilla Community
* SPDX-FileContributor: Harald Eilertsen
*
* SPDX-License-Identifier: MIT
*/
namespace Zotlabs\Lib;
use Zotlabs\Lib\Config;
/**
* Upgrade the database schema if necessary.
*
* Compares the currently active database schema version with the version
* required for this version of Hubzilla, and performs the upgrade if needed.
*
* If the difference consists of more than one revision of the schema, each of
* the intermediate upgrades are performed in turn.
*/
class DB_Upgrade {
public $config_name = '';
public $func_prefix = '';
/**
* Check the installed and required schema versions and perform the upgrade
* if necessary.
*
* @param int $db_version The required DB schema version.
*/
public static function run(int $db_revision): void {
function __construct($db_revision) {
$this->config_name = 'db_version';
$this->func_prefix = '_';
$build = get_config('system', 'db_version', 0);
$build = Config::Get('system', 'db_version', 0);
if(! intval($build))
$build = set_config('system', 'db_version', $db_revision);
$build = Config::Set('system', 'db_version', $db_revision);
if($build == $db_revision) {
// Nothing to be done.
@@ -27,7 +45,7 @@ class DB_Upgrade {
logger('Critical: check_config unable to determine database schema version');
return;
}
$current = intval($db_revision);
if($stored < $current) {
@@ -38,7 +56,7 @@ class DB_Upgrade {
for($x = $stored + 1; $x <= $current; $x ++) {
$s = '_' . $x;
$cls = '\\Zotlabs\Update\\' . $s ;
if(! class_exists($cls)) {
if(! class_exists($cls)) {
return;
}
@@ -52,10 +70,10 @@ class DB_Upgrade {
Config::Load('database');
if(get_config('database', $s))
if(Config::Get('database', $s))
break;
set_config('database',$s, '1');
Config::Set('database',$s, '1');
$c = new $cls();
@@ -65,10 +83,10 @@ class DB_Upgrade {
$source = t('Source code of failed update: ') . "\n\n" . @file_get_contents('Zotlabs/Update/' . $s . '.php');
// Prevent sending hundreds of thousands of emails by creating
// a lockfile.
// a lockfile.
$lockfile = 'store/[data]/mailsent';
@@ -77,7 +95,7 @@ class DB_Upgrade {
@unlink($lockfile);
//send the administrator an e-mail
file_put_contents($lockfile, $x);
$r = q("select account_language from account where account_email = '%s' limit 1",
dbesc(\App::$config['system']['admin_email'])
);
@@ -86,7 +104,7 @@ class DB_Upgrade {
[
'toEmail' => \App::$config['system']['admin_email'],
'messageSubject' => sprintf( t('Update Error at %s'), z_root()),
'textVersion' => replace_macros(get_intltext_template('update_fail_eml.tpl'),
'textVersion' => replace_macros(get_intltext_template('update_fail_eml.tpl'),
[
'$sitename' => \App::$config['system']['sitename'],
'$siteurl' => z_root(),
@@ -104,11 +122,11 @@ class DB_Upgrade {
pop_lang();
}
else {
set_config('database',$s, 'success');
Config::Set('database',$s, 'success');
}
}
}
set_config('system', 'db_version', $db_revision);
Config::Set('system', 'db_version', $db_revision);
}
}
}
}

View File

@@ -1,28 +1,33 @@
<?php
namespace Zotlabs\Lib;
use Zotlabs\Lib\Config;
class DReport {
private $location;
private $sender;
private $recipient;
private $name;
private $message_id;
private $message_uuid;
private $status;
private $date;
function __construct($location,$sender,$recipient,$message_id,$status = 'deliver') {
$this->location = $location;
$this->sender = $sender;
$this->recipient = $recipient;
$this->name = EMPTY_STR;
$this->message_id = $message_id;
$this->status = $status;
$this->date = datetime_convert();
function __construct($location, $sender, $recipient, $message_id, $message_uuid = '', $status = 'deliver') {
$this->location = $location;
$this->sender = $sender;
$this->recipient = $recipient;
$this->name = EMPTY_STR;
$this->message_id = $message_id;
$this->message_uuid = $message_uuid;
$this->status = $status;
$this->date = datetime_convert();
}
function update($status) {
$this->status = $status;
$this->date = datetime_convert();
$this->status = $status;
$this->date = datetime_convert();
}
function set_name($name) {
@@ -30,29 +35,31 @@ class DReport {
}
function addto_update($status) {
$this->status = $this->status . ' ' . $status;
$this->status = $this->status . ', ' . $status;
}
function set($arr) {
$this->location = $arr['location'];
$this->sender = $arr['sender'];
$this->recipient = $arr['recipient'];
$this->name = $arr['name'];
$this->message_id = $arr['message_id'];
$this->status = $arr['status'];
$this->date = $arr['date'];
$this->location = $arr['location'];
$this->sender = $arr['sender'];
$this->recipient = $arr['recipient'];
$this->name = $arr['name'];
$this->message_id = $arr['message_id'];
$this->message_uuid = $arr['message_uuid'] ?? '';
$this->status = $arr['status'];
$this->date = $arr['date'];
}
function get() {
return array(
'location' => $this->location,
'sender' => $this->sender,
'recipient' => $this->recipient,
'name' => $this->name,
'message_id' => $this->message_id,
'status' => $this->status,
'date' => $this->date
'location' => $this->location,
'sender' => $this->sender,
'recipient' => $this->recipient,
'name' => $this->name,
'message_id' => $this->message_id,
'message_uuid' => $this->message_uuid,
'status' => $this->status,
'date' => $this->date
);
}
@@ -65,7 +72,7 @@ class DReport {
static function is_storable($dr) {
if(get_config('system', 'disable_dreport'))
if(Config::Get('system', 'disable_dreport'))
return false;
/**
@@ -82,32 +89,24 @@ class DReport {
if(array_key_exists('reject',$dr) && intval($dr['reject']))
return false;
if(! ($dr['sender']))
if (!$dr['sender']) {
return false;
}
// do not store dismissed create activities
if ($dr['status'] === 'not a collection activity') {
return false;
}
// Is the sender one of our channels?
$c = q("select channel_id from channel where channel_hash = '%s' or channel_portable_id = '%s' limit 1",
dbesc($dr['sender']),
$c = q("select channel_id from channel where channel_hash = '%s' limit 1",
dbesc($dr['sender'])
);
if(! $c)
return false;
// legacy zot recipients add a space and their name to the xchan. remove it if true.
$legacy_recipient = strpos($dr['recipient'], ' ');
if($legacy_recipient !== false) {
$legacy_recipient_parts = explode(' ', $dr['recipient'], 2);
$rxchan = $legacy_recipient_parts[0];
}
else {
$rxchan = $dr['recipient'];
}
// is the recipient one of our connections, or do we want to store every report?
$pcf = get_pconfig($c[0]['channel_id'],'system','dreport_store_all');
@@ -118,7 +117,7 @@ class DReport {
// So if a remote site says they can't find us, that's no big surprise
// and just creates a lot of extra report noise
if(($dr['location'] !== z_root()) && ($dr['sender'] === $rxchan) && ($dr['status'] === 'recipient not found'))
if(($dr['location'] !== z_root()) && ($dr['sender'] === $dr['recipient']) && ($dr['status'] === 'recipient not found'))
return false;
// If you have a private post with a recipient list, every single site is going to report
@@ -127,14 +126,14 @@ class DReport {
// have a channel on that site.
$r = q("select hubloc_id from hubloc where hubloc_hash = '%s' and hubloc_url = '%s'",
dbesc($rxchan),
dbesc($dr['recipient']),
dbesc($dr['location'])
);
if((! $r) && ($dr['status'] === 'recipient_not_found'))
return false;
$r = q("select abook_id from abook where abook_xchan = '%s' and abook_channel = %d limit 1",
dbesc($rxchan),
dbesc($dr['recipient']),
intval($c[0]['channel_id'])
);
if($r)

43
Zotlabs/Lib/DbStats.php Normal file
View File

@@ -0,0 +1,43 @@
<?php
/*
* SPDX-FileCopyrightText: 2026 The Hubzilla Community
* SPDX-FileContributor: Harald Eilertsen <haraldei@anduin.net>
*
* SPDX-License-Identifier: MIT
*/
namespace Zotlabs\Lib;
use DBA;
/**
* Abstract class to obtain statistics from the database.
*
* This class should not be instantiated on it's own, but you can get
* a concrete class for the configured database type of this site by
* calling the `DbStats::getStats()` function.
*/
abstract class DbStats {
/**
* Get an object for getting statistics from the database.
*
* @return DbStats The concrete class for obtaining the statistics from
* this instances database.
*/
public static function getStats(): DbStats {
return DBA::$dba->is_postgres()
? new PostgresDbStats()
: new MySQLDbStats();
}
/**
* Return the number of queries recorded by the database.
*
* @return int Number of queries.
*/
public abstract function getQueries(): int;
// Prevent instantiation of this class
private function __construct() {}
}

View File

@@ -6,6 +6,7 @@ namespace Zotlabs\Lib;
* @brief File with functions and a class for generating system and email notifications.
*/
use Zotlabs\Lib\Config;
class Enotify {
@@ -43,7 +44,7 @@ class Enotify {
dbesc($params['to_xchan'])
);
}
if ($x & $y) {
if ($x && $y) {
$sender = $x[0];
$recip = $y[0];
} else {
@@ -61,32 +62,32 @@ class Enotify {
$product = t('$projectname'); // PLATFORM_NAME;
$siteurl = z_root();
$thanks = t('Thank You,');
$sitename = get_config('system','sitename');
$sitename = Config::Get('system','sitename');
$site_admin = sprintf( t('%s Administrator'), $sitename);
$opt_out1 = sprintf( t('This email was sent by %1$s at %2$s.'), t('$Projectname'), \App::get_hostname());
$opt_out2 = sprintf( t('To stop receiving these messages, please adjust your Notification Settings at %s'), z_root() . '/settings');
$opt_out2 = sprintf( t('To stop receiving these messages, please adjust your Notification Settings at %s'), z_root() . '/settings');
$hopt_out2 = sprintf( t('To stop receiving these messages, please adjust your %s.'), '<a href="' . z_root() . '/settings' . '">' . t('Notification Settings') . '</a>');
$sender_name = $product;
$hostname = \App::get_hostname();
if(strpos($hostname,':'))
$hostname = substr($hostname,0,strpos($hostname,':'));
$hostname = substr($hostname, 0, strpos($hostname,':'));
// Do not translate 'noreply' as it must be a legal 7-bit email address
$reply_email = get_config('system','reply_address');
$reply_email = Config::Get('system', 'reply_address');
if(! $reply_email)
$reply_email = 'noreply' . '@' . $hostname;
$sender_email = get_config('system','from_email');
$sender_email = Config::Get('system', 'from_email');
if(! $sender_email)
$sender_email = 'Administrator' . '@' . $hostname;
$sender_name = get_config('system','from_email_name');
$sender_name = Config::Get('system', 'from_email_name');
if(! $sender_name)
$sender_name = \Zotlabs\Lib\System::get_site_name();
$additional_mail_header = "";
$additional_mail_header = '';
if(array_key_exists('item', $params)) {
require_once('include/conversation.php');
@@ -94,8 +95,8 @@ class Enotify {
if (array_key_exists('verb', $params['item'])) {
// localize_item() alters the original item so make a copy first
$i = $params['item'];
logger('calling localize');
localize_item($i);
// logger('calling localize');
// localize_item($i);
$title = $i['title'];
$body = $i['body'];
$private = (($i['item_private']) || intval($i['item_obscured']));
@@ -108,44 +109,48 @@ class Enotify {
logger('notification invoked for an old item which may have been refetched.',LOGGER_DEBUG,LOG_INFO);
return;
}
}
}
else {
$title = $body = '';
}
$always_show_in_notices = get_pconfig($recip['channel_id'],'system','always_show_in_notices');
$vnotify = get_pconfig($recip['channel_id'],'system','vnotify');
$always_show_in_notices = get_pconfig($recip['channel_id'], 'system', 'always_show_in_notices');
$vnotify = get_pconfig($recip['channel_id'], 'system', 'vnotify');
$salutation = $recip['channel_name'];
// e.g. "your post", "David's photo", etc.
$possess_desc = t('%s <!item_type!>');
if ($params['type'] == NOTIFY_MAIL) {
logger('notification: mail');
$subject = sprintf( t('[$Projectname:Notify] New mail received at %s'),$sitename);
$parent_mid = '';
$parent_item = [];
$preamble = sprintf( t('%1$s sent you a new private message at %2$s.'), $sender['xchan_name'],$sitename);
$epreamble = sprintf( t('%1$s sent you %2$s.'),'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]', '[zrl=$itemlink]' . t('a private message') . '[/zrl]');
// @@TODO: consider using switch instead of those elseif
if (isset($params['type']) && $params['type'] == NOTIFY_MAIL) {
logger('notification: mail');
$subject = sprintf( t('[$Projectname:Notify] New direct message received at %s'), $sitename);
$preamble = sprintf( t('%1$s sent you a new private message at %2$s'), $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s sent you %2$s.'), '[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]', '[zrl=$itemlink]' . t('a direct message') . '[/zrl]');
$sitelink = t('Please visit %s to view and/or reply to your private messages.');
$tsitelink = sprintf( $sitelink, $siteurl . '/mail/' . $params['item']['id'] );
$hsitelink = sprintf( $sitelink, '<a href="' . $siteurl . '/mail/' . $params['item']['id'] . '">' . $sitename . '</a>');
$itemlink = $siteurl . '/mail/' . $params['item']['id'];
$tsitelink = sprintf( $sitelink, $siteurl . '/hq/' . gen_link_id($params['item']['mid']));
$hsitelink = sprintf( $sitelink, '<a href="' . $siteurl . '/hq/' . gen_link_id($params['item']['mid']) . '">' . $sitename . '</a>');
$itemlink = $siteurl . '/hq/' . gen_link_id($params['item']['mid']);
}
if ($params['type'] == NOTIFY_COMMENT) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_COMMENT) {
//logger("notification: params = " . print_r($params, true), LOGGER_DEBUG);
$moderated = (($params['item']['item_blocked'] == ITEM_MODERATED) ? true : false);
$itemlink = $params['link'];
$action = t('commented on');
$action = (($moderated) ? t('requested to post in') : t('posted in'));
if(array_key_exists('item',$params)) {
if(in_array($params['item']['verb'], [ACTIVITY_LIKE, ACTIVITY_DISLIKE])) {
if(in_array($params['item']['verb'], ['Like', 'Dislike', ACTIVITY_LIKE, ACTIVITY_DISLIKE, ACTIVITY_SHARE])) {
if(! $always_show_in_notices || !($vnotify & VNOTIFY_LIKE)) {
logger('notification: not a visible activity. Ignoring.');
@@ -153,11 +158,14 @@ class Enotify {
return;
}
if(activity_match($params['verb'], ACTIVITY_LIKE))
$action = t('liked');
if(activity_match($params['verb'], ['Like', ACTIVITY_LIKE]))
$action = (($moderated) ? t('requested to like') : t('liked'));
if(activity_match($params['verb'], ACTIVITY_DISLIKE))
$action = t('disliked');
if(activity_match($params['verb'], ['Dislike', ACTIVITY_DISLIKE]))
$action = (($moderated) ? t('requested to dislike') : t('disliked'));
if(activity_match($params['verb'], [ACTIVITY_SHARE]))
$action = (($moderated) ? t('requested to repeat') : t('repeated'));
}
@@ -166,12 +174,11 @@ class Enotify {
}
$parent_mid = $params['parent_mid'];
$parent_mid = $params['parent_mid'] ?? '';
// Check to see if there was already a notify for this post.
// If so don't create a second notification
$p = null;
$p = q("select id from notify where link = '%s' and uid = %d limit 1",
dbesc($params['link']),
intval($recip['channel_id'])
@@ -181,7 +188,7 @@ class Enotify {
pop_lang();
return;
}
// if it's a post figure out who's post it is.
@@ -196,6 +203,7 @@ class Enotify {
xchan_query($p);
//@@FIXME $p can be null (line 188)
$item_post_type = item_post_type($p[0]);
// $private = $p[0]['item_private'];
$parent_id = $p[0]['id'];
@@ -205,40 +213,48 @@ class Enotify {
//$possess_desc = str_replace('<!item_type!>',$possess_desc);
// "a post"
$dest_str = sprintf(t('%1$s %2$s [zrl=%3$s]a %4$s[/zrl]'),
$dest_str = sprintf(
t('%1$s %2$s [zrl=%3$s]a %4$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$action,
$itemlink,
$item_post_type);
$item_post_type
);
// "George Bull's post"
if($p)
$dest_str = sprintf(t('%1$s %2$s [zrl=%3$s]%4$s\'s %5$s[/zrl]'),
if($p) {
$dest_str = sprintf(
t('%1$s %2$s [zrl=%3$s]%4$s\'s %5$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$action,
$itemlink,
$p[0]['author']['xchan_name'],
$item_post_type);
$parent_item['author']['xchan_name'],
$item_post_type
);
}
// "your post"
if($p[0]['owner']['xchan_name'] == $p[0]['author']['xchan_name'] && intval($p[0]['item_wall']))
$dest_str = sprintf(t('%1$s %2$s [zrl=%3$s]your %4$s[/zrl]'),
if ($parent_item['owner']['xchan_hash'] === $recip['channel_hash'] && intval($parent_item['item_wall'])) {
$dest_str = sprintf(
t('%1$s %2$s [zrl=%3$s]your %4$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$action,
$itemlink,
$item_post_type);
$item_post_type
);
}
// Some mail softwares relies on subject field for threading.
// So, we cannot have different subjects for notifications of the same thread.
// Before this we have the name of the replier on the subject rendering
// Before this we have the name of the replier on the subject rendering
// differents subjects for messages on the same thread.
if($moderated)
$subject = sprintf( t('[$Projectname:Notify] Moderated Comment to conversation #%1$d by %2$s'), $parent_id, $sender['xchan_name']);
else
$subject = sprintf( t('[$Projectname:Notify] Comment to conversation #%1$d by %2$s'), $parent_id, $sender['xchan_name']);
$preamble = sprintf( t('%1$s commented on an item/conversation you have been following.'), $sender['xchan_name']);
$epreamble = $dest_str;
$preamble = sprintf( t('%1$s commented on an item/conversation you have been following'), $sender['xchan_name']);
$epreamble = $dest_str;
$sitelink = t('Please visit %s to view and/or reply to the conversation.');
$tsitelink = sprintf( $sitelink, $siteurl );
@@ -247,28 +263,27 @@ class Enotify {
$tsitelink .= "\n\n" . sprintf( t('Please visit %s to approve or reject this comment.'), z_root() . '/moderate' );
$hsitelink .= "<br><br>" . sprintf( t('Please visit %s to approve or reject this comment.'), '<a href="' . z_root() . '/moderate">' . z_root() . '/moderate</a>' );
}
}
if ($params['type'] == NOTIFY_LIKE) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_LIKE) {
// logger("notification: params = " . print_r($params, true), LOGGER_DEBUG);
$itemlink = $params['link'];
if (array_key_exists('item',$params) && (! activity_match($params['item']['verb'],ACTIVITY_LIKE))) {
if(! $always_show_in_notices || !($vnotify & VNOTIFY_LIKE)) {
if (array_key_exists('item',$params) && (activity_match($params['item']['verb'], ['Like', 'Dislike', ACTIVITY_LIKE, ACTIVITY_DISLIKE, 'Announce']))) {
if(! $always_show_in_notices || !($vnotify & VNOTIFY_LIKE) || !feature_enabled($recip['channel_id'], 'dislike')) {
logger('notification: not a visible activity. Ignoring.');
pop_lang();
return;
}
}
$parent_mid = $params['parent_mid'];
$parent_mid = $params['parent_mid'] ?? '';
// Check to see if there was already a notify for this post.
// If so don't create a second notification
$p = null;
$p = q("select id from notify where link = '%s' and uid = %d limit 1",
dbesc($params['link']),
intval($recip['channel_id'])
@@ -278,7 +293,7 @@ class Enotify {
pop_lang();
return;
}
// if it's a post figure out who's post it is.
@@ -291,22 +306,39 @@ class Enotify {
);
}
xchan_query($p);
if (!$p) {
pop_lang();
return;
}
xchan_query($p);
$item_post_type = item_post_type($p[0]);
// $private = $p[0]['item_private'];
$parent_id = $p[0]['id'];
$parent_item = $p[0];
//$verb = ((activity_match($params['item']['verb'], ACTIVITY_DISLIKE)) ? t('disliked') : t('liked'));
$moderated = (($params['item']['item_blocked'] == ITEM_MODERATED) ? true : false);
if(activity_match($params['item']['verb'], ['Like', ACTIVITY_LIKE]))
$verb = (($moderated) ? t('requested to like') : t('liked'));
if(activity_match($params['item']['verb'], ['Dislike', ACTIVITY_DISLIKE]))
$verb = (($moderated) ? t('requested to dislike') : t('disliked'));
if(activity_match($params['item']['verb'], [ACTIVITY_SHARE]))
$verb = (($moderated) ? t('requested to repeat') : t('repeated'));
// "your post"
if($p[0]['owner']['xchan_name'] == $p[0]['author']['xchan_name'] && intval($p[0]['item_wall']))
$dest_str = sprintf(t('%1$s liked [zrl=%2$s]your %3$s[/zrl]'),
if ($parent_item['author']['xchan_hash'] === $recip['channel_hash']) {
$dest_str = sprintf(t('%1$s %2$s [zrl=%3$s]your %4$s[/zrl]'),
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$verb,
$itemlink,
$item_post_type);
$item_post_type
);
}
else {
pop_lang();
return;
@@ -314,12 +346,12 @@ class Enotify {
// Some mail softwares relies on subject field for threading.
// So, we cannot have different subjects for notifications of the same thread.
// Before this we have the name of the replier on the subject rendering
// Before this we have the name of the replier on the subject rendering
// differents subjects for messages on the same thread.
$subject = sprintf( t('[$Projectname:Notify] Like received to conversation #%1$d by %2$s'), $parent_id, $sender['xchan_name']);
$preamble = sprintf( t('%1$s liked an item/conversation you created.'), $sender['xchan_name']);
$epreamble = $dest_str;
$preamble = sprintf( t('%1$s liked an item/conversation you created'), $sender['xchan_name']);
$epreamble = $dest_str;
$sitelink = t('Please visit %s to view and/or reply to the conversation.');
$tsitelink = sprintf( $sitelink, $siteurl );
@@ -328,14 +360,14 @@ class Enotify {
if($params['type'] == NOTIFY_WALL) {
elseif(isset($params['type']) && $params['type'] === NOTIFY_WALL) {
$subject = sprintf( t('[$Projectname:Notify] %s posted to your profile wall') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s posted to your profile wall at %2$s') , $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s posted to [zrl=%2$s]your wall[/zrl]') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$params['link']);
$params['link']);
$sitelink = t('Please visit %s to view and/or reply to the conversation.');
$tsitelink = sprintf( $sitelink, $siteurl );
@@ -343,9 +375,8 @@ class Enotify {
$itemlink = $params['link'];
}
if ($params['type'] == NOTIFY_TAGSELF) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_TAGSELF) {
$p = null;
$p = q("select id from notify where link = '%s' and uid = %d limit 1",
dbesc($params['link']),
intval($recip['channel_id'])
@@ -355,12 +386,12 @@ class Enotify {
pop_lang();
return;
}
$subject = sprintf( t('[$Projectname:Notify] %s tagged you') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s tagged you at %2$s') , $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s [zrl=%2$s]tagged you[/zrl].') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$params['link']);
$params['link']);
$sitelink = t('Please visit %s to view and/or reply to the conversation.');
$tsitelink = sprintf( $sitelink, $siteurl );
@@ -368,12 +399,12 @@ class Enotify {
$itemlink = $params['link'];
}
if ($params['type'] == NOTIFY_POKE) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_POKE) {
$subject = sprintf( t('[$Projectname:Notify] %1$s poked you') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s poked you at %2$s') , $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s [zrl=%2$s]poked you[/zrl].') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$params['link']);
$params['link']);
$subject = str_replace('poked', t($params['activity']), $subject);
$preamble = str_replace('poked', t($params['activity']), $preamble);
@@ -385,25 +416,25 @@ class Enotify {
$itemlink = $params['link'];
}
if ($params['type'] == NOTIFY_TAGSHARE) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_TAGSHARE) {
$itemlink = $params['link'];
$subject = sprintf( t('[$Projectname:Notify] %s tagged your post') , $sender['xchan_name']);
$preamble = sprintf( t('%1$s tagged your post at %2$s'),$sender['xchan_name'], $sitename);
$epreamble = sprintf( t('%1$s tagged [zrl=%2$s]your post[/zrl]') ,
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]',
$itemlink);
$itemlink);
$sitelink = t('Please visit %s to view and/or reply to the conversation.');
$tsitelink = sprintf( $sitelink, $siteurl );
$hsitelink = sprintf( $sitelink, '<a href="' . $siteurl . '">' . $sitename . '</a>');
$itemlink = $params['link'];
}
if ($params['type'] == NOTIFY_INTRO) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_INTRO) {
$subject = sprintf( t('[$Projectname:Notify] Introduction received'));
$preamble = sprintf( t('You\'ve received an new connection request from \'%1$s\' at %2$s'), $sender['xchan_name'], $sitename);
$preamble = sprintf( t('You\'ve received a new connection request from \'%1$s\' at %2$s'), $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('You\'ve received [zrl=%1$s]a new connection request[/zrl] from %2$s.'),
$siteurl . '/connections/ifpending',
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]');
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]');
$body = sprintf( t('You may visit their profile at %s'),$sender['xchan_url']);
$sitelink = t('Please visit %s to approve or reject the connection request.');
@@ -412,13 +443,14 @@ class Enotify {
$itemlink = $params['link'];
}
if ($params['type'] == NOTIFY_SUGGEST) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_SUGGEST) {
$itemlink = $params['link'];
$subject = sprintf( t('[$Projectname:Notify] Friend suggestion received'));
$preamble = sprintf( t('You\'ve received a friend suggestion from \'%1$s\' at %2$s'), $sender['xchan_name'], $sitename);
$preamble = sprintf( t('You\'ve received a friend suggestion from \'%1$s\' at %2$s'), $sender['xchan_name'], $sitename);
$epreamble = sprintf( t('You\'ve received [zrl=%1$s]a friend suggestion[/zrl] for %2$s from %3$s.'),
$itemlink,
'[zrl=' . $params['item']['url'] . ']' . $params['item']['name'] . '[/zrl]',
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]');
'[zrl=' . $sender['xchan_url'] . ']' . $sender['xchan_name'] . '[/zrl]');
$body = t('Name:') . ' ' . $params['item']['name'] . "\n";
$body .= t('Photo:') . ' ' . $params['item']['photo'] . "\n";
@@ -427,14 +459,13 @@ class Enotify {
$sitelink = t('Please visit %s to approve or reject the suggestion.');
$tsitelink = sprintf( $sitelink, $siteurl );
$hsitelink = sprintf( $sitelink, '<a href="' . $siteurl . '">' . $sitename . '</a>');
$itemlink = $params['link'];
}
if ($params['type'] == NOTIFY_CONFIRM) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_CONFIRM) {
// ?
}
if ($params['type'] == NOTIFY_SYSTEM) {
elseif (isset($params['type']) && $params['type'] === NOTIFY_SYSTEM) {
// ?
}
@@ -462,11 +493,13 @@ class Enotify {
$sitelink = $h['sitelink'];
$tsitelink = $h['tsitelink'];
$hsitelink = $h['hsitelink'];
$itemlink = $h['itemlink'];
$itemlink = $h['itemlink'];
require_once('include/html2bbcode.php');
/*
do {
$dups = false;
$hash = random_string();
@@ -475,10 +508,17 @@ class Enotify {
if ($r)
$dups = true;
} while ($dups === true);
*/
$datarray = array();
$datarray['hash'] = $hash;
$hash = ((in_array($params['verb'], ['Create', 'Update', 'Invite'])) ? $params['item']['uuid'] : $params['item']['thr_parent_uuid']);
if (!$hash) {
$hash = new_uuid();
}
$datarray = [];
$datarray['hash'] = $hash;
$datarray['sender_hash'] = $sender['xchan_hash'];
$datarray['xname'] = $sender['xchan_name'];
$datarray['url'] = $sender['xchan_url'];
@@ -489,12 +529,13 @@ class Enotify {
$datarray['link'] = $itemlink;
$datarray['parent'] = $parent_mid;
$datarray['parent_item'] = $parent_item;
$datarray['ntype'] = $params['type'];
$datarray['verb'] = $params['verb'];
$datarray['otype'] = $params['otype'];
$datarray['ntype'] = $params['type'] ?? 0;
$datarray['verb'] = $params['verb'] ?? '';
$datarray['otype'] = $params['otype'] ?? '';
$datarray['abort'] = false;
$datarray['seen'] = 0;
$datarray['item'] = $params['item'];
$datarray['item'] = $params['item'] ?? [];
call_hooks('enotify_store', $datarray);
@@ -505,17 +546,16 @@ class Enotify {
// create notification entry in DB
$seen = 0;
// Mark some notifications as seen right away
// Note! The notification have to be created, because they are used to send emails
// So easiest solution to hide them from Notices is to mark them as seen right away.
// Another option would be to not add them to the DB, and change how emails are handled
// Another option would be to not add them to the DB, and change how emails are handled
// (probably would be better that way)
if (!$always_show_in_notices) {
if (($params['type'] == NOTIFY_WALL) || ($params['type'] == NOTIFY_MAIL) || ($params['type'] == NOTIFY_INTRO)) {
$seen = 1;
if (($params['type'] === NOTIFY_WALL) || ($params['type'] === NOTIFY_MAIL) || ($params['type'] === NOTIFY_INTRO)) {
$datarray['seen'] = 1;
}
}
@@ -531,14 +571,16 @@ class Enotify {
intval($datarray['uid']),
dbesc($datarray['link']),
dbesc($datarray['parent']),
intval($seen),
intval($datarray['seen']),
intval($datarray['ntype']),
dbesc($datarray['verb']),
dbesc($datarray['otype'])
);
$r = q("select id from notify where hash = '%s' and uid = %d limit 1",
dbesc($hash),
$r = q("select id from notify where hash = '%s' and link = '%s' and ntype = %d and uid = %d limit 1",
dbesc($datarray['hash']),
dbesc($itemlink),
intval($datarray['ntype']),
intval($recip['channel_id'])
);
if ($r) {
@@ -550,12 +592,12 @@ class Enotify {
}
$itemlink = z_root() . '/notify/view/' . $notify_id;
$msg = str_replace('$itemlink',$itemlink,$epreamble);
$msg = str_replace('$itemlink', $itemlink, $epreamble);
// wretched hack, but we don't want to duplicate all the preamble variations and we also don't want to screw up a translation
if ((\App::$language === 'en' || (! \App::$language)) && strpos($msg,', '))
$msg = substr($msg,strpos($msg,', ')+1);
$msg = substr($msg, strpos($msg,', ')+1);
$datarray['id'] = $notify_id;
$datarray['msg'] = $msg;
@@ -570,12 +612,12 @@ class Enotify {
// send email notification if notification preferences permit
require_once('bbcode.php');
require_once('include/bbcode.php');
if ((intval($recip['channel_notifyflags']) & intval($params['type'])) || $params['type'] == NOTIFY_SYSTEM) {
logger('notification: sending notification email');
$hn = get_pconfig($recip['channel_id'],'system','email_notify_host');
$hn = get_pconfig($recip['channel_id'], 'system', 'email_notify_host');
if($hn && (! stristr(\App::get_hostname(),$hn))) {
// this isn't the email notification host
pop_lang();
@@ -584,15 +626,15 @@ class Enotify {
$textversion = strip_tags(html_entity_decode(bbcode(stripslashes(str_replace(array("\\r", "\\n"), array( "", "\n"), $body))),ENT_QUOTES,'UTF-8'));
$htmlversion = bbcode(stripslashes(str_replace(array("\\r","\\n"), array("","<br />\n"),$body)));
$htmlversion = bbcode(stripslashes(str_replace(array("\\r","\\n"), array('',"<br />\n"),$body)));
// use $_SESSION['zid_override'] to force zid() to use
// use $_SESSION['zid_override'] to force zid() to use
// the recipient address instead of the current observer
$_SESSION['zid_override'] = channel_reddress($recip);
$_SESSION['zrl_override'] = z_root() . '/channel/' . $recip['channel_address'];
$textversion = zidify_links($textversion);
$htmlversion = zidify_links($htmlversion);
@@ -601,14 +643,14 @@ class Enotify {
unset($_SESSION['zid_override']);
unset($_SESSION['zrl_override']);
$datarray = array();
$datarray = [];
$datarray['banner'] = $banner;
$datarray['product'] = $product;
$datarray['preamble'] = $preamble;
$datarray['sitename'] = $sitename;
$datarray['siteurl'] = $siteurl;
$datarray['type'] = $params['type'];
$datarray['parent'] = $params['parent_mid'];
$datarray['type'] = $params['type'] ?? '';
$datarray['parent'] = $params['parent_mid'] ?? '';
$datarray['source_name'] = $sender['xchan_name'];
$datarray['source_link'] = $sender['xchan_url'];
$datarray['source_photo'] = $sender['xchan_photo_s'];
@@ -675,7 +717,6 @@ class Enotify {
'$source_name' => $datarray['source_name'],
'$source_link' => $datarray['source_link'],
'$source_photo' => $datarray['source_photo'],
'$username' => $datarray['to_name'],
'$hsitelink' => $datarray['hsitelink'],
'$hitemlink' => $datarray['hitemlink'],
'$thanks' => $datarray['thanks'],
@@ -697,7 +738,6 @@ class Enotify {
'$source_name' => $datarray['source_name'],
'$source_link' => $datarray['source_link'],
'$source_photo' => $datarray['source_photo'],
'$username' => $datarray['to_name'],
'$tsitelink' => $datarray['tsitelink'],
'$titemlink' => $datarray['titemlink'],
'$thanks' => $datarray['thanks'],
@@ -754,21 +794,21 @@ class Enotify {
return $params['result'];
}
$fromName = email_header_encode(html_entity_decode($params['fromName'],ENT_QUOTES,'UTF-8'),'UTF-8');
$fromName = email_header_encode(html_entity_decode($params['fromName'],ENT_QUOTES,'UTF-8'),'UTF-8');
$messageSubject = email_header_encode(html_entity_decode($params['messageSubject'],ENT_QUOTES,'UTF-8'),'UTF-8');
// generate a mime boundary
$mimeBoundary = rand(0, 9) . "-"
.rand(100000000, 999999999) . "-"
.rand(100000000, 999999999) . "=:"
$mimeBoundary = rand(0, 9) . '-'
.rand(100000000, 999999999) . '-'
.rand(100000000, 999999999) . '=:'
.rand(10000, 99999);
// generate a multipart/alternative message header
$messageHeader =
$params['additionalMailHeader'] .
"From: $fromName <{$params['fromEmail']}>" . PHP_EOL .
"Reply-To: $fromName <{$params['replyTo']}>" . PHP_EOL .
"MIME-Version: 1.0" . PHP_EOL .
"Reply-To: $fromName <{$params['replyTo']}>" . PHP_EOL .
'MIME-Version: 1.0' . PHP_EOL .
"Content-Type: multipart/alternative; boundary=\"{$mimeBoundary}\"";
// assemble the final multipart message body with the text and html types included
@@ -776,15 +816,15 @@ class Enotify {
$htmlBody = chunk_split(base64_encode($params['htmlVersion']));
$multipartMessageBody =
"--" . $mimeBoundary . PHP_EOL . // plain text section
"Content-Type: text/plain; charset=UTF-8" . PHP_EOL .
"Content-Transfer-Encoding: base64" . PHP_EOL . PHP_EOL .
'--' . $mimeBoundary . PHP_EOL . // plain text section
'Content-Type: text/plain; charset=UTF-8' . PHP_EOL .
'Content-Transfer-Encoding: base64' . PHP_EOL . PHP_EOL .
$textBody . PHP_EOL .
"--" . $mimeBoundary . PHP_EOL . // text/html section
"Content-Type: text/html; charset=UTF-8" . PHP_EOL .
"Content-Transfer-Encoding: base64" . PHP_EOL . PHP_EOL .
'--' . $mimeBoundary . PHP_EOL . // text/html section
'Content-Type: text/html; charset=UTF-8' . PHP_EOL .
'Content-Transfer-Encoding: base64' . PHP_EOL . PHP_EOL .
$htmlBody . PHP_EOL .
"--" . $mimeBoundary . "--" . PHP_EOL; // message ending
'--' . $mimeBoundary . '--' . PHP_EOL; // message ending
// send the message
$res = mail(
@@ -793,7 +833,7 @@ class Enotify {
$multipartMessageBody, // message body
$messageHeader // message headers
);
logger("notification: enotify::send returns " . (($res) ? 'success' : 'failure'), LOGGER_DEBUG);
logger('notification: enotify::send returns ' . (($res) ? 'success' : 'failure'), LOGGER_DEBUG);
return $res;
}
@@ -803,28 +843,24 @@ class Enotify {
require_once('include/conversation.php');
// Call localize_item to get a one line status for activities.
// Call localize_item to get a one line status for activities.
// This should set $item['localized'] to indicate we have a brief summary.
// and perhaps $item['shortlocalized'] for an even briefer summary
localize_item($item);
if($item['shortlocalize']) {
if(isset($item['shortlocalize'])) {
$itemem_text = $item['shortlocalize'];
}
elseif($item['localize']) {
elseif(isset($item['localize'])) {
$itemem_text = $item['localize'];
}
else {
$itemem_text = (($item['item_thread_top'])
? (($item['obj_type'] === 'Question') ? t('created a new poll') : t('created a new post'))
: (($item['obj_type'] === 'Answer') ? sprintf( t('voted on %s\'s poll'), '[bdi]' . $item['owner']['xchan_name'] . '[/bdi]') : sprintf( t('commented on %s\'s post'), '[bdi]' . $item['owner']['xchan_name'] . '[/bdi]'))
? (($item['obj_type'] === 'Question') ? t('started a poll') : t('started a conversation'))
: (($item['obj_type'] === 'Answer') ? sprintf( t('voted on %s\'s poll'), '[bdi]' . $item['owner']['xchan_name'] . '[/bdi]') : sprintf( t('posted in %s\'s conversation'), '[bdi]' . $item['owner']['xchan_name'] . '[/bdi]'))
);
if($item['verb'] === ACTIVITY_SHARE) {
$itemem_text = sprintf( t('repeated %s\'s post'), '[bdi]' . $item['author']['xchan_name'] . '[/bdi]');
}
if(in_array($item['obj_type'], ['Document', 'Video', 'Audio', 'Image'])) {
$itemem_text = t('shared a file with you');
}
@@ -833,41 +869,39 @@ class Enotify {
$edit = false;
if($item['edited'] > $item['created']) {
if($item['item_thread_top']) {
$itemem_text = sprintf( t('edited a post dated %s'), relative_date($item['created']));
$edit = true;
}
else {
$itemem_text = sprintf( t('edited a comment dated %s'), relative_date($item['created']));
$edit = true;
}
$edit = true;
$itemem_text = sprintf( t('edited a message dated %s'), relative_date($item['created']));
}
// convert this logic into a json array just like the system notifications
$who = (($item['verb'] === ACTIVITY_SHARE) ? 'owner' : 'author');
$body = html2plain(bbcode($item['body'], ['drop_media' => true, 'tryoembed' => false]), 75, true);
if ($body) {
$body = htmlentities($body, ENT_QUOTES, 'UTF-8', false);
}
$x = array(
'notify_link' => $item['llink'],
'name' => $item[$who]['xchan_name'],
'addr' => (($item[$who]['xchan_addr']) ? $item[$who]['xchan_addr'] : $item[$who]['xchan_url']),
'url' => $item[$who]['xchan_url'],
'photo' => $item[$who]['xchan_photo_s'],
'name' => $item['author']['xchan_name'],
'addr' => $item['author']['xchan_addr'] ? $item['author']['xchan_addr'] : $item['author']['xchan_url'],
'url' => $item['author']['xchan_url'],
'photo' => $item['author']['xchan_photo_s'],
'when' => (($edit) ? datetime_convert('UTC', date_default_timezone_get(), $item['edited']) : datetime_convert('UTC', date_default_timezone_get(), $item['created'])),
'class' => (intval($item['item_unseen']) ? 'notify-unseen' : 'notify-seen'),
'b64mid' => (($item['mid']) ? 'b64.' . base64url_encode($item['mid']) : ''),
//'b64mid' => ((in_array($item['verb'], [ACTIVITY_LIKE, ACTIVITY_DISLIKE])) ? 'b64.' . base64url_encode($item['thr_parent']) : 'b64.' . base64url_encode($item['mid'])),
// 'b64mid' => (($item['mid']) ? gen_link_id($item['mid']) : ''),
'b64mid' => ((in_array($item['verb'] , ['Like', 'Dislike', 'Announce']) && !empty($item['thr_parent_uuid'])) ? $item['thr_parent_uuid'] : $item['uuid'] ?? ''),
//'b64mid' => ((in_array($item['verb'], [ACTIVITY_LIKE, ACTIVITY_DISLIKE])) ? gen_link_id($item['thr_parent']) : gen_link_id($item['mid'])),
'thread_top' => (($item['item_thread_top']) ? true : false),
'message' => bbcode(escape_tags($itemem_text)),
'body' => htmlentities(html2plain(bbcode($item['body']), 75, true), ENT_COMPAT, 'UTF-8', false),
'body' => $body,
// these are for the superblock addon
'hash' => $item[$who]['xchan_hash'],
'hash' => $item['author']['xchan_hash'],
'uid' => $item['uid'],
'display' => true
);
call_hooks('enotify_format',$x);
call_hooks('enotify_format', $x);
if(! $x['display']) {
return [];
}
@@ -876,35 +910,29 @@ class Enotify {
}
static public function format_notify($tt) {
$message = trim(strip_tags(bbcode($tt['msg'])));
if(strpos($message, $tt['xname']) === 0)
$message = substr($message, strlen($tt['xname']) + 1);
$mid = basename($tt['link']);
$b64mid = ((strpos($mid, 'b64.') === 0) ? $mid : 'b64.' . base64url_encode($mid));
$x = [
'notify_link' => z_root() . '/notify/view/' . $tt['id'],
'notify_link' => (($tt['ntype'] === NOTIFY_INTRO) ? z_root() . '/notify/view/' . $tt['id'] : $tt['link']),
'name' => $tt['xname'],
'url' => $tt['url'],
'photo' => $tt['photo'],
'when' => datetime_convert('UTC', date_default_timezone_get(), $tt['created']),
'hclass' => (($tt['seen']) ? 'notify-seen' : 'notify-unseen'),
'b64mid' => (($tt['otype'] == 'item') ? $b64mid : ''),
'b64mid' => (($tt['otype'] == 'item') ? $tt['hash'] : ''),
'notify_id' => (($tt['otype'] == 'item') ? $tt['id'] : ''),
'message' => $message
];
return $x;
}
static public function format_intros($rr) {
$x = [
'notify_link' => z_root() . '/connections/ifpending',
return [
'notify_link' => z_root() . '/connections#' . $rr['abook_id'],
'name' => $rr['xchan_name'],
'addr' => $rr['xchan_addr'],
'url' => $rr['xchan_url'],
@@ -914,13 +942,11 @@ class Enotify {
'message' => t('added your channel')
];
return $x;
}
static public function format_files($rr) {
$x = [
return [
'notify_link' => z_root() . '/sharedwithme',
'name' => $rr['author']['xchan_name'],
'addr' => $rr['author']['xchan_addr'],
@@ -931,13 +957,11 @@ class Enotify {
'message' => t('shared a file with you')
];
return $x;
}
static public function format_mail($rr) {
$x = [
return [
'notify_link' => z_root() . '/mail/' . $rr['id'],
'name' => $rr['xchan_name'],
'addr' => $rr['xchan_addr'],
@@ -945,11 +969,9 @@ class Enotify {
'photo' => $rr['xchan_photo_s'],
'when' => datetime_convert('UTC', date_default_timezone_get(), $rr['created']),
'hclass' => (intval($rr['mail_seen']) ? 'notify-seen' : 'notify-unseen'),
'message' => t('sent you a private message'),
'message' => t('sent you a direct message'),
];
return $x;
}
static public function format_all_events($rr) {
@@ -959,7 +981,7 @@ class Enotify {
$today = ((substr($strt, 0, 10) === datetime_convert('UTC', date_default_timezone_get(), 'now', 'Y-m-d')) ? true : false);
$when = day_translate(datetime_convert('UTC', (($rr['adjust']) ? date_default_timezone_get() : 'UTC'), $rr['dtstart'], $bd_format)) . (($today) ? ' ' . t('[today]') : '');
$x = [
return [
'notify_link' => z_root() . '/cdav/calendar/' . $rr['event_hash'],
'name' => $rr['xchan_name'],
'addr' => $rr['xchan_addr'],
@@ -970,23 +992,20 @@ class Enotify {
'message' => t('created an event')
];
return $x;
}
static public function format_register($rr) {
$x = [
return [
'notify_link' => z_root() . '/admin/accounts',
'name' => $rr['account_email'],
//'addr' => $rr['account_email'],
'name' => $rr['reg_did2'],
//'addr' => '',
'photo' => z_root() . '/' . get_default_profile_photo(48),
'when' => datetime_convert('UTC', date_default_timezone_get(),$rr['account_created']),
'when' => datetime_convert('UTC', date_default_timezone_get(),$rr['reg_created']),
'hclass' => ('notify-unseen'),
'message' => t('requires approval')
'message' => t('status verified')
];
return $x;
}
}

View File

@@ -1,405 +0,0 @@
<?php
namespace Zotlabs\Lib;
use Zotlabs\Lib\Libsync;
class Group {
static function add($uid,$name,$public = 0) {
$ret = false;
if(x($uid) && x($name)) {
$r = self::byname($uid,$name); // check for dups
if($r !== false) {
// This could be a problem.
// Let's assume we've just created a group which we once deleted
// all the old members are gone, but the group remains so we don't break any security
// access lists. What we're doing here is reviving the dead group, but old content which
// was restricted to this group may now be seen by the new group members.
$z = q("SELECT * FROM pgrp WHERE id = %d LIMIT 1",
intval($r)
);
if(($z) && $z[0]['deleted']) {
q('UPDATE pgrp SET deleted = 0 WHERE id = %d', intval($z[0]['id']));
notice( t('A deleted group with this name was revived. Existing item permissions <strong>may</strong> apply to this group and any future members. If this is not what you intended, please create another group with a different name.') . EOL);
}
return true;
}
do {
$dups = false;
$hash = random_string(32) . str_replace(['<','>'],['.','.'], $name);
$r = q("SELECT id FROM pgrp WHERE hash = '%s' LIMIT 1", dbesc($hash));
if($r)
$dups = true;
} while($dups == true);
$r = q("INSERT INTO pgrp ( hash, uid, visible, gname )
VALUES( '%s', %d, %d, '%s' ) ",
dbesc($hash),
intval($uid),
intval($public),
dbesc($name)
);
$ret = $r;
}
Libsync::build_sync_packet($uid,null,true);
return $ret;
}
static function remove($uid,$name) {
$ret = false;
if(x($uid) && x($name)) {
$r = q("SELECT id, hash FROM pgrp WHERE uid = %d AND gname = '%s' LIMIT 1",
intval($uid),
dbesc($name)
);
if($r) {
$group_id = $r[0]['id'];
$group_hash = $r[0]['hash'];
}
if(! $group_id)
return false;
// remove group from default posting lists
$r = q("SELECT channel_default_group, channel_allow_gid, channel_deny_gid FROM channel WHERE channel_id = %d LIMIT 1",
intval($uid)
);
if($r) {
$user_info = $r[0];
$change = false;
if($user_info['channel_default_group'] == $group_hash) {
$user_info['channel_default_group'] = '';
$change = true;
}
if(strpos($user_info['channel_allow_gid'], '<' . $group_hash . '>') !== false) {
$user_info['channel_allow_gid'] = str_replace('<' . $group_hash . '>', '', $user_info['channel_allow_gid']);
$change = true;
}
if(strpos($user_info['channel_deny_gid'], '<' . $group_hash . '>') !== false) {
$user_info['channel_deny_gid'] = str_replace('<' . $group_hash . '>', '', $user_info['channel_deny_gid']);
$change = true;
}
if($change) {
q("UPDATE channel SET channel_default_group = '%s', channel_allow_gid = '%s', channel_deny_gid = '%s'
WHERE channel_id = %d",
intval($user_info['channel_default_group']),
dbesc($user_info['channel_allow_gid']),
dbesc($user_info['channel_deny_gid']),
intval($uid)
);
}
}
// remove all members
$r = q("DELETE FROM pgrp_member WHERE uid = %d AND gid = %d ",
intval($uid),
intval($group_id)
);
// remove group
$r = q("UPDATE pgrp SET deleted = 1 WHERE uid = %d AND gname = '%s'",
intval($uid),
dbesc($name)
);
$ret = $r;
}
Libsync::build_sync_packet($uid,null,true);
return $ret;
}
static function byname($uid,$name) {
if((! $uid) || (! strlen($name)))
return false;
$r = q("SELECT * FROM pgrp WHERE uid = %d AND gname = '%s' LIMIT 1",
intval($uid),
dbesc($name)
);
if($r)
return $r[0]['id'];
return false;
}
static function rec_byhash($uid,$hash) {
if((! $uid) || (! strlen($hash)))
return false;
$r = q("SELECT * FROM pgrp WHERE uid = %d AND hash = '%s' LIMIT 1",
intval($uid),
dbesc($hash)
);
if($r)
return $r[0];
return false;
}
static function member_remove($uid,$name,$member) {
$gid = self::byname($uid,$name);
if(! $gid)
return false;
if(! ( $uid && $gid && $member))
return false;
$r = q("DELETE FROM pgrp_member WHERE uid = %d AND gid = %d AND xchan = '%s' ",
intval($uid),
intval($gid),
dbesc($member)
);
Libsync::build_sync_packet($uid,null,true);
return $r;
}
static function member_add($uid,$name,$member,$gid = 0) {
if(! $gid)
$gid = self::byname($uid,$name);
if((! $gid) || (! $uid) || (! $member))
return false;
$r = q("SELECT * FROM pgrp_member WHERE uid = %d AND gid = %d AND xchan = '%s' LIMIT 1",
intval($uid),
intval($gid),
dbesc($member)
);
if($r)
return true; // You might question this, but
// we indicate success because the group member was in fact created
// -- It was just created at another time
if(! $r)
$r = q("INSERT INTO pgrp_member (uid, gid, xchan)
VALUES( %d, %d, '%s' ) ",
intval($uid),
intval($gid),
dbesc($member)
);
Libsync::build_sync_packet($uid,null,true);
return $r;
}
static function members($gid) {
$ret = array();
if(intval($gid)) {
$r = q("SELECT * FROM pgrp_member
LEFT JOIN abook ON abook_xchan = pgrp_member.xchan left join xchan on xchan_hash = abook_xchan
WHERE gid = %d AND abook_channel = %d and pgrp_member.uid = %d and xchan_deleted = 0 and abook_self = 0 and abook_blocked = 0 and abook_pending = 0 ORDER BY xchan_name ASC ",
intval($gid),
intval(local_channel()),
intval(local_channel())
);
if($r)
$ret = $r;
}
return $ret;
}
static function members_xchan($gid) {
$ret = [];
if(intval($gid)) {
$r = q("SELECT xchan FROM pgrp_member WHERE gid = %d AND uid = %d",
intval($gid),
intval(local_channel())
);
if($r) {
foreach($r as $rr) {
$ret[] = $rr['xchan'];
}
}
}
return $ret;
}
static function members_profile_xchan($uid,$gid) {
$ret = [];
if(intval($gid)) {
$r = q("SELECT abook_xchan as xchan from abook left join profile on abook_profile = profile_guid where profile.id = %d and profile.uid = %d",
intval($gid),
intval($uid)
);
if($r) {
foreach($r as $rr) {
$ret[] = $rr['xchan'];
}
}
}
return $ret;
}
static function select($uid,$group = '') {
$grps = [];
$o = '';
$r = q("SELECT * FROM pgrp WHERE deleted = 0 AND uid = %d ORDER BY gname ASC",
intval($uid)
);
$grps[] = array('name' => '', 'hash' => '0', 'selected' => '');
if($r) {
foreach($r as $rr) {
$grps[] = array('name' => $rr['gname'], 'id' => $rr['hash'], 'selected' => (($group == $rr['hash']) ? 'true' : ''));
}
}
logger('select: ' . print_r($grps,true), LOGGER_DATA);
$o = replace_macros(get_markup_template('group_selection.tpl'), array(
'$label' => t('Add new connections to this privacy group'),
'$groups' => $grps
));
return $o;
}
static function widget($every="connections",$each="group",$edit = false, $group_id = 0, $cid = '',$mode = 1) {
$o = '';
if(! (local_channel() && feature_enabled(local_channel(),'groups'))) {
return '';
}
$groups = array();
$r = q("SELECT * FROM pgrp WHERE deleted = 0 AND uid = %d ORDER BY gname ASC",
intval($_SESSION['uid'])
);
$member_of = array();
if($cid) {
$member_of = self::containing(local_channel(),$cid);
}
if($r) {
foreach($r as $rr) {
$selected = (($group_id == $rr['id']) ? ' group-selected' : '');
if ($edit) {
$groupedit = [ 'href' => "group/".$rr['id'], 'title' => t('edit') ];
}
else {
$groupedit = null;
}
$groups[] = [
'id' => $rr['id'],
'enc_cid' => base64url_encode($cid),
'cid' => $cid,
'text' => $rr['gname'],
'selected' => $selected,
'href' => (($mode == 0) ? $each.'?f=&gid='.$rr['id'] : $each."/".$rr['id']) . ((x($_GET,'new')) ? '&new=' . $_GET['new'] : '') . ((x($_GET,'order')) ? '&order=' . $_GET['order'] : ''),
'edit' => $groupedit,
'ismember' => in_array($rr['id'],$member_of),
];
}
}
$tpl = get_markup_template("group_side.tpl");
$o = replace_macros($tpl, array(
'$title' => t('Privacy Groups'),
'$edittext' => t('Edit group'),
'$createtext' => t('Add privacy group'),
'$ungrouped' => (($every === 'contacts') ? t('Channels not in any privacy group') : ''),
'$groups' => $groups,
'$add' => t('add'),
));
return $o;
}
static function expand($g) {
if(! (is_array($g) && count($g)))
return array();
$ret = [];
$x = [];
// private profile linked virtual groups
foreach($g as $gv) {
if(substr($gv,0,3) === 'vp.') {
$profile_hash = substr($gv,3);
if($profile_hash) {
$r = q("select abook_xchan from abook where abook_profile = '%s'",
dbesc($profile_hash)
);
if($r) {
foreach($r as $rv) {
$ret[] = $rv['abook_xchan'];
}
}
}
}
else {
$x[] = $gv;
}
}
if($x) {
stringify_array_elms($x,true);
$groups = implode(',', $x);
if($groups) {
$r = q("SELECT xchan FROM pgrp_member WHERE gid IN ( select id from pgrp where hash in ( $groups ))");
if($r) {
foreach($r as $rr) {
$ret[] = $rr['xchan'];
}
}
}
}
return $ret;
}
static function member_of($c) {
$r = q("SELECT pgrp.gname, pgrp.id FROM pgrp LEFT JOIN pgrp_member ON pgrp_member.gid = pgrp.id WHERE pgrp_member.xchan = '%s' AND pgrp.deleted = 0 ORDER BY pgrp.gname ASC ",
dbesc($c)
);
return $r;
}
static function containing($uid,$c) {
$r = q("SELECT gid FROM pgrp_member WHERE uid = %d AND pgrp_member.xchan = '%s' ",
intval($uid),
dbesc($c)
);
$ret = array();
if($r) {
foreach($r as $rr)
$ret[] = $rr['gid'];
}
return $ret;
}
}

55
Zotlabs/Lib/Hashpath.php Normal file
View File

@@ -0,0 +1,55 @@
<?php
namespace Zotlabs\Lib;
/*
* Zotlabs\Lib\Hashpath
*
* Creates hashed directory structures for fast access and resistance to overloading any single directory with files.
*
* Takes a $hash which could be any string
* a $prefix which is where to place the hash directory in the filesystem, default is current directory
* use an empty string for $prefix to place hash directories directly off the root directory
* an optional $depth and $slice (default is 2) to indicate the hash level
* $depth = 1, 256 directories, suitable for < 384K records/files
* $depth = 2, 65536 directories, suitable for < 98M records/files
* $depth = 3, 16777216 directories, suitable for < 2.5B records/files
* ...
* The total number of records anticipated divided by the number of hash directories should generally be kept to
* less than 1500 entries for optimum performance though this varies by operating system and filesystem type.
* ext4 uses 32 bit inode numbers (~4B record limit) so use caution or alternative filesystem types with $depth above 3.
* an optional $mkdir (boolean) to recursively create the directory (ignoring errors) before returning
*
* examples: for a $hash of 'abcdefg' and prefix of 'path' the following paths are returned for $depth = 1 and $depth = 3
* path/7d/7d1a54127b222502f5b79b5fb0803061152a44f92b37e23c6527baf665d4da9a
* path/7d/1a/54/7d1a54127b222502f5b79b5fb0803061152a44f92b37e23c6527baf665d4da9a
*
* see also: boot.php:os_mkdir() - here we provide the equivalent of mkdir -p with permissions of 770.
*
*/
class Hashpath {
static function path($hash, $prefix = '.', $depth = 1, $slice = 2, $mkdir = true, $alg = false) {
if ($alg)
$hash = hash($alg, $hash);
$start = 0;
if ($depth < 1)
$depth = 1;
$sluglen = $depth * $slice;
do {
$slug = substr($hash, $start, $slice);
$prefix .= '/' . $slug;
$start += $slice;
$sluglen -= $slice;
}
while ($sluglen);
if ($mkdir)
os_mkdir($prefix, STORAGE_DEFAULT_PERMISSIONS, true);
return $prefix . '/' . $hash;
}
}

View File

@@ -13,7 +13,8 @@ class IConfig {
static public function Get(&$item, $family, $key, $default = false) {
$is_item = false;
$iid = null;
if(is_array($item)) {
$is_item = true;
if((! array_key_exists('iconfig',$item)) || (! is_array($item['iconfig'])))
@@ -22,32 +23,57 @@ class IConfig {
if(array_key_exists('item_id',$item))
$iid = $item['item_id'];
else
$iid = $item['id'];
$iid = $item['id'] ?? 0;
}
elseif(intval($item))
$iid = $item;
if(! $iid)
if (!$iid)
return $default;
if(is_array($item) && array_key_exists('iconfig',$item) && is_array($item['iconfig'])) {
foreach($item['iconfig'] as $c) {
if($c['iid'] == $iid && $c['cat'] == $family && $c['k'] == $key)
if (isset($c['iid']) && $c['iid'] == $iid && isset($c['cat']) && $c['cat'] == $family && isset($c['k']) && $c['k'] == $key) {
if (is_string($c['v'])) {
if (str_starts_with($c['v'], 'json:')) {
$c['v'] = json_unserialize($c['v']);
} else if (preg_match('|^a:[0-9]+:{.*}$|s', $c['v'])) {
// Unserialize in inherently unsafe. Try to mitigate by not
// allowing unserializing objects. Only kept for backwards
// compatibility. JSON serialization should be prefered.
$c['v'] = unserialize($c['v'], ['allowed_classes' => false]);
}
}
return $c['v'];
}
}
}
$r = q("select * from iconfig where iid = %d and cat = '%s' and k = '%s' limit 1",
intval($iid),
dbesc($family),
dbesc($key)
);
if($r) {
$r[0]['v'] = ((preg_match('|^a:[0-9]+:{.*}$|s',$r[0]['v'])) ? unserialize($r[0]['v']) : $r[0]['v']);
if($is_item)
if (str_starts_with($r[0]['v'], 'json:')) {
$r[0]['v'] = json_unserialize($r[0]['v']);
} else if (preg_match('|^a:[0-9]+:{.*}$|s', $r[0]['v'])) {
// Unserialize in inherently unsafe. Try to mitigate by not
// allowing unserializing objects. Only kept for backwards
// compatibility. JSON serialization should be prefered.
$r[0]['v'] = unserialize($r[0]['v'], ['allowed_classes' => false]);
}
if ($is_item) {
$item['iconfig'][] = $r[0];
}
return $r[0]['v'];
}
return $default;
}
@@ -63,15 +89,15 @@ class IConfig {
* $value - value of meta variable
* $sharing - boolean (default false); if true the meta information is propagated with the item
* to other sites/channels, mostly useful when $item is an array and has not yet been stored/delivered.
* If the meta information is added after delivery and you wish it to be shared, it may be necessary to
* alter the item edited timestamp and invoke the delivery process on the updated item. The edited
* If the meta information is added after delivery and you wish it to be shared, it may be necessary to
* alter the item edited timestamp and invoke the delivery process on the updated item. The edited
* timestamp needs to be altered in order to trigger an item_store_update() at the receiving end.
*/
static public function Set(&$item, $family, $key, $value, $sharing = false) {
$dbvalue = ((is_array($value)) ? serialize($value) : $value);
$dbvalue = ((is_array($value)) ? json_serialize($value) : $value);
$dbvalue = ((is_bool($dbvalue)) ? intval($dbvalue) : $dbvalue);
$is_item = false;
@@ -162,4 +188,4 @@ class IConfig {
}
}
}

View File

@@ -25,18 +25,18 @@ class Img_filesize {
static function getLocalFileSize($url) {
$fname = basename($url);
$resolution = 0;
if(strpos($fname,'.') !== false)
$fname = substr($fname,0,strpos($fname,'.'));
if(substr($fname,-2,1) == '-') {
$resolution = intval(substr($fname,-1,1));
$fname = substr($fname,0,-2);
}
$r = q("SELECT filesize FROM photo WHERE resource_id = '%s' AND imgscale = %d LIMIT 1",
dbesc($fname),
intval($resolution)
@@ -116,7 +116,6 @@ function getRemoteFileSize($url)
curl_exec($ch);
curl_getinfo($ch);
curl_close($ch);
return $size;
}
}

View File

@@ -18,7 +18,7 @@ class JSalmon {
$precomputed = '.' . base64url_encode($data_type,true) . '.YmFzZTY0dXJs.UlNBLVNIQTI1Ng';
$signature = base64url_encode(rsa_sign($data . $precomputed, $key), true);
$signature = base64url_encode(Crypto::sign($data . $precomputed, $key), true);
return ([
'signed' => true,
@@ -40,21 +40,21 @@ class JSalmon {
$ret = [ 'results' => [] ];
if(! is_array($x)) {
return $false;
return false;
}
if(! ( array_key_exists('signed',$x) && $x['signed'])) {
return $false;
return false;
}
$signed_data = preg_replace('/\s+/','',$x['data']) . '.'
. base64url_encode($x['data_type'],true) . '.'
. base64url_encode($x['encoding'],true) . '.'
$signed_data = preg_replace('/\s+/','',$x['data']) . '.'
. base64url_encode($x['data_type'],true) . '.'
. base64url_encode($x['encoding'],true) . '.'
. base64url_encode($x['alg'],true);
$key = HTTPSig::get_key(EMPTY_STR,base64url_decode($x['sigs']['key_id']));
logger('key: ' . print_r($key,true));
$key = HTTPSig::get_key(EMPTY_STR,'zot6',base64url_decode($x['sigs']['key_id']));
logger('key: ' . print_r($key,true), LOGGER_DATA);
if($key['portable_id'] && $key['public_key']) {
if(rsa_verify($signed_data,base64url_decode($x['sigs']['value']),$key['public_key'])) {
if(Crypto::verify($signed_data,base64url_decode($x['sigs']['value']),$key['public_key'])) {
logger('verified');
$ret = [ 'success' => true, 'signer' => $key['portable_id'], 'hubloc' => $key['hubloc'] ];
}

Some files were not shown because too many files have changed in this diff Show More