[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Deleting lines in a file from configuration files with editfiles
From: |
Armin Wolfermann |
Subject: |
Re: Deleting lines in a file from configuration files with editfiles |
Date: |
Thu, 15 Dec 2005 18:06:41 +0100 |
User-agent: |
Mutt/1.5.10i |
* Berthold Cogel <cogel@rrz.uni-koeln.de> [15.12.2005 15:52]:
> I want to edit root's authorized_keys file. I want to distribute ssh
> public keys with cfengine. It is not a problem to collect the keys and
> append them to authorized_keys. But I would also like to revoke keys by
> distributing them in a single file.
This is from my ssh.cf file (keys shortened):
control:
actionsequence = ( editfiles )
editfiles:
any::
{ /root/.ssh/authorized_keys
AutoCreate
Backup "off"
DeleteLinesStarting "ssh-dss AAAAB3Nza...
DeleteLinesStarting "ssh-rsa AAAAB3Nza...
DeleteLinesStarting "1024 35 1222975....
AppendIfNoSuchLine "ssh-rsa AAAAB3Nza...
AppendIfNoSuchLine "ssh-rsa AAAAB3Nza...
AppendIfNoSuchLine "ssh-rsa AAAAB3Nza...
}
Revoked keys and authorized keys are distributed in a single file - your
cfengine configuration.
Regards,
Armin Wolfermann