"Potty Talk" in Toddlers
If your child is experiencing or recently experienced potty training, this is an age-appropriate behavior. By talking to your son, scope out what his level of understanding of all this really is. Ask him if he knows how others feel when he asks these questions or makes these comments and how he feels when others ask him these questions or make these types of comments. It's important to allow him a time and place to ask you questions and discuss these issues safely. He might have questions and not know where or how to ask them.
In your discussion, explain to your son the need for privacy: of his body, your body and other people's bodies. He'll need to know that there are some inappropriate behaviors, such as looking, touching and speaking to others about certain topics in certain settings.
You might want to set up a warning cue such as rubbing your ear so that if or when he does ask someone an embarrassing question, he will know to stop. If he is not able to respond to your cue, he might need a consequence, but it should not be harsh or embarrassing. He needs to be able to feel safe and get his arms around this issue without fear.
Also, check to see if anything has been seen or said in a social or school setting that possibly could be the root of this new-found interest.