39 Commits

Author SHA1 Message Date
glen.beasley%sun.com
cea2043bf8 433063 move header to correct directories under freebl and softoken r=nelson
git-svn-id: svn://10.0.0.236/trunk@255566 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-17 21:39:05 +00:00
wtc%google.com
47d7f96061 Bug 436430: NSS public headers should not use NSPR 1.0 compatibility types
and macros.  Replaced PRArenaPool by PLArenaPool and int64 by PRTime.  The
patch is generated by Nelson Bolyard <nelson@bolyard.com>.  r=wtc
Modified Files:
	certdb/cert.h certdb/certdb.h certdb/certt.h certhigh/ocsp.h
	cryptohi/cryptohi.h cryptohi/keyhi.h cryptohi/keythi.h
	freebl/blapit.h pk11wrap/pk11priv.h pk11wrap/pk11pub.h
	pk11wrap/secmodt.h pkcs12/p12.h pkcs12/p12t.h pkcs12/pkcs12t.h
	pkcs7/pkcs7t.h pkcs7/secpkcs7.h smime/cms.h util/nssb64.h
	util/secasn1.h util/secder.h util/secdig.h util/secitem.h
	util/secoid.h


git-svn-id: svn://10.0.0.236/trunk@255477 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:41 +00:00
rrelyea%redhat.com
d55e9b04d6 Bug 391296 – Need an update helper for Shared Databases
r=nelson.


git-svn-id: svn://10.0.0.236/trunk@255474 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:38 +00:00
wtc%google.com
49afdfd211 Bug 402777: moved all fake PKCS #11 defines from secmodt.h to pkcs11n.h.
r=rrelyea.  In loader.c, functions returning void must not return a value.
Modified Files:
	lib/freebl/loader.c lib/pk11wrap/secmodt.h
	lib/softoken/pkcs11n.h


git-svn-id: svn://10.0.0.236/trunk@255473 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:37 +00:00
wtc%google.com
6a4a31320e Bug 402777: Two changes to make lib/util more stand-alone. Moved
CKM_INVALID_MECHANISM from secmodt.h to pkcs11n.h.  Moved the three
CERTValidity functions from lib/util/sectime.c to lib/certdb/certdb.c.
r=rrelyea.
Modified Files:
	lib/certdb/certdb.c lib/nss/utilwrap.c lib/pk11wrap/secmodt.h
	lib/softoken/pkcs11n.h lib/util/nssutil.def lib/util/secoid.c
	lib/util/sectime.c lib/util/utilrename.h


git-svn-id: svn://10.0.0.236/trunk@255470 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:34 +00:00
rrelyea%redhat.com
ce0555eb14 Need to provide a way to modify and create new PKCS #11 objects.
bug 401026
r=julien

Implements 2 new functions, one to modify existing pkcs #11 objects, and
another to creat them.


git-svn-id: svn://10.0.0.236/trunk@255469 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:33 +00:00
julien.pierre.bugs%sun.com
e1c2071eb3 Fix for bug 220115 . Make the CKM constants unsigned . r=nelson
git-svn-id: svn://10.0.0.236/trunk@255468 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:32 +00:00
rrelyea%redhat.com
f35cc7615f Add Camilla cipher suites TLS RFC4132 bug 361025
code supplied by okazaki@kick.gr.jp


git-svn-id: svn://10.0.0.236/trunk@255467 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:31 +00:00
relyea%netscape.com
2eba608c1d Bug 272484 Certificate manager crashes [@ _PR_MD_ATOMIC_DECREMENT - PK11_FreeSymKey]
The problem only happens if we try to import a key into a token which then fails
to import. The basic issue was a hack in the pkcs 7 code to support PKCS 12, A
special structure was used to replace the SymKey structure, and the code 'knew'
the special structure existed before it dealt with the symkey. The fix addes a
new capability to symkeys, where applications can attach application specific
data to the key structure. PKCS 12 uses this to attache the PBE information
for CMS. (part 1 of 3)

This patch also improves the key's reuse of sessions, so sessions are not thrashed
when SSL is used with them.

r=wtc


git-svn-id: svn://10.0.0.236/trunk@255466 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:30 +00:00
relyea%netscape.com
221995519a Bug 119500 PKCS#11 CKF_PROTECTED_AUTHENTICATION_PATH token flag not supported
wtc's review r=wtc


git-svn-id: svn://10.0.0.236/trunk@255465 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:29 +00:00
relyea%netscape.com
8dfbc7fc32 Bugzilla Bug 119500 PKCS#11 CKF_PROTECTED_AUTHENTICATION_PATH token flag not supported
r=nelson

This is only the NSS portion of this patch. The PSM portion will be checked in once the
NSS portion is mainlined to mozilla.


