2N/A * The contents of this file are subject to the terms of the 2N/A * Common Development and Distribution License (the "License"). 2N/A * You may not use this file except in compliance with the License. 2N/A * See the License for the specific language governing permissions 2N/A * and limitations under the License. 2N/A * When distributing Covered Code, include this CDDL HEADER in each 2N/A * If applicable, add the following below this CDDL HEADER, with the 2N/A * fields enclosed by brackets "[]" replaced with your own identifying 2N/A * information: Portions Copyright [yyyy] [name of copyright owner] 2N/A * Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved. 2N/A * FIPS 140-2 pairwise consistency check utilized to validate key pair. 2N/A * This function returns 2N/A * CKR_OK if pairwise consistency check passed 2N/A * CKR_GENERAL_ERROR if pairwise consistency check failed 2N/A * other error codes if pairwise consistency check could not be 2N/A * performed, for example, CKR_HOST_MEMORY. 2N/A * Key type Mechanism type 2N/A * -------------------------------- 2N/A * CKK_DSA => CKM_DSA_SHA1 2N/A * CKK_EC => CKM_ECDSA_SHA1 2N/A * others => CKM_INVALID_MECHANISM 2N/A * None of these mechanisms has a parameter. 2N/A /* always uses SHA-1 digest */ 2N/A /* Get modulus length of private key. */ 2N/A /* Check to see if key object supports signature. */ 2N/A /* Determine length of signature. */ 2N/A /* Allocate space for signature data. */ 2N/A /* Sign the known hash using the private key. */ 2N/A /* Verify the known hash using the public key. */ 2N/A /* Free signature data. */