[#OSSL_HTTP_proxy_connect]
= OSSL&lowbar;HTTP&lowbar;proxy&lowbar;connect
:mrdocs:

Perform an HTTP CONNECT through a proxy on an already&hyphen;connected BIO&period;

== Synopsis

Declared in `&lt;openssl&sol;http&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
int
OSSL&lowbar;HTTP&lowbar;proxy&lowbar;connect(
    xref:BIO.adoc[BIO]* bio,
    char const* server,
    char const* port,
    char const* proxyuser,
    char const* proxypass,
    int timeout,
    xref:BIO.adoc[BIO]* bio&lowbar;err,
    char const* prog);
----

== Return Value

1 on success, or 0 on failure&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *bio*
| BIO connected to the HTTP proxy&semi; on success becomes a tunnel to `serverport&period;`
| *server*
| Target hostname to CONNECT to&period;
| *port*
| Target port (decimal string) or service name&period;
| *proxyuser*
| Optional proxy username for Basic auth, or NULL&period;
| *proxypass*
| Optional proxy password for Basic auth, or NULL&period;
| *timeout*
| Overall timeout in seconds (0 for none &sol; BIO default)&period;
| *bio&lowbar;err*
| Optional BIO for diagnostic output, or NULL&period;
| *prog*
| Optional program name prefix for diagnostics, or NULL&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
