Commit Graph

2551 Commits (0a599d08d8c1d10d3784b3700ebd27efe9e6a468)

Author SHA1 Message Date
Claire 8a5b57f668
Revert "Support JSON-LD named graph ()" ()
Claire cbdd8edf68
Revamp notification policy options ()
Claire 994ef16b72
Bust CDN cache on media deletion ()
Matt Jankowski 52a626f39b
Replace more `font-awesome` icons in `app/helpers` ()
Claire 670e4655d1
Change dismissing a notification to clear existing filtered notifications for that account ()
Claire af2aec1a82
Change notification requests to only count mentions ()
Claire 719cabe024
Fix logic of block/mute bypass for mentions from moderators ()
Claire 438dac99d6
Add option to request partial accounts in grouped notifications API ()
Christian Schmidt 9d0cafd06b
Check Content-Length in ResponseWithLimitAdapter ()
Christian Schmidt e9e63ed203
Support JSON-LD named graph ()
Claire da5b45a573
Add endpoints to accept and dismiss multiple notification requests at once ()
Claire 549ab089ee
Change grouped notifications API shape (take 2) ()
Claire 598ae4f2da
Add endpoints for unread notifications count ()
Tim Rogers 2ce99c51dd
Fixed Rails route covering %40-encoded profile URL paths to not 404 ()
Emelia Smith c40e481169
Implement UI for Admin Search of Hashtags ()
Matt Jankowski 95eadabe44
Extrude `fill_in_auth_details` method to `ProfileStories` spec support module ()
David Roetzel dd53792714
Move UI tests from controller to system spec ()
Emelia Smith 693d9b03ed
Enable OAuth PKCE Extension ()
Adam Niedzielski 887e64efd4
Allow @ at the end of an URL ()
Adam Niedzielski fbf95216c5
Fix LinkCrawlWorker NoMethodError: undefined method `[]' for nil ()
Matt Jankowski bfaa53343a
Improve failure message on pagination matcher ()
Adam Niedzielski 337a7fcf30
Fix ß bug in regexp for mentions and tags ()
Matt Jankowski e881a59671
Add `User.unconfirmed` scope, reduce factories in `scheduler/user_cleanup` spec ()
Adam Niedzielski cd0ca4b994
Select correct self link when parsing Webfinger response ()
Emelia Smith bb2e5a4b58
Add audit logs to Admin::InstancesController ()
Claire ced5e853c7
Fix duplicate `orderedItems` in user archive's `outbox.json` ()
Matt Jankowski 6e4305de69
Fix spec descriptions around configurable limit values ()
Matt Jankowski ef796446e5
Ignore manifest JS parse/interrupt error on CI ()
kyori19 3a00f89aa1
Respect `Account::DISPLAY_NAME_LENGTH_LIMIT` in account spec correctly ()
Matt Jankowski 05342529dd
Reduce factory creation in AP activity move spec ()
Matt Jankowski 848b59c8ae
Reduce factory creation in `MediaAttachment` model spec ()
Matt Jankowski 47ea83d246
Reduce factory creation in `AP::ProcessStatusUpdateService` spec ()
Matt Jankowski 2616fde9e6
Use change-requiring records in admin/reports controller spec ()
Matt Jankowski c5f8256801
Reduce extra factories in `FanOutOnWriteService` spec ()
Matt Jankowski 76c2c5c748
Reduce extra round trips in `activitypub` controller specs ()
Matt Jankowski f5e90f3de3
Reduce extra round trips in `AP::SynchronizeFollowersService` spec ()
Matt Jankowski 81877e7950
Reduce extra round trips in `AP::FetchRemoteStatusService` spec ()
Emelia Smith aa88aca0ad
Add optional OAuth application to reports ()
Matt Jankowski 91ef4a6fc5
Add assertion about key columns to account key generate spec ()
Claire 1dd8262071
Add optional `filtered` attribute to notification entities in REST API ()
Matt Jankowski 00cb4a0313
Avoid repeated factory creation in media_attachments_vacuum_spec ()
David Roetzel 35a437a03f
Destroy `NotificationRequest`s that are dismissed ()
Matt Jankowski 43e24dbb13
Use `include_pagination_headers` in more places ()
Matt Jankowski 73d53827ea
Add change assertion to invites destroy spec ()
David Roetzel 2ea9336b68
Do not pass unknown encoding names to nokogiri. ()
David Roetzel 967505ee9b
Add size limit for all PreviewCard URLs ()
Daniel M Brasil 3875bd138d
Fix HTTP 500 in `/api/v1/polls/:id/votes` ()
David Roetzel fa8e972722
Fix author names as arrays in linked data. ()
Matt Jankowski f1300ad284
Rename jobs/attachments rspec tag names ()
Claire d41b43ed4f
Limit attachments to `MEDIA_ATTACHMENTS_LIMIT` when returning posts through the API ()
David Roetzel 97eddb5906
Fix details extraction when no title exists. ()
David Roetzel 016c1e4e78
Improve handling of encoding problems when creating link previews ()
Claire 502cf75b16
Merge pull request from GHSA-58x8-3qxw-6hm7
* Fix insufficient permission checking for public timeline endpoints

Note that this changes unauthenticated access failure code from 401 to 422

* Add more tests for public timelines

* Require user token in `/api/v1/statuses/:id/translate` and `/api/v1/scheduled_statuses`
Claire 395f17ca17
Merge pull request from GHSA-vp5r-5pgw-jwqx
* Fix streaming sessions not being closed when revoking access to an app

* Add tests for GHSA-7w3c-p9j8-mq3x
Emelia Smith 47f0faebc9
Implement HTML ruby tags for east-asian languages ()
David Roetzel 9be77fc0db
Revert "Add system check for missing database indexes" ()
David Roetzel ebd8e1bbb6
Add system check for missing database indexes ()
Matt Jankowski 836c0477ac
Use vips setting instead of env var in media processing spec ()
David Roetzel ff08d99d4d
Catch encoding errors when creating link previews. ()
David Roetzel 42adb6eaee
Add size limit for link preview URLs ()
Matt Jankowski f6390c3326
Use flatware to parallelize CI specs ()
Claire 7a84b76bb1
Drop favicon.ico generation ()
Matt Jankowski 8ef59729a1
Ignore intermittent chrome/manifest/icon interaction failure ()
Emelia Smith 30ae5952d2
Fix: Ensure "With Media" is highlighted from Admin Accounts page ()
Claire 8827cd597e
Fix `/admin/accounts/:account_id/statuses/:id` for edited posts with media attachments ()
Matt Jankowski 72484a194f
Remove `CacheBuster` default options ()
David Roetzel 2cab1c7b09
Improve encoding detection for link cards ()
Matt Jankowski 84a31319e9
Add `match_json_values` and use in AP worker specs ()
Claire 8098d27f84
Stop calling Webpacker in full-stack tests ()
Claire 58ace2e45e
Fix SQL error in admin measures API ()
Matt Jankowski 38c6825eda
Remove unused `Extractor#extract_cashtags_with_indices` method ()
Matt Jankowski d7b7617321
Use `class_names` in admin/account_moderation_notes helper ()
Matt Jankowski f287462f76
Fix repeated Delete/Undo assertion in remove status service spec ()
Claire 45abddb302
Fix pagination attributes not being returned in ungroupable-only pages ()
Claire bf56e982a9
Fix notifications from limited users being outright dropped ()
Claire 1dfd516284
Fix duplicate `@context` attribute in user export ()
Matt Jankowski d818ddd687
Extract `SIGN_COUNT_LIMIT` constant in `WebauthnCredential` class ()
Matt Jankowski 62d070c438
Check both before/after state in `AccountDomainBlock` spec ()
Matt Jankowski 1622f7aeb9
Remove duplicate fabricator validity checks ()
Matt Jankowski edf6d64eeb
Use correct params in `settings/preferences/appearance` spec ()
Matt Jankowski b2496177e0
Use correct params in `v1/admin/domain_allows` spec ()
Matt Jankowski cfd4823b65
Use fabricator in follow_spec ()
Matt Jankowski 9cc4040308
Extract `COMMENT_SIZE_LIMIT` constant in `AP::Activity::Flag` class ()
Matt Jankowski 9bf2e2eda0
Extract `TEXT_LENGTH_LIMIT` constant in `Appeal` class ()
Matt Jankowski 3e3f3d7580
Match report validation spec to extracted constant ()
Matt Jankowski 92b3004bf3
Reference constants from account validation specs ()
Daniel M Brasil 28f9a8f2ec
Add Specs for Scheduled Status Model Validations ()
Daniel M Brasil 77c2216e47
fix: Return HTTP 422 when scheduled status time is less than 5 minutes ()
Matt Jankowski 827e36ff9e
Fix `Capybara/NegationMatcher` cop in spec/system ()
Claire 1408733386
Fix Mastodon relying on ImageMagick even with `MASTODON_USE_LIBVIPS` ()
Matt Jankowski 04ebbe3077
Add `sidekiq_inline` to appeal service spec ()
Matt Jankowski 07cc94e05f
Use `sidekiq_inline` in requests/api/v1/admin/account_actions spec ()
Matt Jankowski 9b9b0e25b6
Use `sidekiq_inline` in requests/api/v1/reports spec ()
Matt Jankowski a662c6d1d8
Use `sidekiq_inline` in admin/account_action model spec ()
Eugen Rochko a2505e8611
Add timeline of public posts about a trending link to REST API ()
Emelia Smith e02d23b549
Change `read:me` scope to `profile` scope ()
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
Emelia Smith 4655be0da6
Fix add validation to webpush subscription keys ()
Eugen Rochko 5f15a892fa
Add support for libvips in addition to ImageMagick ()
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
Emelia Smith eef2cc054f
Add url validation to Web::PushSubscription endpoints ()
Matt Jankowski 249cbc449c
Use existing config access to `local_domain` value ()
Claire 974335e414
Add experimental server-side notification grouping ()
Matt Jankowski 4d047b95ae
Use more direct attribute handling in `User` fabricator ()
Claire 16249946ae
Merge pull request from GHSA-q3rg-xx5v-4mxh
Claire 3ea4275ae3
Merge pull request from GHSA-5fq7-3p3j-9vrf
Emelia Smith d20a5c3ec9
Fix: remove broken OAuth Application vacuuming & throttle OAuth Application registrations ()
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
Claire 36fe8f8566
Change `ids` param to `id` in `/api/v1/statuses` and `/api/v1/accounts` for consistency ()
Matt Jankowski c61e356475
Add `Status::MEDIA_ATTACHMENTS_LIMIT` configuration constant ()
Matt Jankowski 564ebfefcf
Remove hard reference from status pin validator spec ()
Claire 133d98fb25
Normalize language code of incoming posts ()
Matt Jankowski 3a862439df
Remove unused account record in api/v2/admin/accounts spec ()
Claire 32223863a5
Add coverage to `/admin/accounts/:id` ()
Claire 89f89d738f
Revert "Allow unblocking email addresses from any matching account ()" ()
Matt Jankowski 0a2110b9af
Add coverage for custom filters ()
Claire de4815afda
Add more tests for self-destruct mode ()
Matt Jankowski def6b686ff
Fix `Rails/WhereRange` cop ()
Matt Jankowski 70608f824e
Add coverage for `AdminMailer#auto_close_registrations` ()
Emelia Smith 2da2a1dae9
Support multiple redirect_uris when creating OAuth 2.0 Applications ()
Matt Jankowski 65e82211cd
Rename `cache_*` methods to `preload_*` in controller concern ()
Emelia Smith 5fd56512de
Improve Report Notes and Account Moderation Notes ()
Jason Punyon 85c625d319
Fix repetitive database queries from ()
Matt Jankowski 6beead3867
Move `simplecov` config into `rails_helper` ()
Renaud Chaput 40639510f8
Retain unconfirmed users longer (1 week) ()
Matt Jankowski 0d397db5dd
Consolidate system specs into single directory, use rspec tags for configuration ()
Matt Jankowski fa43a6c835
Use more accurate `redirect_uri` in oauth spec ()
Claire 2fe1b8d169
Add API to get multiple accounts and statuses ()
Co-authored-by: noellabo <noel.yoshiba@gmail.com>
Fawaz Farid bc24c4792d
Allow admins to configure instance favicon and logo ()
Emelia Smith 116f01ec7d
Implement RFC 8414 for OAuth 2.0 server metadata ()
Claire 30ef9fccf0
Fix hashtag matching pattern matching some link anchors ()
Matt Jankowski dbaa4ed891
Use `chewy` which relaxes ES version reqs ()
Claire e5062b7135
Fix post deletion not being deferred when those are part of an account warning ()
Claire 253ead3aa7
Fix not being able to block a subdomain of an already-blocked domain through the API ()
Matt Jankowski 1e7d5d2957
Update `devise-two-factor` to version 5.0.0 ()
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
Matt Jankowski 2447497a4c
Status length validation spec updates ()
Claire 91ca90e25b
Fix Idempotency-Key ignored when scheduling a post ()
Claire e845594878
Fix moderator account being exposed in account moderation notification ()
Claire 4ef0b48b95
Add in-app notifications for moderation actions/warnings ()
Emelia Smith 049b159beb
Add read:me OAuth 2.0 scope, allowing more limited access to user data ()
Matt Jankowski a15139bc02
Fix intermittent order based failure in `UpdateStatusService` spec ()
Matt Jankowski f5d341382e
Add `any_args` to have_enqueued_sidekiq_job call (quiets deprecation) ()
Matt Jankowski 11e0049b08
Use enum-generated scopes/queries for `BulkImport` ()
Claire 8bece467f8
Change `have_enqueued_sidekiq_job` usage to always make argument expectations explicit ()
Matt Jankowski 650c548c31
Add `not_featured_by` scope to Tag ()
Matt Jankowski 9ce2db4136
Combine double subject runs and DRY up change check in bulk import service spec ()
Matt Jankowski 6fed108703
Use Rails `upsert` to generate update_count! query in Counters concern ()
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
Matt Jankowski 7fed4a9740
Pull out repeated setup to shared setup in statusus/show view spec ()
Matt Jankowski 61d108f415
Extract `header_tags` method in statuses/show view spec ()
Matt Jankowski da6b9238f5
Expand coverage for admin/metrics/measure/* classes ()
Matt Jankowski ec5a0e0f5e
Expand coverage for admin/metrics/dimension/* classes ()
Matt Jankowski 449f99e168
Fix repeated concat output buffer duplicating layout markup ()
Matt Jankowski 576554b19b
Use fabrication sequence in domain values ()
Matt Jankowski 285f63c02e
Use composable query in `User.active` scope ()
Claire babbf6017d
Remove caching in `cache_collection` ()
Claire e73cf356d2
Move OAuth flow tests from feature tests to system tests ()
Matt Jankowski b61ae28f8d
Separate methods for theme style and meta color tags ()
Matt Jankowski 59da591d13
Improve spec for dimension/languages admin metric ()
Claire 38b9d31f63
Improve email address validation ()
Claire 1f11aa5f04
Add stub for trending tags in user mailer spec ()
Matt Jankowski 191bf5876e
Add coverage for sanitize failure path in api/web/embeds spec ()
Matt Jankowski f87959ab50
Fix `RSpec/LetSetup` cop in api/v1/timelines/public spec ()
Matt Jankowski 34489591ec
Add `max_pinned_statuses` to instances serializer and api response ()
Renaud Chaput b4d991adaa
Use integers and not numbers in notification policy API counters ()
renovate[bot] 589e34d00c
Update dependency selenium-webdriver to v4.19.0 ()
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
Claire 9c24f2d6b1
Undo notification permissions on individual and domain blocks ()
Claire 81a04ac25c
Improve specs for severed relationships ()
Matt Jankowski 34f293475e
Fix results/query in `api/v1/featured_tags/suggestions` ()
Claire 05eda8d193
Remove severed relationship notifications for single account suspensions ()
Claire 814a48517f
Add some more tests for notification policies ()
Claire 7434c9c276
Fix the relationships controller spec, since it requires an extra model now ()
Claire 44bf7b8128
Add notifications of severed relationships ()
Claire 8a1423a474
Allow unblocking email addresses from any matching account ()
Matt Jankowski 6d2986017e
Remove unused `active_nav_class` helper method ()
Claire d5063072c3
Revert friends-of-friends follow recommendation query to using a CTE ()
Matt Jankowski 92855948a0
Remove unused `show_landing_strip?` helper method ()
Matt Jankowski ecdbf15ebe
Remove unused `link_to_older` and `link_to_newer` helper methods ()
Matt Jankowski 4f4132f1a1
Add diagnostic message for failure during CLI search deploy ()
Matt Jankowski 2e91a9bd34
Add `include_pagination_headers` matcher to check `Link` header in api specs ()
Matt Jankowski e75b55a6d7
Extract target account on list method in bulk import row service spec ()
Matt Jankowski 974c7672e5
Extract shared behavior methods in oauth feature spec ()
Matt Jankowski 0bc17a3d48
Use enum-generated `public_visibility` scope on Status ()
Matt Jankowski 681a89f684
Readability clean up in `ImportVacuum` spec ()
Matt Jankowski f9100743ec
Add `Api::ErrorHandling` concern for api/base controller ()
Matt Jankowski 42875fee52
Add coverage for bad args/options in `CLI::Domains#purge` ()
Matt Jankowski 71e5f0f48c
Add coverage for suspended instance actor scenario ()
Matt Jankowski 6262ceeb70
Fix `RSpec/DescribedClass` cop ()
Matt Jankowski c09b8a7164
Add `Account.without_internal` scope ()
Co-authored-by: Claire <claire.github-309c@sitedethib.com>
Matt Jankowski 46e902f1f3
Merge `api/v1/accounts/credentials` controller spec into existing request spec ()
Matt Jankowski 01b624c4a0
Use `normalizes` on `CustomFilter#context` value ()
Matt Jankowski 71eecbfa1f
Move `api/v2/filters/*` to request spec ()
Matt Jankowski 8349b45d60
Accept extra args that we wont verify in `ap/activity/add_spec` ()
Matt Jankowski 469028b6d3
Remove unneeded `type: :service` from spec/services files ()
Matt Jankowski 3eaac3af73
Use `before_all` block to setup `requests/cache_spec` data ()
Matt Jankowski 19f0590795
Add basic coverage for `TagSearchService` class ()
Matt Jankowski 96013cd576
Reduce `RSpec/ExampleLength` in CSP request spec ()
Matt Jankowski 216cea1e27
Fix incorrect frequency value in `FriendsOfFriendsSource` data ()
Matt Jankowski 24319836de
Convert request-based setup into factory setup in push/subscriptions request spec ()
Matt Jankowski a38e424185
Use unchanging github links in docs/comments ()
Eugen Rochko c10bbf5fe3
Add notification policies and notification requests in web UI ()
Jeong Arm 4a6ddbc9c0
Normalize idna domain before account unblock domain ()
Matt Jankowski a7284690fc
Add coverage for admin/metrics base classes, simplify subclass generation ()
Matt Jankowski 98ef38e34e
Ensure unique values in fabricators ()
Eugen Rochko 50b17f7e10
Add notification policies and notification requests ()
Claire ee8d0b9447
Fix follow suggestions potentially including silenced or blocked accounts ()
Matt Jankowski 18945f62e0
Convert more API specs from controller->request style ()
Daniel M Brasil a25014de8f
Improve `IpBlock` model test coverage ()
Matt Jankowski 3389c41b58
Move `nobody` position in `UserRole` magic number to constant ()
Matt Jankowski eb1b8f69de
Allow pagination `Link` headers on API accounts/statuses when pinned true ()
Matt Jankowski 6675bf574a
Extract `parsed_uri_query_values` helper in ap/replies controller spec ()
Matt Jankowski 14c65180df
Use sequence in `software_update` fabricator to allow multiple ()
Matt Jankowski 8f3c91fc3c
Add `change` block expectation to `admin/invites#deactivate_all` spec ()
Claire 6f7615ba86
Add basic end-to-end test for admin moderation interface ()
Matt Jankowski 9e78129e6e
Use "cacheable response" shared example in more places ()
Matt Jankowski 8156113d58
Use `response_vary_headers` method in requests/cache_spec ()
Damien Mathieu 1540f42522
Better tests for auth/registrations#update ()
Wolfgang Fournès d51c3ac087
Add a missing spec to `SessionsController#webauthn_options` ()
Matt Jankowski b0064ddda7
Add basic coverage for `MoveService` class ()
Matt Jankowski a6ed148769
Use heredoc on the `HTML` blocks in verify link spec ()
Claire 9d8dfeb5fb
Fix processing of `Link` objects in `Image` objects ()
Claire 5152dd869e
Fix link verifications when page size exceeds 1MB ()
Claire b71904816a
Change registrations to be disabled by default for new servers ()
Matt Jankowski e9b0f0c314
Add basic coverage for `RemoveDomainsFromFollowersService` class ()
Matt Jankowski 7c7dfe7de3
Add basic coverage for `RemoveFeaturedTagService` class ()
Matt Jankowski 6342ddd698
Add basic coverage for `UnfavouriteService` class ()
Matt Jankowski f70905f127
Add basic coverage for `UnmuteService` class ()
Matt Jankowski a69fe534e3
Add basic coverage for `WebhookService` class ()
Matt Jankowski d1602c017d
Add basic coverage for `ApproveAppealService` class ()
Matt Jankowski ab2ef63a03
Add basic coverage for `VoteService` class ()
Claire 2751acb6cd
Automatically switch from open to approved registrations in absence of moderators ()
Matt Jankowski 08342ad40c
Add basic coverage for `AfterUnallowDomainService` class ()
Matt Jankowski 8f61e32569
Add basic coverage for `AppealService` class ()
Matt Jankowski b73932461f
Add basic coverage for `CreateFeaturedTagService` class ()
Matt Jankowski 5f19e7e799
Add basic coverage for `ProcessHashtagsService` class ()
Matt Jankowski 1f648fdf1a
Remove erroneous service type on `TagFeed` model spec ()
Matt Jankowski 64f9939e39
Use `capture_emails` helper to improve email assertions in specs ()
Wolfgang Fournès 86627ea2e4
Add a missing thread example to the statuses spec ()
Matt Jankowski 245064bb98
Move "everyone" role and "instance actor" account magic number IDs to constants ()
Claire 96ddf1d482
Fix flaky end-to-end OCR test ()
Matt Jankowski 1946e171e6
Reduce round trips in admin/disputes/appeals spec ()
Matt Jankowski 3454fcbd71
Reduce round trips in auth/sessions spec ()
Matt Jankowski a316c0e38d
Reduce round trips in disputes/appeals spec ()
Matt Jankowski 117b507df5
Extract `subject` from `User#mark_email_as_confirmed!` spec ()
Matt Jankowski 1690fb39e6
Reduce `RSpec/MultipleExpectations` in instance_actors_controller spec ()
Matt Jankowski bba488c189
Reduce `RSpec/MultipleExpectations` in media_attachment spec ()
Claire 9fee5e8526
Merge pull request from GHSA-jhrq-qvrm-qr36
* Fix insufficient Content-Type checking of fetched ActivityStreams objects

* Allow JSON-LD documents with multiple profiles
Matt Jankowski a9f9b0097b
Reduce `RSpec/MultipleExpectations` in captcha feature spec ()
Matt Jankowski 4b7f04e3ea
Reduce `RSpec/MultipleExpectations` in post_status_service spec ()
Matt Jankowski ed4939296a
Reduce `RSpec/MultipleExpectations` in ap/activity/create spec ()
Matt Jankowski 1df2ffc3ee
Use `subject` in blacklist email validator spec ()
Matt Jankowski fc4f823464
Avoid local block var assignment in ap/process_status_update_service spec ()
Claire d4d0565b0f
Fix user creation failure handling in OAuth paths ()
Claire bbbbf00084
Fix OmniAuth tests ()