127 Commits

Author SHA1 Message Date
wtc%netscape.com
5f7e803993 Bugzilla bug 131427: add "for Clients" to the version id strings in the
softoken shared library if MOZ_CLIENT is defined.  r=relyea.


git-svn-id: svn://10.0.0.236/trunk@116994 18797224-902f-48f8-a5cc-f745e15eee43
2002-03-20 21:17:30 +00:00
wtc%netscape.com
796755f94c Bugzilla bug 131430: changed "softoken" to "softokn" to match the file
name.  r=relyea.


git-svn-id: svn://10.0.0.236/trunk@116950 18797224-902f-48f8-a5cc-f745e15eee43
2002-03-20 04:43:41 +00:00
wtc%netscape.com
0470369454 Bugzilla bug 131427: added sccs and rcs version id strings to the softoken
shared library.  r=relyea.
Modified files: manifest.mn pkcs11.c
Added file: softkver.c


git-svn-id: svn://10.0.0.236/trunk@116948 18797224-902f-48f8-a5cc-f745e15eee43
2002-03-20 04:38:09 +00:00
wtc%netscape.com
6e48c6cbb2 Bugzilla bug 130158: fixed a crash in NSC_CopyObject if pk11_CopyObject
fails.


git-svn-id: svn://10.0.0.236/trunk@116520 18797224-902f-48f8-a5cc-f745e15eee43
2002-03-14 03:34:11 +00:00
wtc%netscape.com
53ab332e0a Bugzilla bug 129408: final adjustments of the NSS 3.4 *.def files. List
the symbols in alphabetical order.  In softokn.def, changed "Sofoken 3.4
release" to "NSS 3.4 release, which is what we use in other *.def files.
Added seven new PKCS7 exports to smime.def.  r=relyea
Modified files: nss.def smime.def softokn.def ssl.def


git-svn-id: svn://10.0.0.236/trunk@116083 18797224-902f-48f8-a5cc-f745e15eee43
2002-03-07 21:18:49 +00:00
wtc%netscape.com
7d59ac43e4 Bugzilla bug 128599: link libnss3.so with -R $ORIGIN on Solaris to help it
find libsoftokn3.so.  Fixed an outdated comment in softoken/config.mk.


git-svn-id: svn://10.0.0.236/trunk@115665 18797224-902f-48f8-a5cc-f745e15eee43
2002-03-03 02:34:32 +00:00
relyea%netscape.com
77f0b9ab02 Implement PKCS #11 2.11 DSA PQG Parameter generation.
git-svn-id: svn://10.0.0.236/trunk@115613 18797224-902f-48f8-a5cc-f745e15eee43
2002-03-02 00:52:05 +00:00
relyea%netscape.com
a81db5e449 Fix PSM name problem.
Fix crash when trying to access/delete an non-existant object.


git-svn-id: svn://10.0.0.236/trunk@115505 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-28 21:30:13 +00:00
relyea%netscape.com
2fd301c4bb The KRL reserved handled should be different from the primordial CRL handle
so that CRL matching code will work correctly.


git-svn-id: svn://10.0.0.236/trunk@115428 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-27 16:57:45 +00:00
relyea%netscape.com
e2ffd199c0 When using global params, noCertDB implies noKeyDB as well bug 127312
git-svn-id: svn://10.0.0.236/trunk@115347 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-26 02:28:21 +00:00
relyea%netscape.com
eb8490a832 Bug 125728 truncate utf8 correctly in the pkcs11 string.
git-svn-id: svn://10.0.0.236/trunk@115338 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-26 00:33:42 +00:00
ian.mcgreer%sun.com
202313e65b bug 125359, by default the ASN.1 en/decoder should treat all numbers as signed. But many source/target items desire unsigned integers (specifically, bignums in the crypto stuff), so implement an siUnsignedInteger type which notifies the en/decoder to handle the conversion.
r=nelsonb


git-svn-id: svn://10.0.0.236/trunk@115170 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-21 22:41:44 +00:00
wtc%netscape.com
a07081d36e Fixed misspelling.
git-svn-id: svn://10.0.0.236/trunk@115123 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-21 00:06:14 +00:00
wtc%netscape.com
5ec3d3684a Bugzilla bug 125149: prevent the session ID count component of the session
ID from overflowing and corrupting the slot index component.  Do a lookup
in the session hash table to make sure the session id is not in use before
adding it to the table.  r=relyea.
Modified files: pkcs11.c pkcs11i.h


git-svn-id: svn://10.0.0.236/trunk@115121 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-20 23:59:35 +00:00
wtc%netscape.com
34ff13e6c2 nscSlotHashTable is not protected by a lock, so we need to use
PL_HashTableLookupConst to do the lookups.  r=mcgreer.  This bug is
discussed in bug 125149 but is not the main topic of that bug.


