A deputy at a Georgia courthouse stopped a gunman with explosives and an assault rifle from entering the courthouse on Friday in a shootout that left the deputy wounded.

According to CNN, authorities killed Dennis Marx outside the Forsyth County Courthouse in Forsyth, Ga. Marx had intended to open fire within the courthouse.

"Mr. Marx's intention was to get in that front door and take hostages," Forsyth County Sheriff Duane Piper told CNN.

A witness' video shows officers, with their guns drawn, surrounding a silver Nissan SUV in front of the north Georgia courthouse. A number of shots were fired, then officers surrounded the vehicle. Piper said the suspect began a "full frontal assault" on the courthouse by driving up and throwing "homemade spike strips" to delay police from getting to the scene. He also tried to run over a deputy.

The deputy started shooting, and Marx shot back, hitting the deputy in the leg. He then threw smoke bombs and grenades, and also had flex ties and water in his possession. A number of other explosive devices and ammunition was found in the SUV.

Deputies from inside the courthouse as well as deputies that had arrived on the scene had a 90-second shootout with Marx, eventually killing him.

"The SWAT team, which happened to be close by on their way to another function, also pulled up about 30 seconds into this gunfire fight and they engaged Mr. Marx, and Mr. Marx is dead with multiple gunshot wounds," the sheriff said.

The still unidentified deputy who was shot underwent surgery for fractures to his fibula and tibia in the lower leg, according to the sheriff. His injuries are not life threatening.

The situation "was solved [with] that deputy's actions," Piper said.

"He had been in the courthouse for a good part of his time, and part of his duties were to sweep the outside of the courthouse and he happened to have been out there doing that when Mr. Marx came up," the sheriff continued.

Marx was going to the courthouse Friday to enter a plea on a drug-related charge.

Authorities still had not gone into Marx's home as of 4 p.m. Friday, which Piper said is most likely booby-trapped. Authorities say Marx had not been back to his apartment in 10 days.

A bomb squad worked to remove the bombs from Marx's home in Cumming, Georgia, which is 35 miles northeast of Atlanta. The Georgia Bureau of Investigation and the FBI assisted the bomb squad. At least two agents from the Bureau of Alchohol, Tobacco, Firearms and Explosives also offered assistance.

The county sheriff said there is no indication that Marx's family was involved in the bomb plot.

Not many details have been released about the suspect, but authorities told CNN that he worked at the Transportation Security Administration, which oversees airport security. Marx began working at the TSA in October 2002 and left in either 2003 or 2004.

Watch the witness video of the incident below.