ReactOS 0.4.16-dev-297-gc569aee
altcp_proxyconnect.h
Go to the documentation of this file.
1
9/*
10 * Copyright (c) 2018 Simon Goldschmidt
11 * All rights reserved.
12 *
13 * Redistribution and use in source and binary forms, with or without modification,
14 * are permitted provided that the following conditions are met:
15 *
16 * 1. Redistributions of source code must retain the above copyright notice,
17 * this list of conditions and the following disclaimer.
18 * 2. Redistributions in binary form must reproduce the above copyright notice,
19 * this list of conditions and the following disclaimer in the documentation
20 * and/or other materials provided with the distribution.
21 * 3. The name of the author may not be used to endorse or promote products
22 * derived from this software without specific prior written permission.
23 *
24 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
25 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
26 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
27 * SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
28 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
29 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
30 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
31 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
32 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
33 * OF SUCH DAMAGE.
34 *
35 * This file is part of the lwIP TCP/IP stack.
36 *
37 * Author: Simon Goldschmidt <goldsimon@gmx.de>
38 *
39 */
40
41#ifndef LWIP_HDR_APPS_ALTCP_PROXYCONNECT_H
42#define LWIP_HDR_APPS_ALTCP_PROXYCONNECT_H
43
44#include "lwip/opt.h"
45
46#if LWIP_ALTCP /* don't build if not configured for use in lwipopts.h */
47
48#include "lwip/ip_addr.h"
49
50#ifdef __cplusplus
51extern "C" {
52#endif
53
54struct altcp_proxyconnect_config {
55 ip_addr_t proxy_addr;
56 u16_t proxy_port;
57};
58
59
60struct altcp_pcb *altcp_proxyconnect_new(struct altcp_proxyconnect_config *config, struct altcp_pcb *inner_pcb);
61struct altcp_pcb *altcp_proxyconnect_new_tcp(struct altcp_proxyconnect_config *config, u8_t ip_type);
62
63struct altcp_pcb *altcp_proxyconnect_alloc(void *arg, u8_t ip_type);
64
65#if LWIP_ALTCP_TLS
66struct altcp_proxyconnect_tls_config {
67 struct altcp_proxyconnect_config proxy;
68 struct altcp_tls_config *tls_config;
69};
70
71struct altcp_pcb *altcp_proxyconnect_tls_alloc(void *arg, u8_t ip_type);
72#endif /* LWIP_ALTCP_TLS */
73
74#ifdef __cplusplus
75}
76#endif
77
78#endif /* LWIP_ALTCP */
79#endif /* LWIP_HDR_APPS_ALTCP_PROXYCONNECT_H */
#define altcp_pcb
Definition: altcp.h:159
int proxy
Definition: main.c:67
uint8_t u8_t
Definition: arch.h:125
uint16_t u16_t
Definition: arch.h:127
ip6_addr_t ip_addr_t
Definition: ip_addr.h:344