增加参数关闭ip代理

This commit is contained in:
lubeilin
2023-10-09 20:56:04 +08:00
parent 9ad0525216
commit fc104d5dee
10 changed files with 74 additions and 66 deletions
+4
View File
@@ -25,6 +25,7 @@ pub struct FileConfig {
pub tcp: bool,
pub ip: Option<String>,
pub relay: bool,
pub no_proxy: bool,
pub server_encrypt: bool,
pub parallel: usize,
pub cipher_model: String,
@@ -55,6 +56,7 @@ impl Default for FileConfig {
tcp: false,
ip: None,
relay: false,
no_proxy: false,
server_encrypt: false,
parallel: 1,
cipher_model: "aes_gcm".to_string(),
@@ -145,6 +147,8 @@ pub fn read_config(file_path: &str) -> io::Result<(Config, bool)> {
file_conf.tcp,
virtual_ip,
file_conf.relay,
#[cfg(feature = "ip_proxy")]
file_conf.no_proxy,
file_conf.server_encrypt,
file_conf.parallel,
cipher_model,