git-svn-id: svn://10.0.0.236/trunk@255464 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:28 +00:00
relyea%netscape.com
262e9f2eeb Only call C_WaitForSlotEvent if the module is PKCS #11 v2.01 or later.
bug 196811 r=wtc sr=julien


git-svn-id: svn://10.0.0.236/trunk@255463 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:27 +00:00
wtchang%redhat.com
155a2ec064 Bugzilla Bug 299197: define two bitflags for every PKCS #11 object
attribute with no exceptions. renamed PK11_ATTR_READONLY as
PK11_ATTR_UNMODIFIABLE.  In pk11_OpFlagsToAttributes, backed out a change
I made before.  Made pk11_AttrFlagsToAttributes table-driven. In
pk11_loadPrivKeyWithFlags, fixed the bug (always loading the public key as
a token object).  Other code cleanups. r=relyea,nelsonb.
Modified files: pk11akey.c pk11obj.c pk11pub.h pk11skey.c secmodt.h


git-svn-id: svn://10.0.0.236/trunk@255462 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:26 +00:00
wtchang%redhat.com
0e0c8071f3 Bugzilla Bug 299197: added PK11AttrFlags and PK11_GenerateKeyPairWithFlags.
Modified PK11_TokenKeyGenWithFlags to take a PK11AttrFlags parameter.
PK11AttrFlags controls the values of commonly used PKCS #11 object
attributes that have Boolean values. r=relyea,nelsonb.
Modified Files:
	nss/nss.def pk11wrap/pk11akey.c pk11wrap/pk11obj.c
	pk11wrap/pk11pub.h pk11wrap/pk11skey.c pk11wrap/secmodi.h
	pk11wrap/secmodt.h


git-svn-id: svn://10.0.0.236/trunk@255461 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:25 +00:00
wtchang%redhat.com
c8dbcddb2a Bugzilla Bug 286439: Removed PKCS11_USE_THREADS and PK11_USE_THREADS.
r=relyea,nelsonb.
Modified Files:
	pk11wrap/pk11list.c pk11wrap/pk11pars.c pk11wrap/pk11skey.c
	pk11wrap/pk11slot.c pk11wrap/pk11util.c pk11wrap/secmod.h
	pk11wrap/secmodi.h pk11wrap/secmodt.h pk11wrap/secmodti.h
	softoken/pkcs11.c softoken/pkcs11i.h softoken/pkcs11u.c


git-svn-id: svn://10.0.0.236/trunk@255460 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:24 +00:00
relyea%netscape.com
fe17f2bec3 Bugzilla Bug 252702
NSS needs to handle better token insertion and removal.

Applied from patch to NSS 3.9


git-svn-id: svn://10.0.0.236/trunk@255459 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:23 +00:00
relyea%netscape.com
49b8bc51cc refactor pk11util, splitting large single files down to a managable size.
bug 246130. The new factor is:

pk11akey.c - asymetric keys constructed from pk11cert.c and pk11skey.c
pk11auth.c - authentication/password management factored from pk11slot.c
pk11cert.c - cert code with private key, crls and trust factored out.
pk11ctx.c -- pkcs11 context code, factored out of pk11skey.c
new pk11func.h -- for backward compatibility.
pk11mech.c - mechanism mapping code, factored mostly from pk11slot.c
pk11nobj.c - netscape objects (crls and trust), factored mostly from pk11cert.c
pk11obj.c - generic object support, factored from pk11skey.c pk11slot.c and
pk11cert.c
pk11priv.h -- private functions factored from pk11func.h
pk11pub.h -- public functions factored from pk11func.h
pk11skey.c - now only symetric key ops; private, public key ops, generic ops
and crypto contexs have been factored out.
pk11slot.c - still slot operations. Authentication, generic object ops,
mechanism mapping has been factored out.

This patch should only have refactoring, no new functions or other changes.


git-svn-id: svn://10.0.0.236/trunk@255458 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:22 +00:00
relyea%netscape.com
4d184ed9a6 Bug 244914, 244907 r=nelsonb
Add support for unprotected private keys without requiring authentication.
Add support to access application specific PKCS #11 objects through NSS.


git-svn-id: svn://10.0.0.236/trunk@255457 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:21 +00:00
gerv%gerv.net
d310f82bd8 Bug 236613: change to MPL/LGPL/GPL tri-license.
git-svn-id: svn://10.0.0.236/trunk@255456 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:20 +00:00
relyea%netscape.com
7c14261324 221067 NSS needs to be able to create token symkeys from unwrap and derive.
git-svn-id: svn://10.0.0.236/trunk@255454 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:18 +00:00
jpierre%netscape.com
3d941008c3 Fix for bug 215186 - add missing options to PK11_ListCerts . r=wtc
git-svn-id: svn://10.0.0.236/trunk@255453 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:17 +00:00
wtc%netscape.com
994f3cd51a Bugzilla bug 213158: fixed the misspelling of "attach". The patch is
contributed by Pierre Chanial <chanial@noos.fr>.
Modified Files: pk11slot.c secmodt.h


