Commit Graph

173 Commits

Author SHA1 Message Date
Ehren Kret
417d48c452 Block downgrading sender key support
Disallow linking an additional device to an account that has already
upgraded to having sender key support where the linked device does not
have sender key support. This should prompt the person attempting to
link the older application to upgrade in order to complete the linking
process.
2021-05-25 10:30:26 -05:00
Chris Eager
215621a9b0 Remove temporary adaptation for nested IncomingMessage.online 2021-05-24 11:36:15 -05:00
Ehren Kret
5290656c3b Fix typo 2021-05-20 15:11:44 -05:00
Ehren Kret
0cd3640f13 Add more tests 2021-05-18 13:09:40 -05:00
Ehren Kret
c595d9415c Change from quadratic scan to use more memory instead 2021-05-18 13:09:40 -05:00
Ehren Kret
f76e6705c0 Add handling of registration id in multi recipient send payload 2021-05-18 13:09:40 -05:00
Ehren Kret
6906336dfb Include the uuid with the list of mismatched devices 2021-05-14 14:46:56 -05:00
Chris Eager
e320626c6e Add report message API 2021-05-13 17:19:34 -05:00
Ehren Kret
57ff9f86f5 Refactor repeated use of the UserCapabilities constructor 2021-05-13 12:08:59 -05:00
Ehren Kret
bfd2c32d4e Add sender key capability 2021-05-12 18:15:25 -05:00
Ehren Kret
e9a3d52d7f Add an optional description to the payment intent request 2021-05-12 18:14:33 -05:00
Jon Chambers
46110d4d65 Add client challenges for prekey and message rate limiters 2021-05-11 16:21:32 -05:00
Ehren Kret
17047513c3 Create stripe api endpoint for apple pay donations 2021-05-11 10:03:04 -05:00
Jon Chambers
bf32b766a5 Don't generate stack traces for rate limit exceptions. 2021-05-07 10:44:31 -04:00
Jon Chambers
b41f97233e Measure source country for all pre-key requests. 2021-05-06 11:58:14 -04:00
Jon Chambers
cf495ef7cf Key the message rate limiter to sender e164, not UUID. 2021-05-04 15:18:59 -04:00
Ehren Kret
c448c37cc9 Add logic to handle sending a common payload to multiple recipients 2021-05-04 13:34:27 -05:00
Jon Chambers
6196856a7c Use the JDK-provided Base64 encoder/decoder. 2021-04-26 18:17:03 -04:00
Jon Chambers
0e8d4f9a61 Drop Bouncy Castle as a dependency. 2021-04-26 17:58:19 -04:00
Chris Eager
62315f423c Record duration of successful verifications 2021-04-26 14:31:52 -05:00
Chris Eager
1f53900345 Migrate VoiceVerificationController to Util#findBestLocale 2021-04-26 14:31:52 -05:00
Chris Eager
13053da97f Add Twilio Verify experiment to AccountController 2021-04-26 14:31:52 -05:00
Chris Eager
f190462879 Fully implement unsealed sender cardinality rate limiter 2021-04-23 11:45:53 -05:00
Chris Eager
b7c56108ca Rate limit unsealed sender by E164 2021-04-20 13:00:29 -05:00
Jon Chambers
4d33ba48cc Discard some tools intended to detect abusive behavior that turned out to not actually be that helpful. 2021-04-14 11:18:19 -04:00
Sanket.Ghenand@tomtom.com
37bda0b035 remove unused imports 2021-04-13 11:44:59 -05:00
Chris Eager
dea359ef91 Add metric tag for prekey target type 2021-03-31 17:59:47 -04:00
Chris Eager
ad6c271f9d Add dynamic configuration for signup captcha by country code 2021-03-30 10:22:02 -05:00
Chris Eager
c10d9603ad Add metric for international PreKey requests 2021-03-29 14:52:04 -05:00
Jon Chambers
7e29ed1cc7 Block attempts to set wallet addresses from unsupported countries. 2021-03-26 12:21:11 -04:00
Chris Eager
19295eef46 Add dimensional metrics for account creation and verification 2021-03-18 12:45:20 -05:00
Jon Chambers
0bc1369e04 Work through the full list of supported locales when choosing a language for voice verification. 2021-03-18 13:29:09 -04:00
Jon Chambers
ca2f7d2eed Parse locale strings when sending voice verification codes. 2021-03-18 13:29:09 -04:00
Jon Chambers
738ec2a38e Use ForwardedIpUtil everywhere we're handling X-Forwarded-For values. 2021-03-10 10:37:10 -05:00
Jon Chambers
58210141f4 Discard unhelpful message count histograms. 2021-03-08 16:57:26 -05:00
Jon Chambers
af2a8548c3 Use Durations everywhere, drop unused constructors, and add tests. 2021-03-05 12:47:36 -05:00
brock-signal
1faedd3870 Return Retry-After time to clients when they are rate limited (#421)
* Return Retry-After time to clients when they are rate limited

* Update based on feedback

- New exception type that is mapped differently
- Always report time until allowed on rate limits
- Consume and transform into a differnt exception if we think it will be
  allowed later
2021-03-05 10:23:03 -07:00
Jon Chambers
f57a4171ba Gather IP-based metrics for international, unsealed-sender messages. 2021-03-05 11:54:01 -05:00
Jon Chambers
eb6fe11da1 Add tools to decline messages from senders meeting specific conditions 2021-02-24 18:09:26 -05:00
Jon Chambers
0ee3f0a5b5 Fix a goof where the international unsealed sender country meter was incrementing unconditionally. 2021-02-23 16:45:47 -05:00
Jon Chambers
7dabc92447 Actually increment the international unsealed-sender counter instead of just declaring its existence. 2021-02-23 15:36:36 -05:00
Jon Chambers
5354104128 Only apply unsealed sender rate limits to targeted country codes. 2021-02-23 14:17:16 -05:00
Jon Chambers
a5118e4daa Record push challenge presence/outcomes by country. 2021-02-23 13:36:37 -05:00
Ehren Kret
b5ade5dc12 Only return payment address from latest profile (#408)
* Only return payment address from latest profile

* Rename `currentVersionedProfile` to `currentProfileVersion`

* Change return type to Optional

* Update service/src/main/java/org/whispersystems/textsecuregcm/controllers/ProfileController.java

Co-authored-by: Jon Chambers <63609320+jon-signal@users.noreply.github.com>

* Fix broken test

Co-authored-by: Jon Chambers <63609320+jon-signal@users.noreply.github.com>
2021-02-23 12:29:47 -06:00
Jon Chambers
fff8c72f42 Record the rate of unsealed-sender messages from accounts with a non-push-capable master device. 2021-02-23 12:26:23 -05:00
Jon Chambers
06ca5f14fc Record the age of accounts that send unsealed-sender messages. 2021-02-23 12:16:45 -05:00
Jon Chambers
8c9d871268 Log different messages depending on whether rate limits are actually enforced. 2021-02-23 12:16:45 -05:00
Jon Chambers
7266eeee7a Record the rate of international unsealed-sender attempts. 2021-02-23 12:01:09 -05:00
Ehren Kret
93f845610d Remove payments list from Account 2021-02-19 13:18:30 -06:00
Chris Eager
aa8525385a Temporarily support IncomingMessage.online (#404)
iOS versions prior to 5.5.0.7 send `online` on `IncomingMessage`, rather
than on the top-level entity. This adds a temporary server-side adaptation,
to prevent client-side issues, like persistent typing indicators.
2021-02-18 12:21:16 -06:00