There is an inline fuel filter that is not so hard to change. Try that first. It is located near the fuel tank under the rear of the Jeep.
Stalling at idle is more likely caused by a dirty idle speed control solenoid. This can be cleaned by spraying throttle body cleaner into the little slot near the throttle plate inside the throttle body.
Before servicing the fuel pump or filter, you need to test the fuel pressure. Many auto parts stores have loaner tools available or they may check it for you. The tool consists of a pressure gage that connects to the fuel pressure test port. Normal pressure for the aniline six is around 40psi. A faulty fuel pressure regulator can cause the problems you are seeing as well.
If you do remove the fuel pump form the tank, pay close attention to he rubber hose that connects the pump to the lines. I just had a time tracking down a mystery fuel pressure problem in a Cherokee that turned out to be a pin hole in that little rubber hose.
Mike
http://www.mikestrawbridge.com/jeep-cher