Mossad agents allegedly followed the two men when they were still in Tunisia, and killed them after they crossed the border to Libya.
Iran's regime is one of the main players attempting to take advantage of the chaos created in Libya after the demise of its ruler Muammar Gaddafi in 2011.
According to Al Arabiya, Iran has been trying to infiltrate Libya through several means, including sending military advisors to the country.
As part of its mission to obtain uranium from Libya's mines, Iran is attempting to influence local militias by supporting them in exchange for uranium.
The two Iranian advisors were supposed to coordinate between Iran's regime and the Libyan militias.
The Iranian advisors met with Libyan officials in Libya and Malta to see how Iran could assist Libya and promote its own interests at the same time.
One of Iran's goals is to distance its conflict with Israel away from its border.
A senior IDF official admitted in April that Israel's strike against Syria's T-4 Airfield— which left seven Iranian soldiers killed— was the first strike aimed against Iranian security forces.
"This is the first time we attack human Iranians targets," the senior official said to The New York Times' senior columnist Thomas Friedman.
"The Iranian drone that infiltrated into Israel in February was the first time Iran has executed a direct action against Israel rather than by a proxy. This (action) had triggered a new era in (Iran's) campaign (against Israel)," the official added.
Several hours after the IDF official's remarks had been published, Friedman wrote that the IDF's Spokesperson's Unit had rejected the publication and that Israel is not commenting on foreign reports.
The IDF recently revealed that the Iranian drone that had infiltrated into Israel was carrying explosives and was intended to execute a terror attack on Israel's territory.
In The New York Times' opinion article, "Are Iran and Israel Headed for Their First Direct War?" it is reported that one of the Iranians killed in the T-4 Airfield strike was Col. Mehdi Dehghan, who was the Revolutionary Guards' Quds Force member who led the drone plan unit.