Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(242)

Side by Side Diff: mozilla/security/nss/lib/dev/devm.h

Issue 14249009: Change the NSS and NSPR source tree to the new directory structure to be (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/nss/
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « mozilla/security/nss/lib/dev/dev.h ('k') | mozilla/security/nss/lib/dev/devslot.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4
5 #ifndef DEVM_H
6 #define DEVM_H
7
8 #ifdef DEBUG
9 static const char DEVM_CVS_ID[] = "@(#) $RCSfile: devm.h,v $ $Revision: 1.13 $ $ Date: 2012/04/25 14:49:42 $";
10 #endif /* DEBUG */
11
12 #ifndef BASE_H
13 #include "base.h"
14 #endif /* BASE_H */
15
16 #ifndef DEV_H
17 #include "dev.h"
18 #endif /* DEV_H */
19
20 #ifndef DEVTM_H
21 #include "devtm.h"
22 #endif /* DEVTM_H */
23
24 PR_BEGIN_EXTERN_C
25
26 /* Shortcut to cryptoki API functions. */
27 #define CKAPI(epv) \
28 ((CK_FUNCTION_LIST_PTR)(epv))
29
30 NSS_EXTERN void
31 nssDevice_AddRef
32 (
33 struct nssDeviceBaseStr *device
34 );
35
36 NSS_EXTERN PRBool
37 nssDevice_Destroy
38 (
39 struct nssDeviceBaseStr *device
40 );
41
42 NSS_EXTERN PRBool
43 nssModule_IsThreadSafe
44 (
45 NSSModule *module
46 );
47
48 NSS_EXTERN PRBool
49 nssModule_IsInternal
50 (
51 NSSModule *mod
52 );
53
54 NSS_EXTERN PRBool
55 nssModule_IsModuleDBOnly
56 (
57 NSSModule *mod
58 );
59
60 NSS_EXTERN void *
61 nssModule_GetCryptokiEPV
62 (
63 NSSModule *mod
64 );
65
66 NSS_EXTERN NSSSlot *
67 nssSlot_Create
68 (
69 CK_SLOT_ID slotId,
70 NSSModule *parent
71 );
72
73 NSS_EXTERN void *
74 nssSlot_GetCryptokiEPV
75 (
76 NSSSlot *slot
77 );
78
79 NSS_EXTERN NSSToken *
80 nssToken_Create
81 (
82 CK_SLOT_ID slotID,
83 NSSSlot *peer
84 );
85
86 NSS_EXTERN void *
87 nssToken_GetCryptokiEPV
88 (
89 NSSToken *token
90 );
91
92 NSS_EXTERN nssSession *
93 nssToken_GetDefaultSession
94 (
95 NSSToken *token
96 );
97
98 NSS_EXTERN PRBool
99 nssToken_IsLoginRequired
100 (
101 NSSToken *token
102 );
103
104 NSS_EXTERN void
105 nssToken_Remove
106 (
107 NSSToken *token
108 );
109
110 NSS_EXTERN nssCryptokiObject *
111 nssCryptokiObject_Create
112 (
113 NSSToken *t,
114 nssSession *session,
115 CK_OBJECT_HANDLE h
116 );
117
118 NSS_EXTERN nssTokenObjectCache *
119 nssTokenObjectCache_Create
120 (
121 NSSToken *token,
122 PRBool cacheCerts,
123 PRBool cacheTrust,
124 PRBool cacheCRLs
125 );
126
127 NSS_EXTERN void
128 nssTokenObjectCache_Destroy
129 (
130 nssTokenObjectCache *cache
131 );
132
133 NSS_EXTERN void
134 nssTokenObjectCache_Clear
135 (
136 nssTokenObjectCache *cache
137 );
138
139 NSS_EXTERN PRBool
140 nssTokenObjectCache_HaveObjectClass
141 (
142 nssTokenObjectCache *cache,
143 CK_OBJECT_CLASS objclass
144 );
145
146 NSS_EXTERN nssCryptokiObject **
147 nssTokenObjectCache_FindObjectsByTemplate
148 (
149 nssTokenObjectCache *cache,
150 CK_OBJECT_CLASS objclass,
151 CK_ATTRIBUTE_PTR otemplate,
152 CK_ULONG otlen,
153 PRUint32 maximumOpt,
154 PRStatus *statusOpt
155 );
156
157 NSS_EXTERN PRStatus
158 nssTokenObjectCache_GetObjectAttributes
159 (
160 nssTokenObjectCache *cache,
161 NSSArena *arenaOpt,
162 nssCryptokiObject *object,
163 CK_OBJECT_CLASS objclass,
164 CK_ATTRIBUTE_PTR atemplate,
165 CK_ULONG atlen
166 );
167
168 NSS_EXTERN PRStatus
169 nssTokenObjectCache_ImportObject
170 (
171 nssTokenObjectCache *cache,
172 nssCryptokiObject *object,
173 CK_OBJECT_CLASS objclass,
174 CK_ATTRIBUTE_PTR ot,
175 CK_ULONG otlen
176 );
177
178 NSS_EXTERN void
179 nssTokenObjectCache_RemoveObject
180 (
181 nssTokenObjectCache *cache,
182 nssCryptokiObject *object
183 );
184
185 /* XXX allows peek back into token */
186 NSS_EXTERN PRStatus
187 nssToken_GetCachedObjectAttributes
188 (
189 NSSToken *token,
190 NSSArena *arenaOpt,
191 nssCryptokiObject *object,
192 CK_OBJECT_CLASS objclass,
193 CK_ATTRIBUTE_PTR atemplate,
194 CK_ULONG atlen
195 );
196
197 /* PKCS#11 stores strings in a fixed-length buffer padded with spaces. This
198 * function gets the length of the actual string.
199 */
200 NSS_EXTERN PRUint32
201 nssPKCS11String_Length
202 (
203 CK_CHAR *pkcs11str,
204 PRUint32 bufLen
205 );
206
207 PR_END_EXTERN_C
208
209 #endif /* DEV_H */
OLDNEW
« no previous file with comments | « mozilla/security/nss/lib/dev/dev.h ('k') | mozilla/security/nss/lib/dev/devslot.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698