In the 89th minute, freshman Josh Fawole was taken down just outside of the box. Sharifi took the free kick and placed it in the upper left corner of the goal for the game's equalizer.
He again placed a free kick into the back of the net in the 93rd minute when he spun a 35-yard shot off the tips of Pittsburgh goalkeeper Mikal Outcalt for the game winner.
The Pathers got their go-ahead goal in the 25th minute when Alec Anselmo finished a cross from Kevin Angulo.
For the game, the Greyhounds held a 14-7 shot advantage and a 10-4 advantage in corner kicks. Outcalt turned back eight shots though, including a pair by freshman Brian Saramago in the 15th minute, one by freshman Josh Fawole in the 67th minute and a header attempt by Michael Colao in the 71st minute.
In goal for the Greyhounds, senior Matt Sanchez stopped three shots.
With the win, Loyola logged its first win over an Atlantic Coast Conference program since knocking Maryland out of the 2001 NCAA Tournament with a 1-0 overtime win.
The Greyhounds will return to action on Saturday when they open Patriot League play at Lafayette. Kickoff is scheduled for 7 p.m.