ServerCertificate.cc
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2017 The Squid Software Foundation and contributors
3  *
4  * Squid software is distributed under GPLv2+ license and includes
5  * contributions from numerous individuals and organizations.
6  * Please see the COPYING and CONTRIBUTORS files for details.
7  */
8 
9 #include "squid.h"
10 
11 #if USE_OPENSSL
12 
13 #include "acl/CertificateData.h"
14 #include "acl/Checklist.h"
15 #include "acl/ServerCertificate.h"
16 #include "client_side.h"
17 #include "fde.h"
18 #include "http/Stream.h"
19 #include "ssl/ServerBump.h"
20 
21 int
23 {
24  Security::CertPointer cert;
25  if (checklist->serverCert)
26  cert = checklist->serverCert;
27  else if (checklist->conn() != NULL && checklist->conn()->serverBump())
28  cert = checklist->conn()->serverBump()->serverCert;
29 
30  if (!cert)
31  return 0;
32 
33  return data->match(cert.get());
34 }
35 
36 #endif /* USE_OPENSSL */
37 
Ssl::ServerBump * serverBump()
Definition: client_side.h:253
virtual bool match(M)=0
ConnStateData * conn() const
The client connection manager.
Security::CertPointer serverCert
Definition: ServerBump.h:47
void const char HLPCB void * data
Definition: stub_helper.cc:16
Security::CertPointer serverCert
The peer certificate.
virtual int match(ACLData< MatchType > *&, ACLFilledChecklist *) override
#define NULL
Definition: types.h:166

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors