The European Union is threatening to impose sanctions on groups and individuals that undermine U.N.-backed talks to agree on a cease-fire and lay the groundwork to end the internal conflict in Libya.

The 28 EU foreign ministers said in a statement Monday they were ready to impose "restrictive measures against spoilers of the dialogue process."

Libya has been mired in its worst fighting since Moammar Gadhafi's regime was overthrown in 2011. Two rival governments are each backed by an array of militias that have effectively split the nation.

"Those responsible for violence and those who obstruct or undermine Libya's democratic transition must face consequences for their actions," the statement said. The measures would involve asset freezes and travel bans.