This question already has an answer here:
- How does SSL/TLS PKI work? 9 answers
What does having a certificate issued by a Content Authority protect against? In everything I've red (and watched) they teach it as "you are given the public key to communicate with Alice, but how do you know it is actually from Alice?" in comes the PKI...
what I don't understand is the problem "how do you know the public key came from Alice"?
You contacted the resource, whether it with a host name or IP address. Let me know if my question doesn't make sense and I'll try to reword it. What I'm asking is basic: what's the need of a certificate: you always know the IP address of the person your sending to. Does this have something to do with if someone sends you the public key then the person may be an attacker and give you a bogus public key? But you would still be sending packets to the actual intended recipient so they would likely return an error message saying there's something wrong with the way your messages are encrypted.