White hat hackers are ethical security professionals who find and report vulnerabilities with permission. Black hats are malicious actors, grey hats operate in ethical gray areas. The term comes from Western movies where heroes wore white hats. 'Underground hackers' typically refers to black hats.