Skip to content

Commit

Permalink
man: port tpm2_sign to markdown
Browse files Browse the repository at this point in the history
Signed-off-by: William Roberts <william.c.roberts@intel.com>
  • Loading branch information
William Roberts committed Sep 20, 2017
1 parent ef801b3 commit 67852c1
Show file tree
Hide file tree
Showing 3 changed files with 94 additions and 93 deletions.
4 changes: 2 additions & 2 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,6 @@ EXTRA_DIST = $(top_srcdir)/man
man1_MANS = \
man/man1/tpm2_startup.1 \
man/man1/tpm2_takeownership.1 \
man/man1/tpm2_sign.1 \
man/man1/tpm2_unseal.1 \
man/man1/tpm2_verifysignature.1

Expand Down Expand Up @@ -275,7 +274,8 @@ if HAVE_MD2MAN_ROFF
man/man1/tpm2_readpublic.1 \
man/man1/tpm2_rsadecrypt.1 \
man/man1/tpm2_rsaencrypt.1 \
man/man1/tpm2_send_command.1
man/man1/tpm2_send_command.1 \
man/man1/tpm2_sign.1
endif

MAN_DEPS := man/common-options.troff man/tcti-options.troff \
Expand Down
91 changes: 0 additions & 91 deletions man/tpm2_sign.1.in

This file was deleted.

92 changes: 92 additions & 0 deletions man/tpm2_sign.1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
tpm2_sign 1 "SEPTEMBER 2017" tpm2-tools
==================================================

NAME
----

tpm2_sign(1) - Sign a hash using the TPM.

SYNOPSIS
--------

`tpm2_sign` [OPTIONS]

DESCRIPTION
-----------

tpm2_sign(1) signs an externally provided hash with the specified symmetric or
asymmetric signing key. If keyHandle references a restricted signing key, then
validation shall be provided, indicating that the TPM performed the hash of the
data and validation shall indicate that hashed data did not start with
`TPM_GENERATED_VALUE`. The scheme of keyHandle should not be `TPM_ALG_NULL`.

OPTIONS
-------

* `-k`, `--keyHandle`=_KEY\_HANDLE_:

Handle of key that will perform signing.

* `-c`, `--keyContext`=_KEY\_CONTEXT\_FILE_:

Filename of the key context used for the operation.

* `-P`, `--pwdk`=_KEY\_PASSWORD_:

Specifies the password of _KEY\_HANDLE_. Passwords should follow the
password formatting standards, see section "Password Formatting".

* `-g`, `--halg`=_HASH\_ALGORITHM_:

The hash algorithm used to digest the message.
Algorithms should follow the "formatting standards, see section
"Algorithm Specifiers".
Also, see section "Supported Hash Algorithms" for a list of supported hash
algorithms.


* `-m`, `--msg`=_MSG\_FILE_:

The message file, containing the content to be digested.

* `-t`, `--ticket`=_TICKET\_FILE_:

The ticket file, containning the validation structure, optional.

* `-s`, `--sig`=_TICKET\_FILE_:

The signature file, records the signature structure.

* `-S`, `--input-session-handle`=_SESSION\_HANDLE_:

Optional Input session handle from a policy session for authorization.

[common options](common/options.md)

[common tcti options](common/tcti.md)

[password formatting](common/password.md)

[supported hash algorithms](common/hash.md)

[algorithm specifiers](common/alg.md)

EXAMPLES
--------

```
tpm2_sign -k 0x81010001 -P abc123 -g sha256 -m <filePath> -s <filePath> -t <filePath>
tpm2_sign -c key.context -P abc123 -g sha256 -m <filePath> -s <filePath> -t <filePath>
```

RETURNS
-------
0 on success or 1 on failure.

BUGS
----
[Github Issues](https://github.com/01org/tpm2-tools/issues)

HELP
----
See the [Mailing List](https://lists.01.org/mailman/listinfo/tpm2)

0 comments on commit 67852c1

Please sign in to comment.