Add support for signing a file hash
authorMimi Zohar <zohar@linux.vnet.ibm.com>
Tue, 18 Feb 2014 21:41:33 +0000 (16:41 -0500)
committerDmitry Kasatkin <d.kasatkin@samsung.com>
Wed, 26 Mar 2014 12:50:20 +0000 (14:50 +0200)
commit8feba3f462cc06a6f33bf5cce7a5fec28fc17596
tree82f1c2268d662a6da20ae9fd71e9a701fb1661ac
parentb0da7e69e032e904937d792469cec7525a26fd38
Add support for signing a file hash

In a number of situations, the file hash has already been calculated.
Instead of reading a file to calculate the file hash, read the file hash
from stdin; and instead of writing the signature as an xattr or creating
a .sig file, output the signature as ascii-hex to stdout.

For example, piping the output of sha256sum <pathname> to evmctl would
display the original sha256 output with the file signature appended.

Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com>
src/evmctl.c