Skip to content
Snippets Groups Projects
Commit a2fbbcea authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab Committed by Jonathan Corbet
Browse files

digsig.txt: standardize document format


Each text file under Documentation follows a different
format. Some doesn't even have titles!

Change its representation to follow the adopted standard,
using ReST markups for it to be parseable by Sphinx:

- comment the internal index;
- use the proper markups for titles;
- mark literal blocks.

Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
Signed-off-by: default avatarJonathan Corbet <corbet@lwn.net>
parent 7effa5b0
No related branches found
No related tags found
No related merge requests found
==================================
Digital Signature Verification API Digital Signature Verification API
==================================
CONTENTS :Author: Dmitry Kasatkin
:Date: 06.10.2011
.. CONTENTS
1. Introduction 1. Introduction
2. API 2. API
3. User-space utilities 3. User-space utilities
1. Introduction Introduction
============
Digital signature verification API provides a method to verify digital signature. Digital signature verification API provides a method to verify digital signature.
Currently digital signatures are used by the IMA/EVM integrity protection subsystem. Currently digital signatures are used by the IMA/EVM integrity protection subsystem.
...@@ -17,7 +24,7 @@ GnuPG multi-precision integers (MPI) library. The kernel port provides ...@@ -17,7 +24,7 @@ GnuPG multi-precision integers (MPI) library. The kernel port provides
memory allocation errors handling, has been refactored according to kernel memory allocation errors handling, has been refactored according to kernel
coding style, and checkpatch.pl reported errors and warnings have been fixed. coding style, and checkpatch.pl reported errors and warnings have been fixed.
Public key and signature consist of header and MPIs. Public key and signature consist of header and MPIs::
struct pubkey_hdr { struct pubkey_hdr {
uint8_t version; /* key format version */ uint8_t version; /* key format version */
...@@ -43,9 +50,10 @@ Such approach insures that key or signature header could not be changed. ...@@ -43,9 +50,10 @@ Such approach insures that key or signature header could not be changed.
It protects timestamp from been changed and can be used for rollback It protects timestamp from been changed and can be used for rollback
protection. protection.
2. API API
===
API currently includes only 1 function: API currently includes only 1 function::
digsig_verify() - digital signature verification with public key digsig_verify() - digital signature verification with public key
...@@ -67,7 +75,8 @@ API currently includes only 1 function: ...@@ -67,7 +75,8 @@ API currently includes only 1 function:
int digsig_verify(struct key *keyring, const char *sig, int siglen, int digsig_verify(struct key *keyring, const char *sig, int siglen,
const char *data, int datalen); const char *data, int datalen);
3. User-space utilities User-space utilities
====================
The signing and key management utilities evm-utils provide functionality The signing and key management utilities evm-utils provide functionality
to generate signatures, to load keys into the kernel keyring. to generate signatures, to load keys into the kernel keyring.
...@@ -75,7 +84,7 @@ Keys can be in PEM or converted to the kernel format. ...@@ -75,7 +84,7 @@ Keys can be in PEM or converted to the kernel format.
When the key is added to the kernel keyring, the keyid defines the name When the key is added to the kernel keyring, the keyid defines the name
of the key: 5D2B05FC633EE3E8 in the example bellow. of the key: 5D2B05FC633EE3E8 in the example bellow.
Here is example output of the keyctl utility. Here is example output of the keyctl utility::
$ keyctl show $ keyctl show
Session Keyring Session Keyring
...@@ -90,7 +99,3 @@ Session Keyring ...@@ -90,7 +99,3 @@ Session Keyring
$ keyctl list 128198054 $ keyctl list 128198054
1 key in keyring: 1 key in keyring:
620789745: --alswrv 0 0 user: 5D2B05FC633EE3E8 620789745: --alswrv 0 0 user: 5D2B05FC633EE3E8
Dmitry Kasatkin
06.10.2011
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment