if (!s->hd) {
err = ffurl_open_whitelist(&s->hd, buf, AVIO_FLAG_READ_WRITE,
&h->interrupt_callback, options,
- h->protocol_whitelist);
+ h->protocol_whitelist, h->protocol_blacklist);
if (err < 0)
return err;
}
message_len = snprintf(message, sizeof(message),
"HTTP/1.1 %03d %s\r\n"
"Content-Type: %s\r\n"
- "Content-Length: %zu\r\n"
+ "Content-Length: %"SIZE_SPECIFIER"\r\n"
"\r\n"
"%03d %s\r\n",
reply_code,
goto fail;
if ((ret = ffurl_open_whitelist(&s->hd, lower_url, AVIO_FLAG_READ_WRITE,
&h->interrupt_callback, options,
- h->protocol_whitelist
+ h->protocol_whitelist, h->protocol_blacklist
)) < 0)
goto fail;
s->handshake_step = LOWER_PROTO;
#if CONFIG_HTTP_PROTOCOL
HTTP_CLASS(http);
-URLProtocol ff_http_protocol = {
+const URLProtocol ff_http_protocol = {
.name = "http",
.url_open2 = http_open,
.url_accept = http_accept,
.priv_data_size = sizeof(HTTPContext),
.priv_data_class = &http_context_class,
.flags = URL_PROTOCOL_FLAG_NETWORK,
- .default_whitelist = "http,https,tls,rtp,tcp,udp,crypto"
+ .default_whitelist = "http,https,tls,rtp,tcp,udp,crypto,httpproxy"
};
#endif /* CONFIG_HTTP_PROTOCOL */
#if CONFIG_HTTPS_PROTOCOL
HTTP_CLASS(https);
-URLProtocol ff_https_protocol = {
+const URLProtocol ff_https_protocol = {
.name = "https",
.url_open2 = http_open,
.url_read = http_read,
.priv_data_size = sizeof(HTTPContext),
.priv_data_class = &https_context_class,
.flags = URL_PROTOCOL_FLAG_NETWORK,
- .default_whitelist = "http,https,tls,rtp,tcp,udp,crypto"
+ .default_whitelist = "http,https,tls,rtp,tcp,udp,crypto,httpproxy"
};
#endif /* CONFIG_HTTPS_PROTOCOL */
redo:
ret = ffurl_open_whitelist(&s->hd, lower_url, AVIO_FLAG_READ_WRITE,
&h->interrupt_callback, NULL,
- h->protocol_whitelist);
+ h->protocol_whitelist, h->protocol_blacklist);
if (ret < 0)
return ret;
return ffurl_write(s->hd, buf, size);
}
-URLProtocol ff_httpproxy_protocol = {
+const URLProtocol ff_httpproxy_protocol = {
.name = "httpproxy",
.url_open = http_proxy_open,
.url_read = http_buf_read,