Commit graph

213 commits

Author SHA1 Message Date
Eugen Rochko
1206e691bd Add ability to select all accounts matching search for batch actions () 2022-08-25 23:33:34 +02:00
Eugen Rochko
f9ebc320ed Add audit log entries for user roles ()
* Refactor audit log schema

* Add audit log entries for user roles
2022-08-25 20:39:40 +02:00
Eugen Rochko
38d04135bf Change how hashtags are normalized ()
* Change how hashtags are normalized

* Fix tests
2022-07-13 15:03:28 +02:00
Eugen Rochko
e164d6a687 Add customizable user roles ()
* Add customizable user roles

* Various fixes and improvements

* Add migration for old settings and fix tootctl role management
2022-07-05 02:41:40 +02:00
Eugen Rochko
0eb2db6b52 Add administrative webhooks ()
* Add administrative webhooks

* Fix error when webhook is deleted before delivery worker runs
2022-06-09 21:57:36 +02:00
Eugen Rochko
553889bc7c Fix single Redis connection being used across all threads ()
* Fix single Redis connection being used across all Sidekiq threads

* Fix tests
2022-04-28 17:47:34 +02:00
Eugen Rochko
f982d56b4e Remove sign-in token authentication, instead send e-mail about new sign-in () 2022-04-06 20:58:12 +02:00
Eugen Rochko
11e848bf95 Change design of federation pages in admin UI ()
* Change design of federation pages in admin UI

* Fix query performance in instance media attachments measure

* Fix reblogs being included in instance languages dimension
2022-03-09 08:52:32 +01:00
Eugen Rochko
b25b703cce Add ability to mark statuses as sensitive from reports in admin UI ()
* Add ability to mark statuses as sensitive from reports in admin UI

* Allow mark as sensitive action on statuses with preview cards
2022-03-01 22:20:29 +01:00
Claire
0b41895bbb Fix error when a MX is shared across blocked domains () 2022-02-26 17:26:28 +01:00
Eugen Rochko
e6d2b07ec1 Add trending statuses ()
* Add trending statuses

* Fix dangling items with stale scores in localized sets

* Various fixes and improvements

- Change approve_all/reject_all to approve_accounts/reject_accounts
- Change Trends::Query methods to not mutate the original query
- Change Trends::Query#skip to offset
- Change follow recommendations to be refreshed in a transaction

* Add tests for trending statuses filtering behaviour

* Fix not applying filtering scope in controller
2022-02-25 00:34:14 +01:00
Eugen Rochko
ea5bf21a1d Change e-mail domain blocks to block IPs dynamically ()
* Change e-mail domain blocks to block IPs dynamically

* Update app/workers/scheduler/email_domain_block_refresh_scheduler.rb

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>

* Update app/workers/scheduler/email_domain_block_refresh_scheduler.rb

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>

Co-authored-by: Yamagishi Kazutoshi <ykzts@desire.sh>
2022-02-24 17:28:23 +01:00
Eugen Rochko
82f8d19424 Add appeals ()
* Add appeals

* Add ability to reject appeals and ability to browse pending appeals in admin UI

* Add strikes to account page in settings

* Various fixes and improvements

- Add separate notification setting for appeals, separate from reports
- Fix style of links in report/strike header
- Change approving an appeal to not restore statuses (due to federation complexities)
- Change style of successfully appealed strikes on account settings page
- Change account settings page to only show unappealed or recently appealed strikes

* Change appealed_at to overruled_at

* Fix missing method error
2022-02-14 21:27:53 +01:00
Claire
e806b2325e Fix empty batch statuses selection causing a 500 error ()
* Fix empty batch statuses selection causing a 500 error

* Simplify current_params
2022-02-12 19:52:17 +01:00
Eugen Rochko
9b42aad433 Change actions in reports to require only one click () 2022-02-11 21:51:57 +01:00
Eugen Rochko
25d1195a04 Fix error on account relationships page in admin UI () 2022-02-05 05:06:34 +01:00
Eugen Rochko
2fb76550a9 Add notifications for statuses deleted by moderators () 2022-01-17 09:41:33 +01:00
Claire
d8da1689c1 Add ability for admins to delete canonical email blocks ()
* Add admin option to remove canonical email blocks from a deleted account

* Add tootctl canonical_email_blocks to inspect and remove canonical email blocks
2021-12-17 23:02:14 +01:00
Claire
44c8b6ff2f Add ability to purge undeliverable domains from admin interface ()
* Add ability to purge undeliverable domains from admin interface

* Add tests
2021-12-17 23:01:21 +01:00
Eugen Rochko
7bf5924339 Add batch suspend for accounts in admin UI () 2021-12-05 21:48:39 +01:00
Jeong Arm
5ac17e3a77 Fix admin statuses order() ()
* Fix 

* Add test for statuses order
2021-11-26 22:12:27 +01:00
Eugen Rochko
ad73becf3e Add trending links ()
* Add trending links

* Add overriding specific links trendability

* Add link type to preview cards and only trend articles

Change trends review notifications from being sent every 5 minutes to being sent every 2 hours

Change threshold from 5 unique accounts to 15 unique accounts

* Fix tests
2021-11-25 13:07:38 +01:00
Jeong Arm
33110dee93 Fix statuses order in account's statuses admin page () 2021-11-04 15:49:35 +01:00
Eugen Rochko
cad446611c Add graphs and retention metrics to admin dashboard () 2021-10-14 20:44:59 +02:00
Eugen Rochko
34dd743b58 Add ability to skip sign-in token authentication for specific users ()
Remove "active within last two weeks" exception for sign in token requirement

