Global oil prices rose as maritime attacks in the Middle East sparked energy supply concerns.