http/https proxy (#7600)

* add http(s) proxy

* Add front-end translation

* fix ui description

* For linux platform, add rustls support

* fix: Fix the proxy address test function.

* add: Added default prompts for agency agreement and some multi-language translations

* add: Http proxy request client

* fix: add async http proxy func and format the code

* add: Preliminary support for flutter front-end calling rust back-end http request

* Optimize HTTP calls

* Optimize HTTP calls

* fix: Optimize HTTP requests, refine translations, and fix dependencies
This commit is contained in:
yuluo
2024-04-23 15:00:23 +08:00
committed by GitHub
parent f11c332cb4
commit da57fcb641
68 changed files with 1231 additions and 133 deletions
+2 -1
View File
@@ -1,3 +1,4 @@
use crate::hbbs_http::create_http_client;
use bytes::Bytes;
use hbb_common::{bail, config::Config, lazy_static, log, ResultType};
use reqwest::blocking::{Body, Client};
@@ -25,7 +26,7 @@ pub fn is_enable() -> bool {
pub fn run(rx: Receiver<RecordState>) {
let mut uploader = RecordUploader {
client: Client::new(),
client: create_http_client(),
api_server: crate::get_api_server(
Config::get_option("api-server"),
Config::get_option("custom-rendezvous-server"),