after driving a few minutes the brakes will lock up. on 2002 Nissan Xterra

2002 Nissan Maxima, it has dtc c1111. as soon as you take your foot off the gas all 4 wheels will stop

Asked by for the 2002 Nissan Xterra
Sounds like inspecting and or changing out the master cylinder and booster wouldn't be a bad place to start. Or you could have a vacuum problem causing the master or booster to malfunction even if they are not faulty