It seems OP wanted to pass the file name to -k
, but this parameter takes the password itself and not a filename:
-k password
The password to derive the key from. This is for compatibility with previous versions of OpenSSL. Superseded by the -pass argument.
So, as I understand, the password would be not the first line of /etc/ssl/private/etcBackup.key
, but the string /etc/ssl/private/etcBackup.key
itself. It seems that -kfile /etc/ssl/private/etcBackup.key
or -pass file:/etc/ssl/private/etcBackup.key
is what OP wanted to use.
Same in Python, Rust, Haskell and probably many others.
But apparently JS does work that way, that is its
filter
always iterates over everything and returns a new array and not some iterator object.