If the doctor is aware of a diagnosis that the patient has kept from people who might need to know
Please read my post again. I said that the doctor is the one that is applying for a medical certificate, not the father. I rest my case, I don't think that you've understood the crux of the matter.
If you want a specific legal opinion then ask a lawyer though
I think it's an interesting legal question but I won't pay any money to have it answered. However, I don't think that any lawyer has a definite answer but I do suspect that if it gets challenged in court, the applicant is probably not expected to give out confidential information regarding
another person but himself.