In 1938 Hazairin obtained a post at a court in Padang Sidempuan, North Sumatra, where he stayed until the Japanese invaded the Indies in 1942; during the same period he served to enforce adat law throughout South Tapanuli.