Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ sec_psm_sign_data(3sec) — DCE 3.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

sec_psm_sign_data(3sec)  —  Subroutines

NAME

sec_psm_sign_data —  Compute the signature of data using a specified signature algorithm . This routine is not available in the DCE binary code.  It is provided in DCE source for use by vendors. 

Synopsis

error_status_t sec_psm_sign_data(
sec_psm_handle_t psm_handle,
sec_pk_algorithm_id_t ∗signature_alg_id,
sec_pk_usage_flags_t key_usage,
sec_pk_gen_data_t ∗data,
unsigned32 ∗kvno,
sec_pk_signed_t ∗signature,
error_status_t ∗status_t);

Parameters

Input

psm_handle
A pointer to an opaque handle to the personal security context data. Use sec_psm_open()  to obtain the handle. 

signature_alg_id
The ASN.1 DER-encoded object ID of the signature algorithm. MD5WithRSAEncryption is the only algorithm ID currently supported. 

key_usageA sec_pk_usage_flags_t that contains the usage flag of the private key to be used in this operation. 

dataA pointer to the ASN.1 DER-encoded data to be signed. 

Output

kvnoThe version of the key being used. 

signatureA pointer to the computed signature. 

status_tA pointer to the completion status.  On successful completion, the routine returns error_status_ok.  Otherwise, it returns an error. 

Description

The sec_psm_sign_data() routine computes the signature of input data by using the signature algorithm specified by signature_alg_id.  This routine allocates memory for the returned signed data.  Call the sec_pk_data_free() routine to deallocate that memory. 

Files

/usr/include/dce/sec_pk_base.idl
The idl file from which dce/sec_pk_base.h was derived. 

Errors

The following describes a partial list of errors that might be returned.  Refer to the OSF DCE Problem Determination Guide for complete descriptions of all error messages. 

error_status_ok

sec_psm_not_init

sec_psm_invalid_handle

sec_psm_unsupported_algorithm_id

sec_pvtkey_invalid_handle

sec_pvtkey_mechanism_not_init

sec_pvtkey_internal_error

sec_pvtkey_invalid_password

sec_pvtkey_multiple_key_usages

Related Information

Functions: sec_pk_data_free(3sec), sec_psm_verify_data(3sec). 

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026