A California man, Cole Allen, has been charged with the attempted assassination of US President Donald Trump following a shooting incident at the White House Correspondents’ Association dinner.

Allen, 31, appeared in federal court on Monday after the chaotic Saturday night episode in which gunfire erupted, prompting security personnel to rush Trump offstage while attendees took cover. In addition to the attempted assassination charge, he faces counts of transporting firearms and ammunition across state lines and discharging a weapon during a violent crime. He has not yet entered a plea.

Authorities said Allen, a resident of Torrance, California, was apprehended shortly after the incident and is being prosecuted in Washington. During the attack, a police officer wearing a bullet-resistant vest was struck but is expected to recover.

Prosecutors have not disclosed a clear motive. However, investigators are examining a message Allen allegedly sent to family members minutes before the attack, in which he referred to himself as a “Friendly Federal Assassin.” The message reportedly contained repeated references to the president and hinted at grievances linked to policies of the Trump administration.

Officials are also reviewing Allen’s social media activity and conducting interviews with family members as part of the ongoing investigation into his mindset and possible motivations.

A video shared by Trump shows a man, believed by authorities to be armed, running past a security barricade before being intercepted by Secret Service agents.

Records suggest Allen worked as a tutor and amateur video game developer, with a social media profile indicating part-time employment over several years at a company offering admissions counselling and test preparation services for prospective college students.