The Japanese Defense Ministry punished the Ground Self-Defense Force's vice chief of staff and two others on Friday over the use of official cars for their group visit to Tokyo's war-linked Yasukuni shrine, often seen as a symbol of the country's past militarism.

The ministry, however, added that the visit itself to the Shinto shrine on Jan. 9 was a private one and "based on their free will," and thus not subject to any penalty. The trip was made by 22 GSDF members in total including Lt. Gen. Hiroki Kobayashi, the vice chief of staff.

Photo taken on June 15, 2020, shows the headquarters of Japan's Defense Ministry in Tokyo. (Kyodo)

The ministry had been investigating whether their action violated a directive issued by the then vice defense minister in 1974 prohibiting group visits by SDF members to a religious facility.

According to the ministry, Kobayashi had invited his colleagues to take the afternoon off and visit the shrine, which is a 30-minute walk from where they worked.

Kobayashi and his two colleagues received reprimands, while Gen. Yasunori Morishita, the chief of staff of the GSDF, and three staff members were handed a written warning as they were held ultimately responsible. Two other GSDF members were verbally cautioned.

While Morishita and Kobayashi gave their consent for their names to be made public, the ministry refrained from identifying the seven other punished officers as it could infringe their freedom of religion.

People offer silent prayers at Tokyo's Yasukuni shrine on Aug. 15, 2023, the 78th anniversary of Japan's surrender in World War II. The Shinto shrine honors more than 2.4 million war dead. (Kyodo) ==Kyodo

Past visits to Yasukuni shrine by Japanese lawmakers have been a source of diplomatic friction with China and South Korea as the shrine honors the World War II dead including Japanese leaders who were convicted as war criminals in an international tribunal.