mirror of https://github.com/lianthony/NT4.0
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
50 lines
872 B
50 lines
872 B
//+---------------------------------------------------------------------------
|
|
//
|
|
// Microsoft Windows
|
|
// Copyright (C) Microsoft Corporation, 1992 - 1995.
|
|
//
|
|
// File: sign.c
|
|
//
|
|
// Contents:
|
|
//
|
|
// Classes:
|
|
//
|
|
// Functions:
|
|
//
|
|
// History: 8-30-95 TerenceS created
|
|
//
|
|
//----------------------------------------------------------------------------
|
|
|
|
#include "pctsspi.h"
|
|
|
|
|
|
BOOL PctSign(PPctContext pContext,
|
|
PUCHAR pData,
|
|
DWORD dwDataLen,
|
|
PUCHAR pOutBuf,
|
|
DWORD *dwBufLen)
|
|
{
|
|
if (*dwBufLen < dwDataLen)
|
|
{
|
|
*dwBufLen = dwDataLen;
|
|
return FALSE;
|
|
}
|
|
*dwBufLen = dwDataLen;
|
|
|
|
memcpy(pOutBuf, pData, dwDataLen);
|
|
|
|
return TRUE;
|
|
}
|
|
|
|
BOOL PctVerifySign(PPctContext pContext,
|
|
PVOID pCert,
|
|
PUCHAR pSigData,
|
|
DWORD dwSigLen)
|
|
{
|
|
// get public key from certificate
|
|
|
|
// verify signature with public key
|
|
|
|
return TRUE;
|
|
}
|
|
|