зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1061021, Part 5: Remove InitInputFromSECItem, r=keeler
--HG-- extra : rebase_source : 353ad008af15700266226b6f3f535385cb182d09
This commit is contained in:
Родитель
61df71edb6
Коммит
3c92292236
|
@ -111,11 +111,12 @@ public:
|
|||
if (GenerateKeyPair(rootPublicKey, rootPrivateKey) != Success) {
|
||||
return false;
|
||||
}
|
||||
rootSPKI = SECKEY_EncodeDERSubjectPublicKeyInfo(rootPublicKey.get());
|
||||
if (!rootSPKI) {
|
||||
ScopedSECItem rootSPKIItem(
|
||||
SECKEY_EncodeDERSubjectPublicKeyInfo(rootPublicKey.get()));
|
||||
if (!rootSPKIItem) {
|
||||
return false;
|
||||
}
|
||||
|
||||
rootSPKI.assign(rootSPKIItem->data, rootSPKIItem->len);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -152,7 +153,7 @@ public:
|
|||
}
|
||||
|
||||
Input rootSPKIDER;
|
||||
if (InitInputFromSECItem(rootSPKI.get(), rootSPKIDER) != Success) {
|
||||
if (rootSPKIDER.Init(rootSPKI.data(), rootSPKI.length()) != Success) {
|
||||
abort();
|
||||
}
|
||||
endEntityCertID = new (std::nothrow) CertID(rootNameDERInput, rootSPKIDER,
|
||||
|
@ -163,7 +164,7 @@ public:
|
|||
}
|
||||
|
||||
static ScopedSECKEYPrivateKey rootPrivateKey;
|
||||
static ScopedSECItem rootSPKI;
|
||||
static ByteString rootSPKI;
|
||||
static long rootIssuedCount;
|
||||
OCSPTestTrustDomain trustDomain;
|
||||
|
||||
|
@ -175,7 +176,7 @@ public:
|
|||
|
||||
/*static*/ ScopedSECKEYPrivateKey
|
||||
pkixocsp_VerifyEncodedResponse::rootPrivateKey;
|
||||
/*static*/ ScopedSECItem pkixocsp_VerifyEncodedResponse::rootSPKI;
|
||||
/*static*/ ByteString pkixocsp_VerifyEncodedResponse::rootSPKI;
|
||||
/*static*/ long pkixocsp_VerifyEncodedResponse::rootIssuedCount = 0;
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
|
|
@ -149,15 +149,6 @@ TLV(uint8_t tag, const ByteString& value)
|
|||
return result;
|
||||
}
|
||||
|
||||
Result
|
||||
InitInputFromSECItem(const SECItem* secItem, /*out*/ Input& input)
|
||||
{
|
||||
if (!secItem) {
|
||||
return Result::FATAL_ERROR_INVALID_ARGS;
|
||||
}
|
||||
return input.Init(secItem->data, secItem->len);
|
||||
}
|
||||
|
||||
class Output
|
||||
{
|
||||
public:
|
||||
|
|
|
@ -113,8 +113,6 @@ ByteString CNToDERName(const char* cn);
|
|||
Result TamperOnce(/*in/out*/ ByteString& item, const ByteString& from,
|
||||
const ByteString& to);
|
||||
|
||||
Result InitInputFromSECItem(const SECItem* secItem, /*out*/ Input& input);
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// Encode Certificates
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче