Check-in [5acacab000]
Overview
SHA1:5acacab0009aaaea5cb319348f8298c8eaa29618
Date: 2016-02-19 17:50:50
User: rkeene
Comment:ChromeOS: Fix a potential free(NULL) in initialization of PCSC-NaCl
Timelines: family | ancestors | descendants | both | trunk
Downloads: Tarball | ZIP archive
Other Links: files | file ages | folders | manifest
Tags And Properties
Context
2016-02-26
16:23
[42d0db67a2] ChromeOS: Updated to delete the entire retry queue when we are done with it (user: rkeene, tags: trunk)
2016-02-19
17:50
[5acacab000] ChromeOS: Fix a potential free(NULL) in initialization of PCSC-NaCl (user: rkeene, tags: trunk)
17:50
[c4916c27cd] ChromeOS: Slightly better PCSC-NaCl initialization and enabled debugging in all projects (user: rkeene, tags: trunk)
Changes

Modified build/chrome/cackey-chrome-init.cc from [e1139896d5] to [84155dbf3d].

58
59
60
61
62
63
64

65

66
67
68
69
70
71
72
			if (command.AsString() == "init") {
				if (message->HasKey("smartcardManagerAppId")) {
					smartcardManagerAppId = strdup(message->Get("smartcardManagerAppId").AsString().c_str());
				}

				pcscNaClInit(this, corePointer, smartcardManagerAppId, "CACKey");


				free((void *) smartcardManagerAppId);


				reply->Set("status", "success");
			} else if (command.AsString() == "listcertificates") {
				numCertificates = cackey_chrome_listCertificates(&certificates);

				certificatesPPArray.SetLength(numCertificates);








>
|
>







58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
			if (command.AsString() == "init") {
				if (message->HasKey("smartcardManagerAppId")) {
					smartcardManagerAppId = strdup(message->Get("smartcardManagerAppId").AsString().c_str());
				}

				pcscNaClInit(this, corePointer, smartcardManagerAppId, "CACKey");

				if (smartcardManagerAppId) {
					free((void *) smartcardManagerAppId);
				}

				reply->Set("status", "success");
			} else if (command.AsString() == "listcertificates") {
				numCertificates = cackey_chrome_listCertificates(&certificates);

				certificatesPPArray.SetLength(numCertificates);