In more detail
Vulnerabilities come from coding mistakes, bad configuration or design flaws. Publicly known ones get a CVE identifier and a CVSS severity score, and are fixed by patches. The risk depends on how easy the flaw is to exploit, whether it is exposed and what it would give an attacker.