Not read all of story here or know full facts BUT as an ICt teacher at a secondary school I would imagine that this pupil DID know the rules on what is appropraite and not, and what he CAN and CANNOT do using school computers. Most children when starting secondary fill in, often a spart of school home contract, a consent form to be allowed access to the school's internet/e-mail access. Part of this policy is that the pupil should only download or search for appropriate material - and it is generally layed out what is not appropraite, including pornography, offensive materials, etc.
If this was the case (as it is in the schools I know about) then this boy would have known that the images he included were not appropriate for his school work and therefore he did deserve a punishment.
Is this the right punishement? I don't know. If it is a one off offence and he has no other blots on his record, then yes I think it is over the top. In such a circumstance I would have had his e-mail/internet permissions from the school network stopped for a given period oftime, and for his access to school network to be limited/supervised during a set time too.
If, however, it was just another in a string of offenses, then it would have been justified as a punishment.