Commit Graph

2353 Commits

Author SHA1 Message Date
Chris Eager a302275187 Use a single cluster instance in MessagesCache 2024-04-16 12:04:18 -05:00
Chris Eager b734d58ab7 Coalesce all Redis clusters to per-shard circuit breakers 2024-04-16 12:04:18 -05:00
Ravi Khadiwala 2046b02bd8 Rename `RedeemReceiptRequest` to help openapi 2024-04-16 11:16:18 -05:00
Chris Eager 1df824db7c Remap some JsonMappingExceptions to 408 and 400 2024-04-15 16:01:09 -05:00
Chris Eager 9cad2c6b7d Improve test Redis cluster setup and teardown 2024-04-15 15:58:23 -05:00
ravi-signal 00ca7d5942
Add cdn number query parameter to `/archives/auth/read` 2024-04-15 13:59:14 -05:00
ravi-signal d36df3eaa9
Add new upload-for-copy backup endpoint 2024-04-15 13:47:46 -05:00
ravi-signal e5d654f0c7
Add `/v1/archives/redeem-receipt` 2024-04-15 13:47:02 -05:00
Chris Eager fc1f471369 Use per-shard circuit breakers for additional Redis clusters 2024-04-15 13:45:24 -05:00
Chris Eager 2dc707d86e
Add per-shard Redis circuit breakers 2024-04-12 11:22:41 -05:00
Chris Eager 05a92494bb Remove X-Forwarded-For from RemoteAddressFilter 2024-04-11 11:03:37 -05:00
Alex Konradi 39fd955f13 Allow clients to request zkc-based auth creds
Allow clients to pass a zkcCredential=true query parameter to request the new
auth credential format implemented with the zkcredential Rust library.
2024-04-11 11:00:10 -05:00
ravi-signal 4863e1d227
Add backup levels to subscription configuration response 2024-04-11 10:58:40 -05:00
Jonathan Klabunde Tomer 2b652fe2a9
accept group send endorsements for multi-recipient sends 2024-04-10 16:51:09 -07:00
Ravi Khadiwala cdd2082b07 Decrease logging level in RemoveExpiredBackupsCommand 2024-04-10 18:41:29 -05:00
Chris Eager 5b97bc04e0 Add ExternalRequestFilter 2024-04-04 16:24:20 -05:00
Ravi Khadiwala 63c8b275d1 Return 401 instead of 404 on unknown backup-ids 2024-04-04 10:56:48 -05:00
Ravi Khadiwala 1ebc17352f Check presentation before verifying the signature 2024-04-04 10:56:48 -05:00
Ravi Khadiwala 268c8382ee Fix Backup expiration purge time 2024-04-04 10:55:55 -05:00
ravi-signal 498dcbbfe8
Make media encrypter stream ordered
Co-authored-by: Chris Eager <79161849+eager-signal@users.noreply.github.com>
2024-04-04 10:53:45 -05:00
Ravi Khadiwala 3a1ecb342f allow striping clients in FaultTolerantHttpClient 2024-04-04 10:47:34 -05:00
ravi-signal bb0da69c9e
Set the shutdown gauge earlier in the shutdown process
Co-authored-by: Chris Eager <79161849+eager-signal@users.noreply.github.com>
2024-04-02 09:39:55 -05:00
Jon Chambers 796dce3cd3 Always use the "peek" strategy for counting one-time pre-keys 2024-04-02 10:31:20 -04:00
Jon Chambers f59c34004d De-idiom-ize a "wait for everything to finish" idiom 2024-04-02 10:30:44 -04:00
Katherine d002e5dda8
Hardcode `paymentActivation` flag to `true` 2024-04-01 15:07:11 -07:00
Chris Eager 89cb821c97 Remove vavr dependency 2024-04-01 17:06:55 -05:00
Chris Eager fcc77052a6 Add org.eclipse.jetty.io.EofException to expected measureSendMessageErrors 2024-04-01 17:06:29 -05:00
Ravi Khadiwala 831c9ff5bf Make backupDir/mediaDir indirect 2024-04-01 13:45:21 -05:00
Ravi Khadiwala de37141812 Add a crawler that expires old backups 2024-04-01 13:45:21 -05:00
Ravi Khadiwala a550caf63f Make sure we close the HTTP/2 stream after cdn read errors 2024-03-27 17:00:37 -05:00
Ravi Khadiwala de9eaa98db 404 instead of 400 on unknown source cdn 2024-03-27 17:00:37 -05:00
ravi-signal 37b657cbbd
avoid baos::writeTo on virtual threads 2024-03-27 16:58:38 -05:00
Jon Chambers a733f5c615 Add debugging context to signature validation failures 2024-03-27 17:58:02 -04:00
Jon Chambers 8a587d1d12 Rename `NoiseStreamHandler` to `NoiseTransportHandler` for consistency with Noise specification terminology 2024-03-27 17:57:46 -04:00
Chris Eager 75bb22f08b Include HTTP2ServerConnectionFactory in JettyHttpConfigurationCustomizer 2024-03-27 16:56:19 -05:00
Jon Chambers d10da39e5b Pare back debug-oriented metrics around fetching pre-keys 2024-03-26 16:44:34 -04:00
adel-signal 54e9b839bd
update TurnTokenGenerator to add whether this is with ip or url turn allocation 2024-03-26 13:40:53 -07:00
Jon Chambers aec6ac019f
Introduce a Noise-over-WebSocket client connection manager 2024-03-22 15:20:55 -04:00
Ravi Khadiwala 075a08884b Preserve backupCredentialRequest across rereg 2024-03-22 14:19:35 -05:00
Jon Chambers 6fcb2ab5dd Remove username phased rollout plumbing (usernames are now available to everybody) 2024-03-21 13:42:20 -04:00
ameya-signal 7f0f045f29
Minor cleanup of report spam endpoint (#1979) 2024-03-21 10:41:25 -07:00
Ravi Khadiwala e7d1eadf8e Fix experiments in BackupAuthManager 2024-03-20 11:43:07 -05:00
Chris Eager 9df6e19204 Ignored EofException response failure in MetricsHttpChannelListener 2024-03-18 17:38:19 -05:00
Chris Eager 5eaae184c9 Set request failure to debug in MetricsHttpChannelListener 2024-03-18 17:38:19 -05:00
Chris Eager 459882e6fa Add JettyHttpConfigurationCustomizer 2024-03-18 17:38:19 -05:00
Chris Eager 2c2b5d555e Rename obsolete uses of recaptcha 2024-03-13 16:40:32 -05:00
Alex Konradi 0ab2428d87
Don't produce zkgroup auth creds with PNI as ACI 2024-03-13 16:22:45 -05:00
Chris Eager 8574494573 Support "captcha" rename in AnswerChallengeRequest.type 2024-03-13 16:19:05 -05:00
Chris Eager a4d4a9c686 Remove RecaptchaClient 2024-03-13 16:19:05 -05:00
Chris Eager fd9eb462cc Replace extraneous SecureRandom with empty byte array 2024-03-12 16:49:57 -05:00
Ravi Khadiwala f9533e016f Adjust metrics in RemoveExpiredUsernameHoldsCommand 2024-03-11 13:50:08 -05:00
Jon Chambers 85b15fa63b Actually increment the "get group credentials" counter 2024-03-08 17:07:16 -05:00
Chris Eager 3dadaf9334 Migrate DynamicConfigurationManager to use java.util.concurrent 2024-03-08 13:53:28 -06:00
Ravi Khadiwala 9e510a678c disable response buffering on the websocket
Jersey buffers responses (by default up to 8192 bytes) just so it can
add a content length to responses. We already buffer our responses to
serialize them as protos, so we can compute the content length
ourselves. Setting the buffer to zero disables buffering.
2024-03-08 13:46:00 -06:00
Chris Eager 2dc0ea2b89 Address potential NullPointerException when calling Collection#contains 2024-03-08 13:43:31 -06:00
Alex Konradi 7d364ca7ce
Count group auth reqs without pniAsServiceId=true 2024-03-06 15:41:48 -05:00
Chris Eager 9f6a6d7f5b Include HTTP/2 stream idle timeouts in IOExceptionMapper 2024-03-06 11:11:39 -06:00
Ravi Khadiwala 3cc740cda3 Temporarily hold a username after an account releases it 2024-03-06 11:09:25 -06:00
Ravi Khadiwala 47b24b5dff Simplify username operations in `Accounts`
- Group username table constants together
- Rethrow JsonProcessingException earlier
- Use UpdateAccountSpec.forAccount in username operations
- Inline confirm/clear transaction helpers
2024-03-06 11:09:25 -06:00
adel-signal 8f100a792e
calling: update TurnCallRouter to reduce returned options 2024-03-05 11:26:19 -08:00
Ravi Khadiwala 4e5dd914dd Add varargs variant to HmacUtil 2024-02-28 15:18:39 -06:00
ravi-signal 2adf1e5017
Avoid modification of Account from `@ReadOnly` endpoint 2024-02-28 15:18:12 -06:00
Jon Chambers d1d03f45c5 Resolve warnings throughout `AccountControllerTest` 2024-02-26 16:11:03 -05:00
Ravi Khadiwala 436bd891bd Don't register SpamFilter as a request filter 2024-02-26 09:33:36 -06:00
Chris Eager a7c28fe5ed Rename "name" tags to be more distinguishing 2024-02-26 09:32:50 -06:00
Chris Eager 60814d1ff0 Configure metrics registries earlier in background command setup 2024-02-26 09:32:01 -06:00
Jon Chambers d018efe2a5
Require non-null proofs in "confirm username hash" requests 2024-02-26 10:30:52 -05:00
Jon Chambers 6fd0cba06a Temporarily restore the `giftBadges` capability for backward compatibility 2024-02-26 10:30:29 -05:00
Katherine 12c6af23ee
Map TransactionConflict to ContestedOptimisticLockException in username flows 2024-02-23 14:06:03 -08:00
Ravi Khadiwala 69330f47fd Explicitly call spam-filter for verification session updates
Pass in the same information to the spam-filter, but just use explicit
method calls rather than jersey request filters.
2024-02-23 16:04:24 -06:00
Ravi Khadiwala 4f40c128bf Explicitly call spam-filter for challenges
Pass in the same information to the spam-filter, but just use explicit
method calls rather than jersey request filters.
2024-02-23 15:58:52 -06:00
Jon Chambers 30b5ad1515 Fix an incorrectly-named "check keys" method 2024-02-23 13:17:10 -05:00
adel-signal 665a26d164
update call routing to return ipv6 ips in RFC3986 format 2024-02-23 11:57:58 -05:00
Jon Chambers a5774bf6ff
Introduce a (dormant) Noise/WebSocket for future client/server communication 2024-02-23 11:42:42 -05:00
Jon Chambers d2716fe5cf Add an endpoint for checking that clients and the server have a common view of the client's repeated-use keys 2024-02-23 11:41:58 -05:00
Jon Chambers 279f877bf2 Validate pre-key signatures via the legacy "set signed pre-key" endpoint 2024-02-23 11:33:41 -05:00
Ravi Khadiwala df69d9f195 Annotate authenticated endpoints with `@ReadOnly` or `@Mutable` 2024-02-22 12:05:32 -06:00
Ravi Khadiwala 26ffa19f36 Lifecycle management for Account objects reused accross websocket requests 2024-02-22 12:05:32 -06:00
Jon Chambers 29ef3f0b41 Add tests and metrics for parsing invalid keys 2024-02-21 15:32:25 -05:00
Jon Chambers 106d5e54c7 Extract a common base class for public key serializers/deserializers 2024-02-21 15:32:25 -05:00
Jon Chambers 6ac2460eb0 Drop the "key without version byte" counter 2024-02-21 15:32:25 -05:00
Chris Eager c8d649e8c2 Update MetricsHttpChannelListener to share MetricsRequestEventListener namespace 2024-02-21 13:32:47 -06:00
Ravi Khadiwala 1fdf82dd6c Remove unused ChangePhoneNumberRequest object
Actual request object is ChangeNumberRequest
2024-02-21 13:32:27 -06:00
Jon Chambers 4aa4246695 Clear account records from the account cache after username operations 2024-02-20 12:11:29 -05:00
Chris Eager 1bebceb29c Actually fix flaky test in MetricsHttpChannelListenerIntegrationTest 2024-02-20 10:52:04 -06:00
Jon Chambers a2139ee236 Revert "Add diagnostic dimensions to the "get keys" counter"
This reverts commit cd64390141.
2024-02-18 20:14:05 -05:00
Jon Chambers 8c55f39cdf Revert "Use a phased enrollment strategy for the `pnp` compatibility flag"
This reverts commit 3e12a8780d.
2024-02-18 20:08:39 -05:00
Chris Eager 0329184c94 Fix flaky test in MetricsHttpChannelListenerIntegrationTest 2024-02-18 20:08:29 -05:00
Jon Chambers cd64390141 Add diagnostic dimensions to the "get keys" counter 2024-02-18 18:10:58 -05:00
Jon Chambers 3e12a8780d Use a phased enrollment strategy for the `pnp` compatibility flag 2024-02-18 17:59:00 -05:00
Jon Chambers 11e6ff1bbe Introduce a `pnp` capability for backward compatibility 2024-02-18 17:59:00 -05:00
Jon Chambers 36f85fc97e Fix an inverted boolean in a counter 2024-02-16 15:18:18 -05:00
Jon Chambers 9040cfd200 Count "store key" attempts by key type/platform 2024-02-16 13:09:55 -05:00
Jon Chambers 757da3b15a Fully-qualify OpenAPI `Tag`, allowing for imported Micrometer `Tag` 2024-02-16 13:09:55 -05:00
Jon Chambers d162590a32 Record a remote-aggregated distribution of one-time pre-key counts 2024-02-16 13:09:55 -05:00
Jon Chambers f41e1716c6 Combine/expand existing "get keys" counter 2024-02-16 13:09:55 -05:00
Jon Chambers 4dce0f1b9d Add identity type/"stale" dimensions to the "pre-key unavailable" counter 2024-02-16 13:09:55 -05:00
Jonathan Klabunde Tomer fef57dce0d
use explicit `Timer` rather than micrometer annotation for send-message latency distribution 2024-02-15 14:58:43 -08:00
Jon Chambers d884700b61 Significantly reduce default Redis command timeout 2024-02-15 17:57:17 -05:00
Jonathan Klabunde Tomer ff9ad4bd1d
export 1:1 message send latency as a full distribution 2024-02-15 10:33:02 -08:00