In The Force Awakens, before Han Solo gets the Falcon to land in his cruiser, Rey says to Finn, "Someone's locked on to us. All the controls are overridden." I was wondering how this is even possible. Is this described somewhere before The Force Awakens? If something like this is possible, then can this be prevented by using shields?
It is possible to remotely override cockpit controls while you have another ship caught in a tractor beam. The crew of the Death Star did this to the Millennium Falcon.
From the new canon novelization of Episode IV, titled Star Wars: New Hope: The Princess, the Scoundrel, and the Farm Boy:
Luke let out a small gasp of surprise as the ship dropped sharply once and then again. The second drop rattled them around like dice in a cup. A deafening screech of metal against metal made Han wince. The ship had all but belly flopped onto the hangar floor. He hadn’t been able to deploy the landing gear without giving them away.
Finally, someone must have gotten control of the cockpit remotely, because the ship rose on its landing gear. The ship’s boarding ramp creaked as it was lowered.
- Star Wars: New Hope: The Princess, the Scoundrel, and the Farm Boy: Being the Story of Luke Skywalker, Darth Vader, and the Rise of the Rebellion, Alexandra Bracken
Neither this book, nor the novelization of The Force Awakens, explain how this is done.
“Someone’s locked onto us. All our controls are overridden. They’ve taken control of life support, too, for that matter. Easiest way to get us to cooperate.”
“Who’s taken control of us?” Tapping the scanner to remind him that it was useless, she could only shrug helplessly.
Nothing being visible through the front port, he left his seat and headed for the overhead observation dome.
“See anything?” she called back to him.
“Yeah.” There was no need for elaboration. She would see for herself all too soon. Oddly enough, the sight allowed him to relax finally. There is no point in overexerting oneself when all hope is gone.
The other ship was gigantic, an enormous bulky freighter. The cargo bay door was open, and against the open hangar that loomed above, their stolen vessel appeared no bigger than an escape capsule. Its instrumentation frozen, its engines powerless, and its weapons systems dead, the paralyzed ship was drawn inexorably upward into the cavernous opening.
- Star Wars: Episode VII: The Force Awakens, Alan Dean Foster
I'd add to Wad Cheber's answer that, although not explicitly mentioned, the concept of remote hacking is heavily implied in the examples quoted. If you suddenly lose control of your freighter, it seems to have a mind of its own, and you've a hostile capital ship locked on to you...yeah, they probably hacked into your system remotely. Very 21st century, but also very futuristic in the late 1970s.
How is this possible? The thing about remote hacking is that you can only hack into something connected digitally to the outside world (your iPhone pics are only vulnerable if it's connected to the Internet). As early as the Clone Wars, it has been demonstrated that, with or without an astromech, ships can be remotely commanded to lift-off. As long as such wireless gateways exist, it is possible to enter remotely and do more than just take-off, given the right software. I'd imagine that's not too hard for a Star Destroyer when your target is just a smuggler's freighter.
Shields don't do much in this regard. They only stop physical projectiles. A jammer may be more effective though.