Shinobi (ninja) were historically used for espionage, sabotage, and intelligence gathering. Their primary roles included detecting enemy spies, spying on adversaries, and inciting revolts against enemies. Options B, C, and D are incorrect - shinobi were not primarily Buddhist warriors, assassins (though assassination was sometimes part of their work), or diplomats.