(JNS) Two residents of East Jerusalem were charged Sunday with planning to carry out a shooting attack at a Tel Aviv beach.

According to the indictments filed in Jerusalem District Court, the pair, ages 23 and 27, concocted the plot while serving time together in Israel’s Nafha Prison in the Negev in 2017.

According to the charges, the pair chose the Tel Aviv seaside as a target over Jerusalem due to the high number of attacks in Israel’s capital city and the higher police presence there.

According to the indictment, after their release from prison in February 2019, the men traveled to Istanbul, Turkey, where they met with a Hamas operative, who recommended they assassinate former Jerusalem mayor Nir Barkat, ex-Israel Police chief Roni Alsheich or Temple Mount activist and then-Likud MK Yehudah Glick. They were given funds and pants stitched with hidden messages from Hamas, according to the indictment.

Glick survived an assassination attempt in 2014 by a member of the Palestinian Islamic Jihad.

A third East Jerusalem man was also indicted for making contact with the Hamas operative in Istanbul, and receiving funds from him.

Prosecutors are requesting that all three men remain incarcerated until the conclusion of their trials.