Japan and India agree to boost security ties and work together on projects including high-speed rail.