git-svn-id: svn://10.0.0.236/trunk@255452 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:16 +00:00
nelsonb%netscape.com
0f9d0f0940 Add missing declaration of NSS_Get_SECKEY_EncryptedPrivateKeyInfoTemplate
git-svn-id: svn://10.0.0.236/trunk@255451 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:15 +00:00
nelsonb%netscape.com
8f767acef6 Support SHA256, SHA384, and SHA512 hashes in NSS.
git-svn-id: svn://10.0.0.236/trunk@255450 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:14 +00:00
relyea%netscape.com
de0618aab1 Add token removal blocking function.
git-svn-id: svn://10.0.0.236/trunk@255447 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:11 +00:00
jpierre%netscape.com
7d0d5bc3e0 Fix for 98068 - PR_CALLBACK OS/2 issues
git-svn-id: svn://10.0.0.236/trunk@255446 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:10 +00:00
nicolson%netscape.com
d795bba911 Fix 114979: SECKEY_EncryptedPrivateKeyInfoTemplate no longer in public
header file.
r=relyea.


git-svn-id: svn://10.0.0.236/trunk@255445 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:09 +00:00
relyea%netscape.com
801d87a448 NSS 3.4 integration changes.
1) 3.4 needs to bump the version numbers up by one on secmod.db from NSS 3.3
   2) Need to add escapes to the configdirectory. (should add them to other parameters as well.
   3) put exported files back into the correct headers.
   4) Add _BEGIN/_END protos where appropriate.


git-svn-id: svn://10.0.0.236/trunk@255444 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:08 +00:00
relyea%netscape.com
a02cf5b62e Land BOB_WORK_BRANCH unto the tip.
remove lots of depricated files.
move some files to appropriate directories (pcertdb *_rand
associated headers to soft token, for instance)
rename several stan files which had the same name as other nss files.
remove depricated functions.


git-svn-id: svn://10.0.0.236/trunk@255443 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:07 +00:00
relyea%netscape.com
8e93697045 1) fix warnings on AIX, HP, Linux, and Solaris.
2) Move private functions into private headers.

3) Sharpen the layer separation between NSS components, especially pkcs #12
and soft token.

4) Remove dead code.


git-svn-id: svn://10.0.0.236/trunk@255442 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:06 +00:00
relyea%netscape.com
fd5e572e26 Land new PKCS #11 initialization code.
git-svn-id: svn://10.0.0.236/trunk@255441 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:05 +00:00
nicolson%netscape.com
fbfa9dd136 Changes for NSS/JSS integration.
git-svn-id: svn://10.0.0.236/trunk@255440 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:04 +00:00
nelsonb%netscape.com
2e67c809eb Merge NSS 3.2.1 changes.
git-svn-id: svn://10.0.0.236/trunk@255439 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:03 +00:00
relyea%netscape.com
e2571a855c Add wrapper bindings for AES so S/MIME and SSL may implement their AES suites.
git-svn-id: svn://10.0.0.236/trunk@255438 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:02 +00:00
relyea%netscape.com
8ce83a6d3b Incorporate Wan-Teh's suggestion of using a typdef for the enum.
Follow the same standard we use elsewhere for enums.


git-svn-id: svn://10.0.0.236/trunk@255437 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:01 +00:00
relyea%netscape.com
b82a64c454 Bug 65903: Fixes to allow iWS admin stuff to work with shared library NSS
Add necessary exported symbols.
Fix bug in NSS_Initialize where we weren't passing the read only paramter
	through.
Add function to search for Certificate Lists so that Traverse does not need to
	be exposed.
Update pkcs11 names.


git-svn-id: svn://10.0.0.236/trunk@255436 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:48:00 +00:00
wtc%netscape.com
9b5abb540b Bugzilla bug #65416: assign values explicitly to enumeration constants.
The same values that the compiler would assign are assigned, with only
one exception (cmmfNoPKIStatus in cmmft.h).  This is patch id=22555,
reviewed by Nelson Bolyard.


git-svn-id: svn://10.0.0.236/trunk@255435 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:47:59 +00:00
relyea%netscape.com
61f9727759 Add SSL and TLS to the slotlist search functions
git-svn-id: svn://10.0.0.236/trunk@255432 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:47:28 +00:00
relyea%netscape.com
5756782aab Initial NSS Open Source Checkin
git-svn-id: svn://10.0.0.236/trunk@255431 18797224-902f-48f8-a5cc-f745e15eee43
2008-12-10 22:47:27 +00:00