about summary refs log tree commit diff
path: root/spec/validators
AgeCommit message (Collapse)Author
2022-06-09Add administrative webhooks (#18510)Eugen Rochko
* Add administrative webhooks * Fix error when webhook is deleted before delivery worker runs
2022-04-29Remove IP matching from e-mail domain blocks (#18190)Eugen Rochko
Clear out e-mail domain blocks created from automatically resolved DNS records
2022-03-30Fix being able to post URLs longer than 4096 characters (#17908)Eugen Rochko
2022-02-24Change e-mail domain blocks to block IPs dynamically (#17635)Eugen Rochko
* 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-22Fix various typos (#17621)luzpaz
Found via `codespell -q 3 -S ./CHANGELOG.md,./AUTHORS.md,./config/locales,./app/javascript/mastodon/locales -L ba,keypair,medias,ro`
2022-01-17Add support for private pinned posts (#16954)Claire
* Add support for private pinned toots * Allow local user to pin private toots * Change wording to avoid "direct message"
2021-04-17Add canonical e-mail blocks for suspended accounts (#16049)Eugen Rochko
Prevent new accounts from being created using the same underlying e-mail as a suspended account using extensions and period permutations. Stores e-mails as a SHA256 hash
2021-03-19Bypass MX validation for explicitly allowed domains (#15930)Claire
* Bypass MX validation for explicitly allowed domains This spares some lookups and prevent issues in some edge cases with local domains. * Add tests * Fix test
2021-03-19Prepare Mastodon for zeitwerk autoloader (#15917)Claire
* Prepare Mastodon for zeitwerk autoloader (Rails 6) Add inflections and rename/move a few classes. In particular, app/lib/exceptions.rb and app/lib/sanitize_config.rb were manually loaded while still in autoload paths. * Add inflection for Url → URL
2021-03-04Fix URL scanning in note length validator and preview card fetching (#15827)Claire
* Add tests * Fix URL scanning in note length validator and preview card fetching
2021-03-02Update twitter-text from 1.14 to 3.1.0 and fix toot character counting (#15382)Claire
* Update twitter-text from 1.14 to 3.1.0 * Disable emoji parsing * Properly depend on twitter-text for url detection * Fix some URLs being wrongly detected client-side * Add test for server-side validation of non-autolinkable URLs * Fix server-side status length counting
2021-03-01Add `details` to error response for `POST /api/v1/accounts` in REST API (#15803)Eugen Rochko
2020-08-12Improve email address validation (#14565)ThibG
* 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-02-01Search account domain in lowercase (#13016)abcang
* Search account domain in lowercase * fix rubocop error * fix spec/models/account_spec.rb
2020-01-25Fix validations of reactions limit (#12955)Eugen Rochko
2019-08-05Change admin UI for hashtags and add back whitelisted trends (#11490)Eugen Rochko
Fix #271 Add back the `GET /api/v1/trends` API with the caveat that it does not return tags that have not been allowed to trend by the staff. When a hashtag begins to trend (internally) and that hashtag has not been previously reviewed by the staff, the staff is notified. The new admin UI for hashtags allows filtering hashtags by where they are used (e.g. in the profile directory), whether they have been reviewed or are pending reviewal, they show by how many people the hashtag is used in the directory, how many people used it today, how many statuses with it have been created today, and it allows fixing the name of the hashtag to make it more readable. The disallowed hashtags feature has been reworked. It is now controlled from the admin UI for hashtags instead of from the file `config/settings.yml`
2019-05-19Fix “invited by” not showing up for invited accounts in admin interface ↵ThibG
(#10791)
2019-05-03Change e-mail whitelist/blacklist to not be checked when invited (#10683)Eugen Rochko
* Change e-mail whitelist/blacklist to not be checked when invited And only when creating an account, not when updating it later Fix #10648 * Fix test
2019-04-09Allow set the voting period to just 5 minutes (#10525)Hinaloe
* Add spec of PollValidator for #10190 * Raise fraction less than 1 second * format * simplify time initialize
2019-02-12Add support for IPv6 only MXes in Email validation (#10009)Franck Zoccolo
* Add support for IPv6 only MXes * Fixed email validator tests
2019-01-03Add specs for UrlValidator (#9699)ysksn
2019-01-03Add specs for UnreservedUsernameValidator (#9698)ysksn
* Add specs for UnreservedUsernameValidator * Use instance variable
2018-12-29Add specs for FollowLimitValidator (#9655)ysksn
2018-12-29Add specs for BlackListedEmailValidator (#9651)ysksn
* Add specs for BlackListedEmailValidator * Use instance variable
2018-12-29Add specs for DisallowedHashtagsValidator (#9653)ysksn
In order to implement tests easier, `#select_tags` created.
2018-12-28Add specs for StatusPinValidator (#9648)ysksn
2018-12-28Add pending specs for StatusLengthValidator (#9647)ysksn
* Add pending specs of StatusLengthValidator * Use instance variable
2018-12-10Improve e-mail MX validator and add tests (#9489)Eugen Rochko
2018-12-07Remove pending spec (#9454)ysksn
Since dots are not allowed in username, this spec is no longer needed.
2018-03-27Add a spec for UniqueUsernameValidator (#6927)unarist
Note that this spec has a pending test about dots in the username, because allowing it has been reverted for now.
2017-07-29Count all URLs in text as 23 characters flat, do not count domain part of ↵Eugen Rochko
usernames (#4427) * Count all URLs in text as 23 characters flat, do not count domain part of usernames * Add new status text counting logic to web UI