Rewrite sshkey security plugin

General fixes and doc updates.