Commit Graph

169 Commits

Author SHA1 Message Date
Hugo Sales 3a5e52ee0d
[CORE][SECURITY] Move to the new authentication format, for Symfony 5.3
Keep using (deprecated) Guard
2021-11-24 12:46:26 +00:00
Hugo Sales c68d7ae406
[CONTROLLER][UserPanel] Make function names camelCase 2021-11-20 21:33:25 +00:00
Diogo Peralta Cordeiro 89d36a68e5
[ENTITY][Actor] Add is_local, it's common to depend, and this makes it much faster, with a low space cost 2021-11-16 23:26:20 +00:00
Hugo Sales 587d701d11
[CONTROLLER][Network] Temporarily remove replies from streams, following planned changes to the Reply plugin 2021-11-15 19:25:52 +00:00
Hugo Sales 774eb49af4
[UI][CONTROLLER][UserPanel][ENTITY][ActorLanguage][Language][Actor] Add interface to allow user to select thier preferred languages and to order them. Rename ActorLanguage::order to ordering 2021-11-15 19:25:52 +00:00
Hugo Sales d5e6fd603d
[CONTROLLER][UserPanel] Fix 'could not convert IntergetType to string' error 2021-11-15 19:25:51 +00:00
Hugo Sales 1abd28c949
[UI][TWIG][CONTROLLER][UserPanell] Add way to expand details with a GET parameter. Implement it in UserPanel 2021-11-15 19:25:51 +00:00
Hugo Sales eab6de3609
[TESTS][Security] Fix SecurityTest. Remove nickname normalization on register (a plugin can handle that). Move from filter_var(FILTER_VALIDATE_EMAIL) as it does not support dotless domains 2021-11-15 19:25:50 +00:00
Hugo Sales f667b558f7
[TESTS] Fix SecurityTest
This test was broken by changes in the routing and in the templates.
However, this revealead a potential open redirect and duplicated code
in the Reply and Favourite plugins
2021-11-11 12:39:28 +00:00
Hugo Sales f0c532340e
[DB] Fix uses of `DB::sql`, to remove the deprecated second `entities` parameter 2021-11-08 20:35:38 +00:00
Diogo Peralta Cordeiro f98afd15ce
[ENTITY] Refactor Follow as Subscription 2021-11-08 16:14:23 +00:00
Eliseu Amaro 91dd6e1428
[Controller][Security] Fullname is not setup automatically upon registering anymore.
[ENTITY][Actor] Changes to accomodate fullname from potentially being null.
[ENTITY][Note] Changes to accomodate fullname from potentially being null.
2021-10-29 22:05:10 +01:00
Eliseu Amaro 3e2fefa8af
[TWIG][Cards] Fullname is now displayed as the note author, nickname as an identification.
[CONTROLLER][Security] Fullname is set on resgistration to enable it to be shown by default in notes.
[CONTROLLER][UserPanel] Fullname extra step added.
[CSS] Fullname and nickname representation work.
2021-10-27 20:44:50 +01:00
Hugo Sales 299e893ca9
[TOOLS][PHPStan][DocCheck] Fix errors found by PHPStan and Doc Check 2021-10-27 04:19:31 +01:00
Hugo Sales 8a10fec31d
[CONTROLLER][UserPanel] Make all fields in settings not required 2021-10-27 04:19:30 +01:00
Hugo Sales 2694d83ae4
[TOOLS][CS-FIXER] Run new PHP CS Fixer config. Notably, adds strict_types 2021-10-27 04:19:30 +01:00
Diogo Peralta Cordeiro 8544fe157b
[FreeNetwork] First steps porting webfinger/lrdd to v3, GET webfinger requests already have a basic result 2021-10-27 04:19:29 +01:00
Diogo Peralta Cordeiro 44cf1fa24c
[UTIL][Nickname] Fix some parameters issues found with strict types 2021-10-27 04:19:29 +01:00
Hugo Sales 9109c61af5
[TOOLS][CS-FIXER] Run new PHP CS Fixer config. Notably, adds strict_types 2021-10-27 04:19:28 +01:00
Diogo Peralta Cordeiro 03f6029ce5
[SECURITY] Fix nickname validation and properly allow email auth 2021-10-18 13:22:55 +01:00
Eliseu Amaro 17a13b3f20 [CSS] Fix: Left and right panel checkbox border when active. 2021-10-04 12:31:06 +01:00
Eliseu Amaro 80d1be323d [COMPONENTS][Search][CSS] Extra header forms now accessible through a details element. Re-organizing templates structure. 2021-10-04 12:17:14 +01:00
Eliseu Amaro a557ba0224 [Timelines][Plugins][Left] Plugins now provide their path ID. Feed redone as it's own independant template. 2021-09-22 16:47:06 +01:00
Diogo Peralta Cordeiro 05f16a3084
[ENTITY][AttachmentThumbnail] Now thumbnails are always only available in three sizes: small, medium, big
Commit jointly produced with eli (Eliseu Amaro)

Breaking change: Entity changed to only store the tinyint referring to the size stored

