The arrests were carried out by officers from the Swedish Security Service (Säpo) which took over the investigation shortly after the attack, which left Federley in hospital with a broken nose and severe bruising.
The two suspects were arrested without incident, according to a statement from Säpo. They are suspected of aggravated assault and aggravated robbery.
The arrests took place at two different addresses in Stockholm, according to Säpo. Arrest warrants had been issued for both suspects at the time.
An order to remand the two suspects must be used by Sunday.
Police continue working to identify two additional suspects, Säpo wrote.
The investigation is being led by head prosecutor Tomas Lindstrand. According to Säpo, Lindstrand has no plans to divulge any additional details because of the sensitive nature of the preliminary investigation.
Federley was attacked outside his home in the Hammarby Sjöstad neighbourhood in central Stockholm last Wednesday, just a few days before the elections.
However Federley, who has been threatened in the past and has had police protection since the 2006 elections, refused to speculate as to whether the attacks were politically motivated.
“I’m constantly under threat, but I can’t talk so much about that, because the more you say, the more you weirdoes you wind up,” Federley told the TT news agency a few days after the attack.