He became President Manuel Quezon's aide-de-camp that same year and fought with the United States Army Forces in the Far East during the Battle of Bataan.
[1] He survived the Bataan Death March in 1942 and began organizing resistance against Imperial Japanese occupation, most notably the Fil-American Cavite Guerrilla Forces shortly thereafter.
After seven months in office, the Japanese became aware of his guerrilla affiliation and attempted to arrest him; he was able to elude his would-be captors and joined his comrades in the field and he engineered along with his FACGF officers and in coordination with the US 11th Airborne Division General Swing and Col.Jay Vanderpool the battle for the liberation of the province of Cavite[1] Castañeda was appointed Provost Marshal General of the Philippine Army on 1 June 1946.
[1] The night before the Philippine Parity Rights plebiscite in 1947, President Manuel Roxas addressed a rally at Plaza Miranda.
He narrowly avoided an assassination attempt by Julio Guillen, a disgruntled barber who threw a grenade on the speaker's platform.