Romulan cloaking device theft

Kirk and Spock steal a Romulan cloak

Under secret orders, Kirk took the Enterprise into the Romulan Neutral Zone, faked his own death and stole a Romulan cloaking device while Spock distracted the Romulan commander.

In 2268 Starfleet learned that the Romulans had developed an improved cloaking device and ordered Kirk to obtain it. Kirk pretended to be under strain and took the Enterprise into the Neutral Zone, where it was surrounded by three Romulan warships of a design associated with the Klingons. Kirk and Spock were taken to the flagship, and Spock appeared to betray his captain, telling the Romulan commander that Kirk had acted alone.
Kirk then attacked Spock, who appeared to kill him using a technique he called the Vulcan death grip. Back on the Enterprise, McCoy revived Kirk, who had only been rendered unconscious. Kirk's appearance was surgically altered to look Romulan, and he boarded the flagship and took the cloaking device while Spock kept the commander occupied with talk of an alliance and a growing personal attraction.
Scott installed the device on the Enterprise as the Romulans closed in. Spock was rescued just in time, and the commander was brought aboard as a prisoner. The ship cloaked and escaped, giving the Federation the device it had been ordered to retrieve.