2010-10-26 15:57:18 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-31 13:33:35 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2010-10-26 15:57:18 +04:00
|
|
|
|
2014-09-17 00:24:13 +04:00
|
|
|
#ifndef nsNSSCertificateFakeTransport_h
|
|
|
|
#define nsNSSCertificateFakeTransport_h
|
2010-10-26 15:57:18 +04:00
|
|
|
|
2016-08-13 16:45:00 +03:00
|
|
|
#include "ScopedNSSTypes.h"
|
2014-09-17 02:49:37 +04:00
|
|
|
#include "mozilla/Vector.h"
|
|
|
|
#include "nsCOMPtr.h"
|
2010-10-26 15:57:18 +04:00
|
|
|
#include "nsIClassInfo.h"
|
2014-09-17 00:24:13 +04:00
|
|
|
#include "nsISerializable.h"
|
|
|
|
#include "nsIX509Cert.h"
|
2014-09-17 02:49:37 +04:00
|
|
|
#include "nsIX509CertList.h"
|
2012-11-02 23:34:46 +04:00
|
|
|
#include "secitem.h"
|
2010-10-26 15:57:18 +04:00
|
|
|
|
2011-10-30 22:43:06 +04:00
|
|
|
class nsNSSCertificateFakeTransport : public nsIX509Cert,
|
2014-09-17 00:24:13 +04:00
|
|
|
public nsISerializable,
|
|
|
|
public nsIClassInfo
|
2010-10-26 15:57:18 +04:00
|
|
|
{
|
|
|
|
public:
|
2013-07-19 06:24:14 +04:00
|
|
|
NS_DECL_THREADSAFE_ISUPPORTS
|
2010-10-26 15:57:18 +04:00
|
|
|
NS_DECL_NSIX509CERT
|
|
|
|
NS_DECL_NSISERIALIZABLE
|
|
|
|
NS_DECL_NSICLASSINFO
|
|
|
|
|
|
|
|
nsNSSCertificateFakeTransport();
|
2014-06-24 02:40:03 +04:00
|
|
|
|
|
|
|
protected:
|
2010-10-26 15:57:18 +04:00
|
|
|
virtual ~nsNSSCertificateFakeTransport();
|
|
|
|
|
|
|
|
private:
|
2016-08-13 16:45:00 +03:00
|
|
|
mozilla::UniqueSECItem mCertSerialization;
|
2010-10-26 15:57:18 +04:00
|
|
|
};
|
|
|
|
|
2014-09-17 02:49:37 +04:00
|
|
|
class nsNSSCertListFakeTransport : public nsIX509CertList,
|
|
|
|
public nsISerializable
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
NS_DECL_THREADSAFE_ISUPPORTS
|
|
|
|
NS_DECL_NSIX509CERTLIST
|
|
|
|
NS_DECL_NSISERIALIZABLE
|
|
|
|
|
|
|
|
nsNSSCertListFakeTransport();
|
|
|
|
|
|
|
|
protected:
|
|
|
|
virtual ~nsNSSCertListFakeTransport();
|
|
|
|
|
|
|
|
private:
|
|
|
|
mozilla::Vector<nsCOMPtr<nsIX509Cert> > mFakeCertList;
|
|
|
|
};
|
|
|
|
|
2014-09-17 00:24:13 +04:00
|
|
|
#endif // nsNSSCertificateFakeTransport_h
|