Barcelona were given a testing tie against Valencia in Friday's draw for the semi-finals of the King's Cup while Leganes were handed a marginally more comfortable tie against Sevilla after dumping Real Madrid out of the competition.
Barcelona hammered a hapless Valencia side then coached by Gary Neville 7-0 in a 2016 semi-final first leg, easing into the final 8-1 on aggregate, but the six-times Liga champions have been revitalised by coach Marcelino this season and should pose more difficulties for the Catalans than last time around.
Runaway Liga leaders Barca reached the last four of the competition for the eighth year in a row by beating local rivals Espanyol 2-0 on Thursday, while Valencia, who are third in the standings, sneaked into the last four by overcoming Deportivo Alaves in a penalty shoot-out on Wednesday.
Barca have won the last three editions of the Cup and reached the last four finals, while Valencia have not made it to a final since winning the tournament in 2008.
Leganes reached the semi-finals for the first time in their history by staging a second leg turnaround against crisis-hit Real, beating Zinedine Zidane's stumbling side 2-1 at the Santiago Bernabeu to advance on away goals.
Barca host Valencia in the first leg of the tie on either Jan. 31 or Feb. 1 with the second leg coming on Feb. 8 or 9, while Leganes will play the first leg against Sevilla at home.