AuthorizedKeysCommand size issue?

Dag-Erling Smørgrav des at
Wed Apr 16 02:57:00 EST 2014

Yves Dorfsman <yves at> writes:
> Dag-Erling Smørgrav <des at> writes:
> > Shouldn't 'curl ... | cat' suffice?
> Tried that before, it returns an exit code 141.

What returns exit code 141?

If the curl command line you're using normally prints the file to
stdout, then curl | cat will do exactly the same, cat will buffer it.
However, the command line you're using will _not_ print the file to
stdout.  It will save it in the current working directory, which is most
likely /var/empty, which is not writable.  You need to add -o- to your
curl command line to have it print the file to stdout:

  curl -s -o- --compressed$1

> > Or even 'echo "$(curl ...)"'
> Can you completely prevent echo from interpreting $ sign?

Uh, echo does not interpret the $ sign.  The shell does, and you want it
to.  $() is equivalent to ``, so entire construct is replaced with
whatever curl outputs.  Note that the double quotes ensure that the
entire output is passed to echo as a single argument, rather than split
into words, thus preserving whitespace.

Dag-Erling Smørgrav - des at

More information about the openssh-unix-dev mailing list