Less than two years after a massive Palestinian prisoner release, Hamas has been planning mass-casualty attacks in Israel’s capital.

The Israel Security Agency has determined that Hamas rebuilt its military wing in the West Bank and Jerusalem. Officials said ISA has detected Hamas plots to conduct massive bombings against Israeli civilian targets as well as acquire surface-to-surface rockets.

“They took advantage of those with Israeli residents, who enjoy freedom of movement, to implement attacks in Israel,” an official said.

On Sept. 1, ISA disclosed a Hamas plot to bomb a leading shopping mall in Jerusalem. The domestic intelligence agency said Hamas planned to conduct the attack during the Jewish holiday season over the next few weeks.

Hamas has rebuilt its military wing over the last year in wake of Israel’s release of more than 1,000 Palestinian insurgents. They said many of the more than 200 Palestinians allowed to return to the West Bank resumed insurgency activities.

The latest Hamas plot was attributed to two operatives who lived in the Jerusalem area, Ahmed Rishak and Ismail Abu Mafalfal. Rishak and Abu Mafalfal were said to have been led by Hamdi Romana, a 22-year-old from the West Bank capital of Ramallah.

ISA, backed by the army and police, determined that Romana operated a bomb-making laboratory in Ramallah. They said Romana recruited Rishak and Abu Mafalfal in part because of their Israeli residency cards, which allowed them to move through Israel and the West Bank. “During questioning, members of the terror cell mentioned other initial plans to carry out additional attacks, including harming IDF soldiers by booby trapping homes in Ramallah, manufacturing and firing rockets at Israeli communities near Ramallah, and attempts to get hold of handguns to fire on IDF soldiers at the Hizma roadblock, northeast of Jerusalem,” ISA said.

Rishak and Abu Mafalfal were also employed at the targeted Mamila mall. An Israeli court indictment said that in July 2013 the two defendants were directed by Romana to take the bomb, wrap it as a gift and plant into a restaurant at the mall. All three were reported arrested.

“They were supposed to bring an explosive charge into Israeli territory,” ISA said. “They were to bring it into the mall and hide it in their lockers at their place of work.”

The Israel Army used the infantry’s Givati Brigade to raid Romana’s laboratory, said to have been supplied by Palestinians around Ramallah. The raid found evidence that the Hamas cell also sought to produce rockets.

“The infrastructure was extensive and it took about two weeks to capture all of the operatives,” Lt. Col. Liran Hajbi, a Givati battalion commander, said.

Hajbi said the army was making arrests on a nightly basis in the Ramallah area over the last month. He said many of the suspects were linked to Hamas and other Islamist insurgency factions.

“We are tracking an escalation in the terrorist infrastructure and the battalion has been conducting arrests and raids every night to reduce the ability to implement attacks,” Hajbi said.