Mosby, who has cultivated a national reputation as well as local critics, now faces a series of challenges to preserve her political and legal career, including a primary election just months away and the daunting task of taking on federal prosecutors.