mirror of
https://github.com/floci-io/floci.git
synced 2026-11-24 06:20:24 -05:00
feat(secretsmanager): implement automatic secret rotation lifecycle (#1467)
* fix: return XML error for missing action and add volume action fallbacks * fix(eventbridge): sync EventBridge tags to ResourceGroupsTaggingService EventBridge stored tags on rules, buses, and archives in its own stores but never propagated them to the central ResourceGroupsTaggingService. This caused GetResources with --resource-type-filters events:rule to return an empty list. Inject ResourceGroupsTaggingService into EventBridgeService (following the existing GlueService pattern) and sync tags during putRule, tagResource, untagResource, and deleteRule operations. Closes #1343 * feat(secretsmanager): implement automatic secret rotation lifecycle * fix(secretsmanager): correct RotationLambdaARN validation in tests and rotation rules parsing * fix(secretsmanager): avoid implicit unboxing NPE when parsing rotation rules * fix: remove debug print, drop camelCase rotation parameters fallback, and revert unrelated eventbridge changes * fix: align PutSecretValue error code and resolve NPE in JSON handler tests * fix(test): create Lambda function before rotateSecret to fix ResourceNotFoundException rotateSecretStub failed because SecretsManagerService validates the rotation Lambda exists synchronously. The test was passing an ARN for a function that had never been created in the emulator. Create a real Lambda function via LambdaClient before calling rotateSecret, and clean it up afterwards. Uses Runtime.fromValue(nodejs20.x) for SDK compatibility. * fix: non-immediate rotation runs testSecret only Per AWS RotateSecret docs, when RotateImmediately is false Secrets Manager tests the rotation configuration by running only the testSecret step. Remove the createSecret invocation from the non-immediate path. * fix(test): align rotateSecretNotImmediate with non-immediate rotation path The non-immediate rotation path only invokes testSecret (not createSecret), so the test should expect 1 lambda invocation instead of 2.
This commit is contained in:
1 parent
2301db53c7
commit
f725a38969
7 files changed
+723
-54
No files matched your search
+51
-9
@@ -11,6 +11,7 @@ import jakarta.enterprise.context.ApplicationScoped;
|
||||
import jakarta.inject.Inject;
|
||||
import jakarta.ws.rs.core.Response;
|
||||
|
||||
import java.time.Instant;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Comparator;
|
||||
import java.util.HashMap;
|
||||
@@ -148,13 +149,14 @@ public class SecretsManagerJsonHandler {
|
||||
String secretId = request.path("SecretId").asText();
|
||||
String secretString = request.has("SecretString") ? request.path("SecretString").asText() : null;
|
||||
String secretBinary = request.has("SecretBinary") ? request.path("SecretBinary").asText() : null;
|
||||
String clientRequestToken = request.has("ClientRequestToken") ? request.path("ClientRequestToken").asText() : null;
|
||||
|
||||
List<String> versionStages = request.has("VersionStages") && request.path("VersionStages").isArray()
|
||||
? StreamSupport.stream(request.path("VersionStages").spliterator(), false).map(JsonNode::asText).toList()
|
||||
: null;
|
||||
|
||||
Secret secret = service.describeSecret(secretId, region);
|
||||
SecretVersion version = service.putSecretValue(secretId, secretString, secretBinary, region, versionStages);
|
||||
SecretVersion version = service.putSecretValue(secretId, secretString, secretBinary, clientRequestToken, region, versionStages);
|
||||
|
||||
ObjectNode response = objectMapper.createObjectNode();
|
||||
response.put("ARN", secret.getArn());
|
||||
@@ -179,7 +181,8 @@ public class SecretsManagerJsonHandler {
|
||||
|
||||
String versionId = null;
|
||||
if (secretString != null || secretBinary != null) {
|
||||
SecretVersion version = service.putSecretValue(secretId, secretString, secretBinary, region, null);
|
||||
String clientRequestToken = request.has("ClientRequestToken") ? request.path("ClientRequestToken").asText() : java.util.UUID.randomUUID().toString();
|
||||
SecretVersion version = service.putSecretValue(secretId, secretString, secretBinary, clientRequestToken, region, null);
|
||||
versionId = version.getVersionId();
|
||||
}
|
||||
|
||||
@@ -206,6 +209,30 @@ public class SecretsManagerJsonHandler {
|
||||
response.put("KmsKeyId", secret.getKmsKeyId());
|
||||
}
|
||||
response.put("RotationEnabled", secret.isRotationEnabled());
|
||||
if (secret.getRotationLambdaArn() != null) {
|
||||
response.put("RotationLambdaARN", secret.getRotationLambdaArn());
|
||||
}
|
||||
if (secret.getRotationRules() != null) {
|
||||
ObjectNode rulesNode = objectMapper.createObjectNode();
|
||||
if (secret.getRotationRules().automaticallyAfterDays() != null) rulesNode.put("AutomaticallyAfterDays", secret.getRotationRules().automaticallyAfterDays());
|
||||
if (secret.getRotationRules().duration() != null) rulesNode.put("Duration", secret.getRotationRules().duration());
|
||||
if (secret.getRotationRules().scheduleExpression() != null) rulesNode.put("ScheduleExpression", secret.getRotationRules().scheduleExpression());
|
||||
response.set("RotationRules", rulesNode);
|
||||
}
|
||||
if (secret.getLastRotatedDate() != null) {
|
||||
response.put("LastRotatedDate", secret.getLastRotatedDate().toEpochMilli() / 1000.0);
|
||||
}
|
||||
|
||||
Instant nextRotationDate = secret.getNextRotationDate();
|
||||
if (nextRotationDate == null && secret.isRotationEnabled() && secret.getRotationRules() != null && secret.getRotationRules().automaticallyAfterDays() != null) {
|
||||
Instant lastRotated = secret.getLastRotatedDate() != null ? secret.getLastRotatedDate() : secret.getCreatedDate();
|
||||
if (lastRotated != null) {
|
||||
nextRotationDate = lastRotated.plusSeconds((long) secret.getRotationRules().automaticallyAfterDays() * 86400);
|
||||
}
|
||||
}
|
||||
if (nextRotationDate != null) {
|
||||
response.put("NextRotationDate", nextRotationDate.toEpochMilli() / 1000.0);
|
||||
}
|
||||
if (secret.getCreatedDate() != null) {
|
||||
response.put("CreatedDate", secret.getCreatedDate().toEpochMilli() / 1000.0);
|
||||
}
|
||||
@@ -349,20 +376,35 @@ public class SecretsManagerJsonHandler {
|
||||
|
||||
private Response handleRotateSecret(JsonNode request, String region) {
|
||||
String secretId = request.path("SecretId").asText();
|
||||
String clientRequestToken = request.has("ClientRequestToken") ? request.path("ClientRequestToken").asText() : java.util.UUID.randomUUID().toString();
|
||||
|
||||
String lambdaArn = request.has("RotationLambdaARN") ? request.path("RotationLambdaARN").asText() : null;
|
||||
boolean rotateImmediately = request.path("RotateImmediately").asBoolean(true);
|
||||
|
||||
Map<String, Integer> rules = new HashMap<>();
|
||||
JsonNode rulesNode = request.path("RotationRules");
|
||||
if (rulesNode.has("AutomaticallyAfterDays")) {
|
||||
rules.put("AutomaticallyAfterDays", rulesNode.path("AutomaticallyAfterDays").asInt());
|
||||
|
||||
boolean rotateImmediately = true;
|
||||
if (request.has("RotateImmediately")) {
|
||||
rotateImmediately = request.path("RotateImmediately").asBoolean();
|
||||
}
|
||||
|
||||
Secret secret = service.rotateSecret(secretId, lambdaArn, rules, rotateImmediately, region);
|
||||
Secret.RotationRules rotationRules = null;
|
||||
JsonNode rulesNode = request.has("RotationRules") ? request.path("RotationRules") : null;
|
||||
|
||||
if (rulesNode != null && !rulesNode.isNull()) {
|
||||
Integer automaticallyAfterDays = null;
|
||||
if (rulesNode.hasNonNull("AutomaticallyAfterDays")) {
|
||||
automaticallyAfterDays = rulesNode.path("AutomaticallyAfterDays").asInt();
|
||||
}
|
||||
|
||||
String duration = rulesNode.hasNonNull("Duration") ? rulesNode.path("Duration").asText() : null;
|
||||
String scheduleExpression = rulesNode.hasNonNull("ScheduleExpression") ? rulesNode.path("ScheduleExpression").asText() : null;
|
||||
rotationRules = new Secret.RotationRules(automaticallyAfterDays, duration, scheduleExpression);
|
||||
}
|
||||
|
||||
Secret secret = service.rotateSecret(secretId, clientRequestToken, lambdaArn, rotationRules, rotateImmediately, region);
|
||||
|
||||
ObjectNode response = objectMapper.createObjectNode();
|
||||
response.put("ARN", secret.getArn());
|
||||
response.put("Name", secret.getName());
|
||||
response.put("VersionId", clientRequestToken);
|
||||
return Response.ok(response).build();
|
||||
}
|
||||
|
||||
|
||||
+174
-11
@@ -8,10 +8,19 @@ import io.github.hectorvent.floci.core.storage.StorageBackend;
|
||||
import io.github.hectorvent.floci.core.storage.StorageFactory;
|
||||
import io.github.hectorvent.floci.services.secretsmanager.model.Secret;
|
||||
import io.github.hectorvent.floci.services.secretsmanager.model.SecretVersion;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.fasterxml.jackson.databind.node.ObjectNode;
|
||||
import io.github.hectorvent.floci.services.lambda.LambdaService;
|
||||
import io.github.hectorvent.floci.services.lambda.model.InvocationType;
|
||||
import io.github.hectorvent.floci.services.lambda.model.InvokeResult;
|
||||
import jakarta.annotation.PreDestroy;
|
||||
import jakarta.enterprise.context.ApplicationScoped;
|
||||
import jakarta.inject.Inject;
|
||||
import org.jboss.logging.Logger;
|
||||
|
||||
import java.util.concurrent.ExecutorService;
|
||||
import java.util.concurrent.Executors;
|
||||
|
||||
import java.time.Instant;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
@@ -33,24 +42,40 @@ public class SecretsManagerService {
|
||||
private final StorageBackend<String, Secret> store;
|
||||
private final int defaultRecoveryWindowDays;
|
||||
private final RegionResolver regionResolver;
|
||||
private final LambdaService lambdaService;
|
||||
private final ObjectMapper objectMapper;
|
||||
private final ExecutorService rotationExecutor = Executors.newCachedThreadPool();
|
||||
private final java.util.concurrent.ConcurrentHashMap<String, Object> rotationLocks = new java.util.concurrent.ConcurrentHashMap<>();
|
||||
|
||||
private Object lockFor(String secretArn) {
|
||||
return rotationLocks.computeIfAbsent(secretArn, k -> new Object());
|
||||
}
|
||||
|
||||
@Inject
|
||||
public SecretsManagerService(StorageFactory factory, EmulatorConfig config, RegionResolver regionResolver) {
|
||||
public SecretsManagerService(StorageFactory factory, EmulatorConfig config, RegionResolver regionResolver,
|
||||
LambdaService lambdaService, ObjectMapper objectMapper) {
|
||||
this(factory.create("secretsmanager", "secretsmanager-secrets.json",
|
||||
new TypeReference<Map<String, Secret>>() {}),
|
||||
config.services().secretsmanager().defaultRecoveryWindowDays(),
|
||||
regionResolver);
|
||||
regionResolver, lambdaService, objectMapper);
|
||||
}
|
||||
|
||||
SecretsManagerService(StorageBackend<String, Secret> store, int defaultRecoveryWindowDays) {
|
||||
this(store, defaultRecoveryWindowDays, new RegionResolver("us-east-1", "000000000000"));
|
||||
this(store, defaultRecoveryWindowDays, new RegionResolver("us-east-1", "000000000000"), null, new ObjectMapper());
|
||||
}
|
||||
|
||||
SecretsManagerService(StorageBackend<String, Secret> store, int defaultRecoveryWindowDays,
|
||||
RegionResolver regionResolver) {
|
||||
RegionResolver regionResolver, LambdaService lambdaService, ObjectMapper objectMapper) {
|
||||
this.store = store;
|
||||
this.defaultRecoveryWindowDays = defaultRecoveryWindowDays;
|
||||
this.regionResolver = regionResolver;
|
||||
this.lambdaService = lambdaService;
|
||||
this.objectMapper = objectMapper;
|
||||
}
|
||||
|
||||
@PreDestroy
|
||||
void shutdown() {
|
||||
rotationExecutor.shutdown();
|
||||
}
|
||||
|
||||
public Secret createSecret(String name, String secretString, String secretBinary,
|
||||
@@ -126,7 +151,7 @@ public class SecretsManagerService {
|
||||
}
|
||||
|
||||
public SecretVersion putSecretValue(String secretId, String secretString,
|
||||
String secretBinary, String region,
|
||||
String secretBinary, String clientRequestToken, String region,
|
||||
List<String> versionStages) {
|
||||
Secret secret = resolveSecret(secretId, region);
|
||||
|
||||
@@ -135,8 +160,23 @@ public class SecretsManagerService {
|
||||
"Secrets Manager can't find the specified secret.", 400);
|
||||
}
|
||||
|
||||
if (clientRequestToken != null && (clientRequestToken.length() < 32 || clientRequestToken.length() > 64)) {
|
||||
throw new AwsException("InvalidParameterException", "ClientRequestToken must be between 32 and 64 characters long.", 400);
|
||||
}
|
||||
|
||||
if (clientRequestToken != null && secret.getVersions() != null && secret.getVersions().containsKey(clientRequestToken)) {
|
||||
SecretVersion existingVersion = secret.getVersions().get(clientRequestToken);
|
||||
if (!Objects.equals(existingVersion.getSecretString(), secretString) ||
|
||||
!Objects.equals(existingVersion.getSecretBinary(), secretBinary)) {
|
||||
throw new AwsException("ResourceExistsException",
|
||||
"You can't use ClientRequestToken " + clientRequestToken
|
||||
+ " because that value is already in use for a version of secret " + secret.getArn(), 400);
|
||||
}
|
||||
return existingVersion;
|
||||
}
|
||||
|
||||
Instant now = Instant.now();
|
||||
String newVersionId = UUID.randomUUID().toString();
|
||||
String newVersionId = clientRequestToken != null ? clientRequestToken : UUID.randomUUID().toString();
|
||||
|
||||
List<String> stages;
|
||||
if (versionStages != null) {
|
||||
@@ -280,7 +320,7 @@ public class SecretsManagerService {
|
||||
return secret;
|
||||
}
|
||||
|
||||
public Secret rotateSecret(String secretId, String rotationLambdaArn, Map<String, Integer> rotationRules,
|
||||
public Secret rotateSecret(String secretId, String clientRequestToken, String rotationLambdaArn, Secret.RotationRules rotationRules,
|
||||
boolean rotateImmediately, String region) {
|
||||
Secret secret = resolveSecret(secretId, region);
|
||||
|
||||
@@ -289,14 +329,131 @@ public class SecretsManagerService {
|
||||
"Secrets Manager can't find the specified secret.", 400);
|
||||
}
|
||||
|
||||
secret.setRotationEnabled(true);
|
||||
secret.setLastChangedDate(Instant.now());
|
||||
if (clientRequestToken != null && (clientRequestToken.length() < 32 || clientRequestToken.length() > 64)) {
|
||||
throw new AwsException("InvalidParameterException", "ClientRequestToken must be between 32 and 64 characters long.", 400);
|
||||
}
|
||||
|
||||
store.put(regionKey(region, secret.getName()), secret);
|
||||
LOG.infov("Stub: Rotated secret: {0} (rotation enabled)", secret.getName());
|
||||
if (rotationRules != null && rotationRules.automaticallyAfterDays() != null && rotationRules.scheduleExpression() != null) {
|
||||
throw new AwsException("InvalidParameterException",
|
||||
"RotationRules can't include both AutomaticallyAfterDays and ScheduleExpression.", 400);
|
||||
}
|
||||
|
||||
String finalLambdaArn = rotationLambdaArn != null ? rotationLambdaArn : secret.getRotationLambdaArn();
|
||||
if (finalLambdaArn == null) {
|
||||
throw new AwsException("InvalidRequestException",
|
||||
"You tried to enable rotation on a secret that doesn't already have a Lambda function ARN configured and you didn't include such an ARN as a parameter in this call.", 400);
|
||||
}
|
||||
|
||||
// Validate Lambda exists synchronously
|
||||
if (lambdaService != null) {
|
||||
try {
|
||||
lambdaService.getFunction(region, finalLambdaArn);
|
||||
} catch (AwsException e) {
|
||||
if (e.getHttpStatus() == 404) {
|
||||
throw new AwsException("ResourceNotFoundException",
|
||||
"Secrets Manager cannot find the specified Lambda function.", 404);
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
synchronized (lockFor(secret.getArn())) {
|
||||
SecretVersion pendingVersion = findVersionByStage(secret, "AWSPENDING");
|
||||
if (pendingVersion != null) {
|
||||
SecretVersion currentVersion = findVersionByStage(secret, "AWSCURRENT");
|
||||
if (currentVersion == null || !pendingVersion.getVersionId().equals(currentVersion.getVersionId())) {
|
||||
throw new AwsException("InvalidRequestException",
|
||||
"A previous rotation isn't complete. That rotation will be reattempted.", 400);
|
||||
}
|
||||
}
|
||||
|
||||
if (rotationLambdaArn != null) {
|
||||
secret.setRotationLambdaArn(rotationLambdaArn);
|
||||
}
|
||||
if (rotationRules != null) {
|
||||
secret.setRotationRules(rotationRules);
|
||||
}
|
||||
secret.setRotationEnabled(true);
|
||||
secret.setLastChangedDate(Instant.now());
|
||||
|
||||
store.put(regionKey(region, secret.getName()), secret);
|
||||
}
|
||||
|
||||
String arn = secret.getArn();
|
||||
String finalToken = clientRequestToken != null && !clientRequestToken.isEmpty() ? clientRequestToken : UUID.randomUUID().toString();
|
||||
boolean isExistingVersion = secret.getVersions() != null && secret.getVersions().containsKey(finalToken);
|
||||
|
||||
rotationExecutor.submit(() -> {
|
||||
try {
|
||||
executeRotationLifecycle(arn, finalToken, finalLambdaArn, rotateImmediately, isExistingVersion, region);
|
||||
} catch (Exception e) {
|
||||
LOG.errorv(e, "Rotation lifecycle failed for secret {0}", arn);
|
||||
}
|
||||
});
|
||||
|
||||
LOG.infov("Started background rotation for secret: {0}", secret.getName());
|
||||
return secret;
|
||||
}
|
||||
|
||||
|
||||
private void executeRotationLifecycle(String secretArn, String clientRequestToken, String lambdaArn, boolean rotateImmediately, boolean isExistingVersion, String region) {
|
||||
if (!rotateImmediately) {
|
||||
invokeRotationLambda(secretArn, clientRequestToken, lambdaArn, "testSecret", region);
|
||||
|
||||
Secret refreshed = resolveSecret(secretArn, region);
|
||||
SecretVersion pending = findVersionByStage(refreshed, "AWSPENDING");
|
||||
if (pending != null) {
|
||||
List<String> stages = new ArrayList<>(pending.getVersionStages());
|
||||
stages.remove("AWSPENDING");
|
||||
pending.setVersionStages(stages);
|
||||
store.put(regionKey(region, refreshed.getName()), refreshed);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
if (!isExistingVersion) {
|
||||
invokeRotationLambda(secretArn, clientRequestToken, lambdaArn, "createSecret", region);
|
||||
invokeRotationLambda(secretArn, clientRequestToken, lambdaArn, "setSecret", region);
|
||||
}
|
||||
invokeRotationLambda(secretArn, clientRequestToken, lambdaArn, "testSecret", region);
|
||||
invokeRotationLambda(secretArn, clientRequestToken, lambdaArn, "finishSecret", region);
|
||||
|
||||
Secret refreshed = resolveSecret(secretArn, region);
|
||||
refreshed.setLastRotatedDate(Instant.now());
|
||||
store.put(regionKey(region, refreshed.getName()), refreshed);
|
||||
} catch (Exception e) {
|
||||
LOG.errorv(e, "Error during rotation steps for secret {0}", secretArn);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
private void invokeRotationLambda(String secretArn, String clientRequestToken, String lambdaArn, String step, String region) {
|
||||
if (lambdaService == null) {
|
||||
LOG.warnv("LambdaService is not available; skipping rotation lambda invocation for step {0}", step);
|
||||
return;
|
||||
}
|
||||
try {
|
||||
ObjectNode payload = objectMapper.createObjectNode();
|
||||
payload.put("Step", step);
|
||||
payload.put("SecretId", secretArn);
|
||||
payload.put("ClientRequestToken", clientRequestToken);
|
||||
payload.put("RotationToken", clientRequestToken);
|
||||
|
||||
String payloadStr = objectMapper.writeValueAsString(payload);
|
||||
|
||||
InvokeResult result = lambdaService.invoke(region, lambdaArn, payloadStr.getBytes(java.nio.charset.StandardCharsets.UTF_8), InvocationType.RequestResponse);
|
||||
if (result.getFunctionError() != null) {
|
||||
throw new AwsException("InternalServiceError",
|
||||
"Rotation lambda returned an error during " + step + ": " + result.getFunctionError(), 500);
|
||||
}
|
||||
} catch (AwsException e) {
|
||||
throw e;
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException("Failed to invoke rotation lambda for step " + step, e);
|
||||
}
|
||||
}
|
||||
|
||||
public void tagResource(String secretId, List<Secret.Tag> tags, String region) {
|
||||
Secret secret = resolveSecret(secretId, region);
|
||||
|
||||
@@ -418,6 +575,8 @@ public class SecretsManagerService {
|
||||
mutablePrevStages.remove(AWSPREVIOUS);
|
||||
previous.setVersionStages(mutablePrevStages);
|
||||
}
|
||||
|
||||
// we will set currentVersionId further down
|
||||
}
|
||||
secret.getVersions().get(removeFromVersionId).setVersionStages(mutableStages);
|
||||
}
|
||||
@@ -434,6 +593,10 @@ public class SecretsManagerService {
|
||||
List<String> mutableStages = new ArrayList<>(secret.getVersions().get(moveToVersionId).getVersionStages());
|
||||
mutableStages.add(versionStage);
|
||||
secret.getVersions().get(moveToVersionId).setVersionStages(mutableStages);
|
||||
|
||||
if (AWSCURRENT.equals(versionStage)) {
|
||||
secret.setCurrentVersionId(moveToVersionId);
|
||||
}
|
||||
}
|
||||
|
||||
store.put(regionKey(region, secret.getName()), secret);
|
||||
|
||||
@@ -24,6 +24,16 @@ public class Secret {
|
||||
private List<Tag> tags;
|
||||
private Map<String, SecretVersion> versions;
|
||||
private String currentVersionId;
|
||||
private String rotationLambdaArn;
|
||||
private RotationRules rotationRules;
|
||||
private Instant lastRotatedDate;
|
||||
private Instant nextRotationDate;
|
||||
|
||||
public record RotationRules(
|
||||
@JsonProperty("AutomaticallyAfterDays") Integer automaticallyAfterDays,
|
||||
@JsonProperty("Duration") String duration,
|
||||
@JsonProperty("ScheduleExpression") String scheduleExpression) {
|
||||
}
|
||||
|
||||
public Secret() {
|
||||
}
|
||||
@@ -128,4 +138,36 @@ public class Secret {
|
||||
public void setCurrentVersionId(String currentVersionId) {
|
||||
this.currentVersionId = currentVersionId;
|
||||
}
|
||||
|
||||
public String getRotationLambdaArn() {
|
||||
return rotationLambdaArn;
|
||||
}
|
||||
|
||||
public void setRotationLambdaArn(String rotationLambdaArn) {
|
||||
this.rotationLambdaArn = rotationLambdaArn;
|
||||
}
|
||||
|
||||
public RotationRules getRotationRules() {
|
||||
return rotationRules;
|
||||
}
|
||||
|
||||
public void setRotationRules(RotationRules rotationRules) {
|
||||
this.rotationRules = rotationRules;
|
||||
}
|
||||
|
||||
public Instant getLastRotatedDate() {
|
||||
return lastRotatedDate;
|
||||
}
|
||||
|
||||
public void setLastRotatedDate(Instant lastRotatedDate) {
|
||||
this.lastRotatedDate = lastRotatedDate;
|
||||
}
|
||||
|
||||
public Instant getNextRotationDate() {
|
||||
return nextRotationDate;
|
||||
}
|
||||
|
||||
public void setNextRotationDate(Instant nextRotationDate) {
|
||||
this.nextRotationDate = nextRotationDate;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user