And, the doctor may not have a choice. Even if they’re asking for purely medical-history reasons, they may have to put the information into a system (according to their employer or insurance company or for their own records), and that system may be subject to information gathering from hostile parties.
This is likely in the context of abortion bans in some US states. Presumably they still trust the doctor to do a regular checkup for everything else.
And, the doctor may not have a choice. Even if they’re asking for purely medical-history reasons, they may have to put the information into a system (according to their employer or insurance company or for their own records), and that system may be subject to information gathering from hostile parties.