Terminator Salvation

In 2003, Dr. Serena Kogan (Helena Bonham Carter) of Cyberdyne Systems convinces death row inmate Marcus Wright (Sam Worthington) to sign his body over for medical research following his execution by lethal injection. One year later, the Skynet system is activated, perceives humans as a threat to its own existence, and eradicates much of humanity in the event known as Judgment Day (see Terminator 3: Rise of the Machines). In 2018, John Connor (Christian Bale) leads an attack by the Resistance on a Skynet base. John discovers human prisoners and the plans for the development of a new type of Terminator incorporating living tissue, but is the only apparent survivor of the attack after the base is destroyed in a small nuclear explosion. However, Marcus emerges from the wreckage of the base and proceeds on foot to Los Angeles.John returns to Resistance headquarters located aboard a nuclear submarine and tells General Ashdown (Michael Ironside), the current leader, of his discovery. Meanwhile, the Resistance has discovered a radio frequency capable of shutting down Skynet machines. They plan to launch an offensive against the Skynet base in San Francisco in four days, in response to an intercepted "kill list" indicating that Skynet plans to kill the Resistance's command staff in four days' time. John learns that his own name is second on the list, following Kyle Reese. The Resistance leaders are unaware of Kyle's importance to Skynet, but John knows that it is because Kyle will later become his father (see The Terminator). John meets with his officer Barnes (Common) and wife Kate (Bryce Dallas Howard) and sends radio broadcasts to Resistance members and surviving civilians around the world.Arriving in the ruins of Los Angeles, Marcus is saved from a T-600 Terminator by Kyle Reese (Anton Yelchin) and his mute companion Star (Jadagrace Berry). Kyle relates to Marcus the events of Judgment Day and the ensuing war between humans and machines. Hearing John's radio broadcast, the three leave Los Angeles in search of the Resistance. On the way, they are spotted by a Skynet spy drone that identifies Kyle. They manage to destroy it and escape into the desert.In the desert, Kyle spots a Resistance symbol at a seemingly abandoned 7-11. The man who meets them is hostile and refuses to lend them food or gasoline, but the compound's leader, Virginia, refuses to let the trio leave until Star gets some food. The compound is suddenly attacked by a Harvester which grabs Virginia and a few others. Marcus and Kyle try to escape but are followed by Moto-terminators and an aerial HK. The Moto-terminators are destroyed in the chase but Kyle and Star are captured by the Harvester. The Resistance sends a couple of A-10 Warthogs which are shot down by an HK.Marcus locates downed pilot Blair Williams (Moon Bloodgood) and they make their way to John's base, but Marcus is wounded by a magnetic land mine. Attempting to save his life, the Resistance fighters discover that he is in fact a cyborg with human organs, a mechanical endoskeleton, circuitry, and a partially artificial cerebral cortex. Marcus believes himself to be human, demanding to be released so that he can save Kyle from Skynet, but John orders his destruction. However, Blair releases him and helps him to escape from the base. During the resulting pursuit Marcus saves John's life from Skynet hydrobots, and the two form an alliance. Marcus will enter Skynet's headquarters and attempt to disable its defenses so that John can rescue Kyle.John demands that Ashdown delay the attack so that he can rescue Kyle and the other prisoners, but Ashdown refuses and relieves John of his command. However, John's soldiers remain loyal to him and he sends a radio broadcast asking the other Resistance fighters not to attack Skynet. Meanwhile, Marcus enters the Skynet base and interfaces with the computer, disabling the perimeter defenses and allowing John to infiltrate the cell block and release the human prisoners. The Resistance's disabling signal is revealed to be a ruse, and the command submarine with the Resistance leaders aboard is destroyed by a Hunter-Killer.Marcus discovers that he was created by Skynet and has unwittingly fulfilled his programmed mission to lure John into the base to be killed. He tears out the hardware linking him to Skynet and leaves to assist John in battling a T-800 model 101 Terminator. John is mortally wounded during the fight, but succeeds in destroying the Skynet base by rigging several Terminator nuclear power cells to an explosive, detonating them as he, Marcus, Kyle, and Star are airlifted out. Kate attempts to save John's life, but his heart is too damaged. Marcus offers his heart for transplant, sacrificing himself to save John. Recovering, John radios to the other Resistance fighters that though this battle has been won, the war is far from over. [D-Man2010]

Question: Who is the enemy of the resistance?
Answer: Skynet