Contexto
Differing ethical standpoints hackers
Ethically speaking, black hats are horrible. They have little regard for the well being of others and act with complete impunity. They engage in activity that is not only illegal, but to most people, highly immoral as well. They gain unauthorized access to secure systems, steal sensitive data, exploit or blackmail individuals, and disrupt the system just for fun. The laws regarding hacking are quite strict, most likely in an attempt to dissuade future black hats from proliferating.
White hats, on the other hand, adhere to not only a strong moral code, but also take a very ethical approach to hacking. They are the ones attempting to find issues with networks, hardware or software, with the intention of notifying the effected parties. Since this is the case, most of what they do is considered perfectly legal. Many white hats operate as private contractors, or are even employed by government agencies, such as the National Security Agency. They are, as the color of their hat denotes, the 'purest' form of hacker, ethically and morally speaking.
Hardware hackers find themselves in a bit of a grey area, however. In the case of hacking video game consoles, most people would consider it completely ethical (and moral) to modify a gaming system. But, these modifications, regardless of the original intent of the creator, can sometimes be used to pirate games. This is highly illegal, and extremely unethical. As a general rule of thumb, so long as the hacker isn't attempting to create monetary gains from their work, they are typically safe from legal ramifications.