X-Git-Url: http://www.lcore.org/git/lcore.git/blobdiff_plain/693e2ce95d2225be709499570ea94c324d663562..9653ddc572f5fd8ec065e4c357101ae6edae7959:/lcorelocalips.pas diff --git a/lcorelocalips.pas b/lcorelocalips.pas index ae2a00b..dcc633a 100644 --- a/lcorelocalips.pas +++ b/lcorelocalips.pas @@ -188,7 +188,7 @@ end; {$else} uses - sysutils,windows,winsock,dnssync; + sysutils,windows,winsock,dnssync,dnscore; {the following code's purpose is to determine what IP windows would come from, to reach an IP it can be abused to find if there's any global v6 IPs on a local interface} @@ -255,8 +255,14 @@ function getlocalips:tbiniplist; var a:integer; ip:tbinip; + usewindnstemp:boolean; begin + {this lookup must always be done with the windows API lookup + setting usewindns to false on windows will fail with infinite recursion} + usewindnstemp := usewindns; + usewindns := true; result := forwardlookuplist('',0); + usewindns := usewindnstemp; {$ifdef ipv6}