The materials for the ninja sword are found in dungeon battles. One important catch: you need to be playing as a ninja while you run the dungeon, otherwise the drops will not go toward the sword you are after. Gear up in the ninja class, head into a dungeon, and keep an eye out for the components as you clear encounters.