git-svn-id: svn://10.0.0.236/trunk@115120 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-20 23:53:45 +00:00
kirk.erickson%sun.com
994e815065 Added tokenIDCount, and tokenHashTable to comments about objectLock.
git-svn-id: svn://10.0.0.236/trunk@115108 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-20 18:05:52 +00:00
nelsonb%netscape.com
d58ebedbc4 Change most coreconf and NSS makefiles to use OS_TARGET (which can
be overridden via an environment variable) rather than OS_ARCH.
This is a precursor to more flexibility in cross-platform builds.
Bug 104541.


git-svn-id: svn://10.0.0.236/trunk@114608 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-15 22:54:08 +00:00
relyea%netscape.com
a81513d4cf Fix UMR in the session info structure.
git-svn-id: svn://10.0.0.236/trunk@114461 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-14 01:12:51 +00:00
kirk.erickson%sun.com
513f733351 Commented SlotStr with information what what locks protect what.
git-svn-id: svn://10.0.0.236/trunk@114193 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-11 20:14:05 +00:00
nelsonb%netscape.com
d2efb641d7 Make NSS 3.4 build as part of mozilla on OS/2. Bug 114748.
Patch supplied by Javier Pedemonte.


git-svn-id: svn://10.0.0.236/trunk@114184 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-11 05:48:37 +00:00
wtc%netscape.com
dfc55d137a Bugzilla bug 121523: checked in Kirk Erickson's session lock fix.
Modified Files:
	lib/pk11wrap/pk11slot.c lib/softoken/pkcs11.c
	lib/softoken/pkcs11i.h lib/softoken/pkcs11u.c


git-svn-id: svn://10.0.0.236/trunk@113726 18797224-902f-48f8-a5cc-f745e15eee43
2002-02-05 23:41:36 +00:00
relyea%netscape.com
92d5738180 Fix searching code so it can find CRL's
git-svn-id: svn://10.0.0.236/trunk@113254 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-31 00:16:29 +00:00
ian.mcgreer%sun.com
c1c7114dbe changes related to bug 115660
* fipstoken will only force authentication for object-related functions when the object is a private or secret key
* certutil does not authenticate to token when in FIPS and only doing cert-related operations
* QA does not provide password to certutil when doing cert-related operations in FIPS tests


git-svn-id: svn://10.0.0.236/trunk@113122 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-29 17:30:22 +00:00
relyea%netscape.com
2ae1f651be (sigh) not only do we need to find the objects, we need to be able to read
them as well.


git-svn-id: svn://10.0.0.236/trunk@113061 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-28 23:28:29 +00:00
relyea%netscape.com
517e6d30a2 Fix 2 memory leaks and a UMR.
(keyhand needs to be initialized before we start xor hashing)
Free item and time elements which are transparently allocated for us.


git-svn-id: svn://10.0.0.236/trunk@112916 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-26 00:16:03 +00:00
relyea%netscape.com
d9934c8ada Change Sha1_hash to a simple XOR hash for building key handles for token
objects.


git-svn-id: svn://10.0.0.236/trunk@112869 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-25 19:09:34 +00:00
relyea%netscape.com
61c9862c40 Fix bug 115660. Note that fixing the bugs necessitates fixing the test
cases as well. The test case was depending on the failure to read certs to
detect the failure to read keys. Now certutil returns a failure if no keys
are found. This also means that the FIPS test after the key and cert
has been deleted should expect a failure to list any keys.


git-svn-id: svn://10.0.0.236/trunk@112866 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-25 19:03:17 +00:00
relyea%netscape.com
cbe61129a7 Too agressive on fixing leaks;). This one isn't a leak.
bob


git-svn-id: svn://10.0.0.236/trunk@112733 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-24 21:33:51 +00:00
relyea%netscape.com
ae3fbdd717 Fix memory leaks.
git-svn-id: svn://10.0.0.236/trunk@112591 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-24 00:26:29 +00:00
relyea%netscape.com
a9049ce9b3 Fix memory like in readSMimeEntry
git-svn-id: svn://10.0.0.236/trunk@112560 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-23 01:44:22 +00:00
relyea%netscape.com
3a74953b5a Labels don't have NULL's by default.
git-svn-id: svn://10.0.0.236/trunk@112552 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-23 00:53:53 +00:00
ian.mcgreer%sun.com
6f2350c744 PSM bug 119359, NSS 3.4 also needs to recognize valid CA trust in order for cert download to work correctly
git-svn-id: svn://10.0.0.236/trunk@112551 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-23 00:49:23 +00:00
ian.mcgreer%sun.com
f07c00bdc9 more backwards compatibility fixes
* always send DER of serial number to PKCS#11 queries
* in softoken, construct key for certificate using decoded serial number with (possibly) a leading zero, for compatibility with version 7 db
* in softoken, decode serial number *without* removing leading zero for searches


