mirror of
https://github.com/house-of-vanity/v2-uri-parser.git
synced 2025-12-16 06:57:52 +00:00
20 lines
637 B
Rust
20 lines
637 B
Rust
pub mod data;
|
|
mod models;
|
|
use crate::{config_models::*, utils::parse_raw_json};
|
|
|
|
pub fn create_outbound_settings(data: &RawData) -> OutboundSettings {
|
|
return OutboundSettings::Vless(VlessOutboundSettings {
|
|
vnext: vec![VlessServerObject {
|
|
port: data.port,
|
|
address: data.address.clone(),
|
|
users: Some(vec![VnextUser {
|
|
id: data.uuid.clone(),
|
|
flow: data.flow.clone(),
|
|
encryption: Some(data.encryption.clone().unwrap_or(String::from("none"))),
|
|
level: Some(0),
|
|
security: None,
|
|
}]),
|
|
}],
|
|
});
|
|
}
|