mirror of
https://github.com/floci-io/floci.git
synced 2026-11-27 07:39:24 -05:00
fix(sts): apply role session duration limit to AssumeRole (#7131)
This commit is contained in:
1 parent
2d68edc4b7
commit
cbb563f24c
4 files changed
+148
-1
No files matched your search
@@ -179,6 +179,11 @@ public class StsQueryHandler {
|
||||
return trustDenied;
|
||||
}
|
||||
|
||||
Response roleDurationError = validateMaxSessionDuration(durationSeconds, role);
|
||||
if (roleDurationError != null) {
|
||||
return roleDurationError;
|
||||
}
|
||||
|
||||
String sessionRoleArn = canonicalRoleArn(role, accountId, roleName);
|
||||
String assumedRoleArn = assumedRoleArn(sessionRoleArn, accountId, roleName, sessionName);
|
||||
String roleId = (role != null && role.getRoleId() != null) ? role.getRoleId() : ("AROA" + randomId(16));
|
||||
|
||||
Reference in new issue
Block a user