diff options
author | Bill Marquette <billm@pfsense.org> | 2008-05-17 20:09:15 +0000 |
---|---|---|
committer | Bill Marquette <billm@pfsense.org> | 2008-05-17 20:09:15 +0000 |
commit | a488f12d72bc5485e4b504b342422f1fff60dad8 (patch) | |
tree | 9004e674d34244434f051ec09b3b51220f90709f /etc | |
parent | 04fc41b8239fd8a3a9edf9e40c477a581569202c (diff) | |
download | pfsense-a488f12d72bc5485e4b504b342422f1fff60dad8.zip pfsense-a488f12d72bc5485e4b504b342422f1fff60dad8.tar.gz |
MFC of changeset [22589]
Ticket #1697 - rm authorized key file if keys don't exist in config.xml
Diffstat (limited to 'etc')
-rwxr-xr-x | etc/sshd | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -125,6 +125,10 @@ fwrite($fd, $authorizedkeys); pclose($fd); chmod("/root/.ssh/authorized_keys",0644); + } else { + if(file_exists("/root/.ssh/authorized_keys")) { + unlink("/root/.ssh/authorized_keys"); + } } /* mop up from a badly implemented ssh keys -> cf backup */ |