summaryrefslogtreecommitdiff
path: root/chromium/net/tools/flip_server/spdy_ssl.h
blob: 8db0d8ccc9591e3c0011602c7560b46c69d6f49d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef NET_TOOLS_FLIP_SERVER_SPDY_SSL_H_
#define NET_TOOLS_FLIP_SERVER_SPDY_SSL_H_

#include <string>

#include "openssl/ssl.h"

namespace net {

struct SSLState {
  const SSL_METHOD* ssl_method;
  SSL_CTX* ssl_ctx;
};

void InitSSL(SSLState* state,
             std::string ssl_cert_name,
             std::string ssl_key_name,
             bool use_npn,
             int session_expiration_time,
             bool disable_ssl_compression);
SSL* CreateSSLContext(SSL_CTX* ssl_ctx);
void PrintSslError();

}  // namespace net

#endif  // NET_TOOLS_FLIP_SERVER_SPDY_SSL_H_