NSSSWriteSharedSecret
Creates a SecretID according to the Shared Secret format
utilizing either the prefix SS_App or SS_CredSet.
Syntax
#include <nssscl.h>
SS_EXTERN_LIBCALL(int) NSSSWriteSharedSecret
(
void *handle,
SS_SH_SECRET_ID_T *pSharedSecret,
SSS_CONTEXT_T *context,
SS_OBJECT_DN_T targetObjDN,
unsigned long *ssFlags,
SS_PWORD_T *epPassword,
SS_EXT_T *ext
);
Parameters
- handle
- Specifies the handle created by NSSSCreateSHSHandle.
- pSharedSecret
- (IN) Points to the user-populated SS_SH_SECRET_ID_T
struct containing the Shared Secret type, name, and length.
- context
- (IN) Specifies an optional structure that can be
initialized by making a call to NSSSGetServiceInformation prior to use here. The flags field
of the structure can take on the following values to indicate the
type of context used.NSSS_NCP_CTX_F—Directory
Service API context indicator flagNSSS_LDAP_CTX_F—LDAP
context indicator flag <reserved>
- targetObjDN
- (IN) This is the optional RDN (relative distinguished
name or "short name") of the target object that contains the user's
secrets. The caller should have at least READ/WRITE privileges
over the target object.
NOTE:For binding to server over LDAP/SSL this parameter
is mandatory and it should be in fully qualified LDAP form ("cn=user,
ou=users, o=novell").
- ssFlags
- (IN) Specifies the flags used when making the call
to NSSSWriteSecret.
- epPassword
- (IN) Specifies an optional field to pass in the
Master Password or the Enhanced Protection Password for reading
a secret. When neither one of the passwords are present, you can
pass in a NULL.
- ext
- (IN) Points to the extensions used for the secrets.
Remarks
The internal buffer is parsed according to the shared secret
format defined by the parsing library. The resulting data is passed
into the secret buffer for passage into NSSSWriteSecret and stored as shared secrets in the
SecretStore. Consequently, this function provide flexibility in
making calls to trees and user DNs other than the primary connection.