https://www.etzion.org.il/en/talmud/seder-nashim/massekhet-kiddushin/72b-mamzerim-messianic-age
Ramban (Nachmanides) and some other commentators claim that, with the arrival of the Mashiach (Messiah), there will be a Divinely authorized "pardon" of sorts for mamzerim. However, the prohibition will still be on the books, such that new mamzerim that will be created after that time will be prohibited from marrying into the Jewish community. Many other Rishonim (a name that refers to the early Rabbis of the era after the decline of Babylonia as the dominant center of the Jewish world; it includes scholars who lived approximately between the years 1000 and 1500 of the common era), including the Ran (Rabbenu Nissim), argue that even this is impossible. Rather, Rabbi Yossi means to say that Eliyahu ha-Navi (Elijah the Prophet), who according to tradition will accompany the Mashiach, will not disclose the identity of mamzerim who have integrated into the community, despite the fact that he will know the true status of each person's lineage. However, people recognized as mamzerim will still be prohibited from marrying into the community. This is a much less radical statement, because it does not posit a one-time suspension of halakha; even nowadays we do not uncover the identity of mamzerim who are not recognized as such and have integrated into the community (Gemara 71a, Shulchan Arukh EH 2:5, Rama).