All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
as_tls.h
Go to the documentation of this file.
1 /*
2  * Copyright 2008-2017 Aerospike, Inc.
3  *
4  * Portions may be licensed to Aerospike, Inc. under one or more contributor
5  * license agreements.
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License"); you may not
8  * use this file except in compliance with the License. You may obtain a copy of
9  * the License at http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14  * License for the specific language governing permissions and limitations under
15  * the License.
16  */
17 #pragma once
18 
19 #include <openssl/ssl.h>
20 
21 #include <aerospike/as_config.h>
22 #include <aerospike/as_status.h>
23 #include <aerospike/as_socket.h>
24 
25 
26 void as_tls_check_init();
27 
28 void as_tls_cleanup();
29 
31 
33  as_tls_context* octx,
34  as_error* err);
35 
37 
39 
40 int as_tls_wrap(as_tls_context* ctx, as_socket* sock, const char* tls_name);
41 
42 void as_tls_set_name(as_socket* sock, const char* tls_name);
43 
45 
46 int as_tls_connect(as_socket* sock, uint64_t deadline);
47 
48 // int as_tls_peek(as_socket* sock, void* buf, int num);
49 
51 
52 int as_tls_read_once(as_socket* sock, void* buf, size_t num);
53 
54 int as_tls_read(as_socket* sock, void* buf, size_t num, uint32_t socket_timeout, uint64_t deadline);
55 
56 int as_tls_write_once(as_socket* sock, void* buf, size_t num);
57 
58 int as_tls_write(as_socket* sock, void* buf, size_t num, uint32_t socket_timeout, uint64_t deadline);
int as_tls_write_once(as_socket *sock, void *buf, size_t num)
void as_tls_check_init()
as_status
Definition: as_status.h:30
void as_tls_thread_cleanup()
void as_tls_set_name(as_socket *sock, const char *tls_name)
void as_tls_context_destroy(as_tls_context *ctx)
int as_tls_read_pending(as_socket *sock)
void as_tls_cleanup()
as_status as_tls_config_reload(as_config_tls *tlscfg, as_tls_context *ctx, as_error *err)
int as_tls_connect(as_socket *sock, uint64_t deadline)
int as_tls_connect_once(as_socket *sock)
as_status as_tls_context_setup(as_config_tls *tlscfg, as_tls_context *octx, as_error *err)
int as_tls_write(as_socket *sock, void *buf, size_t num, uint32_t socket_timeout, uint64_t deadline)
int as_tls_wrap(as_tls_context *ctx, as_socket *sock, const char *tls_name)
int as_tls_read(as_socket *sock, void *buf, size_t num, uint32_t socket_timeout, uint64_t deadline)
int as_tls_read_once(as_socket *sock, void *buf, size_t num)