With this, the logic was simplified and now it's not possible to make an
instance produce unnecessary thumbs. The aspect ratio is preserved and
thus the thumbs will always look nice. New configuration was added to
maintain flexibility.
2021-09-22 15:13:46 +01:00
Diogo Peralta Cordeiro 941cbe6599
[Actor] Refactor GSActor into Actor 2021-09-18 05:12:17 +01:00
Diogo Peralta Cordeiro d6f31d102a
[CORE][ActivityStreamsTwo][ActivityPub] Set all routes
Allow global routes to act for every actor
Fix Favoured stream query
2021-09-18 05:12:15 +01:00
Eliseu Amaro 26af284353 [CONTROLLER][SECURITY] Registration feedback. The flashError works. However, Symfony's Exception error page is viewed upon trying to register. 2021-09-15 14:48:06 +01:00
Diogo Peralta Cordeiro 365edbaff0
[ActivityStreamsTwo] Initial Actor support
Various bug fixes
2021-09-15 10:26:53 +01:00
Hugo Sales 4e30e5aad9
[TOOLS] Fix all issues found by PHPStan level 2 2021-09-14 13:13:44 +01:00
Hugo Sales add8f4a52f
[TOOLS] Fix all errors found by PHPStan level 1 2021-09-14 13:13:42 +01:00
Hugo Sales eb833b62e2
[TOOLS] Fix all level 0 errors found by PHPStan and move constant definition to bootstrap file 2021-09-14 13:13:42 +01:00
Hugo Sales 4916c8cbda
[CONTROLLER][AdminPanel] Add missing Exception import 2021-09-14 13:13:41 +01:00
Diogo Peralta Cordeiro e4aa3ae968
[NOTE] Add route and controller 2021-09-14 13:13:37 +01:00
Diogo Peralta Cordeiro 2a3db65216
[CONTROLLER][Attachment] Some attachments may not have dimensions 2021-09-14 13:13:34 +01:00
Hugo Sales 458b6d0009
[UI] Rename all forms to more specific names, to avoid form name collisions 2021-09-14 13:13:33 +01:00
Hugo Sales 6799052ff5
[ATTACHMENTS] Ensure thumbnail dimensions are bounded and change way cropping is implemented 2021-09-14 13:13:32 +01:00
Hugo Sales e2e6c7a5bf
[TESTS] Hot-fix Security controller tests, broken with ongoing form rendering changes 2021-09-14 13:13:30 +01:00
Eliseu Amaro 87d7318de5
[CONTROLLER][SECURITY] Added class names. Help labels for each form element. Each form element now has a proper block prefix (the resulting HTML won't simply concatenate the form's name to the element's label). 2021-09-14 13:13:30 +01:00
Hugo Sales 3843348c1b
[CONTROLLER][Attachment] Small refactor and add testing annotation 2021-09-14 13:13:28 +01:00
Diogo Peralta Cordeiro 968e3431e1
[Attachment] Sometimes we can't provide download of original file 2021-09-14 13:13:26 +01:00
Diogo Peralta Cordeiro 3f61537140
[ENTITY] Split Attachment in various new entities
Remove Attachment Scope
Fixed some minor bugs

Scope will be implemented later in v3. It doesn't make sense to have
the scope handling being per attachment. Different actors can post
the same attachment with different scopes. The attachment controller
will assume the highest level of scope applied to the attachment and
the rest will be handled at the note level.

Motivation:
* Remove title from attachment, as it's part of the relation between attachment and note.
* Remove actor from attachment, many actors may publish the same attachment.
* Remove is_local from attachment,  as it's part of the relation between attachment and note.
* Remove remote_url from attachment, different urls can return the same attachment.

Addition:
* Attachment now has a lives attribute,  it's a reference counter with a nicer name
* GSActorToAttachment
* GSActorToRemoteURL
* RemoteURL
* RemoteURLToNote
* RemoteURLToAttachment
* AttachmentToNote now has a title attribute
2021-09-14 13:13:24 +01:00
Hugo Sales 061a85d6b3
[EVENTS] Change FormatNoteList do separate in and out arguments
This is necessary due to some weird problem which I wasn't able to figure out (but which doesn't matter)
that somehow causes the event to be called twice during testing, and thus the function was exploding
2021-09-14 13:13:23 +01:00
Hugo Sales b5de80303a
[TEST] Raise test coverage for UserPanel to 100% 2021-09-14 13:13:23 +01:00
Hugo Sales 480665afc8
[CONTROLLER][UserPanel] Finish implementation of ::notifications so it actually saves the values in the database 2021-09-14 13:13:23 +01:00
Hugo Sales cdf3426567
[CONTROLLR][UserPanel][PLUGINS] Add submit button to notification settings for each transport 2021-09-14 13:13:23 +01:00
Hugo Sales afbcb179b2
[CONTROLLER][AdminPanel] Further ensure form validity 2021-09-14 13:13:23 +01:00
Hugo Sales 1b623a85ae
[UTIL][FormFields] Move FormFields class to Util\Form namespace 2021-09-14 13:13:22 +01:00
Hugo Sales 0ae67d96ea
[TESTS] Raise test coverage for AdminPanel to 100% 2021-09-14 13:13:19 +01:00
Diogo Peralta Cordeiro b77e35ef09
[SECURITY] Do not require email when in development 2021-09-14 13:13:19 +01:00
Hugo Sales fe7c2b5115
[TESTS] Raise test coverage for AdminPanel controller to 100% 2021-09-14 13:13:19 +01:00