Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(254)

Side by Side Diff: net/socket/ssl_server_socket_nss.cc

Issue 11434009: Ensure that NSS HTTP IO is initialized on iOS. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Sync with ToT Created 8 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/socket/ssl_server_socket_nss.h" 5 #include "net/socket/ssl_server_socket_nss.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <winsock2.h> 8 #include <winsock2.h>
9 #endif 9 #endif
10 10
(...skipping 18 matching lines...) Expand all
29 29
30 #include <limits> 30 #include <limits>
31 31
32 #include "base/lazy_instance.h" 32 #include "base/lazy_instance.h"
33 #include "base/memory/ref_counted.h" 33 #include "base/memory/ref_counted.h"
34 #include "crypto/rsa_private_key.h" 34 #include "crypto/rsa_private_key.h"
35 #include "crypto/nss_util_internal.h" 35 #include "crypto/nss_util_internal.h"
36 #include "net/base/io_buffer.h" 36 #include "net/base/io_buffer.h"
37 #include "net/base/net_errors.h" 37 #include "net/base/net_errors.h"
38 #include "net/base/net_log.h" 38 #include "net/base/net_log.h"
39 #include "net/ocsp/nss_ocsp.h"
40 #include "net/socket/nss_ssl_util.h" 39 #include "net/socket/nss_ssl_util.h"
41 #include "net/socket/ssl_error_params.h" 40 #include "net/socket/ssl_error_params.h"
42 41
43 // SSL plaintext fragments are shorter than 16KB. Although the record layer 42 // SSL plaintext fragments are shorter than 16KB. Although the record layer
44 // overhead is allowed to be 2K + 5 bytes, in practice the overhead is much 43 // overhead is allowed to be 2K + 5 bytes, in practice the overhead is much
45 // smaller than 1KB. So a 17KB buffer should be large enough to hold an 44 // smaller than 1KB. So a 17KB buffer should be large enough to hold an
46 // entire SSL record. 45 // entire SSL record.
47 static const int kRecvBufferSize = 17 * 1024; 46 static const int kRecvBufferSize = 17 * 1024;
48 static const int kSendBufferSize = 17 * 1024; 47 static const int kSendBufferSize = 17 * 1024;
49 48
(...skipping 775 matching lines...) Expand 10 before | Expand all | Expand 10 after
825 // initializes the NSS base library. 824 // initializes the NSS base library.
826 EnsureNSSSSLInit(); 825 EnsureNSSSSLInit();
827 if (!NSS_IsInitialized()) 826 if (!NSS_IsInitialized())
828 return ERR_UNEXPECTED; 827 return ERR_UNEXPECTED;
829 828
830 EnableSSLServerSockets(); 829 EnableSSLServerSockets();
831 return OK; 830 return OK;
832 } 831 }
833 832
834 } // namespace net 833 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698