Two men arrested for breaking into the Dallas County Courthouse told law enforcement they were hired to do so by the judicial branch.

The men, outfitted with numerous burglary tools, told authorities they were on contract to test out the courthouse alarm system's viability and to gauge law enforcement's response time, an alleged contract that Dallas County officials said they had no knowledge of, according to a criminal complaint.

Authorities later found out the state court administration did, in fact, hire the men to attempt "unauthorized access" to court records "through various means" in order to check for potential security vulnerabilities of Iowa's electronic court records, according to Iowa Judicial Branch officials.

But, the state court administration "did not intend, or anticipate, those efforts to include the forced entry into a building," a Wednesday news release from the Iowa Judicial Branch read.

Authorities:Polk County Courthouse burglary similar to break-in by men hired by judicial branch to test security in neighboring county

Evidently, the courthouse's security system did its job. The alarm system was triggered by the two men whom law enforcement found walking around the courthouse's third floor at about 12:30 a.m. Wednesday, court records show.

Justin Wynn, of Naples, Florida, and Gary Demercurio, 43, of Seattle, Washington, were both charged with third-degree burglary and possession of burglary tools. Their bond has been set at $50,000.

The men were employed with Coalfire, a cybersecurity advisor headquartered out of Colorado, Iowa Judicial Branch spokesman Steve Davis confirmed.

A spokesperson for Coalfire declined to comment on the situation Wednesday afternoon.

They are set to make another appearance at the Dallas County Courthouse, only this time, not of their own volition, on Sept. 23 for preliminary hearings. The Dallas County sheriff declined to comment, as the investigation is ongoing.

The state court administration issued an apology Wednesday to Dallas County officials, who are continuing to investigate the break-in.

Anna Spoerre covers crime and courts for the Des Moines Register. She can be contacted at aspoerre@dmreg.com, 515-284-8387 or on Twitter at @annaspoerre.

Your subscription makes work like this possible. Subscribe today at DesMoinesRegister.com/Deal.