diff --git a/service/src/main/java/org/whispersystems/textsecuregcm/limits/RateLimiters.java b/service/src/main/java/org/whispersystems/textsecuregcm/limits/RateLimiters.java index 49e728873..05f8facc2 100644 --- a/service/src/main/java/org/whispersystems/textsecuregcm/limits/RateLimiters.java +++ b/service/src/main/java/org/whispersystems/textsecuregcm/limits/RateLimiters.java @@ -18,8 +18,6 @@ public class RateLimiters extends BaseRateLimiters { public enum For implements RateLimiterDescriptor { BACKUP_AUTH_CHECK("backupAuthCheck", false, new RateLimiterConfig(100, Duration.ofMinutes(15))), - SMS_DESTINATION("smsDestination", false, new RateLimiterConfig(2, Duration.ofSeconds(30))), - VERIFY("verify", false, new RateLimiterConfig(6, Duration.ofSeconds(30))), PIN("pin", false, new RateLimiterConfig(10, Duration.ofDays(1))), ATTACHMENT("attachmentCreate", false, new RateLimiterConfig(50, Duration.ofMillis(1200))), BACKUP_ATTACHMENT("backupAttachmentCreate", true, new RateLimiterConfig(10_000, Duration.ofSeconds(1))), @@ -118,14 +116,6 @@ public class RateLimiters extends BaseRateLimiters { return forDescriptor(For.ATTACHMENT); } - public RateLimiter getSmsDestinationLimiter() { - return forDescriptor(For.SMS_DESTINATION); - } - - public RateLimiter getVerifyLimiter() { - return forDescriptor(For.VERIFY); - } - public RateLimiter getPinLimiter() { return forDescriptor(For.PIN); } diff --git a/service/src/test/java/org/whispersystems/textsecuregcm/controllers/DeviceControllerTest.java b/service/src/test/java/org/whispersystems/textsecuregcm/controllers/DeviceControllerTest.java index 6f7306cef..a3b3255f6 100644 --- a/service/src/test/java/org/whispersystems/textsecuregcm/controllers/DeviceControllerTest.java +++ b/service/src/test/java/org/whispersystems/textsecuregcm/controllers/DeviceControllerTest.java @@ -132,8 +132,6 @@ class DeviceControllerTest { @BeforeEach void setup() { - when(rateLimiters.getSmsDestinationLimiter()).thenReturn(rateLimiter); - when(rateLimiters.getVerifyLimiter()).thenReturn(rateLimiter); when(rateLimiters.getAllocateDeviceLimiter()).thenReturn(rateLimiter); when(rateLimiters.getVerifyDeviceLimiter()).thenReturn(rateLimiter);