The Atlantis team is waiting for the arrival of a hive ship that they've been tracking on an approach to their planet. Woolsey orders them to engage the cloak rather than bring up the shields, while Sheppard is prepared to launch the drones. The hive ship arrives in orbit… and it doesn't do anything. They pick up a transmission of a file and McKay decrypts it. It's a corrupted broadcast from Todd the Wraith, asking for help for something derived from Keller's gene therapy. Ronon advises them to blow up the ship and Woolsey agrees, but McKay and Teyla suggest they recontact him and ask for more info. They decide to take a cloaked Jumper and make contact to avoid betraying Atlantis' location.
Sheppard's team approaches the hive ship and they don't sense any life signs. McKay suspects the Wraith are hibernating and Sheppard decide they need to go aboard. Woolsey agrees and the team enters the ship and heads for the bridge. McKay confirms the Wraith are in their hibernation chambers and they didn't leave any kind of wake-up signal. There's a power fluctuation. McKay brings up Todd's uncorrupted transmission, and he explains that they've been stricken with a disease that's a complication from Keller's gene therapy, that he stole when they occupied the Daedalus He admits that the gene therapy worked, but the crew sickened and their natural healing couldn't help them. He asks them for help and warns them that he and his crew die, Atlantis' hope of distributing the gene therapy dies with them.
Back on Atlantis, Sheppard suggests they destroy the hive ship but Woolsey believe they need to analyze all the medical data and a few of the Wraith to get a full analysis of the gene therapy. Ronon suggests they keep the formula as-is, but there's no guarantee the disease will affect all Wraith or kill them all. Woolsey orders them to go aboard but take Keller and Lorne's team as backup.
As McKay tries to access the system, one of Lorne's men finds a melting wall and calls in his report. He goes to investigate and a Wraith attacks him, dragging him away.
Keller starts taking samples and determines the gene therapy weakened their immune systems. She's worried she can't handle it but McKay assures her she can handle it. Meanwhile, Sheppard and Lorne's team look for the missing man and find his missing gun. They search the ship with life sign detectors but can't find anything. Sheppard and Lorne find a corridor that ends in a dead-end that doesn't match with the ship's schematics. Ronon and Teyla find the soldier, dead and partially eaten. Lorne picks up a life sign and he and Sheppard follow it to a chamber that is seemingly a dead end. An unmasked Wraith soldier leaps out and the two men manage to kill it. They realize the Wraith soldier was desperate to eat and tried to consume the dead soldier.
Back on the bridge, McKay concludes that the power fluctuations shut down the Wraith soldier's pods and others may have been released as well. Sheppard orders everyone out but a new wall has sealed them off from the dart bay. They take an alternate route but it leads to a giant hole, blocking them off. Back on the bridge, McKay figures that the hive ship is reconfiguring the ship on its own. The communication systems are off-line so they're unable to call Atlantis for help. McKay suggests they release Todd from hibernation despite Keller's warning that the plague will kill him. Navigation begins to go out and McKay warns he can't keep ahead of the malfunctions much longer.
The team frees Todd who maintains his control and determines that the ship is not working correctly because it's infected by the disease. Teyla suggests landing the ship but Todd doesn't recommend it. He suggests they cure the disease and warns they only have four days before the ship is uninhabitable. McKay comes up with a way to override the safety protocols and keep the pods from being released, but it will result in the soldiers suffocating. The team considers the fact that the Wraith are no longer entirely Wraith, and that Todd will object, but they decide not to tell him.
Keller apologizes to Todd, which he finds amusing. Meanwhile, McKay engages the safety protocol override but is unable to do so for one of the chambers. Sheppard grabs some explosives and the team goes to the chamber. One Wraith soldier attacks them and they gun it down, and they proceed to the hibernation chamber. They discover that the pods are open and all of the Wraith soldiers got out.
The team splits up to hunt down the Wraith soldiers and they take them down one at a time. Meanwhile, Todd identifies one of the elements in the gene therapy as the Eratos bug and has Keller summon Sheppard. Todd explains they can undo the gene therapy by having an Eratos bug feed on a Wraith. However, the process is extremely dangerous but he doesn't have another solution. There's a planet with one such bug three days away but Sheppard refuses to okay the procedure. Todd accuses him of placing his people's lives ahead of the Wraiths and they're responsible. Sheppard isn't impressed and Todd charges at him, only to realize he can no longer feed. He points out that Sheppard owes him the choice but Sheppard disagrees and orders him out.
The ship begins to deteriorate and McKay warns that Todd's estimate was optimistic. A crack is spreading across the hull and can depressurize the entire ship at one time. The other teams retreat but Ronon and another soldier are ambushed. Teyla and the remaining Marines manage to save Ronon. However, they're unable to get past one particular door. They try to hold off the advancing Wraith soldiers while Sheppard goes to the door to try to open it. The crack begins to widen and McKay warns them to get out. They get the door open and get out of the section just as the hive ship splits in half. McKay seals off the bulkheads to prevent depressurization of the half that they're in. However, the ship starts to plummet out of orbit.
McKay tries to come up with a plan to use the thrusters and Sheppard goes to get Todd's help. The Wraith welcomes a quick death but Sheppard accuses him of being a quitter and gives his word to take him to the planet with the Eratos. He informs Todd the rest of his crew is dead and he needs to help. Todd goes to the bridge and takes control of the forward thrusters. McKay gets him all the power there is and Todd manages to level off the ship for a landing in the ocean.
Atlantis sends rescue teams and gets everyone back safely. Sheppard talks to Woolsey about the fact Todd isn't responding to treatment. Woolsey questions Sheppard's request to help Todd find the cure against protocol. Sheppard insists Todd is the best ally that they've had and they'll need his help to deploy the gene treatment. Woolsey reluctantly agrees. As Todd departs through the Stargate, he promises to remember Sheppard keeping his word.