2 // DL plugin transition layer.
3 // This file was automatically generated. Do not edit on penalty of futility!
5 #ifndef _H_DLABSTRACTSESSION
6 #define _H_DLABSTRACTSESSION
8 #include <security_cdsa_plugin/pluginsession.h>
9 #include <security_cdsa_utilities/cssmdata.h>
10 #include <security_cdsa_utilities/cssmacl.h>
11 #include <security_cdsa_utilities/cssmdb.h>
18 // A pure abstract class to define the DL module interface
20 class DLAbstractPluginSession
{
22 virtual ~DLAbstractPluginSession();
23 virtual void FreeNameList(CSSM_NAME_LIST
&NameList
) = 0;
24 virtual void CreateRelation(CSSM_DB_HANDLE DBHandle
,
25 CSSM_DB_RECORDTYPE RelationID
,
26 const char *RelationName
,
27 uint32 NumberOfAttributes
,
28 const CSSM_DB_SCHEMA_ATTRIBUTE_INFO
*pAttributeInfo
,
29 uint32 NumberOfIndexes
,
30 const CSSM_DB_SCHEMA_INDEX_INFO
&pIndexInfo
) = 0;
31 virtual void DataModify(CSSM_DB_HANDLE DBHandle
,
32 CSSM_DB_RECORDTYPE RecordType
,
33 CSSM_DB_UNIQUE_RECORD
&UniqueRecordIdentifier
,
34 const CSSM_DB_RECORD_ATTRIBUTE_DATA
*AttributesToBeModified
,
35 const CssmData
*DataToBeModified
,
36 CSSM_DB_MODIFY_MODE ModifyMode
) = 0;
37 virtual void DataAbortQuery(CSSM_DB_HANDLE DBHandle
,
38 CSSM_HANDLE ResultsHandle
) = 0;
39 virtual void DestroyRelation(CSSM_DB_HANDLE DBHandle
,
40 CSSM_DB_RECORDTYPE RelationID
) = 0;
41 virtual void DbCreate(const char *DbName
,
42 const CSSM_NET_ADDRESS
*DbLocation
,
43 const CSSM_DBINFO
&DBInfo
,
44 CSSM_DB_ACCESS_TYPE AccessRequest
,
45 const CSSM_RESOURCE_CONTROL_CONTEXT
*CredAndAclEntry
,
46 const void *OpenParameters
,
47 CSSM_DB_HANDLE
&DbHandle
) = 0;
48 virtual CSSM_HANDLE
DataGetFirst(CSSM_DB_HANDLE DBHandle
,
49 const CssmQuery
*Query
,
50 CSSM_DB_RECORD_ATTRIBUTE_DATA
*Attributes
,
52 CSSM_DB_UNIQUE_RECORD_PTR
&UniqueId
) = 0;
53 virtual void GetDbNames(CSSM_NAME_LIST_PTR
&NameList
) = 0;
54 virtual void DbClose(CSSM_DB_HANDLE DBHandle
) = 0;
55 virtual void GetDbNameFromHandle(CSSM_DB_HANDLE DBHandle
,
57 virtual void DataInsert(CSSM_DB_HANDLE DBHandle
,
58 CSSM_DB_RECORDTYPE RecordType
,
59 const CSSM_DB_RECORD_ATTRIBUTE_DATA
*Attributes
,
61 CSSM_DB_UNIQUE_RECORD_PTR
&UniqueId
) = 0;
62 virtual void ChangeDbAcl(CSSM_DB_HANDLE DBHandle
,
63 const AccessCredentials
&AccessCred
,
64 const CSSM_ACL_EDIT
&AclEdit
) = 0;
65 virtual void PassThrough(CSSM_DB_HANDLE DBHandle
,
67 const void *InputParams
,
68 void **OutputParams
) = 0;
69 virtual void GetDbAcl(CSSM_DB_HANDLE DBHandle
,
70 const CSSM_STRING
*SelectionTag
,
71 uint32
&NumberOfAclInfos
,
72 CSSM_ACL_ENTRY_INFO_PTR
&AclInfos
) = 0;
73 virtual void DataGetFromUniqueRecordId(CSSM_DB_HANDLE DBHandle
,
74 const CSSM_DB_UNIQUE_RECORD
&UniqueRecord
,
75 CSSM_DB_RECORD_ATTRIBUTE_DATA
*Attributes
,
77 virtual void DbOpen(const char *DbName
,
78 const CSSM_NET_ADDRESS
*DbLocation
,
79 CSSM_DB_ACCESS_TYPE AccessRequest
,
80 const AccessCredentials
*AccessCred
,
81 const void *OpenParameters
,
82 CSSM_DB_HANDLE
&DbHandle
) = 0;
83 virtual bool DataGetNext(CSSM_DB_HANDLE DBHandle
,
84 CSSM_HANDLE ResultsHandle
,
85 CSSM_DB_RECORD_ATTRIBUTE_DATA
*Attributes
,
87 CSSM_DB_UNIQUE_RECORD_PTR
&UniqueId
) = 0;
88 virtual void FreeUniqueRecord(CSSM_DB_HANDLE DBHandle
,
89 CSSM_DB_UNIQUE_RECORD
&UniqueRecord
) = 0;
90 virtual void ChangeDbOwner(CSSM_DB_HANDLE DBHandle
,
91 const AccessCredentials
&AccessCred
,
92 const CSSM_ACL_OWNER_PROTOTYPE
&NewOwner
) = 0;
93 virtual void Authenticate(CSSM_DB_HANDLE DBHandle
,
94 CSSM_DB_ACCESS_TYPE AccessRequest
,
95 const AccessCredentials
&AccessCred
) = 0;
96 virtual void DbDelete(const char *DbName
,
97 const CSSM_NET_ADDRESS
*DbLocation
,
98 const AccessCredentials
*AccessCred
) = 0;
99 virtual void DataDelete(CSSM_DB_HANDLE DBHandle
,
100 const CSSM_DB_UNIQUE_RECORD
&UniqueRecordIdentifier
) = 0;
101 virtual void GetDbOwner(CSSM_DB_HANDLE DBHandle
,
102 CSSM_ACL_OWNER_PROTOTYPE
&Owner
) = 0;
105 } // end namespace Security
107 #endif //_H_DLABSTRACTSESSION