As long as individuals and businesses continue to get victimized by data breaches, huge money will keep flowing to private companies that take on hackers.

According to a report by CB Insights, a company that tracks venture capital and angel investment, cybersecurity startups raised a record $2.5 billion across 240 deals in 2014. The industry is on pace to nearly match last year's numbers, with $1.2 billion raised across 99 deals during the first half of 2015.

The last half-decade has seen rapid growth in the space. Companies raised less than $1 billion in 2010.

The second and third quarters of last year were especially active in terms of investment. Notable deals during those quarters include Tanium's $90 million round from Andreessen Horowitz and Lookout's $150 million round from Andreessen Horowitz, Morgan Stanley, Goldman Sachs, and Khosla Ventures. Q2 2015, during which Illumio raised $100 million from investors led by Accel Partners, also was strong.

More than 80 percent of all cybersecurity startup funding since 2010 has gone to companies based in the United States, according to CB Insights. The majority of that went to companies in California. Startups in Massachusetts, Virginia, Texas, and New York also have received significant funding.

Israel ranked second after the U.S. in terms of number of deals, with 50 since 2010. Canada ranked second and the United Kingdom ranked third.