In November 1943, Hannah was appointed commanding officer of No. 6 Squadron at Milne Bay, Papua, flying Bristol Beaufort light bombers. During a familiarisation flight he came under friendly fire from anti-aircraft guns on Kiriwina Island, but avoided serious injury. He was raised to temporary group captain in December, and assumed command of No. 71 Wing the following month. The Beauforts of No. 6 Squadron and No. 71 Wing took part in a series of major attacks on Rabaul, bombing and strafing airfields, infrastructure and shipping; this continued until February 1944, when the Japanese withdrew their aircraft from Rabaul. The same month, Hannah fell ill and had to be repatriated to Australia. After six weeks recuperation at Laverton, he returned to No. 6 Squadron, based on Goodenough Island. From March to August, the squadron was mainly involved in convoy escort and anti-submarine duties. In September 1944, Hannah was appointed senior air staff officer (SASO) at Headquarters Western Area Command, Perth. He took over control of the formation from Air Commodore Raymond Brownell in July 1945, following Brownell's departure to command No. 11 Group in the Dutch East Indies.