Yes, I agree that if the law attempts to be ex post facto, it would be potentially an utter disaster. If it's retroactive for one generation it's retroactive for all, and would technically require certification of everyone's parents and their parents back to the founding of the nation. Or at least it would open up any native born citizen's citizenship to be challenged. On the other hand, if you allow the very idea of naturalized citizens, then birthright is irrelevant to them. Since it's part and parcel of naturalization that you were NOT born in the US, and NOT previously a citizen of the US, naturalization is inherently exempt from the complications of birthright citizenship. You can challenge their citizenship only if you can prove that they cheated in the process. So in a sense, the only people whose citizenship would be immune to the documentation challenge should be those who were naturalized!
If not only the citizenship but the legal residence of a person born in the US is dependent on the status of one's parents, it is a naturally endless process. If your ancestors were not documented immigrants at the time the United States was founded, none of their descendants can ever be. Now of course that is flamboyantly, flagrantly, floridly crazy, utterly ridiculous and unthinkably stupid, and in a rational world we would probably not have to wait and see, but we'd better wait and see.
Now of course, aside from the fact that such a law would be flagrantly unconstitutional as ex post facto, I could imagine that you could argue that a law basing the citizenship of a native-born American on the status of their parents would be effectively a bill of attainder, also forbidden. Of course I would not put it past the stable geniuses in charge of all this to opine that although a fetus is an innocent and fully vested citizen, the very act of being born makes them law breakers in their own right.
Of course any such legal denial of citizenship is never meant to apply to everyone. It is, from the get-go, a transparently selective, targeted law, unenforceable in the main while ready and waiting for the dictator's enemies.