Libssh2 publickey remove ex
From Libssh2
int libssh2_publickey_remove_ex(LIBSSH2_PUBLICKEY *pkey, const unsigned char *name, unsigned long name_len, const unsigned char *blob, unsigned long blob_len); #define libssh2_publickey_remove(pkey, name, blob, blob_len) \ libssh2_publickey_remove_ex((pkey), (name), strlen(name), (blob), (blob_len))
[edit]
About
Remove a spcific public key from the currently logged in user's list of authorized public keys. If a public key if found matching both the name and blob it will be removed from that user's authorized keys file/directory (depending on server implementation.
[edit]
Parameters
- pkey
- Publickey instance as returned by libssh2_publickey_init().
- name / name_len
- Human readable name associated with the key to be removed.
- blobk / blob_len
- Machine readable representation of the public key to be removed.
[edit]
Returns
- On Success: 0
- On Failure: -1
