diff options
author | Michael Johnson <ahze@FreeBSD.org> | 2006-05-30 02:01:38 +0000 |
---|---|---|
committer | Michael Johnson <ahze@FreeBSD.org> | 2006-05-30 02:01:38 +0000 |
commit | 0e98e425893e8711c45e35e091602037d252cffb (patch) | |
tree | 033b9d1e59298c046eef555962538bf2308d1874 /security/nss | |
parent | - update to 0.82 (diff) |
- Update to 3.11.1
Notes
Notes:
svn path=/head/; revision=163915
Diffstat (limited to 'security/nss')
-rw-r--r-- | security/nss/Makefile | 3 | ||||
-rw-r--r-- | security/nss/distinfo | 6 | ||||
-rw-r--r-- | security/nss/files/patch-crlgen.c | 105 | ||||
-rw-r--r-- | security/nss/files/patch-warnings | 449 |
4 files changed, 4 insertions, 559 deletions
diff --git a/security/nss/Makefile b/security/nss/Makefile index f35f3ca01079..5359e6e0d263 100644 --- a/security/nss/Makefile +++ b/security/nss/Makefile @@ -6,8 +6,7 @@ # PORTNAME= nss -PORTVERSION= 3.11 -PORTREVISION= 1 +PORTVERSION= 3.11.1 CATEGORIES= security MASTER_SITES= ${MASTER_SITE_MOZILLA} MASTER_SITE_SUBDIR= security/nss/releases/NSS_${PORTVERSION:S/./_/g}_RTM/src diff --git a/security/nss/distinfo b/security/nss/distinfo index 257832aca93b..b61354b67f88 100644 --- a/security/nss/distinfo +++ b/security/nss/distinfo @@ -1,3 +1,3 @@ -MD5 (nss-3.11.tar.gz) = 9be73bd73e361e5e36edf77f456fa20a -SHA256 (nss-3.11.tar.gz) = 35b65a672c699f1e5fc082fccc29bcc65102ef8d31cff106f2ec68beace96809 -SIZE (nss-3.11.tar.gz) = 5002908 +MD5 (nss-3.11.1.tar.gz) = 5cb32527df232a62a7aed61336c8c373 +SHA256 (nss-3.11.1.tar.gz) = 3f29d1f77f8f4fb9dc59d3a2fd13587e9be373a1cc8528e39c5d17f30807dc50 +SIZE (nss-3.11.1.tar.gz) = 3650552 diff --git a/security/nss/files/patch-crlgen.c b/security/nss/files/patch-crlgen.c deleted file mode 100644 index c7a655c0b8f5..000000000000 --- a/security/nss/files/patch-crlgen.c +++ /dev/null @@ -1,105 +0,0 @@ ---- cmd/crlutil/crlgen.c Mon Apr 11 22:24:14 2005 -+++ cmd/crlutil/crlgen.c Fri Jul 29 01:50:48 2005 -@@ -53,46 +53,4 @@ - #include "crlgen.h" - -- --/* these reroutines were taken from secitem.c, which is supposed to -- * replace this file some day */ --/* -- * This is the hash function. We simply XOR the encoded form with -- * itself in sizeof(PLHashNumber)-byte chunks. Improving this -- * routine is left as an excercise for the more mathematically -- * inclined student. -- */ --PLHashNumber PR_CALLBACK --SECITEM_Hash ( const void *key) --{ -- const SECItem *item = (const SECItem *)key; -- PLHashNumber rv = 0; -- -- PRUint8 *data = (PRUint8 *)item->data; -- PRUint32 i; -- PRUint8 *rvc = (PRUint8 *)&rv; -- -- for( i = 0; i < item->len; i++ ) { -- rvc[ i % sizeof(rv) ] ^= *data; -- data++; -- } -- -- return rv; --} -- --/* -- * This is the key-compare function. It simply does a lexical -- * comparison on the item data. This does not result in -- * quite the same ordering as the "sequence of numbers" order, -- * but heck it's only used internally by the hash table anyway. -- */ --PRIntn PR_CALLBACK --SECITEM_HashCompare ( const void *k1, const void *k2) --{ -- const SECItem *i1 = (const SECItem *)k1; -- const SECItem *i2 = (const SECItem *)k2; -- -- return SECITEM_ItemsAreEqual(i1,i2); --} -- - /* Destroys extHandle and data. data was create on heap. - * extHandle creaded by CERT_StartCRLEntryExtensions. entry -@@ -513,5 +471,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "AddIssuerAltNames: insufficient number of arguments.\n"); - return SECFailure; - } -@@ -575,5 +533,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "AddCrlNumber: insufficient number of arguments.\n"); - goto loser; - } -@@ -725,5 +683,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "%s: insufficient number of arguments.\n", extName); - } - -@@ -923,5 +881,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "SetNewRangeField: insufficient number of arguments.\n"); - return SECFailure; - } -@@ -988,5 +946,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "SetTimeField: insufficient number of arguments.\n"); - return SECFailure; - } -@@ -1024,5 +982,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "AddExtension: insufficient number of arguments.\n"); - return SECFailure; - } -@@ -1042,5 +1000,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "AddExtension(%s) insufficient number of arguments.\n", *extData); - return SECFailure; - } -@@ -1078,5 +1036,5 @@ - PORT_SetError(SEC_ERROR_INVALID_ARGS); - crlgen_PrintError(crlGenData->parsedLineNum, -- "insufficient number of arguments.\n"); -+ "AddCert(%s, %s) insufficient number of arguments.\n", certId, revocationDate); - return SECFailure; - } diff --git a/security/nss/files/patch-warnings b/security/nss/files/patch-warnings deleted file mode 100644 index ed10a25868b0..000000000000 --- a/security/nss/files/patch-warnings +++ /dev/null @@ -1,449 +0,0 @@ ---- lib/freebl/unix_rand.c Wed Dec 8 18:00:19 2004 -+++ lib/freebl/unix_rand.c Mon Jul 25 00:26:00 2005 -@@ -783,7 +783,7 @@ - char *randfile; - #ifdef DARWIN -- char **environ = *_NSGetEnviron(); -+ const char * const *environ = *_NSGetEnviron(); - #else -- extern char **environ; -+ extern const char * const *environ; - #endif - #ifdef BEOS ---- lib/pk11wrap/pk11obj.c Thu Sep 8 22:03:57 2005 -+++ lib/pk11wrap/pk11obj.c Wed Jan 18 18:40:19 2006 -@@ -553,5 +553,4 @@ - CK_ATTRIBUTE theTemplate = { CKA_EC_PARAMS, NULL, 0 }; - SECItem params = {siBuffer, NULL, 0}; -- int length; - - switch (key->keyType) { -@@ -570,11 +569,12 @@ - &theTemplate, 1) == CKR_OK) { - if (theTemplate.pValue != NULL) { -+ int length; - params.len = theTemplate.ulValueLen; - params.data = (unsigned char *) theTemplate.pValue; - length = SECKEY_ECParamsToKeySize(¶ms); - PORT_Free(theTemplate.pValue); -+ return ((length + 7)/8) * 2; - } -- length = ((length + 7)/8) * 2; -- return length; -+ return 0; - } - break; -@@ -1075,6 +1075,6 @@ - * for (thisObj=firstObj; thisObj; - * thisObj=PK11_GetNextGenericObject(thisObj)) { -- * /* operate on thisObj */ --/* } -+ * operate on thisObj -+ * } - * - * If you want a particular object from the list... -@@ -1084,6 +1084,6 @@ - * if (isMyObj(thisObj)) { - * if ( thisObj == firstObj) { -- * /* NOTE: firstObj could be NULL at this point */ --/* firstObj = PK11_GetNextGenericObject(thsObj); -+ * // NOTE: firstObj could be NULL at this point -+ * firstObj = PK11_GetNextGenericObject(thsObj); - * } - * PK11_UnlinkGenericObject(thisObj); -@@ -1094,6 +1094,6 @@ - * PK11_DestroyGenericObjects(firstObj); - * -- * /* use myObj */ --/* PK11_DestroyGenericObject(myObj); -+ * use myObj -+ * PK11_DestroyGenericObject(myObj); - */ - PK11GenericObject * -@@ -1130,5 +1130,5 @@ - - /* link it in */ -- if (firstObj == NULL) { -+ if (i == 0) { - firstObj = obj; - } else { -@@ -1248,5 +1248,5 @@ - CK_ATTRIBUTE_TYPE attrType, SECItem *item) - { -- PK11SlotInfo *slot = NULL; -+ PK11SlotInfo *slot; - CK_OBJECT_HANDLE handle; - -@@ -1270,7 +1270,4 @@ - case PK11_TypeCert: /* don't handle cert case for now */ - default: -- break; -- } -- if (slot == NULL) { - PORT_SetError(SEC_ERROR_UNKNOWN_OBJECT_TYPE); - return SECFailure; ---- cmd/certcgi/certcgi.c Sat Apr 2 00:24:07 2005 -+++ cmd/certcgi/certcgi.c Wed Jul 27 22:01:50 2005 -@@ -112,5 +112,5 @@ - - static char * --make_copy_string(char *read_pos, -+make_copy_string(const char *read_pos, - int length, - char sentinal_value) -@@ -122,5 +122,5 @@ - char *new; - -- new = write_pos = (char *) PORT_Alloc (length); -+ new = write_pos = PORT_Alloc (length); - if (new == NULL) { - error_allocate(); -@@ -145,5 +145,4 @@ - } - -- - static SECStatus - clean_input(Pair *data) -@@ -217,5 +216,5 @@ - - static char * --make_name(char *new_data) -+make_name(const char *new_data) - /* gets the next field name in the input string and returns - a pointer to a string containing a copy of it */ -@@ -229,11 +228,10 @@ - - static char * --make_data(char *new_data) -+make_data(const char *new_data) - /* gets the data for the next field in the input string - and returns a pointer to a string containing it */ - { - int length = 100; -- char *data; -- char *read_pos; -+ const char *read_pos; - - read_pos = new_data; -@@ -241,11 +239,10 @@ - ++read_pos; - } -- data = make_copy_string(read_pos, length, '&'); -- return data; -+ return make_copy_string(read_pos, length, '&'); - } - - - static Pair --make_pair(char *new_data) -+make_pair(const char *new_data) - /* makes a pair name/data pair from the input string */ - { -@@ -298,77 +295,46 @@ - } - --static char * --return_name(Pair *data_struct, -+#ifdef FILEOUT /* The two functions below are only used for FILEOUT */ -+static const char * -+return_name(const Pair *data_struct, - int n) - /* returns a pointer to the name of the nth - (starting from 0) item in the data structure */ - { -- char *name; - -- if ((data_struct + n)->name != NULL) { -- name = (data_struct + n)->name; -- return name; -- } else { -- return NULL; -- } -+ return data_struct[n].name; - } - --static char * --return_data(Pair *data_struct,int n) -+static const char * -+return_data(const Pair *data_struct, int n) - /* returns a pointer to the data of the nth (starting from 0) - itme in the data structure */ - { -- char *data; - -- data = (data_struct + n)->data; -- return data; -+ return data_struct[n].data; - } -- -- --static char * --add_prefix(char *field_name) --{ -- extern char prefix[PREFIX_LEN]; -- int i = 0; -- char *rv; -- char *write; -- -- rv = write = PORT_Alloc(PORT_Strlen(prefix) + PORT_Strlen(field_name) + 1); -- for(i = 0; i < PORT_Strlen(prefix); i++) { -- *write = prefix[i]; -- write++; -- } -- *write = '\0'; -- rv = PORT_Strcat(rv,field_name); -- return rv; --} -- -+#endif - - static char * - find_field(Pair *data, -- char *field_name, -+ const char *field_name, - PRBool add_pre) - /* returns a pointer to the data of the first pair - thats name matches the string it is passed */ - { -- int i = 0; -- char *retrieved; -- int found = 0; -- -- if (add_pre) { -- field_name = add_prefix(field_name); -- } -- while(return_name(data, i) != NULL) { -- if (PORT_Strcmp(return_name(data, i), field_name) == 0) { -- retrieved = return_data(data, i); -- found = 1; -- break; -- } -- i++; -- } -- if (!found) { -- retrieved = NULL; -+ extern char prefix[PREFIX_LEN]; -+ size_t plen; -+ -+ plen = add_pre ? PORT_Strlen(prefix) : 0; -+ -+ for (; data->name != NULL; data++) { -+ /* See if the name begins with the prefix, if any */ -+ if (plen > 0 && PORT_Memcmp(data->name, prefix, plen) != 0) -+ continue; -+ if (PORT_Strcmp(data->name + plen, field_name) == 0) -+ return data->data; - } -- return retrieved; -+ -+ return NULL; - } - -@@ -389,79 +355,4 @@ - } - --static char * --update_data_by_name(Pair *data, -- char *field_name, -- char *new_data) -- /* replaces the data in the data structure associated with -- a name with new data, returns null if not found */ --{ -- int i = 0; -- int found = 0; -- int length = 100; -- char *new; -- -- while (return_name(data, i) != NULL) { -- if (PORT_Strcmp(return_name(data, i), field_name) == 0) { -- new = make_copy_string( new_data, length, '\0'); -- PORT_Free(return_data(data, i)); -- found = 1; -- (*(data + i)).data = new; -- break; -- } -- i++; -- } -- if (!found) { -- new = NULL; -- } -- return new; --} -- --static char * --update_data_by_index(Pair *data, -- int n, -- char *new_data) -- /* replaces the data of a particular index in the data structure */ --{ -- int length = 100; -- char *new; -- -- new = make_copy_string(new_data, length, '\0'); -- PORT_Free(return_data(data, n)); -- (*(data + n)).data = new; -- return new; --} -- -- --static Pair * --add_field(Pair *data, -- char* field_name, -- char* field_data) -- /* adds a new name/data pair to the data structure */ --{ -- int i = 0; -- int j; -- int name_length = 100; -- int data_length = 100; -- -- while(return_name(data, i) != NULL) { -- i++; -- } -- j = START_FIELDS; -- while ( j < (i + 1) ) { -- j = j * 2; -- } -- if (j == (i + 1)) { -- data = (Pair *) PORT_Realloc(data, (j * 2) * sizeof(Pair)); -- if (data == NULL) { -- error_allocate(); -- } -- } -- (*(data + i)).name = make_copy_string(field_name, name_length, '\0'); -- (*(data + i)).data = make_copy_string(field_data, data_length, '\0'); -- (data + i + 1)->name = NULL; -- return data; --} -- -- - static CERTCertificateRequest * - makeCertReq(Pair *form_data, -@@ -620,10 +511,10 @@ - serialFile = fopen(filename, "r"); - if (serialFile != NULL) { -- fread(&serial, sizeof(int), 1, serialFile); -+ fread(&serial, sizeof(serial), 1, serialFile); - if (ferror(serialFile) != 0) { - error_out("Error: Unable to read serial number file"); - } -- if (serial == 4294967295) { -- serial = 21; -+ if (serial == 4294967295U) { -+ serial = 21U; - } - fclose(serialFile); -@@ -633,5 +524,5 @@ - error_out("ERROR: Unable to open serial number file for writing"); - } -- fwrite(&serial, sizeof(int), 1, serialFile); -+ fwrite(&serial, sizeof(serial), 1, serialFile); - if (ferror(serialFile) != 0) { - error_out("Error: Unable to write to serial number file"); -@@ -643,6 +534,6 @@ - error_out("ERROR: Unable to open serial number file"); - } -- serial = 21; -- fwrite(&serial, sizeof(int), 1, serialFile); -+ serial = 21U; -+ fwrite(&serial, sizeof(serial), 1, serialFile); - if (ferror(serialFile) != 0) { - error_out("Error: Unable to write to serial number file"); -@@ -672,6 +563,4 @@ - return serial; - } -- -- - - typedef SECStatus (* EXTEN_VALUE_ENCODER) -@@ -1396,5 +1285,4 @@ - int j = 0; - SECItem *ipaddress; -- - - while (*string == ' ') { ---- cmd/crmftest/testcrmf.c Fri Oct 7 20:57:31 2005 -+++ cmd/crmftest/testcrmf.c Wed Jan 18 18:52:23 2006 -@@ -965,16 +965,4 @@ - } - --static CK_MECHANISM_TYPE --mapWrapKeyType(KeyType keyType) --{ -- switch (keyType) { -- case rsaKey: -- return CKM_RSA_PKCS; -- default: -- break; -- } -- return CKM_INVALID_MECHANISM; --} -- - #define KNOWN_MESSAGE_LENGTH 20 /*160 bits*/ - -@@ -1329,5 +1317,5 @@ - } - if (retrieved != randomNums[i]) { -- printf ("Retrieved the number (%d), expected (%d)\n", retrieved, -+ printf ("Retrieved the number (%ld), expected (%ld)\n", retrieved, - randomNums[i]); - return 913; -@@ -1435,5 +1423,4 @@ - DestroyPair(TESTKeyPair *pair) - { -- SECStatus rv = SECSuccess; - int irv = 0; - ---- cmd/fipstest/fipstest.c Fri Oct 14 16:04:39 2005 -+++ cmd/fipstest/fipstest.c Wed Jan 18 18:59:34 2006 -@@ -426,5 +426,5 @@ - } else { - to_hex_str(keystr, key, 8); -- printf("%ld\tKEY=%s\t", i, keystr); -+ printf("%d\tKEY=%s\t", i, keystr); - } - if (iv) { -@@ -497,5 +497,5 @@ - } else { - to_hex_str(keystr, key, 8); -- printf("%ld\tKEY=%s\t", i, keystr); -+ printf("%d\tKEY=%s\t", i, keystr); - } - if (iv) { -@@ -569,5 +569,5 @@ - } else { - to_hex_str(keystr, keyin, 8); -- printf("%ld\tKEY=%s\t", i, keystr); -+ printf("%d\tKEY=%s\t", i, keystr); - } - if (iv) { -@@ -643,5 +643,5 @@ - } else { - to_hex_str(keystr, keyin, 8); -- printf("%ld\tKEY=%s\t", i, keystr); -+ printf("%d\tKEY=%s\t", i, keystr); - } - if (iv) { -@@ -705,5 +705,5 @@ - } else { - to_hex_str(keystr, keyin, 8); -- printf("%ld\tKEY=%s\t", i, keystr); -+ printf("%d\tKEY=%s\t", i, keystr); - } - if (iv) { -@@ -806,5 +806,5 @@ - } else { - to_hex_str(keystr, keyin, 8); -- printf("%ld\tKEY=%s\t", i, keystr); -+ printf("%d\tKEY=%s\t", i, keystr); - } - if (iv) { -@@ -1981,6 +1981,6 @@ - unsigned int mod; - SECItem digest = { 0 }, sig = { 0 }; -- DSAPublicKey pubkey = { 0 }; -- DSAPrivateKey privkey = { 0 }; -+ DSAPublicKey pubkey = {{ 0 }}; -+ DSAPrivateKey privkey = {{ 0 }}; - PQGParams params; - PQGVerify verify; |