lib/cryptohi/keyi.h
author Kai Engert <kaie@kuix.de>
Thu, 16 Mar 2017 15:37:06 +0100
changeset 13219 412729bb2f245170bcd9a809e818bfeafe0b7c00
parent 13140 608b71f014fa37f8c5a95b9f3d9c684ea99de9bd
child 14065 84e886ea090e36c69df58a71665a97bd25c62d02
permissions -rw-r--r--
trigger a build to pick up NSPR bug 1313612

/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#ifndef _KEYI_H_
#define _KEYI_H_

SEC_BEGIN_PROTOS
/* NSS private functions */
/* map an oid to a keytype... actually this function and it's converse
 *  are good candidates for public functions..  */
KeyType seckey_GetKeyType(SECOidTag pubKeyOid);

/* extract the 'encryption' (could be signing) and hash oids from and
 * algorithm, key and parameters (parameters is the parameters field
 * of a algorithm ID structure (SECAlgorithmID)*/
SECStatus sec_DecodeSigAlg(const SECKEYPublicKey *key, SECOidTag sigAlg,
                           const SECItem *param, SECOidTag *encalg, SECOidTag *hashalg);

SEC_END_PROTOS

#endif /* _KEYHI_H_ */