That just means that the site is poorly configured. On the other hand, spammy and porny site can make money, and can be seriously administered. So finding certificates for them is not a surprise.
What can be the cause of that?
- the site has indeed be compromised and the hacker has used a certificate that they once obtained for the porny sites. Yes it is possible
- the site is hosted in a large datacenter that also hosts the porny sites. It has erroneously be connected to a reverse proxy that is configured with a certificate for the porny-spammy sites. It is possible too
If a site presents a correct certificate obtained from a reputable source (for example one that is trusted by Firefox or Chrome) then you can trust that you are reaching the expected site, but it cannot be an evidence that the site itself was not compromised
If a site presents an expired certificate, or a certificate not valid for that URL or a certificate from a source that Firefox does not trust, it just means that the administrator was uncautious or just did not care. Firefox warns you that it cannot certify that the name has reached the expected server, full stop. It has nothing to do with the site being compromised. It is easy for attackers that want to redirect traffic to change one letter in the URL and that way be able to present a valid certificate...