diff --git a/filters/gentoo-ldap-authentication.lua b/filters/gentoo-ldap-authentication.lua index c1e382f..3b6564b 100644 --- a/filters/gentoo-ldap-authentication.lua +++ b/filters/gentoo-ldap-authentication.lua @@ -106,7 +106,7 @@ local lualdap = require("lualdap") function gentoo_ldap_user_groups(username, password) -- Ensure the user is alphanumeric - if username:match("%W") then + if username == nil or username:match("%W") then return nil end