Yes, a great question Ruby. There is this temptation to relate Capsaicin to Black Pepper, however this is not true. The black pepper seeds are from a plant in the vine family of plants. The Capsicum family is the home of the chillies and the chemical Capsaicin which is a chemical in the alkaloid family. Capsaicin is not only used in pepper sprays it also has some curative properties, for example it is an effective pain killer.
I think it is very interesting that certain chemicals, particularly those derived from plants can be used for destructive purposes and for curing purposes. Just a thought.