The correct option is B.
Looking at the given sentence, it will be observed that, the word summarily qualifies the word 'punished'. The sentence will still make sense if the word summarily is not included. The word 'punished' is a verb, therefore any word that qualify it will be an adverb. This is because, an adverb is a word which qualifies or modifies the meaning of a verb.Thus, the word summarily is an adverb.