Federal led home a one-two for trainer Joseph O'Brien in the Paddy Power Supporting Cancer Trials Ireland Irish Cambridgeshire.
The Owning Hill handler saddled just two of 28 runners in the €100,000 feature and the pair ultimately dominated the finish at the end of the Curragh’s straight mile.
The JP McManus-owned Good Heavens was the better fancied of the pair at 13-2 – making his handicap debut following a dominant victory at Cork last month.
Federal had finished four and a half lengths behind his stablemate in the same race and while he was significantly better off at the weights for the rematch, he was much bigger odds at 28-1.
Good Heavens battled his way to the lead inside the final furlong, but was unable to resist the late surge of Federal, who having been ridden with more restraint by 3lb claimer Mikey Sheehy got up to secure top honours by a neck.
O’Brien said: "Mikey gave him a great ride. He’d been off the track for a long time and ran well the last day. He was a talented enough two-year-old but had a bit of trouble with his feet and that’s why he was off for so long.
"He was due to go to Australia but lucky for us he didn’t. The owners’ patience has been rewarded and a lot of people put in a lot of work to get him here.
"I ran him on soft ground here as a three-year-old and shouldn’t have run him that day. He ran well in Cork after being off for ages and we said that we’d give him a shot here with the prize money on offer.
"He looks a stakes horse in the making."
Viareggio wins the Snow Fairy Fillies Stakes!
— The Curragh Racecourse (@curraghrace) August 27, 2022
A brilliant Group 3 success for Shane Foley and Jessica Harrington 🏇@Jessica_Racing pic.twitter.com/6dGvhJHm3M
Viareggio was a comfortable winner of the Snow Fairy Fillies Stakes.
Twice third in Listed company this season, the Jessica Harrington-trained three-year-old significantly boosted her value in this Group Three affair.
Lullaby led them for much of the way, closely attended by Female Soldier, but as things hotted up Galway winner Magic Chegaga moved powerfully – as did favourite Juncture, who looked at one stage like she only needed the splits to come.

But switched for a run, Colin Keane's mount did not pick up as might have been expected and instead it was Shane Foley’s mount who came out on top by two and a quarter lengths from Magic Chegaga.
Aspen Grove claimed a shock victory in the Newtownanner Stud Irish EBF Stakes.
Fozzy Stack's filly had finished fifth and 12th on her first two competitive starts, so it was no surprise to see her go off a 66-1 rank outsider for this Group Three contest.
The daughter of American ace Justify was faced with five previous winners, with course winner Shelton and impressive Leopardstown debut winner Caroline Street the top two in the market.
But with several horses still in with a chance spread across the track racing inside the final furlong, it was Aspen Grove who finished strongest to score by a length and a quarter under Mark Enright – winning his first Group race on the Flat.
Finally, Treasure Trove is a possible for the Breeders' Cup after powering home to secure top honours in the Heider Family Stables Round Tower Stakes at the Curragh.
Making a quick reappearance after landing the Listed Roses Stakes at York a week ago – having been second at this track the week before that – Paddy Twomey’s filly was the 6-4 favourite as she had her sights raised to Group Three company.
Given a patient ride by Billy Lee, the daughter of Siyouni found top gear quickly once popped the question to make significant inroads on the leaders.
Previous course winner Ocean Quest refused to bend against the rail, but Treasure Trove eventually reeled her in to prevail by a short head.
Coralillo and Apricot Twist finished close up in third and fourth respectively.