Apple has been making OS X safer for sometime. This year in particular there has been a number of security updates. A recent update has taken it one step further by removing Java from use in a browser.
If a web site need Java to work, it will give you the option to download it. Any updates then must be made by the user. The first thing you should do to keep your Mac safe is to keep the OS up to date.
See the Forbes article here: http://www.forbes.com/sites/adriankingsleyhughes/2012/10/19/apple-makes-os-x-safer-by-removing-java/