Skip to content

Commit

Permalink
Apply patch provided by @rain2fog in #801
Browse files Browse the repository at this point in the history
pppd → tun interface + embedded PPP code
  • Loading branch information
DimitriPapadopoulos committed Feb 25, 2023
1 parent d875af7 commit ecb8bf2
Show file tree
Hide file tree
Showing 5 changed files with 1,071 additions and 18 deletions.
5 changes: 5 additions & 0 deletions src/http.c
Original file line number Diff line number Diff line change
Expand Up @@ -834,6 +834,11 @@ static int parse_xml_config(struct tunnel *tunnel, const char *buffer)
if (!gateway)
log_warn("No gateway address, using interface for routing\n");

if (tunnel->use_tun) {
tunnel->ipv4.ip_addr.s_addr = inet_addr(gateway);
tunnel->ipv4.peer_addr.s_addr = inet_addr("192.0.2.1");
}

// The dns search string
val = buffer;
while ((val = xml_find('<', "dns", val, 2))) {
Expand Down
Loading

0 comments on commit ecb8bf2

Please sign in to comment.