Vault adds carriage return and new line characters to output if -field used.
$ du /tmp/key
0 /tmp/key
$ vault write -address=http://127.0.0.1:8200 secret/encrypted key=@/tmp/key
$ vault read -address=http://127.0.0.1:8200 -field=key secret/encrypted > /tmp/key1
$ du /tmp/key1
4 /tmp/key1
$ xxd -p /tmp/key1
0d0a
Please note that documentation claims:
-field=field If included, the raw value of the specified field
will be output raw to stdout.