Matthew 7:21
Not everyone who says to Me, Lord, Lord, will enter the kingdom of heaven, but he who does the will of My Father who is in heaven will enter.”
That was Old Covenant before Jesus died and rose from the dead which triggered the New Covenant. Jesus was talking to the Jews who thought they could be saved by keeping the law. Much of the beatitudes were meant to flummox the Pharisees to show NO ONE can keep the law and ALL need Jesus.
As prophesied in Joel 2:32, today's' new covenant declares, "Whosoever shall call upon the name of the Lord shall be saved" Rom 10:13.
And neither you nor I know for sure who those people are. That's why Romans 2 and elsewhere shows the folly of judging others and to not judge another. They can be as bad as Bad Bob the Albino, but if they've received Jesus they are saved. It's all God's grace.