I'm currently reading a book about the history of the FBI, and one cannot possibly exclude the contributions of its director for 48 years. Despite being among the top law enforcement officers in the nation, J. Edgar Hoover seems to have had no problem whatsoever with breaking and/or severely bending many of the very laws he was supposed to uphold. He was very much a dictator and a despot in his own ways, and usually prevailed in the various bureaucratic and political battles he engaged in, the formation of the CIA probably being his biggest defeat.
I remember watching the 1959 Jimmy Stewart movie The FBI Story when I was a kid, and remember being quite thrilled with it. I watched it again recently, about 40 years after the first time, and laughed my ass off. It was very, very obvious that no part of that movie was made without Hoover's complete scrutiny and approval. To be fair, most entities like organizations, countries, and people are unwilling to approve of anything that portrays them in an unfavorable light, but this movie went way beyond that; supposedly, Hoover had a "dirt file" created on the director/producer of the movie, just in case he was "uncooperative". A massive and comprehensive accumulation of such files was at the heart of Hoover's power, and why he managed to stay in office for almost half a century.
Although Hoover made a big splash pursuing (and usually killing) the Midwest bandits in the early 1930's, Hoover was first and foremost a fanatical, rabid, and vicious anti-Communist. Indeed, any organization, group, or individual that went against the U.S. Government was fair game for his FBI. As organized crime was interested only in making money and not revolution, he simply didn't view them as much of a threat, and in any case, was a local matter. Much has been made (legitimately) of Hoover's war against the Civil Rights movement and others under the COINTELPRO, but to Hoover, they were nothing but a front for the Communists. Indeed, a senior advisor to MLK was a long-time Communist agent, which in and of itself would have given Hoover reason to go berserk.
Much, if not most of Hoover's intelligence was gained through technical means like bugs and wiretaps, most of which were warrantless and therefore illegal. Hoover also distrusted sources of information from people whom he considered to be "immoral", such as the spy code-named "Tricycle" because of his penchant for having sex with two women simultaneously. While Hoover made his agents constantly move around the country, and even the world, he stayed firmly planted in Washington, D.C., never far from the corridors of power.
Overall, I'd say that Hoover did his job as he saw how it needed to be done, but that fact that he routinely broke the law makes him a career criminal of sorts. When Hoover died on May 2, 1972, the vast majority of his private papers and files were destroyed, so we'll probably never know the full extent of his activities. One of the first things the government did after Hoover's death in 1972 was to impose a ten-year limit on the term a director of the FBI can serve, lifted only once in the case of Robert Mueller. Only Mueller and Judge William Webster seem to be the only FBI directors not mired in scandal and controversy. It's a tough job for sure, but people like Mueller and Webster have demonstrated that with good leadership, any organization can shine. The headquarters of the FBI, The J. Edgar Hoover Building, is widely regarded as one of the ugliest buildings in Washington D.C., described by somebody as being a creation of the Soviet politburo trying their hands at Narcotecture.