Change admin reset password to lock access until the password is reset
2021-07-08 05:31:28 +02:00
Takeshi Umeda
c958bc7297 Add management of delivery availability in Federation settings ()
* Add management of delivery availavility in Federation settings

* fix translate

* Remove useless object creation

* Fix DeepSource issue

* Add shortcut for all

* Fix DeepSource(skipcq)

* Change 'remove' to 'clear'

* Fix style

* Change class method name (exhausted_deliveries_key_by)
2021-05-05 23:39:02 +02:00
abcang
dec6f34546 Further improve the media attached status query for accounts () 2021-04-26 18:57:46 +02:00
abcang
fa2d62e6e2 Improve media attached status query () 2021-04-25 06:34:48 +02:00
Eugen Rochko
92b2d926bf Add cold-start follow recommendations () 2021-04-12 12:37:14 +02:00
Eugen Rochko
2e8a673376 Remove spam check and dependency on nilsimsa gem () 2021-04-11 11:22:50 +02:00
Eugen Rochko
19df881320 Add system checks to dashboard in admin UI () 2021-04-03 14:12:30 +02:00
Claire
7e74891ff0 Fix /admin/tags/:id crashing since Rails 6.1 update ()
Raw SQL passed to `pluck` now has to be explicitly marked as SQL via
Arel.sql, see https://github.com/rails/rails/pull/27947
2021-03-26 18:36:16 +01:00
Claire
151e79fe72 Add warning in admin dashboard if some required queues are not handled () 2021-03-26 18:22:54 +01:00
Claire
6024c263bf Further preparation for Rails 6 ()
* Use ActiveRecord::Result#to_ary instead of deprecated to_hash

They do the same thing, and to_hash has been removed from Rails 6.1

* Explicitly name polymorphic indexes to workaround a bug in Rails 6.1

cf. https://github.com/rails/rails/issues/41693

* Fix incorrect usage of “foreign_key” in migration script

* Use `ActiveModel::Errors#delete` instead of deprecated clear method

* Fix link headers tests on Rails 6.1

Rails 6.1 adds values to the Link header by default, thus it is not a
LinkHeader object anymore. Fix the test to parse the Link header instead
of assuming it is a LinkHeader.
2021-03-19 02:45:34 +01:00
Eugen Rochko
4930e71ae7 Add server rules () 2021-02-21 19:50:12 +01:00
Eugen Rochko
816df80b86 Add option to obfuscate domain name in public list of domain blocks ()
- Replace the middle of the domain with * characters (except for periods)
- Add SHA-256 digest of the domain name in tooltip
2020-12-18 08:30:41 +01:00
Eugen Rochko
df8874b24e Fix performance on instances list in admin UI ()
- Reduce duplicate queries
- Remove n+1 queries
- Add accounts count to detailed view
- Add separate action log entry for updating existing domain blocks
2020-12-14 09:06:34 +01:00
Eugen Rochko
48534762cf Fix slow distinct queries where grouped queries are faster ()
About 2x speed-up on inboxes query
2020-12-07 12:08:30 +01:00
ThibG
b1a78a5cce Change order of announcements in admin page to sort them newest-first ()
* Change order of announcements in admin page to sort show newly-created first

Fixes 

* Use reverse-chronological rather than creation date only
2020-11-04 21:15:22 +01:00
Takeshi Umeda
385c2eac6f Add account sensitized ()
* Add account sensitized

* Fix i18n normalize

* Fix description and spec

* Fix spec

* Fix wording
2020-11-04 20:45:01 +01:00
Eugen Rochko
da4c730c47 Add IP-based rules () 2020-10-12 16:33:49 +02:00
Eugen Rochko
e514304a76 Change account suspensions to be reversible by default () 2020-09-15 14:37:58 +02:00
ThibG
8baad22f68 Improve email address validation ()
* Increase DNS timeout from 1 second to 5 seconds for MX check

1 seconds is rather short when using a recursive DNS resolver which
hasn't got a cached result already available. Use 5 seconds instead,
which is the timeout value we use for outgoing HTTP queries.

* Add more precise error messages for invalid e-mail addresses
2020-08-12 12:40:25 +02:00
ThibG
8b552d6f0c Fix unpermitted operations on custom emojis leading to cryptic errors ()
* Display appropriate error when performing unpermitted operation on custom emoji

Fixes 

* Remove links to custom emoji actions not performable by moderators
2020-06-05 15:23:27 +02:00
Eugen Rochko
2d3219549b Change delivery failure tracking to work with hostnames instead of URLs () 2020-04-15 20:33:24 +02:00
Eugen Rochko
6932e0e2af Add ability to filter audit log in admin UI () 2020-04-03 13:06:34 +02:00
Eugen Rochko
9ced8b6dd5 Add option to include resolved DNS records when blacklisting e-mail domains in admin UI ()
* Add shortcuts to blacklist a user's e-mail domain in admin UI

* Add option to blacklist resolved MX and IP records for e-mail domains
2020-03-12 22:35:20 +01:00
Eugen Rochko
da9d81c4ac Add titles to warning presets in admin UI () 2020-03-12 17:57:59 +01:00
ThibG
cb93be3b88 Add ability to delete files uploaded for settings in admin UI ()
* Allow deleting site uploads

* Refactor and move links into hints

* Fix i18n tests

* Fix HTML output of site_upload_delete_hint
2020-03-08 16:00:24 +01:00
Eugen Rochko
9fb8165712 Add publish/unpublish controls to announcements in admin UI () 2020-01-27 11:05:33 +01:00