Georgia Secretary of State Brian Kemp is demanding to know why the Department of Homeland Security tried to hack into the state's voter database. He's pictured here in Atlanta, Feb. 24, 2016. /Letitia Stein/Reuters

Georgia’s secretary of state said Thursday an attempt to hack into the state’s voter registration database has been traced back to the Department of Homeland Security.

Secretary of State Brian Kemp, a Republican, said on his Facebook page he has sent a letter to Homeland Secretary Jeh Johnson, demanding to know why.

“At no time has my office agreed to or permitted DHS to conduct penetration testing or security scans of our network,” Kemp wrote. “Moreover, your department has not contacted my office since this unsuccessful incident to alert us of any security event that would require testing or scanning of our network.”

Homeland Security said it is looking into the matter and will respond directly to Kemp.

“It’s outrageous to think about our own federal government is doing this to us,” Kemp told WSB-TV, Atlanta, adding he was “mad as hell.”

"We're demanding answers to some of these questions, you know? Are they doing this to other states? Was it authorized or not? Who ordered this? Why is it being done and why weren't we notified?"

Kemp said the Nov. 15 database attack had been traced back to an IP address at Homeland Security.

Kemp said the state’s firewall held up, blocking a breach. The database also contains information about company incorporations.

Kemp refused help from Homeland Security to beef up protections ahead of the election, saying fears of Russian hacking attempts were overblown. The state had a contract with a major third-party security firm, and Kemp chief of staff David Dove told cyberscoop they thought that was sufficient.

Willis McDonald, a former FBI and Defense Department cybersecurity analyst, told WSB it is unlikely Homeland Security committed the hack. What is more likely, he said, is a hacker spoofed the department’s address.

"It's fairly easy. It's fairly common to see something like that happening," McDonald said.

Homeland Security reported attempts had been made by hackers to get into voter databases in 20 states ahead of the election but no attempt was made on Election Day itself. There was no evidence any of the systems was breached.