ki8byte.c revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* Copyright (c) 1999 by Sun Microsystems, Inc.
* All rights reserved.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
/* Copyright (C) RSA Data Security, Inc. created 1990, 1996. This is an
unpublished work protected as such under copyright law. This work
contains proprietary, confidential, and trade secret information of
RSA Data Security, Inc. Use, disclosure or reproduction without the
express written authorization of RSA Data Security, Inc. is
prohibited.
*/
#include "port_before.h"
#include "global.h"
#include "bsafe2.h"
#include "bkey.h"
#include "kinfotyp.h"
#include "kiitem.h"
#include "ki8byte.h"
#include "port_after.h"
int KI_8Byte (keyInfoType)
{
/* Return 1 to indicate a KeyInfoType, not an AlgorithmInfoType */
return (1);
}
/* info points to 8 byte key.
Cache as a KITItem and a KIT_8Byte.
*/
{
int status;
/* Copy the 8 byte key. */
if ((status = B_MemoryPoolAllocAndCopy
return (status);
/* Cache as a KITItem as well as KIT_8Byte.
*/
return (status);
}
{
int status;
/* Try to make one from a KI_Item. Since KI_Item doesn't
call KI_8Byte, this should not cause an endless loop.
*/
return (status);
return (BE_WRONG_KEY_INFO);
return (0);
}