It is an open problem of how to protect the traffics and at the same time, to support In-network processing in sensor networks. This paper tackles the problem by proposing an efficient model of categorizing encrypted data transmitted on sensor networks. An aggregator, an intermediate sensor node in our setting, is embedded with a set of searching in encrypted format. Upon receiving an encrypted message it matches the message with the keywords and then processes the message based on certain policies such as forwarding the original message to the next hop updating it and forwarding or simply dropping it on detecting duplicates. The messages are encrypted before being sent out and decrypted only at their destination. Although the intermediate classifiers can categorize the messages they learn nothing about the encrypted messages except several encrypted keywords even the statistic information. The secure and efficient aggregation SEA scheme uses Bloom filter to further reduce transmission cost. The performance analysis shows that the computational cost and communication cost are well balanced.