Court: Buckingham Palace trespasser was convicted murderer.

Armed police officers work at the main gate of Buckingham Palace in London, Thursday, May 19, 2016. British police say they have arrested a man who scaled a wall and got into the grounds of Buckingham Palace. The Metropolitan Police force says a 41-year-old man was detained in the palace grounds Wednesday evening on suspicion of trespassing on a protected site. (AP Photo/Kirsty Wigglesworth) (The Associated Press)

Armed police officers patrol in the grounds of Buckingham Palace in London, Thursday, May 19, 2016. British police say they have arrested a man who scaled a wall and got into the grounds of Buckingham Palace. The Metropolitan Police force says a 41-year-old man was detained in the palace grounds Wednesday evening on suspicion of trespassing on a protected site. (AP Photo/Kirsty Wigglesworth) (The Associated Press)

Tourists around Buckingham Palace in London, Thursday, May 19, 2016. British police say they have arrested a man who scaled a wall and got into the grounds of Buckingham Palace. The Metropolitan Police force says a 41-year-old man was detained in the palace grounds Wednesday evening on suspicion of trespassing on a protected site. (AP Photo/Kirsty Wigglesworth) (The Associated Press)

Authorities say a man who climbed over a wall and got into the grounds of Buckingham Palace while Queen Elizabeth II was at home is a convicted murderer.

Dennis Hennessy pleaded guilty to trespass at a court appearance Friday.

He was arrested in the palace grounds on Wednesday evening. Police say he was not armed.

Prosecutor Tom Nicholson told the court that 41-year-old Hennessy walked around the gardens for about 10 minutes toward the palace before being arrested. As he was detained he asked "is Ma'am in?" — the courtesy term used for the queen.

Prosecutors said Hennessy was on parole after being convicted of the murder of a homeless man in 1992.