IAM: Issues with ListMFADevices and CreateVirtualMFADevice (#5334)
This commit is contained in:
parent
98501ae676
commit
036cc6879e
@ -85,8 +85,8 @@ class VirtualMfaDevice(object):
|
|||||||
self.base32_string_seed = base64.b64encode(
|
self.base32_string_seed = base64.b64encode(
|
||||||
random_base32_string.encode("ascii")
|
random_base32_string.encode("ascii")
|
||||||
).decode("ascii")
|
).decode("ascii")
|
||||||
self.qr_code_png = base64.b64encode(
|
self.qr_code_png = base64.b64encode(os.urandom(64)).decode(
|
||||||
os.urandom(64)
|
"ascii"
|
||||||
) # this would be a generated PNG
|
) # this would be a generated PNG
|
||||||
|
|
||||||
self.enable_date = None
|
self.enable_date = None
|
||||||
|
@ -2110,6 +2110,9 @@ LIST_MFA_DEVICES_TEMPLATE = """<ListMFADevicesResponse>
|
|||||||
<member>
|
<member>
|
||||||
<UserName>{{ user_name }}</UserName>
|
<UserName>{{ user_name }}</UserName>
|
||||||
<SerialNumber>{{ device.serial_number }}</SerialNumber>
|
<SerialNumber>{{ device.serial_number }}</SerialNumber>
|
||||||
|
{% if device.enable_date %}
|
||||||
|
<EnableDate>{{ device.enabled_iso_8601 }}</EnableDate>
|
||||||
|
{% endif %}
|
||||||
</member>
|
</member>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</MFADevices>
|
</MFADevices>
|
||||||
|
Loading…
Reference in New Issue
Block a user