Under Qing rule, the Hakka on Taiwan owned matchlock muskets. Han people traded and sold matchlock muskets to the Taiwanese aborigines. During the Sino-French War, the Hakka and Aboriginals used their matchlock muskets against the French in the Keelung Campaign and Battle of Tamsui. The Hakka used their matchlock muskets to resist the Japanese invasion of Taiwan (1895) and Han Taiwanese and Aboriginals conducted an insurgency against Japanese rule.