RSA Security 5 Projection Television User Manual


 
Chapter 3 Key Info Types 259
KI_DSAPublic
KI_DSAPublic
Purpose:
This KI allows you to specify a public key used by the DSA algorithm. The
information consists of a private component and the three parameters:
p
,
q
, and
g
,
which are explained below. See
KI_DSAPublicBER or KI_DSAPublicX957BER for the
same key type with BER encoding.
Type of information this allows you to use:
a DSA public key where all the parameters are specified as in X9.30 Part III: the public
component (
y
), the prime (
p
), the subprime (
q
), and the base (
g
).
Format of info supplied to B_SetKeyInfo:
pointer to an A_DSA_PUBLIC_KEY structure:
where
A_DSA_PARAMS is defined as:
Each
ITEM supplies an integer in canonical format, where the ITEM’s
data
points to an
unsigned byte array, most significant byte first, and the
ITEM’s
len
gives its length. All
leading zeros are stripped from each integer before it is copied to the key object.
Format of info returned by B_GetKeyInfo:
pointer to an A_DSA_PUBLIC_KEY structure (see above). All leading zeros have been
stripped from each integer in the structure.
typedef struct {
ITEM y; /* public component */
A_DSA_PARAMS params; /* the DSA parameters, p, q and g */
} A_DSA_PUBLIC_KEY;
typedef struct {
ITEM prime; /* the prime p */
ITEM subPrime; /* the subprime q */
ITEM base; /* the base g */
} A_DSA_PARAMS;