It was a machine who shot the fake president. It was hooked up via the main terrorist’s cell phone. He set it off when he was watching the fake president’s speech in the plaza.
I just watched the movie yesterday, and at one point you can see where the main terrorist aligns the rifle using his smartphone, and even controls the camera and has a shoot button. One of the secret service agents was part of the plot so he takes it away in a long bag dressed as a cop.
I loved the way they put the movie together, kept me down in my chair the whole time. Highly recommended!