| John Cowan wrote:
| As I mentioned earlier, the x (later X) command and the
| corresponding option caused files to be decrypted when read and
| encrypted when written. This feature existed in the 7th edition,
| where it depended on the very weak encryption of crypt(1), but was
| not present before or since AFAICT.

Encryption was removed from GNU ed at the request of Richard Stallman
on the grounds that it's not ed's job. For the record, the versions on
*BSD and my own (https://github.com/slewsys/ed) do support an `x'
command. On Linux, it's dependent on libbsd.

As Paul Jackson correctly observes, the buffer is not encrypted.
However, Illumos (i.e., OpenSolaris) ed evidently does encrypt the
buffer. Might be worth a look.

For reference, in my implementation, encryption is disabled with the
`x' command followed by an empty password.

In practice, I use Mozilla's sops "editor" for maintaining secrets but
have nothing against making encryption more accessible.
-AM

Reply via email to