All these techniques are shit. Untested.
local names = {}
for k , v in ipairs(player.GetAll()) do
	table.insert(names , {v , v:Nick()})
end
function table.HasMember(tbl , val) -- table.HasValue only works on tables with singular indexes
	for k ,v in ipairs(tbl) do
		for a , b in ipairs(v) do
			if val == b then
				return true
			end
		end
		if v == val then
			return true
		end
	end
end
local function CheckNames(p , c , a)
	for k , v in ipairs(player.GetAll()) do
		if not table.HasMember(names , v) then
			table.insert(names , {v , v:Nick()})
		end
		for a , b in pairs(names) do
			if b[1] == v then
				if b[2] != v:Nick() then
					print(v:SteamID().. " is using a name changer")
				end
			end
		end
	end
end
concommand.Add("check_names" , CheckNames)