get access key create date for cred report
This commit is contained in:
parent
2e91b91294
commit
72bc07f112
1
.gitignore
vendored
1
.gitignore
vendored
@ -22,3 +22,4 @@ tests/file.tmp
|
||||
.eggs/
|
||||
.mypy_cache/
|
||||
*.tmp
|
||||
.venv/
|
@ -680,14 +680,14 @@ class User(BaseModel):
|
||||
access_key_2_last_rotated = "N/A"
|
||||
elif len(self.access_keys) == 1:
|
||||
access_key_1_active = "true"
|
||||
access_key_1_last_rotated = date_created.strftime(date_format)
|
||||
access_key_1_last_rotated = self.access_keys[0].create_date.strftime(date_format)
|
||||
access_key_2_active = "false"
|
||||
access_key_2_last_rotated = "N/A"
|
||||
else:
|
||||
access_key_1_active = "true"
|
||||
access_key_1_last_rotated = date_created.strftime(date_format)
|
||||
access_key_1_last_rotated = self.access_keys[0].create_date.strftime(date_format)
|
||||
access_key_2_active = "true"
|
||||
access_key_2_last_rotated = date_created.strftime(date_format)
|
||||
access_key_2_last_rotated = self.access_keys[1].create_date.strftime(date_format)
|
||||
|
||||
return "{0},{1},{2},{3},{4},{5},not_supported,false,{6},{7},{8},{9},false,N/A,false,N/A".format(
|
||||
self.name,
|
||||
|
Loading…
Reference in New Issue
Block a user