X-Git-Url: https://git.rvb.name/lua-squid-acl-helper.git/blobdiff_plain/2e41ad1dc4bac0a74a64a14fabec46bd0aeb7fae..refs/heads/master:/src/connection.lua diff --git a/src/connection.lua b/src/connection.lua index e1eff46..f40dead 100644 --- a/src/connection.lua +++ b/src/connection.lua @@ -7,14 +7,15 @@ arpcache = require "arpcache" function _connection.auth(serv, localport, remoteport) local user = config.map_ip(serv) + local mac = nil if not user then - local mac = arpcache.get_mac(serv) + mac = arpcache.get_mac(serv) if mac then user = config.map_mac(mac) end end - + if user == "*ident" then user = ident.resolve(serv,localport,config.map_port(remoteport)) end