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

Side by Side Diff: src/tspi/obj_rsakey.c

Issue 3581012: Upgrade from trousers 0.3.3 to 0.3.6 and from testsuite 0.2 to 0.3. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/trousers.git
Patch Set: git cl push Created 10 years, 2 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 | « src/tspi/obj_context.c ('k') | src/tspi/ps/tspps.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Licensed Materials - Property of IBM 3 * Licensed Materials - Property of IBM
4 * 4 *
5 * trousers - An open source TCG Software Stack 5 * trousers - An open source TCG Software Stack
6 * 6 *
7 * (C) Copyright International Business Machines Corp. 2005, 2007 7 * (C) Copyright International Business Machines Corp. 2005, 2007
8 * 8 *
9 */ 9 */
10 10
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 rsakey->key.hdr.key12.fill = 0; 75 rsakey->key.hdr.key12.fill = 0;
76 rsakey->type = TSS_KEY_STRUCT_KEY12; 76 rsakey->type = TSS_KEY_STRUCT_KEY12;
77 rsakey->pcrInfoType = TSS_PCRS_STRUCT_INFO_LONG; 77 rsakey->pcrInfoType = TSS_PCRS_STRUCT_INFO_LONG;
78 break; 78 break;
79 default: 79 default:
80 free(rsakey); 80 free(rsakey);
81 return TSPERR(TSS_E_INVALID_OBJECT_INITFLAG); 81 return TSPERR(TSS_E_INVALID_OBJECT_INITFLAG);
82 break; 82 break;
83 } 83 }
84 84
85 » if (initFlags & TSS_KEY_EMPTY_KEY) 85 » if (initFlags == TSS_KEY_EMPTY_KEY)
86 goto add_key; 86 goto add_key;
87 87
88 memset(&rsaKeyParms, 0, sizeof(TCPA_RSA_KEY_PARMS)); 88 memset(&rsaKeyParms, 0, sizeof(TCPA_RSA_KEY_PARMS));
89 89
90 rsakey->key.algorithmParms.algorithmID = TCPA_ALG_RSA; 90 rsakey->key.algorithmParms.algorithmID = TCPA_ALG_RSA;
91 rsakey->key.algorithmParms.parmSize = sizeof(TCPA_RSA_KEY_PARMS); 91 rsakey->key.algorithmParms.parmSize = sizeof(TCPA_RSA_KEY_PARMS);
92 92
93 rsakey->key.algorithmParms.parms = calloc(1, sizeof(TCPA_RSA_KEY_PARMS)) ; 93 rsakey->key.algorithmParms.parms = calloc(1, sizeof(TCPA_RSA_KEY_PARMS)) ;
94 if (rsakey->key.algorithmParms.parms == NULL) { 94 if (rsakey->key.algorithmParms.parms == NULL) {
95 LogError("calloc of %u bytes failed.", rsakey->key.algorithmParm s.parmSize); 95 LogError("calloc of %u bytes failed.", rsakey->key.algorithmParm s.parmSize);
(...skipping 2030 matching lines...) Expand 10 before | Expand all | Expand 10 after
2126 2126
2127 if (value) 2127 if (value)
2128 rsakey->flags |= TSS_RSAKEY_FLAG_OWNEREVICT; 2128 rsakey->flags |= TSS_RSAKEY_FLAG_OWNEREVICT;
2129 else 2129 else
2130 rsakey->flags &= ~TSS_RSAKEY_FLAG_OWNEREVICT; 2130 rsakey->flags &= ~TSS_RSAKEY_FLAG_OWNEREVICT;
2131 2131
2132 obj_list_put(&rsakey_list); 2132 obj_list_put(&rsakey_list);
2133 2133
2134 return TSS_SUCCESS; 2134 return TSS_SUCCESS;
2135 } 2135 }
OLDNEW
« no previous file with comments | « src/tspi/obj_context.c ('k') | src/tspi/ps/tspps.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698