Brunei's football association NFABD created Tabuan Muda in 2015, a league team that serves to prepare for international tournaments, mirroring Singapore's Young Lions and Malaysia's Harimau Muda teams.[5] Hanif was assigned to the Under-18s playing in the Brunei Premier League at the start of the season,[6] however he was promoted to the Brunei Super League team in the second half of the season.[7] Tabuan Muda finished fifth in the 2015 and 2016 seasons of the BSL.
Hanif trialled out for and joined Brunei DPMM FC's Under-19 team in early 2015.[8] Although he was overlooked for promotion in 2016, he was handed a professional contract by Steve Kean to play for DPMM in the S.League in 2017. He signed full terms on 15 January.[9] He made his debut in the 4–0 loss against Albirex Niigata FC (S) on 16 June.[10]
Hanif made eight league appearances for DPMM in the 2019 season en route to the championship, his first with the professional club.[11] He left DPMM at the end of the season.[12]
In 2017, Hanif was announced as one of Brunei's athletes for the year's SEA Games football tournament held in Malaysia in August, playing with the under-23s.[19] However he was replaced by Nadzri Erwan on the eve of the biennial sporting event.[20]
Yet to register an appearance in the 2019 Singapore Premier League, Hanif accepted a callup to the senior national team for the two-legged 2022 World Cup qualification matches against Mongolia in June of that year.[23] He was deployed by Robbie Servais as a starter in both games alongside captain Sairol Sahari at centre-back. In the first leg, he was at the short end of a weak backpass by Helmi Zambin for the crucial second Mongolia goal.[24] The second match was also eventful for Hanif as he was the one who felled Narmandakh Artag inside the penalty box that led to a Mongolia penalty scored by Tsedenbal Norjmoo.[25] Brunei were beaten 2–3 on aggregate and failed to progress to Round 2 of the qualification process.[26]
Hanif was selected and started the friendly match away against Laos on 27 March 2022 which ended in a 3–2 loss.[27][28] Later in the year, he was retained for a tri-nation tournament in late September involving the Maldives and Laos and played in both fixtures.[29] That December, he was selected for the Brunei squad for the 2022 AFF MItsubishi Electric Cup in their second ever appearance at the level since 1996.[30] He was brought in as an early substitute against Thailand in a 0–5 defeat in the first group game. He then started the third game against Indonesia where he suffered an injury early in the game and was taken off.[31]
Hanif was selected for the Brunei national team at the 2026 World Cup qualifying matches against Indonesia held in October 2023 over two legs.[32] He played the full 180 minutes in a 0–12 aggregate loss to their Southeast Asian compatriots.[33]