Anatomy of an attack is unclear. But its clear, hacker managed to upload the shell on the website and deface the index of the website. The reason of hacking the Nigerian Ministry of Energy website is the export of  Oil to Israel by the Nigerian Governmnt.
Hacked Site:
http://ministryofenergy.dl.gov.ng/
Mirror of the hacked Site:
http://www.aljyyosh.org/mirror.php?id=50998
Complete Deface message left by the hacker on the deface page can be found below,
->
Deface Message:
Free Palestine
Fuck Nigerian Government about supporting the Israeli Occupation
about exporting gas to Israel after Egypt stopped for export to Israel
You help to killing Palestinian people in Gaza & West Bank
At the time of writing, Site was Up with the critical errors like Internal Path Disclosure and SQL Queries. It seems that website database is deleted or it is misconfigured by the hackers.