git-svn-id: svn://10.0.0.236/trunk@112364 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-17 00:20:53 +00:00
ian.mcgreer%sun.com
8e74c502fd fix build bustage
git-svn-id: svn://10.0.0.236/trunk@112355 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-16 21:36:33 +00:00
ian.mcgreer%sun.com
57295d6507 fix for bug 115360, failure in pkcs12 backwards compatibility tests
git-svn-id: svn://10.0.0.236/trunk@112352 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-16 21:22:30 +00:00
ian.mcgreer%sun.com
0ffa79b3fc unfortunately, the SDR key keeps the value of CK_KEY_TYPE in the coefficient field of an RSA key. This means some format is lost through the ASN.1 encoder/decoer. Trying again to account for that without affecting normal key type attributes.
git-svn-id: svn://10.0.0.236/trunk@112345 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-16 16:02:51 +00:00
ian.mcgreer%sun.com
ef3b20d931 fix up problems in last change
git-svn-id: svn://10.0.0.236/trunk@112235 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-16 00:04:16 +00:00
ian.mcgreer%sun.com
58cb3db0bc revert last change, and move conversion of attribute value to host long up to where the long variable actually appears.
git-svn-id: svn://10.0.0.236/trunk@112190 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-15 21:45:38 +00:00
ian.mcgreer%sun.com
b09f4e3c33 fix SDR on big-endian platforms. The leading zeros in the RSA coefficient have been stripped, but PKCS#11 needs them back in order to form a CK_ULONG correctly.
git-svn-id: svn://10.0.0.236/trunk@112189 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-15 19:20:34 +00:00
ian.mcgreer%sun.com
9e90fd1474 Fix for serial numbers which are negative when intrepreted as signed integers. Since the ASN.1 encoder now add/strips leading zeros to INTEGERs, the hand decoder written here will incorrectly decode serial numbers passed to it that have leading zeros.
git-svn-id: svn://10.0.0.236/trunk@112178 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-15 15:43:35 +00:00
ian.mcgreer%sun.com
69f304d8ad fix for bug 115360, ASN.1 encoder/decoder should handle conversion of unsigned integers used in NSS to ASN.1 INTEGERs, and vice versa.
git-svn-id: svn://10.0.0.236/trunk@112118 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-14 23:20:43 +00:00
ian.mcgreer%sun.com
05b6bbf20c *sigh*
fixed backward compatibity tests, but broke current version.  will have to rework.


git-svn-id: svn://10.0.0.236/trunk@111981 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-11 23:37:37 +00:00
ian.mcgreer%sun.com
18b97b7a4c temporary fix for bug 115360
git-svn-id: svn://10.0.0.236/trunk@111969 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-11 22:24:31 +00:00
relyea%netscape.com
af84479b7f Set up default trust order correctly.
Default trustorder is
   0 for the internal token
   100 for the builtins
   50 for everyone else

Default Cipher order is
   100 for the internal token
   0 for everyone else


git-svn-id: svn://10.0.0.236/trunk@111760 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-10 00:59:26 +00:00
ian.mcgreer%sun.com
e46a7dedc4 bug 118612, implement valid peer trust in softoken
git-svn-id: svn://10.0.0.236/trunk@111595 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-08 22:01:17 +00:00
ian.mcgreer%sun.com
93942f465e memory leak fixes
git-svn-id: svn://10.0.0.236/trunk@111574 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-08 15:37:42 +00:00
relyea%netscape.com
f4994efe5d Startup problems on new profiles: 1) Windows does not initially open the DB R/W
on startup. 2) All platforms do not see the built-ins token if you startup with
a new profile.

Fix: 1) Escape the initialization parameters.
     2) Rebuild the Token iterator when new tokens are added to the trust domain.


git-svn-id: svn://10.0.0.236/trunk@111399 18797224-902f-48f8-a5cc-f745e15eee43
2002-01-05 03:00:10 +00:00
relyea%netscape.com
e5afe0dfcb Fix Bug 115657.
1) advance the pointers in the initialization setup for p12 pbes (at the same
time fix the code to be much easier to read and understand).
2) Copy out the returned IV in pkcs11c.c.


git-svn-id: svn://10.0.0.236/trunk@110815 18797224-902f-48f8-a5cc-f745e15eee43
2001-12-19 18:06:29 +00:00
ian.mcgreer%sun.com
d079ef794b needed for traversal of keys
git-svn-id: svn://10.0.0.236/trunk@110628 18797224-902f-48f8-a5cc-f745e15eee43
2001-12-17 13:43:34 +00:00
ian.mcgreer%sun.com
ee0266636e dbhandle needs to be set for subject list certs to work
git-svn-id: svn://10.0.0.236/trunk@110627 18797224-902f-48f8-a5cc-f745e15eee43
2001-12-17 13:43:10 +00:00