This is the function
def list_authorized_public_keys_at(%__MODULE__{authorized_keys: auth_keys}, secret_index)
when is_integer(secret_index) and secret_index >= 0 do
auth_keys
|> Enum.at(secret_index)
|> Map.keys()
end
the values are taken from documentation example
iex> %Keys{
...> secrets: [<<205, 124, 251, 211, 28, 69, 249, 1, 58, 108, 16, 35, 23, 206, 198, 202>>],
...> authorized_keys: [%{
...> <<0, 0, 229, 188, 159, 80, 100, 5, 54, 152, 137, 201, 204, 24, 22, 125, 76, 29,
...> 83, 14, 154, 60, 66, 69, 121, 97, 40, 215, 226, 204, 133, 54, 187, 9>> =>
...> <<139, 100, 20, 32, 187, 77, 56, 30, 116, 207, 34, 95, 157, 128, 208, 115, 113,
...> 177, 45, 9, 93, 107, 90, 254, 173, 71, 60, 181, 113, 247, 75, 151, 127, 41, 7,
...> 233, 227, 98, 209, 211, 97, 117, 68, 101, 59, 121, 214, 105, 225, 218, 91, 92,
...> 212, 162, 48, 18, 15, 181, 70, 103, 32, 141, 4, 64, 107, 93, 117, 188, 244, 7,
...> 224, 214, 225, 146, 44, 83, 111, 34, 239, 99, 1, 126, 241, 246>>
...> }]
...> }
...> |> Keys.list_authorized_public_keys()
[
<<0, 0, 229, 188, 159, 80, 100, 5, 54, 152, 137, 201, 204, 24, 22, 125, 76, 29,
83, 14, 154, 60, 66, 69, 121, 97, 40, 215, 226, 204, 133, 54, 187, 9>>
]