<%namespace name="base" file="/base/base.mako"/>

### ${base.gravatar_with_user(c.user.username, 16, tooltip=False, _class='pull-left')} - ${_('SSH Keys')}

${_('Fingerprint')} | ${_('Description')} | ${_('Created on')} | ${_('Accessed on')} | ${_('Action')}
--- | --- | --- | --- | ---
%if c.user_ssh_keys: %for ssh_key in c.user_ssh_keys:
`${ssh_key.ssh_key_fingerprint}` | ${ssh_key.description} | ${h.format_date(ssh_key.created_on)} | ${h.format_date(ssh_key.accessed_on)} | ${h.secure_form(h.route_path('edit_user_ssh_keys_delete', user_id=c.user.user_id), request=request)} ${h.hidden('del_ssh_key', ssh_key.ssh_key_id)} ${h.end_form()}
%endfor %else:
${_('No additional ssh keys specified')}
%endif

${h.secure_form(h.route_path('edit_user_ssh_keys_add', user_id=c.user.user_id), request=request)}
${_('New ssh key')}:
${h.text('description', class_='medium', placeholder=_('Description'))} % if c.ssh_key_generator_enabled: ${_('Generate random RSA key')} % endif
${h.textarea('key_data',c.default_key, size=30, placeholder=_("Public key, begins with 'ssh-rsa', 'ssh-dss', 'ssh-ed25519', 'ecdsa-sha2-nistp256', 'ecdsa-sha2-nistp384', or 'ecdsa-sha2-nistp521'"))}
${h.submit('save',_('Add'),class_="btn")} ${h.reset('reset',_('Reset'),class_="btn")}
% if c.default_key: ${_('Click add to use this generate SSH key')} % endif
${h.end_form()}