-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
read DNS ip address from openvpn output ( fix #3 ) #5
base: master
Are you sure you want to change the base?
read DNS ip address from openvpn output ( fix #3 ) #5
Conversation
@@ -165,6 +165,11 @@ pub async fn connect_ovpn( | |||
if let Ok(ref line) = next { | |||
if let Some(line) = line { | |||
log.append_process(pid, line.as_str()); | |||
tokio::spawn(async move { | |||
// Process each socket concurrently. | |||
parse_dns(line.to_string()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
compiler-message: error[E0425]: cannot find function parse_dns
in this scope
--> src/cmd.rs:170:21
|
170 | parse_dns(line.to_string())
| ^^^^^^^^^ not found in this scope
|
help: consider importing this function
|
1 | use crate::dns::parse_dns;
|
ℹ️ Expand to see all @sonatype-lift commands
You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.
Command | Usage |
---|---|
@sonatype-lift ignore |
Leave out the above finding from this PR |
@sonatype-lift ignoreall |
Leave out all the existing findings from this PR |
@sonatype-lift exclude <file|issue|path|tool> |
Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file |
Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.
Help us improve LIFT! (Sonatype LiftBot external survey)
Was this a good recommendation for you? Answering this survey will not impact your Lift settings.
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]
tokio::spawn(async move { | ||
// Process each socket concurrently. | ||
parse_dns(line.to_string()) | ||
.and_then(|dns_address| _WIP_("Do something with this IP address")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
compiler-message: error[E0425]: cannot find function _WIP_
in this scope
--> src/cmd.rs:171:49
|
171 | .and_then(|dns_address| WIP("Do something with this IP address"))
| ^^^^^ not found in this scope
ℹ️ Expand to see all @sonatype-lift commands
You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.
Command | Usage |
---|---|
@sonatype-lift ignore |
Leave out the above finding from this PR |
@sonatype-lift ignoreall |
Leave out all the existing findings from this PR |
@sonatype-lift exclude <file|issue|path|tool> |
Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file |
Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.
Help us improve LIFT! (Sonatype LiftBot external survey)
Was this a good recommendation for you? Answering this survey will not impact your Lift settings.
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is intentional: I don't know what "interface index" to give to systemd-resolved
Thanks for the contribution, I'll try to look into this and see if I can help. I came across this documentation and by looking at the samples scripts I have on my machine it seems that we can use the “main interface” id¹ and append the DNS server there, in such a way that it doesn't override the current ones, but serves as a fallback, and this may be enough to resolve intranet addresses (we could also prepend, but honestly idk which one is better). ¹: About this one, we can look at |
fixes #3
for now, this will read the "here's a DNS ip address you should set to", but I don't know exactly what to do with it. systemd-resolved requires an interface index... which I dunno where to get it from.