With armor equipped with the thorn enchantment, some attacks from mobs will not always hurt them. This is best found with spiders.
Linked issues
is duplicated by 1
Comments 2
It should be noted that this seems to happen more often with mobs which have weaker attacks (note that spiders have a higher attack rate than most mobs, but are also weaker) - it might be due to rounding error making Thorns less effective against weaker mobs - and entirely ineffective against silverfish, which deal only half a heart of damage.
https://twitter.com/Dinnerbone/status/279275321595932672