Ibrāhīm is syntactically accusative in «مَرَرْتُ بِإِبْرَاهِيمَ».

Diptote Causes — Foreign Origin and Its Conditions