Where an exploit takes advantage of a weakness in an operating system or vended application program, the owners of the system or application issue a "fix" or patch in response. Users of the system or application are responsible for obtaining the patch, which can usually be downloaded from the internet. Failure to install a patch for a given problem exposes the user to a security breach. (However, it can be difficult to keep up with all the required patches.)
Some programs such as EMET can be used to block exploit attacks.