The teenager was taking part in a guided tour of the Assembly building in Cardiff when he accessed the computers to send a joke e-mail to a friend.
![[ image: width=150]](/olmedia/525000/images/_526362_chapman150.jpg)
But the prank backfired when the message was sent to Assembly Member Christine Chapman instead.
Ms Chapman, who had recently written an anti-racism column for a newspaper, was shocked when the message flashed up on her laptop computer as she worked from home.
She immediately contacted security officials at the Assembly, who managed to track down the culprit.
He was given a warning and allowed to continue with the tour.
'A minor review'
A spokesman for the Assembly confirmed that a security review had been ordered to prevent visitors accessing desktop computers in the chamber.
He said: "The Presiding Officer has written to all members asking them not to bring visitors to the Members' area of the chamber because of concerns about the security of the technology there.
"These computers do not hold any files but it is possible to send e-mails from them.
"This incident highlighted that we did need to look again at our security arrangements, although it is only a minor review."
'Badly spelt'
Ms Chapman, who is Labour AM for the Cynon Valley, said: "When I first saw the message it really unnerved me. It was not a nice thing for them to do."
Her researcher Simon Evans added: "It was a one-line message which shook her up a bit, but once the shock had passed it became clear it wasn't a truly sinister message.
"The message was badly spelt, which pointed to it being children.
"The boy who was responsible has since written a letter of apology to Christine."
The BBC is not responsible for the content of external internet sites.
Labour explores Assembly election wounds
Delays hit coach crash compensation
Ex-headmaster guilty of more sex charges
Museum in pay-off probe
Euro row over "Welsh" money rebate
Germans challenge Cardiff for Tyson fight
Ticket chief resigns after World Cup fiasco
Quick-thinking driver foils 'carjacker'
Spring clean for river
Roman remains may halt rugby centre plan
Olympic rider Sir Harry is mourned
The Welsh Week at Westminster
Hanged farmer had been cautioned
Children take over the Assembly
Assembly security review follows pupil's 'threat'
Opposition parties criticise Health Secretary
Welsh airline is launched
Anglesey power plan may bring 1,500 jobs
Former paratroopers recruited drugs courier
Star's cyber-fans help Welsh charity
Labour election inquest blames party rifts
New factory creates 500 jobs
Bassey will go world wide on the web
French boycott gathers pace
Villagers fume at delay over sewage problem
Pensioner leaves fortune to birds
MP demands return of Glyndwr letter